Hi all
anyone know how to reset a pushbutton counter back to zero?
I want to get my arduino to send the integer value as an sms, but once it has done that I want it to reset the counter back to 0!
ive got int myval = 0; in declarations and myval++; in the loop
Thanks a lot
Hi,
In your program, the next line after you send the SMS
myval=0;
Can you please post a copy of your sketch, using code tags?
They are made with the </> icon in the reply Menu.
See section 7 http://forum.arduino.cc/index.php/topic,148850.0.html
Tom..... 
It's a pushbutton counter. Why not call it "buttonCount" or something meaningful instead of "myval" which only says that it's a value (which you know already) and that it's yours (which you know already).
of course! thanks Tom. I just tell it that it is now 0.
thanks a lot
and yes will put code in proper format