I have been looking a modifying some code and cant understand what the defines the true conditional in the while function.
while(true){//keeps running while true but what makes it true?
if (digitalRead(hall_pin)==0){//every time hall is switched to 0 run if
if (on_state==false){//already set to false so make true
on_state = true;
hall_count+=1.0;//count = (hall_count + 1.0) + new value of hall_count
}
Any shafts of enlightenment?
Thanks
kev