Forum Rule: Always post complete source code & details to reproduce any issue!

Search:

Type: Posts; User: defragster

Search: Search took 0.02 seconds.

  1. Button usage in another thread pointed to this:...

    Button usage in another thread pointed to this: https://www.pjrc.com/teensy/td_libs_Bounce.html

    Looking suggests this might be better - though perhaps not ideal.


    static int SawButton = 0;
    ...
  2. You did okay with the if() watching for the...

    You did okay with the if() watching for the button. Just because there is an if() doesn't mean you need an else. If your case the off things stay off [you might want to set them off in setup()]. ...
  3. @grayfx: The loop() is called as often as nothing...

    @grayfx: The loop() is called as often as nothing pauses the loop ... as often as the loop exits, and it checks the buttons on entry. Any time you are in delay() buttons will be missed.

    I think...
  4. Not sure how the button code runs - catching the...

    Not sure how the button code runs - catching the risingEdge is going to be a quick single event. As I see this the delay(1000) is where most time will be spent and for that second - unless the...
Results 1 to 4 of 4