Guided tutorial

Mood Lamp

Create a color-mixing lamp using RGB LED and potentiometers.

beginner · 25 Sept 2026

Difficulty

beginner

Learning complexity

Sections

6

Structured content blocks

Topics

7

Linked learning concepts

Related links

5

Next steps and references

1. What you will build

Create a color-mixing lamp using RGB LED and potentiometers.

2. Wire RGB LED

Connect RGB LED to PWM pins 9, 10, 11 for R, G, B.

3. Add 3 Pots

Connect 3 potentiometers to A0, A1, A2 for color control.

4. Read Values

Read each pot and map to 0-255 for PWM.

5. Mix Colors

Apply values to RGB pins to mix any color.

6. Add Effects

Press a button to cycle through preset colors or modes.

FAQ

Can I try Mood Lamp in the simulator?

Yes. Use the Open in Lab action to load the guided build in the browser-based simulator.

Next step

Open this tutorial in the lab

Load the guided build in Ayantrik Lab and follow the same components and steps inside the simulator.