Hello Charlot,
Which language do you use to program your board? Which board are you using? Which driver (DAQmx, Traditional DAQ)?
This is a tricky question. If you look at this link:
http://zone.ni.com/devzone/conceptd.nsf/webmain/2a03115556fb233386256870005bb522?OpenDocument
you can see that you could use ND_ABOVE_HIGH_LEVEL type of trigger. If you route this trigger signal (ATCOUT) to use it as the GATE of a pulse train operation using a counter (frequency equal to your desired sample rate), and then route/choose the pulse train as the scan clock for your analog input operation, then that's the only way I can think of this to work in a completely-hardware controlled manner.
At the end of the document, it explains the Analog Scan Clock Gating, with an example that shows this idea. Please note not all boards support this.
Besides that option, I'm afraid you cannot do that operation completely by hardware with just one board. The reason is that you can only have one active analog trigger condition, as there is just one analog trigger circuit on each board.
There are some approaches though:
-Do the comparison via software (you check the samples and keep those inside the window/above your level, and discard those samples outside the window/below your threshold/level)
-Use an external circuit (comparator, etc..) that generates a digital pulse/edge both when the signal enters the window and when it leaves the window. Then program your analog input acquisition based on a digital start and stop trigger.
-Use a second board to accomplish this. You can initiate a windowed trigger analog input operation on one board, and route the output of the trigger circuit ACTOUT to the second board, which will be configured to do analog acquisition with a digital start and digital stop triggers.
These links are related and I recommend you to check them out:
http://digital.ni.com/public.nsf/websearch/8737E90ABEE342BD862569EE0077F6D2?OpenDocument
http://forums.ni.com/ni/board/message?board.id=170&message.id=5573&requireLogin=False
http://forums.ni.com/ni/board/message?board.id=170&message.id=70967&requireLogin=False
Hope this helps... Please let me know if you get this application working!
Any other suggestions out there?
Regards,
Jorge M.
Mensaje editado por Jorge M.
Mensaje editado por Jorge M.
Mensaje editado por Jorge M.