I'm trying to write modbus slave and have one problem: I'm correctly receive requests from master, but when I try to response it's look like something is incorrectly sended to serialport, because when I plug RS485 sniffer - I see both req and res (in HEX).
Hardware: Mac (slave written by me) - USBtoRS485 - ICPCON tGW-715 (TCPtoRTU gateway) - Win PC (software master)
When I'm trying this variant: Win PC (software slave) - USBtoRS485 - ICPCON tGW-715 (TCPtoRTU gateway) - Win PC (software master) everything works.
Libs: libmodbus, h5.modbus (node.js). Doesn't matter - correct request, but no response.
Target PC (for slave) will be on Linux, so Mac is nearly closer than Win.
I'm already have no ideas what to check and how to make it work. What can be wrong?