LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

MODBUS TCP/IP Read Holding Register using LabVIEW error

Solved!
Go to solution

Hi all,

Using LabVIEW 2017, i am trying to pull data from (DIRIS A-40) power meter through Modbus-TCP. using attached vi (Power meter modbus.vi). but it gives the following,

1- error code:-389121

2- Source:<APPEND>Function 3.

 After searching for this error its something to do with Gateway misconfigured or overloaded.

Hence: I used ModScan32 to retrieve same holding registers and it worked fine with same settings used in previous vi.

attached you can see the settings were made for both programs (LabVIEW and Modscan).

Thank You.

Download All
0 Kudos
Message 1 of 5
(2,910 Views)

How are you running the LabVIEW code?  Did you hit the Run button once.  Or did you press the Run Continuously button.

0 Kudos
Message 2 of 5
(2,878 Views)

By hitting Run button once ofcourse.

My Question here is, what is different between these two methods/software in pulling the registers? 

 

0 Kudos
Message 3 of 5
(2,871 Views)

My concern was that the regular run buttons should not be a problem.  But that if you are using the Run Continuously button (which many new LabVIEW users use when they don't know any better), the same code would be executing so quickly that you'd be flooding the device with open requests that it would eventually kick back an error.

 

You might want to try using a port sniffer to see if anything looks different between the messages the modscan package is sending vs. your LabVIEW code.

0 Kudos
Message 4 of 5
(2,860 Views)
Solution
Accepted by topic author MoahmmadFayiz

I found that for some remote modbus devices, even though they are communicating using Ethernet connections they also have a device ID.

LabVIEW  accepts a device ID if it was a serial connection only, in case of Ethernet connections LabVIEW asks only for Ethernet IP address. 

 

To solve this issue i added a function called (add device ID.vi) after configuring the connection. by this way i assigned an Ethernet IP address and Device ID as the Remote Device settings.

 

It works fine Now. 🙂 

0 Kudos
Message 5 of 5
(2,751 Views)