General Arduino

Arduino to Arduino communication via SoftwareSerial

userHead CarmosKarranCarmosKarran 2022-11-05 15:59:40 1028 Views1 Replies

I have two Arduino Leonardo. Could these two Arduino boards communicate with each other by SoftwareSerial library? (Not Serial1, Thank you)

2022-11-08 18:14:29

You can use an arduino as a USB to serial with a simple sketch without trying to remove the chip.

 

Basically arduino connect to computer as a USB to Serial Converter. So whatever you write to that serial port from your computer can be read from arduinos hardware Serial port. Whatever you write to hardwareserial port from arduino can be read from computer.

 

Use software serial library to setup another pair of pins as a 2nd serial port (you don't even have to do this if you are using a Mega as mega got 4 hardware serial ports.) And your sketch must simply read from hardware serial and write to software serial and vice versa.

userHeadPic ManjotSnithcarl