2025-11-08 1:48 AM - last edited on 2025-11-10 9:40 AM by Andrew Neil
I’m working on a project that requires bidirectional communication between daisy-chained STM32F103C bluepill boards and an ESP8266. I’m using a master-slave architecture and UART for initial testing and prototyping. The chain has 3–6 STM32 boards.
Right now I’m having trouble getting reliable two-way data transfer between the ESP8266 (master) and the STM32 boards (slaves). Can anyone help me get this working?
2025-11-08 6:10 AM
Here are multiple examples for UART on the STM32F1 series.
Get one of these working, then use it as a code base for your own project.
2025-11-10 9:39 AM - edited 2025-11-10 9:43 AM
Note that BluePill is not an ST Product, and likely will not have a genuine STM32 fitted.
@its-nott-me wrote:bidirectional communication between daisy-chained STM32F103C bluepill boards and an ESP8266. ?
What, exactly, does that mean?
A diagram would probably explain best...
@its-nott-me wrote:Right now I’m having trouble getting reliable two-way data transfer between the ESP8266 (master) and the STM32 boards (slaves).
So what, exactly, have you tried?
And what, exactly, is/are the problem(s) you're having?
As always, the secret is to not try to do everything all at once - see this.
As @TDK says, there are plenty of examples of doing UART serial comms on STM32; no doubt there are also plenty of examples of doing UART serial comms on ESP32 ESP8266...
Test each part on its own before bringing them together.
Tips specifically on Debugging Serial Comms.
PS:
Corrected ESP32 to ESP8266 - although the principles remain the same for communications between any two devices.
2025-11-15 10:18 AM
Your first post says you are using UART, now you say you are using SPI. Might want to present a consistent story. They are handled quite differently. There are examples for both.
2025-11-15 10:29 AM
I tried UART, didn't work as expected.. so now I am testing SPI.. I am fine with either of those
2025-11-15 12:13 PM
SPI question split to separate thread:
BluePill: bidirectional SPI communication between STM32F103C and ESP8266