LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

HSDIO Generate Continuous Output Clock

Hi,

I have a NI PXIe-6612 Counter/Timer with DIO.

Using the HSDIO L/V Inst Drivers, I'm trying to get a single output  (PFI 35/P1.3/CTR 1 SOURCE) to generate a continuous TTL 1MHz Square Wave with a 50% Duty Cycle.

I looked through the examples but am unable to find one that matches my requirements.

Please point me in the right direction or provide sample vi.

 

Regards...

 

Ian

0 Kudos
Message 1 of 6
(3,361 Views)

HI Ian, 

 

Your NI PXIe 6612 card doesn't actually support the HSDIO drivers, so even if you did find an HSDIO example to create your pulse train, it would not work with your hardware. 

 

Your card is a Counter/digital I/O card and falls under the Data Acquisition family, so the drivers for the card are actually the DAQmx Drivers. To generate a continuous 1MHz square wave with a 50% duty cycle you want an example for a counter output for a continuous pulse train. I've included a few links below. 

 

http://www.ni.com/example/30090/en/

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

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

 

I hope this helps. 

Vsenior

0 Kudos
Message 2 of 6
(3,333 Views)

Hi,

 

Thanks for that, and it does indeed do the job of putting out a continuous squarewave; however it relies on a "While Loop" with in the Labview code to achive this!

 

Is it not possible to achieve the same result without any Looping, i.e configure, trigger and ignore?

 

Regards...

 

Ian F

0 Kudos
Message 3 of 6
(3,232 Views)

Technically it does use a while loop, but if you look at the logic it really doesn't have anything to do with the signal generation. The whole point of the DAQmx function inside the loop is to stop the loop if there is an error. Otherwise the loop simply sits there looping and wasting computer resources until the stop button is pressed. 

 

This is one of those places where I wish NI would put a little more time into the examples.

 

Mike..


Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 4 of 6
(3,223 Views)

Hi Mike,

 

Thanks for the very prompt reply, and I completely agree with your thoughts; however before I "Close" this subject, I'm just going to give it a try on my H/W after removing the Loop from the example code, fingers crossed!

 

Watch this space.

 

Regards...

 

Ian F

0 Kudos
Message 5 of 6
(3,214 Views)
Well remember that if you simply take the loop out the generation will start and then stop almost immediately. My point was that in creating these demos they should use an event structure inside the loop so you ate wasting resources with the polling.

Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 6 of 6
(3,197 Views)