Autonomous Light-Following Flower Robot
Author: Serban Lidia-Andreea
GitHub Project Link: https://github.com/UPB-PMRust-Students/fils-project-2026-lidiaserban
Description
The Autonomous Light-Following Flower Robot is a bio-inspired system that mimics plant phototropism by navigating toward the strongest light source using dual photoresistors and an STM32 Nucleo U545RE-Q. Built with the Embassy framework for asynchronous control, it balances light-seeking with active obstacle avoidance via ultrasonic sensors while monitoring environmental conditions through a DHT22 sensor and LCD. The robot utilizes a dual-rail power strategy to isolate high-torque motor noise from sensitive logic, ensuring stable, real-time performance in a standalone package.
Motivation
My motivation for this project is to apply embedded systems engineering to a nature-inspired concept. I chose a light-following robot because it provides a practical way to learn how the STM32 Nucleo U545RE-Q handles real-time sensor data and motor control. The project requires me to use the Embassy framework to solve a specific technical challenge: prioritizing obstacle avoidance while concurrently tracking light sources. Additionally, implementing a dual-rail power system with a DC-DC converter allows me to explore power management and noise isolation between high-current motors and sensitive logic circuitry.
Architecture
┌───────────────────────────┐
│ PRIMARY POWER SOURCE │
│ (4x Batteries) │
└─────┬───────────────┬─────┘
│ │
│ ┌──────▼──────────────────────────┐
│ │ DC-DC VOLTAGE CONVERTER │
│ │ (High-Current / Motor Rail) │
│ └──────────────┬──────────────────┘
│ │
│ ▼
┌────── ──────▼────────────┐ ┌──────────────────────────┐
│ STM32 U545RE-Q │ │ L9110S DRIVER │
│ (Logic / Brain Rail) │ │ (Motor Control H-Bridge)│
└────────────┬────────────┘ └──────────────▲───────────┘
│ │
├──────────────────────────────┘
│ (PWM Speed Control)
│
┌───────┴───────┬───────────────┬───────────────┐
│ │ │ │
┌────▼────┐ ┌─────▼─────┐ ┌─────▼─────┐ ┌─────▼─────┐
│ LIGHT │ │ DISTANCE │ │ DHT22 │ │ LCD 16x2 │
│ SENSORS │ │ (HC-SR04) │ │ (Temp/Hum)│ │ (Status) │
└─────────┘ └───────────┘ └───────────┘ └───────────┘
Log
Week 5 - 11 May
Week 12 - 18 May
Week 19 - 25 May
Hardware
The system is based on the STM32 Nucleo U545RE-Q microcontroller, which manages data processing and control. Light detection is performed using photoresistors, while an ultrasonic sensor provides obstacle detection and a temperature–humidity sensor monitors environmental conditions. Movement is achieved using DC motors controlled by an H-bridge driver with PWM signals. The structure includes wheels and a caster for stability. Power is supplied by a battery and regulated with a DC-DC converter. An LCD display is used to present system data.
Schematics
Place your KiCAD or similar schematics here in SVG format.
Bill of Materials
| Device | Usage | Price |
|---|---|---|
| STM32 Nucleo U545RE-Q | The microcontroller | ~130 RON |
| DC Motors | The DC motors | ~15 RON |
| Ultrasonic sensor | Distance sensors | ~11 RON |
| Photo rezistors | Light sensors | ~10 RON |
| Movement | Wheels | ~11 RON |
| Support caster ball | Caster | ~4 RON |
| Baterry case | Baterry holder | ~5 RON |
| Driver for motor | H-Driver for motors | ~8 RON |
| Module for humidity sensor | Humidity sensor module | ~7 RON |
| Humidity and temperature sensor | Humidity and temperature sensor | ~18 RON |
| Adjustable DC voltage reducer module | DC-DC voltage converter module | ~28 RON |
| LCD | LCD Display | ~23RON |
| Total ~= 275RON |
Software
| Library | Description | Usage |
|---|---|---|
| embassy-stm32 | Hardware Abstraction Layer (HAL) for STM32 | Configures GPIO, ADC for light sensors, and PWM for motors |
| embassy-executor | Async runtime for embedded systems | Manages concurrent tasks like obstacle detection and movement |
| hd44780-driver | LCD Controller library | Displays temperature, humidity, and status on the 16x2 LCD screen |
| dht-sensor | DHT22 Driver | Specifically used to parse the digital signal from the DHT22 temperature and humidity sensor |
| panic-probe | Debugging tool | Helps you see errors in VS Code if the sensor fails to initialize |
| embassy-time | Timekeeping and delays | Provides the microsecond-precision delays needed to "handshake" with the DHT22 and measure its data pulses |
Links
- Embassy Book
- link ...