I just started a project to control an irrigation pump remotely using text messages. Arduino Uno and GSM shield.
It is not too hard to simply say "pumpon" in a text message and have it turn on the pump. Where I am having a problem is when I get more complicated. I would like to do 3 things at once. I would like to be able to send the pump a length of time to be on. Time frames being 2, 4, 6, 8, 10, or 12 hours. i.e. "pumpon12" While the pump is in its timing sequence I would also like to monitor a fault input and send a text message to my phone if a fault were to occur. I would also like to monitor an analog pressure input and and send myself a message if the pressure were to go out of a certain threshold.
If I simply put in a delay for 12 hours to hold the pump on for that time I am unable to monitor the fault or the pressure inputs. I want to learn how to do this but I just don't know where to begin looking. I looked under interrupts which seem sort of promising but I don't think I fully understand what they do or how to use them. Maybe a timer might have a chance here but I really just don't know what might the easiest route. Also with my current knowledge of using delays says to input 12 hours I need delay(43200000) I am not sure if that is even possible and I haven't been patient enough to find out.
Thank you in advance for you help,
You all are amazing!
Jake