-
Notifications
You must be signed in to change notification settings - Fork 297
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow modbus tcp slave id to be zero #2799
Comments
Hi @nichokap, Regards, |
Hello @Limraj, Thanks for looking that quickly the case. Sorry but i didn't understand your request. I cannot apply the configuration needed because when I write slave id 0 I get an error that the slave id should be between 1 and 255. Thus, saving the configuration and creating a data point is not possible. If I choose modbus slave id 1, I get an error message that no reply received from this slave id (there is a reply actually, but the modbus tcp response packet has replaced slave id with 0). Happy to support with anything more you may need. |
Okej @nichokap, |
Thank you once again @Limraj . Sorry if I didn't describe it corrently in the first place! |
Hi @nichokap, The issue you're experiencing with slave ID = 0 is because this ID is reserved for broadcast communication in the Modbus protocol. When using Modbus TCP, setting the slave ID to 0 allows a master to send a message to all devices on the network. This means any device receiving a message with slave ID = 0 will process the request but typically will not send a response to avoid network congestion and collisions. Here’s a reference to this behavior: Fernhill Software - Modbus Protocol Overview: "A master can broadcast a message to all devices using address 0 (zero)." I hope this clarifies why the device is responding with slave ID = 0 and helps you understand the reserved usage for broadcast communication. Best regards, |
hello @Patrykb0802, thank you for your feedback. The issue I am facing is due to the strange behaviour of this specific Allen Bradley device. The only way to communicate with it is to send Modbus TCP requests with Slave ID =0. The question is from my side is simple, do you still have plans to allow setting Slave ID = 0 in Modbus TCP requests in a future release? |
Hi @nichokap, Regards. |
Hi again @Limraj, |
Added option to set modbus data point slave id to range from 0 to 255 instead of range from 1 to 255
…ave_id_to_be_zero #2799 Allow modbus tcp slave id to be zero
When using some Allen Brandley devices, for example the Powermonitor 3000, and request data over Modbus TCP the device ignores the modbus slave id sent through the requests and replies with the slave id section as zero. Thus, in order to accept the responses you must
either be able to set the modbus tcp slave id to 0 when sending the request, or
accept that through modbus tcp you can send a request to slave id 1 and get a response from slave id 0.
The text was updated successfully, but these errors were encountered: