Real-Time Measurement and Control

cancel
Showing results for 
Search instead for 
Did you mean: 

Waiting for RT target to Respond

I'm using a crio 9074 for a control application with the 9263 AO, 9205 AI, and the 9401 DIO modules.  Attached are the VI's of interest.

 

In the last frame of the Alice VI I have the control loop.  The Apply Motor Voltage sub vi simply try to write a voltage to the 9263 module.  The get measurement sub vi read some inputs from the 9205 and the 9401. The other sub vi in the control loop is simply applying a kalman filter to the measurements.

 

The VI works find if I am either reading the inputs from the 9205 and the 9401 OR if I am writing voltages to the 9263.  However, when I try to do both I get the "Waiting for RT target to Respond" and my host computer loses its connection to the CRIO until I cycle it's power on and off.

 

Is there a strategy for accomplishing both the reading in and out of data to different modules simultaneously that I should be using instead of that hear.

 

Any help is greatly appreciated.

 

 

Download All
0 Kudos
Message 1 of 2
(3,302 Views)

Hello Engbrecht,

 

I took a look at the code you posted, and I think the problem is that the loop is consuming all available CPU at a high priority and is starving out the thread that communicates back to the host.

 

You should be able to check the "Finished Late?" boolean under "Previous Iteration Timing" on the inside left edge of the timed loop to confirm that this is the problem.

 

Out of curiosity, what is your scan period currently set to?

 

To avoid this you need to either give the loop more time to complete or reduce the time the code in the loop takes to execute.  A few things you can try are:

 

- Lengthen the scan period or increase the number of scans on the loop

- Move code out of subVIs to eliminate the calling overhead

- I've seen that, in some cases, using the error terminals to wire IOV nodes in series results in significant performance improvements.  You don't appear to have too many IOVs but it is worth a try.

 

Let me know if that helps,

 

Thanks,

 

Sebastian

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