LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Modbus TCP Communication with ICPDAS ET-87P8

Solved!
Go to solution

Hello,

 

I have been struggling struggling to generate an Analog Output from a remote datalogger (ICPDAS ET-87P8) using the example code provided. I have been successfully able read Analog Inputs using the device and example and have confirmed correct Network Configuration, Wiring...etc.

 

The unit has a configuration program called "Modbus Utility" where we can configure the channels (see screenshot) and I am able to manually set an Analog Output and have confirmed that it is correct with a multimeter and also by reading it back into one of the other analog input cards on the same device. 

 

LabView Modbus.png

I have confirmed that all hardware, wiring and communication is correct and I now believe that the issue is related to me not understanding how the LabView program works. We have successfully gotten an older generation unit to work and deliver an analog output using their DCON protocol but this is not compatible with the newer MTCP unit. 

 

Model here: http://www.icpdas.com/root/product/solutions/pac/ipac/et-87pn-mtcp.html

 

I believe that it may have something to do with choosing the Analog Output register in the program but I have not had any luck.

 

I would appreciate any suggestions or ideas.

 

All the best,

 

Barry

 

 

 

Download All
0 Kudos
Message 1 of 7
(3,593 Views)

Hi Barry, 

 

Could I possibly check what the issue is? Are you not generating any output or are you seeing anything unexpected? Also, which VI are you referring to and what is the difference between the ones in the zip? 

 

Many Thanks, 

 

Riley Ilieva 

Applications Engineer

National Instruments

0 Kudos
Message 2 of 7
(3,557 Views)

Hi Riley,

 

 

We have 2 systems. 
 
The first is an I8KE8 using a single I-87024W module. This is functioning correctly and we have communication and control of it using LabView via the DCON protocol. We can generate an analog output as expected using the DCON LabView example provided from ICPDAS.
 
The second system is the MTCP ET-87P8 with an I-87024W (Slot 0), I-87019 (Slot 1), and I-87017RC (Slot 2). We have communication with the backplane and are able to read in the analog inputs from  I-87019 (Slot 1), and I-87017RC (Slot 2) respectively using the ICPAS Modbus LabView example. 
 
However, we are unable to generate an analog output on Slot 0 using the same LabView example that they provide. I have verified that the hardware is fully functioning as we can manually generate an analog output using their Modbus Utility program. I have verified that the inputted value produces an expected result. We cannot replicate this using the LabView example which is confusing as the analog reads worth fine within the same program. 
 
I believe that it has something to do with the operation of the LabView program and selecting the analog output register. We are using LabView 2016 (32-Bit).
 
To summarise - the hardware is functioning but we are unable to get the analog output to write using the provided LabView program. It is strange as the analog reads are fully functional within the same VI (coming from a separate card on the same backplane).
 
The VI we are using is MB_Ethernet_Example_ai_ao_di_do_1_device.vi ‏49 KB . I included the zip so that you would have the library to run the VI.
 
Regards,
 
Barry
0 Kudos
Message 3 of 7
(3,554 Views)
Solution
Accepted by topic author Barry675

SOLVED.

 

I knew it was a silly error on my side. The problem was that I was inputting a value of 0-20mA into the AO fields. Of course this is not correct and it should have been a proper value for a 12 bit range. So instead of inputting "10" mA into the A0 field the it should have been something like 30000.

 

It is working perfectly.

 

Barry

0 Kudos
Message 4 of 7
(3,550 Views)

Hi Barry, 

 

 

Haha I was just typing a post to check the input parameters in the code compared to the Modbus utility. 

 

I am glad this is working now! 

 

Riley

Applications Engineer 

National Instruments

0 Kudos
Message 5 of 7
(3,548 Views)

@Barry675 wrote:

SOLVED.

 

I knew it was a silly error on my side. The problem was that I was inputting a value of 0-20mA into the AO fields. Of course this is not correct and it should have been a proper value for a 12 bit range. So instead of inputting "10" mA into the A0 field the it should have been something like 30000.

 

It is working perfectly.

 


If it's working perfectly then I probably don't need to post this, but I just wanted to remind you that the largest (unsigned) value that can be represented with 12 bits is 4095, so 30000 would be out of range.

Message 6 of 7
(3,539 Views)

arteitle,

 

Sorry - I mispoke it's a 16-bit DAC.

 

All the best,

 

Barry

0 Kudos
Message 7 of 7
(3,509 Views)