Counter/Timer

cancel
Showing results for 
Search instead for 
Did you mean: 

buffered event counting on a 6601?

Has anyone had any success using buffered event counting (circular buffer) on a 6601? I'm using a PCI-6033E to trigger the 6601 counter gates (via RTSI_0). I'm trying to count pulses on the source pins of each respective counter. I can get counter 0 to work OK, but counters 1 thru 3 are only returning their programmed initial counts in the buffers.
It appears that only the counter whose transfer mode is set to use DMA will work. I have counter 0 setup to use DMA, but since you can't setup all 4 counters to use DMA (the 6601 only has 1 DMA channel), how do you get all 4 counters to do buffered event counting?

BTW, I'm using Delphi 5.0, and NI-DAQ 6.9.2. Sample rate (and the gate rate) is 1000 Hz. Pulses coming into SOURCE_0
thru SOURCE_3 are from 0Hz to about 6Khz.

Thanks for any assistance.
0 Kudos
Message 1 of 3
(3,524 Views)
You will need to use the NI-DAQ function Set_DAQ_Device_Info to set the other counters to use interrupts. For example to set counter 1 to use interrupts use the function would be like this:

Set_DAQ_Device_Info(Device#, ND_DATA_XFER_MODE_GPCTR1, ND_INTERRUPTS)

Let me know if this does not solve the problem.

Brian
0 Kudos
Message 2 of 3
(3,524 Views)
Unfortunately, this did not solve the problem. I have counter 0 using DMA, and counters 1-3 using ND_INTERRUPTS, but only counter 0 seems to work; Counters 1-3 are updating their circular buffers, but only with the value that their counters were initially set to (i.e. no new count values are appearing in the buffer).
0 Kudos
Message 3 of 3
(3,524 Views)