05-28-2009 01:13 AM - edited 05-28-2009 01:13 AM
I am using LabVIEW 8.6, with the NI MODBUS 1.2 VI library. I have a device that serves up about 50 holding registers, all of the same format. I would like to read about 20 of them, however they are not consecutive. (40010, 40015, 40017, etc) The Read Holding Registers VI only gives me the option to read consecutive registers starting at a given address. In contrast, Write Multiple Registers VI seems to let me write to an array of discrete registers. Is there a way to do this for reading registers?
Solved! Go to Solution.
05-28-2009 01:55 AM
AZZOAutomation a écrit:I am using LabVIEW 8.6, with the NI MODBUS 1.2 VI library. I have a device that serves up about 50 holding registers, all of the same format. I would like to read about 20 of them, however they are not consecutive. (40010, 40015, 40017, etc) The Read Holding Registers VI only gives me the option to read consecutive registers starting at a given address. In contrast, Write Multiple Registers VI seems to let me write to an array of discrete registers. Is there a way to do this for reading registers?
Message Edited by AZZOAutomation on 05-28-2009 01:13 AM
There is no way to write non consecutive registers with Write Multiple Registers ! It is "only" possible to write consecutive registers starting at a given address.
You must either read the whole memory range covering all needed registers and extract the used ones or made multiple reads.