Real-Time Measurement and Control

cancel
Showing results for 
Search instead for 
Did you mean: 

It seems like outputs don't respond to inputs / cRIO-9024, custom device, NI VeriStand, ControlDesk of dSPACE

Hello

 

I am now working on running a labview controller on VxWorks RTOS, and then this labview controller is integrated with a vehicle plant model in ControlDesk of dSPACE through CAN (cRIO-9113). 

 

I have two models as below:

1. vehicle cruise controller written in labview using the Control and Simulation loop of labview

2. custom device project

   : LabVIEW model is not supported for VxWorks RTOS, so it is necessary to interface between labview model and compactRIO. 

   This custom device project is set to Asynchronous execution mode and labview model was integrated into <custom device name> RT Driver VI.vi. 

 

Anyway, I successfully built a custom device project and deployed to the target, and seems like there is no problem to integrate with a plant model in ControlDesk of dSPACE. (I can see the green light blinking on CRIO-9113, CAN module)

 

The problem is that signals from input are not delivered to ouput. 

 

As seen below, I just put a laview model into <custom device name> RT Driver VI.

In order to synchronize time between Timed loop and Control and Simulation loop, Device Clock is connected to two loops.

Besides, local variables are used to share inputs and outputs. 

loca.variable.jpg

 

Inputs were not delivered to outputs even when labview controller was an empty loop as below.

control.jpg

 

When I manipulated signals at ControlDesk of dSPACE, I saw values in input channels of workspace of veristand changing as I expected, but output didn't change. 

 

How can I solve this? shoudl I add some functions into labview code? 

Besides, when Device Clock is connected to the Control and Simulation loop, should I place a checkmark to 'Synchronize loop to Timing source?

 

Thank you 

0 Kudos
Message 1 of 1
(4,390 Views)