Hi everyone,
I have a project which involves Annikken Andee, a bluetooth shield which is connected to Arduino. I encountered a problem where my programme keeps going to the initial state after a loop sequence. Below is a part of my programme.
void setup{
UGVbutton1.setId(0);
UGVbutton1.setColor(LIGHT_SALMON);
UGVbutton1.requireAck(true);
}
void loop {
if(UGVbutton1.isPressed())
{
UGVbutton1.ack();
UGVbutton1.setColor(THEME_RED_DARK);
UGVbutton2.setColor(LIGHT_SALMON);
UGVSelect = 1;
}
}
So for example if i press the button, button will turn into THEME_RED_DARK in colour. However, after about 5 seconds when the programme finished its loop, it will go back into its original colour.
One thing i want to clarify is that the main programme will not run the void setup loop after finishing the void loop. Correct me if i am wrong.
Thank you for the help.