Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Microsecond precision analog wave form output using PCI 6229

Hi,

 

I am trying to setup a VI circuit to output a waveform with microsecond precision. I am using an old PCI 6229.

 

The wave form is a series of square wave with some pre defined length and rate.

I've already written a small VI that generates the wave form and now I am trying to send this waveform to one of the analog outputs.

However, when I measure the signals coming out using an oscilloscope, I get a jitter in the pulsed signals.

 

I am novice to labview, so any tips are welcome. I am running on a windows 7 32 bit.

Is this even possible to do, or do I need a real time PXI machine for that?

 

What is the best way to get a microsecond precision waveform with such card?

 

Many thanks,

 

-- Shay

 

 

 

Download All
0 Kudos
Message 1 of 9
(4,090 Views)

Did you look at the specifications for the PCI-6229?  The analog output update rate is 833 kS/s.  You cannot get 1 MHz with this board.

 

Lynn

0 Kudos
Message 2 of 9
(4,085 Views)

Yes, I know. But lets say a 0.5 microsec resolution would also work for me.

The jitter I experienced was in the millisecond range.

 

-- Shay

 

0 Kudos
Message 3 of 9
(4,082 Views)

Shay,

 

I think I recall that your progam tried to set the sampling rate to 1 MHz.  I have no idea how the driver or the hardware responds to an out of range value.

 

Try setting the rate to 100 kHz and see what happens.

 

Other things to look at are the size of the buffers on the device and how often you need to write to them to avoid gaps.

 

Lynn

0 Kudos
Message 4 of 9
(4,074 Views)

Hello Shay,

 

The maximum resolution you can output from your PCI-6229 is 1/833Hz ~ 1.2 microseconds.  I would recommend connecting your waveform directly to the DAQmx Timing VI so it can use the exact interval "dt" from your waveform.  The Source you will want to use should be set to ao/SampleClock.

 

DAQ_exp4 revised.png

 

Brian G.
0 Kudos
Message 5 of 9
(4,070 Views)

You can use the waveform to specify timing, however to do this you'll need to change the instance of the DAQmx Timing VI from DAQmx Timing (Sample Clock) to DAQmx Timing (Use Waveform) via the polymorphic VI selector.  I wouldn't expect the waveform data type to coerce to a double and give you the value you'd expect.

 

Hope that helps,

Dan

0 Kudos
Message 6 of 9
(4,062 Views)

Thank you Dan,

 

The correct way to use waveform timing is via the DAQmx Timing (Use Waveform) VI.  This will still use the analog output sample clock for hardware timing. 

DAQ_exp4 revised.png

 

Brian

Brian G.
0 Kudos
Message 7 of 9
(4,056 Views)

Hi Guys,

 

Thank you for all the responses.

 

I did two things which seem to solve the problem:

1. I used a smaller wave form sampling rate (500,000)

2. I moved the start task after the write block (not sure this made any difference, though).

 

Waveform seem to be accurate now.

 

-- Shay

 

 

 

 

0 Kudos
Message 8 of 9
(4,045 Views)

Hi Shay,

 

Generally with DAQmx finite buffered generation you should write data to the memory buffer before starting the task.  But regardless of this, samples will not be output until all the data is written to the buffer.  I can only assume that your issue was resolved by reducing the output rate to 500k.  Glad you were able to get it working as desired, good luck!

 

 

Brian 

Brian G.
0 Kudos
Message 9 of 9
(4,032 Views)