Break
From Microduino Wiki
- break
Break is used to exit do, for, and while loop, and it can skip the common judge condition. And it can also exit the switch statement.
- Example
for (x = 0; x < 255; x ++) { digitalWrite(PWMpin, x); sens = analogRead(sensorPin); if (sens > threshold){ // beyond test range x = 0; break; } delay(50); }