Digital I/O

cancel
Showing results for 
Search instead for 
Did you mean: 

continuously recording counter signals?

Hello, 

 

I am using a digital counter signal to trigger an external device, while continuously recording analog input using a PCI 6071e card. I would also like to record my digital output, so that I can use my triggers for later analysis. Ideally, I would like to have a continuous recording that I can put side by side with my analog input. 

 

I have tried to connect the internal counter output to the line I want to record from using the connect terminals vi. However, when I want to make a digital input recording (via the express VI, I am quite the labview newbie), I only get the 1 sample on demand option. I think that this is not because I used the 1 sample option for my digital output (I have tried changing that).

 

Is there any way to continuously record counter output? Or, failing that, another way to record this output so I can later line it up with my analog input?

0 Kudos
Message 1 of 3
(4,555 Views)

Hi Susan,

 

I understand that you generate a digital pulse with DAQmx counter functionality. This pulse triggers a continuous analog data acquisition on the same device. You would like to record the pulse, that triggers your analog task. Right?

 

Please ask yourself the following questions:

 

1. You can track the occurrence of the digital trigger pulse by the start of the analog acquisition, why do you need the trigger to be recorded separately?

2. When do you want the digital recording to begin? How to you plan to correlate it in time to the analog recording?

 

What you try to achieve is not a trivial DAQ task that is covered by DAQ Assistant. Please focus on the DAQmx low-level VIs. A good starting point is the following tutorial, in your case especially the synchronization part.

 

Getting Started with NI-DAQmx: Advanced Programming with NI-DAQmx

http://www.ni.com/white-paper/5469/en

 

This example could be of some help:

 

Correlated Digital Input Using Analog Input Task in DAQmx

https://decibel.ni.com/content/docs/DOC-5264

 

Regards, Topper


 

0 Kudos
Message 2 of 3
(4,548 Views)

Hi Topper, 

 

Thanks for your reply. I haven't been clear in describing my recording setup:
I am recording signals from one brain area continuously (this is my analog input). I then stimulate another brain area to see what that does to my signals (the digital output is triggering the stimulation machine). Since I am interested in what happens before, during, and after, it is better for me to have a continuous recording that I can chop up in shorter bits later on, depending on the kind of analysis. 

That is what I need the digital signal for. I thought that the easiest would be to somehow record the digital signal in a similar way to the analog one, but it would also work if I can generate a list of precise timestamps of when the digital pulse is generated (both analog and digital input would need to get the same timing then). It seems that the only way to do that is to connect it to a digital input somehow. 

The digital signal does not directly affect my recoding loop at all, it just triggers a graph of the immediate response after stimulation, so I can see what is going on during the experiment (although this bit of the vi needs tweaking too, it is not my major problem right now). 

I did not including the bit of my VI that does the recording, because I am testing with a simulated signal for now. 

I will study the DAQmx tasks some more. I just hope that I am able to get them running, when I already have trouble with the express version :s Thanks for the links, though 🙂

 

Susan

 

0 Kudos
Message 3 of 3
(4,543 Views)