Industrial Communications

cancel
Showing results for 
Search instead for 
Did you mean: 

Modbus I/O server working properly only if DSM open.

Hi everyone:

 

I'm having some problems when I try to run a Modbus Master I/O server (Ethernet). I have done a basic project to show you what is happening:

 

I want to read the 300016 register of a Modbus device with address number 3, so I have configured a I/O server this way:


IO server config.PNG

 

These are the properties of the 300016 variable.

 

variable config.PNG

 

And the VI just to display the value of the variable:

VI.PNG

 

I have to say that I know the value of the 300016 register because the device has a display showing it, but when I run the VI, the 300016 variable appears to be 0 (wrong value). So, I open the Distributed System Manager to see whats happening and this is what I see:

DSM1.PNG

 

As you can see, the library is deployed and the variable 300016 has value 0 (wrong). And here it comes the weird part: If I click on Modbus1, and after that I click on the marked item, everything starts working well.

 

DSM2.PNG

 

As you can see, the 300016 variable has now the value 22 (expected value) and starts updating at the configured refresh rate. The Vi is working perfectly too.

 

But if I close the Distributed System Manager, everything goes back to the previous situation and the indicator of the 300016 variable shows 0 again. Do you know what I'm doing wrong?

 

I would really appreciate any help.
Thank you very much.

0 Kudos
Message 1 of 2
(3,707 Views)

Hi Alekuona,

 

I think your question will get better exposure in LabVIEW forum. You will find lot more LabVIEW DSC users there who might be able to help

 

http://forums.ni.com/t5/LabVIEW/bd-p/170

 

But just by looking at your screenshots I would expect only variables under Modbus1 to work as they are the only one associated with modbus communication.

In LabVIEW right clock on Modbus1 and look for something called bind shared variables. Configuration window should pop up and you should be able to bind to modbus registers. 

Sorry it's been a while since i touched LabVIEW DSC, as I mentioned earlier LabVIEW forum would be best for your question. 

 

0 Kudos
Message 2 of 2
(3,696 Views)