LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Modbus serial communication shared variable

Hi,

I'm trying to develop a Serial Modbus communication between two NI-9014 CompactRIOs using I/O servers and shared variables. The C-Series modules used are NI-9871. If I try to write an I16 or U16 into a Shared Variable in the CompactRIO Slave device, and read the same address with a Shared Variable in the CompactRIO Master device, the communication works without trouble. But, increasing the number of Shared Variable used the Master VI sometimes runs but sometimes it gives me some errors, the CompactRIO disconnect and I need to restart the system.
The encountered error is:

1967353906

Shared Variable in MASTER PC.vi<APPEND>
This error or warning occurred while reading the following Shared Variable:
\\MASTER\PC IO\430060
\\10.3.3.102\PC IO\430060

Attached you can find the project and the two VIs (master and slave) with the needed variable

0 Kudos
Message 1 of 2
(2,146 Views)

Hi Andreee87,

my first questions is: Why you're communicating with modbus? if the cRIOs are in the same network you can communicate using ethernet and it's much easier!

Indeed, what's the scan rate? maybe the refreshing is too fast.

 

0 Kudos
Message 2 of 2
(2,093 Views)