int val =analogRead(plugPin);
if( val = (warningThreshold >= .001)){
analogRead returns integers (whole numbers) between 0 and 1023. If you get anything other than zero, your if-statement will be true. It's not unusual to have noise or bias on the analog inputs, so you may never read that low, or the value could jump-around between zero and something else...
What kind of
voltage do you have (or what do you expect) with the phone plugged-in or unplugged?
Try using the
Analog Serial Read Example to see what kind of analog readings you are getting (with your actual analog input instead of the pot).
He wants the card to identify when the phone is plugged in. What does he need to use?
We don't know! We don't know what the phone is plugged-into, or how the phone is connected to the Arduino, etc.