Closed serefseven closed 2 months ago
You are using Serial
for both debugging and Modbus communication. These need to be on separate ports.
The Arduino Nano only has one HardwareSerial port, but the ModbusRTUMaster and ModbusRTUSlave libraries will work with SoftwareSerial.
Hi Chris,
I have been working on simple modbus communication but, I haven't succeeded yet. I need your help.
I want to write boolean value from slave and read it from master. I have two Arduino nano and two TTL rs485 converter.
Both Arduino pin connection; R0 to RX(D0) DI to TX(D1) DE and RE to D2 A to A B to B
Where is problem? Could you help me?
Slave code
Master code
Best regards, Seref