10-16-2008 04:28 PM
i need to read and write some data member in 32 bit integer signed format <sd4xxxx> modbus address
in my modbus device this format is [for example] low word 44097 - hi word 44098
for example if the value of address 44097 is 1 and 44098 is 0 the value of sd44097 is 1
(1) + (2^16 x 0) = (1) + (65536 x 0) = 1
but lookout interprets this data like (2^16 x 1) + (0) = (65536 x 1) + (0) = 65536
in modbus object advanced options you could check the modicon option for floating value, but i don't find similar setting for duble precision signed integer and don't find any solution
does anyone know a solution ?
thank you
Solved! Go to Solution.
10-17-2008 10:09 AM
Hi B_N_
When I use 32bit registers I do this:
If the 2 registers are 44097 and 44098, I write to and read from F44097. Lookout then knows that you are dealing with a 32 bit float and arranges the data in the registers accordingly.
You don't need to use the advanced settings in modbus, "F" does all that for you, at least in my setups.
Hope that works in yours.
Roger
10-20-2008 04:42 AM
If you use Lookout 6.1, follow this KB to create a modbus.ini file.
http://digital.ni.com/public.nsf/allkb/2E64D5CF87CA6A1086256BB30070DC1A?OpenDocument
Input
ReverseByteOrder=1
It will work on SD as you want.
But if you use 6.0 or lower version, I don't know a way to do it. I'm not sure if the F will work. You may use the expression to calculate the value.
10-20-2008 03:52 PM
perfect !
is the complet list of modbus.ini parameter availlable ?
10-20-2008 10:18 PM
01-04-2009 07:40 PM
Hi,
Does this applies to LabVIEW 8.5 as well?
i'm also tyring to communicate with a device that has Floating-Point paired-register.
the addresses it's using are 20249 & 20250.
does it means i map these addresses in LabVIEW by F200249, then i should be able to get the Float value?
WF
01-04-2009 09:19 PM
Fxxx reads two adjacent addresses and combine them to a float value.