Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I generate a10MHz reference clock output from PCI-6110?

I want to get a 10MHz reference clock output from a PCI-6110 to synchronize with another non-NI DAQ card. (1) Is there a pre-set terminal in the 68-pin output connector? (2) Can I use the C-code DAQmxExportSignal function to do this? (3) For either question 1 or 2, what are the parameters of the 10MHz waveform?

0 Kudos
Message 1 of 10
(4,422 Views)

Hi src42,

 

There is no PLL on the 6110 but it does have a 20 MHz and a 100 kHz timebase.  Would the 20 MHz timebase suffice for your external DAQ card?  If so the best way to route the signal (using DAQmx Export Signal) would be to use one of the following:

 

    -PFI 3 (requires counter 1)

    -PFI 8 (requires counter 0)

    -RTSI 7 (direct but you'll need a RTSI cable to connect to the device).

 

 

You can divide-down the timebase using an on-board counter to 10 MHz if you want.  You'll need to set the output mode to pulse instead of toggle, the source to the 20 MHz timebase, and generate 2 ticks high / 2 ticks low.  This will give a pulse every time the counter rolls over, which would be every 2 pulses of the 20 Mhz timebase.

 

 

Our newer DAQ hardware supports reference clocks and does have a 10 MHz Reference Cock available for export.

 

 

Best Regards,

John Passiak
0 Kudos
Message 2 of 10
(4,416 Views)

John,

 

What is the situation with the PCI-6115 card? According to a data sheet I have found, a "frequency scaler" output of 10MHz is supposedly available. I can't tell from the NI documentation about the DAQmxExportSignal function, which cards its signalID value 'DAQmx_Val_10MHzRefClock' applies to.

 

Thanks,

Steve

0 Kudos
Message 3 of 10
(4,397 Views)

Hi Steve,

 

Very good call, both the 6110 and the 6115 have the frequency scaler.  It's mentioned in the S Series user manual on page 7-10 as the "Frequency Output Signal".  The frequency scaler is essentially a limited counter--you could use it instead of one of the full-featured counters to output the divide-down of the 20 MHz timebase.  The available frequencies on the frequency scaler are {100 kHz, 10 MHz} / {1:16}.  In DAQmx, it's programmed just like a basic counter output.  You wouldn't have to worry about the pulse/toggle mode that I mentioned in my last post if you're using the frequency scaler.

 

The 10MHzRefClock signal only currently applies to the 6124, 6154, M Series Devices, X Series Devices, and SC Express Devices.  Device-specific information about synchronization methods can be found in the DAQmx Help:

 

                19111i313C635FF8FDC12B

 

 

If you're trying to synchronize the PCI 6110 to the PCI 6115, the best bet is to use RTSI and share the 20 MHz timebase between the two. 

 

It should be noted that the PXI version of the 6115 does have a sort of PLL--it automatically locks its 20 MHz timebase to the 10 MHz reference clock on the PXI backplane.

 

 

Best Regards,

John Passiak
0 Kudos
Message 4 of 10
(4,389 Views)

John,

There seems to be a conflict in the documentation. When I use the NI MAX explorer application on my mounted PCI-6110 device, there is no routable source shown for a 10MHz reference clock, only 20MHz.

0 Kudos
Message 5 of 10
(4,335 Views)

Hi Steve,

 

There is no 10 MHz Reference Clock on the 6110 or 6115.  If you're referring to the frequency generator (i.e. "frequency scaler"), then this isn't in the device routes tab in MAX since it is hard-wired to pin 1 on these devices:

 

               19415i2036BA168CCB0F94

 

 

To output 10 MHz on this line, you can program it like a regular counter:

 

        19419iCA785720B5E6188F

 

Best Regards,

John Passiak
Message 6 of 10
(4,320 Views)

Hi, John-

 

This is interesting to me also, but I need to do it in C/C++. Can you tell me what calls are required to enable to output (the documentation I found says it is tri-state by default). Would DAQmx_ConnectTerminals do it? How do you control the divider?

 

Thanks!

 

John Weeks

WaveMetrics, Inc.
Phone (503) 620-3001
Fax (503) 620-6754
www.wavemetrics.com
0 Kudos
Message 7 of 10
(4,317 Views)

The equivalent calls in C would be:

 

    -DAQmxCreateTask  (not pictured / necessary in LabVIEW)

 

    -DAQmxCreateCOPulseChanFreq

 

    -DAQmxCfgImplicitTiming

 

    -DAQmxStartTask

 

    -DAQmxIsTaskDone  (call this in a loop to check for errors while the task is running)

 

    -DAQmxClearTask  (to stop the generation)

 

 

The driver will choose the divider for you based on the desired output frequency (specified in DAQmxCreateCOPulseChanFreq).  If you choose a frequency outside of the range of the device, an error should be thrown.  If you choose a frequency within the range of the device but not attainable exactly, the driver will coerce the output to the nearest available frequency.

 

So... if you want a frequency of 10MHz, you would need to specify 10000000 as the freq input to DAQmxCreateCOPulseChanFreq.

 

 

EDIT:  Left out DAQmxStartTask

 

 

 

Best Regards,

John Passiak
Message 8 of 10
(4,312 Views)

Thanks, John. That was fast!

 

And, presumably, the counter to use as input to DAQmxCreateCOPulseChanFreq would be "Dev1/freqout".

John Weeks

WaveMetrics, Inc.
Phone (503) 620-3001
Fax (503) 620-6754
www.wavemetrics.com
0 Kudos
Message 9 of 10
(4,293 Views)

Hi John,

 

That's correct, assuming your device is Dev1.

 

 

Best Regards,

John Passiak
0 Kudos
Message 10 of 10
(4,259 Views)