Skip to content
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

Modbus slave ID #2

Open
tucano opened this issue Jun 7, 2016 · 3 comments
Open

Modbus slave ID #2

tucano opened this issue Jun 7, 2016 · 3 comments

Comments

@tucano
Copy link

tucano commented Jun 7, 2016

Hello, seems I can't use this library for a real connection with an industrial machine.

The machine have modbus slave ID = 1. Where I can set the slave ID? All the request goes to timeout.

I am playing with Example_01 (read holding reg, FC03)

Best Regards

@stefanpoeter
Copy link
Member

I think a request with a wrong id (event thou we do not need the id for modbus tcp) are usually not going to timeout. Give me some more informations like server and client IP. What kind of a plc are you using. Can you ping your PLC? try to connect to the plc with the node-modbus library.

@tucano
Copy link
Author

tucano commented Jul 4, 2016

Hi, have hard coded the Slave ID of my machine and it works...

commit:
https://github.com/tucano/chrome-modbus/commit/84950138e41ba32537e2326e830240f20a2dce79#commitcomment-17856036

You have putted

.setUID(255);

I have

.setUID(1);

If we make a function arguments, everybody will be happy.

On Tue, 7 Jun 2016 at 17:38 Stefan Poeter [email protected] wrote:

I think a request with a wrong id (event thou we do not need the id for
modbus tcp) are usually not going to timeout. Give me some more
informations like server and client IP. What kind of a plc are you using.
Can you ping your PLC? try to connect to the plc with the node-modbus
https://github.com/Cloud-Automation/node-modbus library.


You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
#2 (comment),
or mute the thread
https://github.com/notifications/unsubscribe/AADInkcsdtCnsUjiz1GYUaakyx5qvzknks5qJZCFgaJpZM4IwAaI
.

@stefanpoeter
Copy link
Member

I will see to it. Great work. Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants