Question: Modify the function loop() that prints the state of on_off, so that on_off is initially and switches from 0 to 1 and back from 1
Modify the function loop() that prints the state of on_off, so that on_off is initially and switches from 0 to 1 and back from 1 to 0 every time the digitalRead(13) steps up from 0 to 1. Hint: use prev_read to keep track of the previous reading of pin 13. 7777 DON'T CHANGE THIS typedef std::vector
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
