Disko cat
The idea came to me from Disco lights that constantly change colors and create a fun atmosphere. I wanted to replicate this concept on a smaller scale using Arduino. The objective was to design a smart circuit where I could wirelessly control RGB LED colors through my phone, and at the same time display the selected color on an LCD screen. This made the project both visually attractive and functional, while also aligning with the course requirements.
For this project, I used:
Software: Arduino IDE for programming, wokwi for circuit design and wiring simulation.
Components: Arduino UNO board, Bluetooth module (HC-05), RGB LED, LiquidCrystal I2C LCD screen, breadboard, jumper wires, and USB cable.
Materials/Tools: Breadboard for implementation, laptop for coding, and a mobile phone with a Bluetooth terminal app to send commands.
wokwi circuit
Before building the circuit on a breadboard, I used wokwi as a simulation and design tool. It allowed me to place the Arduino Uno, the RGB LED,on a virtual workspace and wire them correctly without any risk of damaging real components. I tested the pin assignments for the RGB LED (pins 3, 5, and 6), the SoftwareSerial connection for the Bluetooth module (pins 10 and 11), and the I2C connections for the LCD (SDA to A4 and SCL to A5).
The simulation helped me debug the wiring and check the logic of the Arduino code before implementation. For example, I could easily test how each color command sent via Bluetooth changes the RGB LED and updates the LCD display. Once the design worked virtually, I documented the wiring connections with screenshots, so I had a clear reference for the physical implementation on the breadboard.
Code Explanation
The code uses an RGB LED controlled by Arduino with a Bluetooth module and an LCD I2C screen
At the beginning, the libraries for I2C LCD Wire and SoftwareSerial are included then the LCD object is created with address 0x27 and size 16x2 and the Bluetooth is set on pins 10 RX and 11 TX
Three pins are defined for the RGB LED red on pin 3 green on pin 5 and blue on pin 6
In setup the LCD is initialized and the backlight is turned on the RGB pins are set as output the Bluetooth starts at 9600 baud and a welcome message is displayed on the LCD
In the loop the Arduino checks if Bluetooth sent a command If a character is received it compares the value If R is sent the LED turns red and the LCD displays Color RED If G is sent the LED turns green and the LCD shows Color GREEN If B is sent the LED turns blue If Y is sent the LED mixes red and blue to make purple If P is sent the LED mixes red and green to make yellow If W is sent the LED lights red green and blue to make white The LCD is updated each time
The setColor function takes three values red green blue and sends PWM signals to the LED pins to mix colors
Connections
RGB LED cathode goes to GND
RGB LED anode red goes to pin 3 with a resistor
RGB LED anode green goes to pin 5 with a resistor
RGB LED anode blue goes to pin 6 with a resistor
LCD I2C VCC to 5V GND to GND SDA to A4 SCL to A5
Bluetooth module VCC to 5V GND to GND RX to Arduino pin 11 TX to Arduino pin 10
In my smart circuit, I connected all components as follows:
RGB LED:
Red pin → Arduino D3 (PWM)
Green pin → Arduino D5 (PWM)
Blue pin → Arduino D6 (PWM)
Common cathode → GND through 220Ω resistors for each color pin.
LCD (I2C 16x2):
VCC → 5V on Arduino
GND → GND
SDA → A4
SCL → A5
Bluetooth Module (HC-05):
TX → Arduino D10 (Bluetooth TX → Arduino RX in SoftwareSerial)
RX → Arduino D11 (Bluetooth RX → Arduino TX in SoftwareSerial, sometimes with a voltage divider to avoid 5V on RX)
VCC → 5V
GND → GND
One of the main challenges I faced was identifying the correct order of the RGB LED pins. At first, I did not know the exact arrangement of the Red, Green, and Blue terminals, which caused the colors to appear incorrectly when I ran the circuit. I solved this problem by testing several pin configurations until I found the right order that produced the intended colors. This trial-and-error process helped me better understand how RGB LEDs work and reminded me of the importance of checking datasheets or documentation before wiring.
This week, I gained practical experience in integrating and programming an LCD with Arduino. In my final project, I will also use an LCD as a main component to display important information and feedback to the user. The skills I acquired—such as initializing the LCD, controlling its display, and updating messages dynamically—will directly help me implement the LCD in my final project more efficiently.