LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Modbus read problem - beginner

          I'm trying to read six input registers from a remote device but the software I put together doesn't seem to do much; no errors but no read-backs either.  I'm a beginner, so the answer is probably simple.  The remote device input registers start at 200 hex.  It uses TCP and the IP address is correct.  My computer communicates well with the remote device through QmodMaster.  Any help you could give would be appreciated.  Thanks, Mike

Download All
0 Kudos
Message 1 of 4
(1,374 Views)

First thing I would try is to drop the leading 0s in your IP address. Just enter it as 192.168.0.21. The other thing is are they holding or input registers? You could be calling the wrong VI for your read.



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
0 Kudos
Message 2 of 4
(1,349 Views)

Put some indicators on your error wires so you can see the errors while they are running.  Right now you only see them after you hit the stop buttons.

 

Why do you have this has two separate loops?  I'm concerned about the opening of two connections to the same IP address.  Just open it once and split the wire to the two loops.  But really both things can go into the same loop.  I would just wire the Modbus Read in series with the Modbus Write.  I doubt they can run in parallel anyway since you are reading and writing to the same 502 port on the same IP address.  And the act of trying to do this may be what is causing the problem.

0 Kudos
Message 3 of 4
(1,321 Views)

Mark,

 

         Thanks for the help.  That fixed it.

 

 

0 Kudos
Message 4 of 4
(1,274 Views)