UART comminication between RPI and arduino

Have some feedback, questions, suggestions, or just fancy a chat? Pop it in here.
Post Reply
nik0351
Posts: 1
Joined: Tue Sep 08, 2020 10:05 am

UART comminication between RPI and arduino

Post by nik0351 »

hello everyone,

We are trying to communicate with Arduino using hw uart (RPI pin 8,10).

But we are able to communicate between Arduino and RPI due to a mismatch in baud rate.

to receive the data, we have to select 115200 baud rate on RPI. and 78400 on Arduino. then only we are able to receive any data.


Please help us, solving this problem
User avatar
Lukeerth
Posts: 1
Joined: Thu Sep 17, 2020 11:11 am

Re: UART comminication between RPI and arduino

Post by Lukeerth »

Hi,
I was also curious how to build a Raspberry Pi UART interface and make a communication between the 2 devices; found a couple of guides and pics, though didn't have enough time (I'm up to my neck in other projects). I haven't tried it yet, but here's a tutorial >> Rpi to Arduino Serial UART Communication Tutorial:

https://raspberrypi.stackexchange.com/q ... n-tutorial
User avatar
MichaIng
Site Admin
Posts: 2336
Joined: Sat Nov 18, 2017 6:21 pm

Re: UART comminication between RPI and arduino

Post by MichaIng »

Please check out the official RPi documentation which applies to DietPi as well since we use the same firmware, kernel and repository.
E.g.: https://www.raspberrypi.org/documentati ... on/uart.md
First of all it depends if you use the hardware UART on ttyAMA0 or the software UART on ttyS0, AFAIK there was some dtparam or dtoverlay to set the baudrates for those, check out /boot/overlays/README: https://github.com/raspberrypi/firmware ... ays/README
Post Reply