You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1

Using analogWrite

  • Not only can you blink LED, dimming LED is also possible.
  • Depending on the Arduino you have, the number of pin that supports native output PWM varies.

Pre-requisite:

  1. Finished Add an external LED and, another button
  2. Basic circuit knowledge

Objectives:

  1. Dim the LED

Descriptions:

  1. You already know how to connect an LED to the Arduino board.
  2. This time, you need to connect the LED the same way but into different output number that supports PWM( what is this ) output
    In other word, with "~" by the side of the number of PIN.
  3. Let's connect the LED to pin 9 as refer to : http://arduino.cc/en/Tutorial/Fade

  4.  PWM is "Pulse-width modulation", please refer to : http://arduino.cc/en/Tutorial/PWM

 


  • No labels