SignalExpress

cancel
Showing results for 
Search instead for 
Did you mean: 

User defined step for polling data

Hi,

I'm creating a User Defined VI to be called from SignalExpress, that needs to poll a serial device for data.

 

The serial device makes new data availiable in a register-array at a rate of 10Hz, and uses an additional register as a "message ID" to indicate when new data is availiable.

This means that my VI needs to poll this MessageID, and when it increments, I can read the register array into a waveform and return it to SignalExpress.

 

Now, what is the best/correct way of writing this VI in regard to the polling wait time?

I see two options here for the case when my VI is called and it detects that no new message is availiable:

  1. It immediately returns to SignalExpress ("non blocking").
    In this case, should I return an empty waveform or the previous waveform?
    (I do not want duplicated data logged in SignalExpress)
  2. It blocks the SignalExpress loop where the user defined step is placed, by waiting in my VI until a new message arrives, and then returns this new data in a waveform.

My user defined step is placed in a separate loop in signal express so the blocking in case 2 should not affect other DAQ loops in my SignalExpress project, right?

 

/LeifS

0 Kudos
Message 1 of 1
(5,674 Views)