LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

cDAQ-9189 disconnects from cRIO-9040

I have been troubleshooting this problem for several days now and have run out of ideas. I am hoping someone has either run into this or has an idea of what might be happening and how to stop it from happening again. The problem I keep having is the cDAQ will drop the network connection to the cRIO, seemingly at random times. This results in an error when trying to collect data from the cDAQ chassis (The first error I get is that there are not enough samples). 

 

The setup:
cRIO-9040: Static IP on Eth Port 1: 192.168.1.99

cDAQ-9189: Static IP on Eth Port 1: 192.168.1.9

Both have subnet masks of: 255.255.255.0

LabVIEW 2021 SP1

I am running DAQmx in a loop reading 400 samples at a time, so affectively the loop should run at 5Hz.

The cRIO and cDAQ are being powered from a large battery bank so I know this isn't from a power loss.

 

 

The cRIO and cDAQ are connected with a standard ethernet cable, and when I first start the cRIO, all is well and fine. Within 24 hours, the connection between the cRIO and cDAQ will drop giving me a DAQmx error. I have attached a skeleton of the code I am running, as this is the first time that I am running a cDAQ connected to a cRIO. From everything I have read I have everything setup correctly, but I am still running into the disconnecting issue. 

 

I have seen and read this article several times and the only thing I haven't been able to do yet is verify what the LEDs do when it disconnects (the systems are remote to me). Ethernet cDAQ Chassis Disconnects or Loses Connection While Acquiring Data - NI

 

I have written some code to try and re-establish the connection, but so far have been unable to get it to re-establish a connection (mostly me not thinking far enough ahead on potential errors).

 

If anyone has any thoughts/suggestions/questions/etc. please let me know as I am running out of ideas on how to make this work reliably!

 

Thanks!

Andrew

 

 

Download All
0 Kudos
Message 1 of 2
(253 Views)

Adding more information to try and get this solved.

 

The latest code I wrote (that is attached in the original post) to re-establish the connection works to reset the cDAQ, but I am unable to start streaming data again.

 

Inside the CheckNetworkConnection.VI (Once I've received the initial "not enough samples" error), I can do the following steps with no errors:

1. Add the network device (cDAQ).

2. Reset the cDAQ.

3. Stop then current DAQmx task that generated the error.

4. Clear the current DAQmx task that generated the error.

5. Reserve the cDAQ.

6. Self-test the cDAQ. 

 

Once the above steps have been carried out, I attempt to create another DAQmx task and that is where it is having the issue. Creating the new task generates two errors that alternate back and forth:

The first error I get is: -201003

The second error I get is: -200324

 

These two errors alternate till the cRIO is restarted -OR- if I start a debug connection and force a -200279 error (SW can't keep up), then the system generates one last -200324 code, then it is able to setup a new DAQmx task (with no errors) and start collecting data.

0 Kudos
Message 2 of 2
(206 Views)