Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

General Purpose Counters on a PCI-6052E

We would like to use the general purpose counters on a PCI-6052E to count pulses from an external source. I have a few questions on this:

a) Can we run 2 buffered count operations at the same time (as with analog acquisition)?

b) Can the buffered count operation run while analog acquisition and waveform generation is running?

c) If so, then can the operation be set to record a count in the buffer synchronously with the analog output clock? We currently synchronise the analog input clock with the analog output clock by using the PFI_5 line. Can we also hook the counter clock into this with another line and if so, which line?

Thank you

Russell Hind
0 Kudos
Message 1 of 7
(3,386 Views)
Russell,

The PCI-6025E only has one DMA channel. For each buffered operation, one DMA channel is required. Therefore, you will be limited to only one buffered operation, counter or analog input, at a time. The remaining operations must all be interrupt based transfers.

Keep in mind that interrupt based transfers are slower than DMA based transfers. Therefore, if the analog output operation is relatively slow and you need speed for your counter operation, I would configure the buffered counter operation for DMA and the buffered analog output operation for interrupts.

How Many DMA Channels Does My E Series Data Acquisition (DAQ) Device Have?
http://digital.ni.com/public.nsf/websearch/E00C0F790CA2CDA686256BF000614DE1?OpenDocument

Regards,
Justi
n Britten
0 Kudos
Message 2 of 7
(3,386 Views)
On the link you gave, it says the PCI-6052E has 3 DMA channels (not 1 as you state). Therefore, I should be able to perform buffered AI and buffered counting at the same time using DMA.

But can I link the counter clock to the analog output clock (ND_OUT_UPDATE) so it stores the count in the buffer everytime a value is output?

We're running at a clock rate of -3, 75 (~266KS/s).

Thanks

Russell
0 Kudos
Message 3 of 7
(3,386 Views)
Russell,

You are entirely correct, the PCI-6052E does have 3 DMA channels. I misread the card you are using as PCI-6025E and issued my previous reply around you using the 6025E and not the 6052E. You will be able to perform up to 3 buffered operations using DMA.

Also, you can connect the PFI5/UPDATE* (pin 6) to a counter source to perform counting of the analog output updates.

Regards,
Justin
0 Kudos
Message 4 of 7
(3,386 Views)
Thanks. I have enabled the PFI_5 line from the ND_OUT_UPDATE source, and set ND_IN_CONVERT source to the PFI_5 line. This synchronises the wave form generation and acquisition.

Can I also set the PFI5 line as the gate for the counter so it stores the count in the buffer whenever a sample is output?

Thanks

Russell
0 Kudos
Message 5 of 7
(3,386 Views)
Sorry, just realised what you meant by this. We don't want to count the output updates, but I want to count the pulses from an encoder. For every sample generated on the output (and hence every sample acquired on the input because they are synchronised) I want the count from the encoder.

I imagined I would plug the encoder signal into the counter source, and set the PFI_5 line to be source for the counter gate so it stores the count every time a sample is output (and hence acquired also).

Thanks

Russell
0 Kudos
Message 6 of 7
(3,386 Views)
Russell,

Sorry for the confusion. You can use the UPDATE* as a gate for your encoder measurement. The encoder measurement will just be performing simple event counting. As such, you can use a low gate signal to pause the counter. Your source will be connected to the encoder.

Regards,
Justin
0 Kudos
Message 7 of 7
(3,386 Views)