This is also my first attempt at trying to debounce a switch and to make it pause and start the running lights.
It worked out quite well =)
What i used for this project was (beside the Arduino):
- 9 LED's
- 9 330ohms resistors (R1-R9)
- 1 10Kohms pull-up resistor (R10)
- 1 10Kohms pot (P1)
- 1 Switch (K1)
Other legends for the wire diagram beside the above:
- DP - Arduino digital pin (DP4 = pin 4 on Arduino)
- A0 - Arduino analog pin 0
- V5 - 5v pin
- GND - Arduino ground pin
The wire diagram
The code: