2023-11-11 10:45 PM
hi all,
I'm Trying to send a string from STM32F401RE MCU to EPS32 Via UART i have programmed both STM as well as ESP32 and i successfully verified that data is available on UART pin of STM
Data on UART Pins of STM
But I'm not able to receive data on ESP32, i double checked the UART Hardware connection is correct
and i configured STM UART in TX_ONLY mode , did not configure any hardware flow pins ,baudrate is 9600,1 stop bit and not using parity
I'm receiving some Garbage value on Arduino
can anyone please help me with the UART message not Receiving in ESP32
Solved! Go to Solution.
2023-11-12 10:12 AM - edited 2023-11-12 10:14 AM
Hello All,
Thanks for taking your time and Interest in Solving the Issue, I figured the Solution for this problem, I was using USART2 peripheral but i did not know SB62 and SB63 Are by default OFF(means
)
I got the Above Information from User Manual of STM32F401RE,
So in my Implementation I used UART6 Peripheral instead of 2, So i'm receiving the data on ESP32
2023-11-12 01:02 AM
Provide a wiring diagram. Output from STM32 needs to go to input of ESP32, need common ground.
2023-11-12 01:54 AM
Hello Thanks for the reply
I followed the wiring Connections as mentioned in the above image Where Device 1 is STM32 and Device 2 is ESP32, Both the devices are powered using PC USB Port
2023-11-12 05:43 AM
I'm not familiar with which ESP32 board you're using or the physical pins involved. Check the signal with a scope, I think you've already established the STM32 is doing what it's supposed to be doing, so focus on why the code on Arduino doesn't function as expected. Perhaps to character level forwarding instead of string.
2023-11-12 06:40 AM
I looks like ESP is having difficulties interpreting STM32's messages, or your serial viewer is having same issue. Check both.
2023-11-12 10:12 AM - edited 2023-11-12 10:14 AM
Hello All,
Thanks for taking your time and Interest in Solving the Issue, I figured the Solution for this problem, I was using USART2 peripheral but i did not know SB62 and SB63 Are by default OFF(means
)
I got the Above Information from User Manual of STM32F401RE,
So in my Implementation I used UART6 Peripheral instead of 2, So i'm receiving the data on ESP32
2023-11-12 10:32 AM
Manual for NUCLEO-F401RE board, the STM32F401RE is a chip.
It would be good practice moving forward to identify exactly what boards and hardware you're using, with enough specificity a manual could be found.
2024-06-06 11:54 AM
@mast3rshinobi @Tesla DeLorean iam facing the same issue, receiving garbage value, could you please share clock configuration and USART6 details for your board ? iam using STM32f407vet6 board USART6 with half_duplex (Only transmit)
thanks & regards
2024-06-06 12:59 PM
If clocking from an external source (oscillator or crystal, HSE), make sure the the HSE_VALUE in stm32f4xx_hal_conf.h is reflective of the correct speed. Otherwise the baud math is broken.
Send a constant stream of 'U' or 0x55 bytes, and scope the UART_TX signal to confirm the speed you're actually transmitting at.
If you're transmitting properly, check the receiver..