Please, help me ! As we write in arduino, if a condition is not met, it stops the program, otherwise, it continues
Define "stops"
stop the program execution
while (!condition) { }
My program:
If level_1 is between 650 and 670, the program works normally, otherwise it stops the program.
#define EVER (;;)
if (condition)
{
...do stuff
}
else
for EVER;
Thank you for help !
computers typically can't be "stopped", they can do nothing , or probably in your case, do nothing while the value is outside your limits, 650 and 670
int level_1 = analogRead (A0);
if (650 <= level_1 && level_1 <= 670)
doSomething();
// othersize do nothing
Thank you !