EmotiBuddy
Your Pocket AI Companion
Author: Braniste Andrei-Cristian
GitHub Project Link: https://github.com/UPB-PMRust-Students/proiect-branistecristian
Description
EmotiBuddy is a pocket-sized AI emotional companion that listens to simple voice commands or sound triggers and responds with voice messages, animated OLED expressions, and motivational phrases. It connects via WiFi to cloud APIs for enhanced AI interactions.
Motivation
I chose this project because I wanted to build a device that provides emotional support and interactive companionship, especially during moments when it's most needed. The idea of having an AI "buddy" that can lift your mood, respond to your thoughts, or simply engage in meaningful interaction is both exciting and impactful. I believe such an instrument could enhance daily life by offering a sense of connection and comfort through technology.
Architecture
- User Interaction: Captures audio input (voice / clap / whistle) via microphone.
- Processing Core: Raspberry Pi Pico W handles sound detection, AI message requests, and control flow.
- Cloud Interaction: Sends API requests (e.g., OpenAI) via WiFi when needed.
- Audio Output: Plays back pre-recorded motivational audio clips via DFPlayer Mini or a TTS UART module.
- Visual Output: Displays emotional faces (happy, sad, excited) on the OLED screen based on interaction.
- Power Supply: A rechargeable Li-ion battery powers the device through a TP4056 charging and protection module, allowing full portability.
Log
Week 5 - 11 May
Week 12 - 18 May
Week 19 - 25 May
Hardware (not final!)
Raspberry Pi Pico W
- Purpose: Main controller
- Function: Handles all logic, controls modules, reads inputs, and sends/receives API data via WiFi (OpenAI API). It coordinates voice input, playback, emotional state rendering, and user interactions.
MAX9814 Microphone (with optional INMP441 I2S mic)
- Purpose: Captures voice input
- Function: Currently, the MAX9814 provides analog audio signals read via ADC. In the future, the INMP441 I2S digital microphone may be used if I2S functionality is implemented manually using PIO on the Pico.
DFPlayer Mini MP3 Module (planned upgrade to TTS module)
- Purpose: Voice response output
- Function: Plays motivational audio responses stored on a microSD card. It is currently used for pre-recorded responses, but it may later be replaced by a UART-based TTS module to allow dynamic speech generation from AI output.
3W Speaker
- Purpose: Outputs audio
- Function: Connected to the DFPlayer Mini, it plays the responses from the AI output.
I2C OLED Display (0.96")
- Purpose: Visual emotion feedback
- Function: Displays expressive facial animations (emojis) that reflect the AI’s current mood or response, enhancing emotional interaction with the user.
Push Button
- Purpose: Triggers interaction
- Function: Allows the user to wake up the AI Companion.
TP4056 Charging Module + 18650 Battery
- Purpose: Portable power system
- Function: Powers the entire system with a 2500mAh rechargeable Li-ion battery. The TP4056 module allows safe USB charging and voltage regulation.
Schematics
Bill of Materials
Device | Usage | Price |
---|---|---|
Raspberry Pi Pico W (RP2350) | Main controller with WiFi | ~40 RON |
MAX9814 Microphone Module | Voice input via analog signal | ~12 RON |
DFPlayer Mini MP3 Module | Pre-recorded voice response playback | ~14 RON |
Speaker 3W 4Ω 40mm | Audio output from DFPlayer | ~10 RON |
OLED Display 0.96'' I2C | Visual display for AI face and emotions | ~21 RON |
TP4056 Charging Module | Battery charging and protection | ~6 RON |
Samsung 18650 25R 2500mAh Battery | Power source | ~26 RON |
Push Button | Triggers interaction or startup | ~1–2 RON |
MicroSD Card (8–16 GB) | Stores MP3 files for DFPlayer | ~40 RON |
Breadboard + jumpers | Wiring and prototyping | ~40 RON |
Software (not final!)
Library | Description | Usage |
---|---|---|
rp2040-hal | Low-level hardware abstraction layer for the RP2040/RP2350 microcontroller | Used to control GPIOs, ADC, I2C, UART, and peripherals |
embedded-hal | Generic hardware abstraction traits for embedded systems | Used by drivers like OLED and DFPlayer for hardware access |
ssd1306 | OLED display driver over I2C/SPI | Used to control the 0.96" I2C OLED for rendering the AI face |
embedded-graphics | 2D graphics library for embedded devices | Used to draw faces, text, and icons on the OLED screen |
ufmt | Minimal core::fmt -like formatting for no_std | Used for lightweight logging and debugging |
heapless | Fixed-size no_std data structures like Vec and String | Used for storing incoming/outgoing messages efficiently |
defmt | Highly efficient logging framework for embedded Rust | Used to debug easily without panicking the board |
probe-rs | Flash, debug, and trace embedded devices | Used for uploading code and flashing the Pico W |
embassy | Async embedded framework | Optional: used if multitasking (like WiFi + display + sound) is needed |