Jump to content

Recommended Posts

I have some actuators I am controlling with a vision 700 over modbus. When I read the holding registers for the position data the data is being brought in as signed 2s compliment numbers. Does anyone know why this is and how to bring it is as base 10? If i read the same registers with the program MODBUS POLL the data reads correctly with that program which leads me to believe it is something in how Visilogic converts the data. 

Link to comment
Share on other sites

On 6/23/2023 at 9:44 AM, garydreppert said:

I have some actuators I am controlling with a vision 700 over modbus. When I read the holding registers for the position data the data is being brought in as signed 2s compliment numbers. Does anyone know why this is and how to bring it is as base 10? If i read the same registers with the program MODBUS POLL the data reads correctly with that program which leads me to believe it is something in how Visilogic converts the data. 

Are you sure that is actually what is going on, based on my own experience using Modbus on Unitronics devices and without giving it much more thought It sounds like it may be the endianness.

are you sure that you are not getting the Bytes in a reversed order? if that the case the easiest way to fix it is to use swap bytes function block

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...