NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Timed Interrupt Test

I am using TS to test software timing requirements. I would like to have an interrupt in TS so that I could execute code depending on how long the the Unit under test has been running. I think I can use what is called the module time for this but I don't know how.

 

This is what I want to do...

 

1)Run ARINC for x seconds (according to the unit, not real time).

2)Check output

 

Currently I am breaking at points in the software and checking the system timer. The problem with this is that I can overrun the timing requirement because I am breaking every 250ms. So if I am shotting for 5 seconds I sometimes get 5.135 seconds.

 

Thanks for any help,

Pat

0 Kudos
Message 1 of 2
(3,071 Views)

Hi Pat,

 

One approach you could take would be to call a module asynchronously at the beginning of the test that constantly monitors the time status on your unit, using shared memory space such as a notifier to allow your main code to query the time status before deciding which action to take. This way, you can check the time more often since you will have a separate thread dedicated to managing the timing.you can implement the timing in a new thread by calling the module in a subsequence, then calling that subsequence in a new thread.  Let me know if you have any other questions!

Al B.
Staff Software Engineer - TestStand
CTA/CLD
0 Kudos
Message 2 of 2
(3,038 Views)