Little help here please


i have arduino uno , want use pushbutton turn on led turn off 1 push turns on 2 push turns off idea how might , going using 4 pushbuttons. thanks

you use count push button presses.

eg

int buttoncount = 0;

if (button == high) // if pressed
{
if(buttoncount == 0)
{
turn on
buttoncount++;
}
if(buttoncount == 1)
{
turn off
buttoncount = 0;
}
}


Arduino Forum > Using Arduino > Programming Questions > Little help here please


arduino

Comments

Popular posts from this blog

VIDIOC_S_FMT error 16, Device or resource busy - Raspberry Pi Forums

using a laptop skeleton to build a pi laptop - Raspberry Pi Forums

Forum for Joomla? - Joomla! Forum - community, help and support