This week, I’m working on Asmaa’s MoodMate, a device that visually communicates my mood through an RGB light and an LCD screen, controlled via an Android GUI. The idea is simple:
When I’m stressed, the RGB turns red, and the LCD displays “Asmaa is stressed now”.
When I’m calm, the RGB turns blue, and the LCD displays “Asmaa’s calm now”.
(Additional moods can be added based on preferences.)
I care about this idea because everyone experiences hard times, but we often struggle to communicate our emotional state. Many of us find it difficult to express that we don’t feel like talking without worrying about making others feel uncomfortable. Sometimes, we simply need personal space without having to explain ourselves.
Why does this matter?
I believe that respecting personal boundaries is important and this project can help people communicate their emotional state in a way that is clear, yet gentle.
What inspired me?
My inspiration comes from personal experiences where I felt overwhelmed but didn’t want to embarrass or disappoint others by saying I couldn’t talk. I realized that a simple signal—like a color change or a short message—could make it easier for others to understand and respect my space.
Hardware Components & Materials:
Breadboard – To easily connect and test all electronic components before finalizing the wiring.
LCD 1602 with I2C Module – To display mood messages like “Asmaa is stressed now” or “Asmaa’s calm now” in a clear, readable way. The I2C module was used to simplify wiring by reducing the number of connections required.
RGB LED – To visually indicate different moods using color changes (e.g., red for stress, blue for calm).
Jumper Wires – To establish electrical connections between components.
Bluetooth Module (HC-05/HC-06) – To enable wireless communication between the Arduino and the Android app, allowing me to control the outputs via my phone.
Cardboard – Used as the physical structure for the project, creating a neat and organized setup to hold the electronics in place.
Glue Gun – To assemble and secure the cardboard enclosure, ensuring the project is well-structured and durable.
Software & Tools:
Arduino IDE – To write and upload the Arduino C code that controls the hardware components.
Android Bluetooth Control App – This Android application was used to send commands wirelessly to the Arduino via Bluetooth, allowing me to change the mood state manually.
At first, I came up with the idea of a simple yet expressive way to communicate my mood without needing to say a word. I planned to use an RGB LED to visually indicate different moods and an LCD 1602 I2C display to show corresponding text messages. The idea was to control everything wirelessly using an Android app via a Bluetooth module.
I started by defining the four different moods and their corresponding LED colors and messages:
Pressing '1' on the app: The Red LED lights up, and the LCD displays "Asmaa's Stressed" to signal that I need space.
Pressing '2': The Green LED lights up, and the LCD shows "Relaxed!" to indicate that I’m in a good mood.
Pressing '3': The Blue LED lights up, and the LCD displays "Deep Focus", letting others know that I’m concentrating.
Pressing '4': The Purple LED lights up, and the LCD humorously states "COFFEE is needed", signaling that I’m running low on caffeine and energy.
Once I finalized the mood-to-message mapping, I moved on to the wiring.
The Bluetooth module connects to an Android phone via a Bluetooth control app.
The app sends commands ('1', '2', '3', or '4') over serial communication to the Arduino.
The Arduino reads the received data using Serial.read().
Based on the received number:
The RGB LED changes color accordingly.
The LCD displays the corresponding message.
The setColor() function sets the appropriate PWM values for the RGB LED to achieve the desired color.
I first tested everything on a breadboard, ensuring each component worked correctly. After verifying the Bluetooth communication and LCD response, I finalized the setup and secured the circuit components inside a cardboard enclosure . I used a glue gun to hold the circuit in place and made cutouts to display the LCD and allow easy visibility of the RGB LED.
#include <Wire.h>
#include <LiquidCrystal_I2C.h>
Wire.h: Enables communication with I2C devices (like the LCD).
LiquidCrystal_I2C.h: Library for controlling an LCD with an I2C interface.
LiquidCrystal_I2C lcd(0x27, 16, 2);
Creates an LCD object with the I2C address 0x27, 16 columns, and 2 rows.
This means the LCD can display two lines of text, each 16 characters long.
const int redPin = 9;
const int bluePin = 11;
Defines the RGB LED pin connections.
Here, only Red and Blue pins are used (Green is missing).
void setup() {
Serial.begin(9600);
Initializes serial communication at 9600 baud rate for Bluetooth connection.
lcd.init();
lcd.backlight();
lcd.clear();
lcd.setCursor(0, 0);
lcd.print("Bluetooth Control");
Initializes the LCD, turns on the backlight, and displays "Bluetooth Control".
pinMode(redPin, OUTPUT);
pinMode(bluePin, OUTPUT);
Sets RGB LED pins as OUTPUT.
digitalWrite(redPin, LOW);
digitalWrite(bluePin, LOW);
Turns off all LEDs at startup.
if (Serial.available() > 0) {
char command = Serial.read(); // Read the incoming command
Checks if a Bluetooth command has been received.
Reads the command as a single character ('1', '2', '3', etc.).
switch (command) {
Uses a switch-case to handle different Bluetooth commands.
case '1':
setColor(255, 0, 0); // Red
lcd.clear();
lcd.setCursor(0, 0);
lcd.print("Asmaa's Stressed");
break;
Turns on the Red LED (full brightness, 255).
Clears the LCD and displays "Asmaa's Stressed".
case '2':
setColor(0, 0, 255); // Blue
lcd.clear();
lcd.setCursor(0, 0);
lcd.print("Deep focus");
break;
Turns on the Blue LED (full brightness).
Displays "Deep focus" on the LCD.
case '3':
setColor(128, 0, 128); // Purple
lcd.clear();
lcd.setCursor(0, 0);
lcd.print("COFFEE is needed");
break;
Combines Red (128) and Blue (128) to create Purple.
Displays "COFFEE is needed" on the LCD.
default:
setColor(0, 0, 0); // Off
lcd.clear();
lcd.setCursor(0, 0);
lcd.print("No command");
break;
Turns off the LED (sets brightness to 0).
Displays "No command" on the LCD.
void setColor(int red, int green, int blue) {
analogWrite(redPin, red);
analogWrite(bluePin, blue);
}
Controls the brightness of the LED colors using PWM (analogWrite).
Problem: Green LED pin is missing! (should be added to support full RGB colors).
Bluetooth Module (HC-05/HC-06):
TX → Arduino RX (pin 0) (Used a voltage divider: 1kΩ + 2kΩ to step down 5V to 3.3V)
RX → Arduino TX (pin 1)
VCC → 5V
GND → GND
RGB LED (Common Cathode):
Red pin → Arduino pin 9
Green pin → Arduino pin 12
Blue pin → Arduino pin 11
Cathode (common) → GND
LCD 1602 I2C Display:
SDA → Arduino A4
SCL → Arduino A5
VCC → 5V
GND → GND
After finalizing the circuit design and ensuring it worked properly on the breadboard, I moved on to implementing the final setup inside a cardboard enclosure.
Step 1: Assembling the Circuit in the Enclosure
I carefully mounted the breadboard and Arduino inside the cardboard box, making sure all components were securely placed.
The LCD screen was positioned at the front of the box, ensuring visibility for easy reading of the displayed messages.
The RGB LED was placed in a way that its colors could be clearly seen, making mood indications obvious.
I made a small opening in the cardboard for the Arduino's cable, so I could easily connect it to the lap top.
Step 2: Final Wiring Adjustments
After mounting the components, I neatly reconnected the jumper wires to prevent loose connections.
I ensured that the Bluetooth module’s TX/RX pins were correctly wired, and the logic level was adjusted properly.
Step 3: Connecting the Android App to the Bluetooth Module
I used the Android Bluetooth Controller app to pair my phone with the HC-05 Bluetooth module.
I tested sending commands (‘1’, ‘2’, ‘3’, and ‘4’) to check if the RGB LED changed colors and the LCD displayed the correct messages.
Everything worked as expected, but I made small refinements in the Arduino code to ensure smooth transitions between different moods.
Step 4: Securing the Enclosure & Final Testing
I performed one final test to ensure:
The LED lights up in the correct color when I press a number on the app.
The LCD correctly displays the corresponding message.
The Bluetooth connection remains stable during operation.
Asmaa's MoodMate Final Project
Seeking Feedback & Troubleshooting
My first option was using DeepSeek to generate and refine my Arduino code. While it helped structure the code efficiently, I still encountered some issues in implementation.
I then reached out to Yassin, my instructor, as I was struggling with some parts of the Arduino code logic and Bluetooth communication.
Whenever I got stuck, my first approach was to research online and experiment with different solutions. However, when I couldn't resolve the issue myself, I turned to Yassin for guidance.
Challenge with Processing GUI vs. Android App
Since I don't have an Android device, I initially decided to use Processing GUI on my Laptop instead of an Android app to control the MoodMate. I spent a lot of time trying to get it to work, and while the system functioned properly when the Arduino was connected via USB, it completely failed when I powered it using a 5V adapter instead of the laptop.
Despite multiple trials and debugging attempts, I couldn’t figure out why it wasn’t working.
How I Overcame the Issue
During the offline session, Yassin advised me to use an Android device instead of Processing, and he allowed me to test my project using his phone. This solved the issue immediately, confirming that my approach with Processing had some underlying compatibility issues that I wasn't aware of.
Mistakes & Lessons for Others
One major mistake I made was spending too much time troubleshooting Processing without consulting an expert sooner. If I had asked for advice earlier, I could have saved a lot of time and effort.
So, my advice to others would be:
-Ask your instructor early about the pros and cons of different approaches before committing to one.
-Test power sources separately to ensure that the system runs independently of the PC before finalizing the design.
-Always have a backup plan in case your first solution doesn’t work out.
This experience taught me the importance of seeking guidance at the right time instead of getting stuck in endless trial and error.
Title of Media
Title of Media
We made a wirelessly controlled Micro Robot Arm in a short amount of time! 🚀
Mariam, Rabab, and I worked together as a team and even though we didn't win, we had a great time collaborating together. The experience reminded me that teamwork and enjoying the process matter more than the outcome. الكنز في الرحلة