LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

DAQmx IO sync, acquiring finite samples

hey there

i am having a few problems writing some code to do triggered acquisition, i had a look at the examples but none of them seemed to be what i was after. basically, i want a VI to generate a pulse, which will be constantly output. every time it is output i want to acquire a fixed number of samples.

what is the easiest way to go about this? i have attached my efforts so far, is this the right approach? it does not behave as i would expect, when i stop the output generation the input triggering does not stop. does the ao/StartTrigger fire every time the output buffer is regenerated also? if not, the wrong thing to use i suppose.

thanks
0 Kudos
Message 1 of 3
(2,833 Views)

Hi,

The easiest solution would probably be to use a digital counter output on your DAQ device to generate the pulse train and then use this to trigger your analogue acquisition, rather than generating a pulse train yourself using an analogue output.

Using the digital counter would mean that you would not have to physically wire your pulse train to your trigger if you didn’t want to; you could configure this programmatically. If you are limited to using an analogue output for your pulse stream, then you need to make sure that the amplitude of your pulses are close to 5V (preferably > 4V) so that the TTL Logic trigger will register an edge.

Also ao/StartTrigger would cause the acquisition to trigger only once, as soon as the analogue output starts doing anything at all. You will need to refer to a real pin e.g. /PFI0 and route your pulse stream to this for triggering.

If you let me know what hardware you are using and whether your system permits or denies the use of the above suggestions I’d be more than happy to finalise an example VI that I am creating for you and upload it for your reference.

Regards,

Ian

0 Kudos
Message 2 of 3
(2,816 Views)
ok, that is what i thought. i have to be able to write the pulse myself, as the pulse characteristics need to change in an arbitrary fashion.

the hardware is a DAQcard 6062e, and i am currently generating the pulse on ao0, branching this into an amplifier and PFI0 to trigger the analogue input. i seem to have sorted the problem i had earlier, thanks for the help though.
0 Kudos
Message 3 of 3
(2,813 Views)