Fading LED
In this project, you'll learn how to control the brightness of a LED.
You can control the brightness of a LED by specifying how much power you provide to it. This is done by using an analog signal instead of a digital signal.
The analog output pins on the Arduino board are labeled with a ~ symbol. They are pins 3, 5, 6, 9, 10 and 11.
Parts needed:
|
| |
| 1 | Making the connections
|
|
| 2 | Create a new Bare Minimum program by selecting File from the menu
Then type in this program. Just like the |
|
| 3 | Run the program and notice the brightness of the LED. | |
| 4 | Change the fadeValue from 14 to another number between 0 and 255. Run the program and notice the difference in the brightness of the LED. | |