DesignSpark Electrical Logolinkedin
Menu Search
Ask a Question

Working with two LEDs and Arduino

This project demonstrates working with two LEDs and Arduino.

Parts List

Qty Product Part number
1 × Arduino UNO 715-4081
1 × Breadboard 102-9147
2 × Resistor (1k ohm) 707-7666
4 × Jumper wires 505-3403
1 × Red LED 228-5988
1 × Yellow LED 228-6010
See more products


  • Blinking of two LEDs (alternating)
  • Fading effect of two LEDs (alternating)


Circuit Diagram


Schematic Diagram


Breadboard Diagram





I am a mechanical Engineer.


May 20, 2019 07:16

Nice simple code for the dimming. Here is a challenge; make the dimming use a square law curve so the dimming will appear to be linear. ie When the loop is at 50% the light should appear to be at 50% it now appears to be 75%. This is due to the human eye perception of the intensity of light and it is not linear.

Good work

0 Votes