CRC calculation of serial RTU requests seems to be implemented incorrectly. Client address (first byte) should be included in the calculation (it is skipped currently) and the CRC should be transmitted as little endian (it is transmitted as big endian currently).
I have noticed this because my devices do not respond to the current node-modbus implementation-generated requests.
You can find the fixed rtu-request.js in the attachment: rtu-request.js.txt
Note that the same problem is in CRC check of the received responses.
CRC calculation of serial RTU requests seems to be implemented incorrectly. Client address (first byte) should be included in the calculation (it is skipped currently) and the CRC should be transmitted as little endian (it is transmitted as big endian currently).
I have noticed this because my devices do not respond to the current node-modbus implementation-generated requests.
You can find the fixed rtu-request.js in the attachment: rtu-request.js.txt
Note that the same problem is in CRC check of the received responses.