Vidmas30 Posted December 6, 2019 Report Posted December 6, 2019 Hi all, I use US5-B10-TR22 to read data from Modbus slaves. Technical documentation of slaves gives such information (see attached picture). Could someone tell if in US5 is the same byte order (didn't find that information). As for now everything looks OK, but I'm afraid that there could be a problem when there will be large numbers accumulated. Thank you in advance.
MVP 2023 Joe Tauser Posted December 7, 2019 MVP 2023 Report Posted December 7, 2019 What you've shown here is the standard Modbus definition for regular 16 bit integers. This is old school Modbus for Unitronics and the US5 will be fine. What it doesn't say is whether the return data is signed or unsigned. In other words, is the maximum value 32,767 or 65,535. Do you have an idea of the magnitude of the data the slaves will return? Joe T.
Vidmas30 Posted December 7, 2019 Author Report Posted December 7, 2019 Thanks for the quick feedback, Joe! Attached information about magnitude All the infomation I'm reading is INT32.
MVP 2023 Joe Tauser Posted December 7, 2019 MVP 2023 Report Posted December 7, 2019 You're probably going to have to swap the words on anything you read in 32 bit land. Look at this post on how to do that- http://forum.unitronics.com/topic/6241-read-single-precision-arrays-with-modbus-tcpip/ Joe T.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now