10-04-2013 11:23 AM
Julien I have learned a lot thanks to your post so many thanks!!
Considering that the counter output event occurs when the counter reaches terminal value, maybe I could set that value to 1, and restart the task each time. That is exactly what I dind't wwant to do initially, but maybe the software is quick enough to do thatevery 100 ms.
Considering that our lab wants to buy a NI DAQ, I'll simulate the devices listed to support sample clock timing for DIO. Those card should support change detection events or not????
10-07-2013 03:21 AM
Maybe there is a better solution ! Take a look at screenshot (on my computer, LV is in french but it will help you anyway) : that's an example, you can search it among LV examples ("Event Response.vi").
Here is a part of VI documentation :
"This example demonstrates how to use the timed loop in conjuction with the Digital Change Detection DAQmx timing source to show how to do an Event Response application. If a digital edge is detected we want to immediately respond to this and shut down our process.
Note: This example only works with National Instruments devices which support Digital Change Detection"
So, you should try using "DAQmx Create Timing Source", which is a polymorphic VI. And you will need to use a timed loop as well.
In this example, the instance selected is "Digital Change Detection". But on the screenshot, I have highlighted in blue the suitable instance for your need : "Digital Edge Using Counter". You will need to adapt this example for your application, but it should work with counter input.
Please let me know wether or not it works ! (hoping that your HW will allow using this technique...)
10-07-2013 07:07 AM
Rhaaaaaa I can't find any equivalent function (DAQmx Create Timing Source) in LabWindows !!!
10-09-2013 10:43 PM
Unfortunately, I haven't been able to try the labview VI because I am not familiar with LabView.
Maybe the function is DAQmxCfgSampClkTiming, or not.
I have participated in the labview topic you refeered to, and learnt a lot from it too. If you have a look there maybe more ideas arise.
I still have to investigate more about how this cards work,
10-10-2013 02:16 AM
As we said previously, I think that using a digital input with change detection event will be a relevant solution.