LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

change frequency 6259

Hi,

 

I have a 6259 and its frequency this around 66 hz,  I wish my frequency was around 100 hz.

I I used the function "wait  until next ms multiple" for 10ms and  I made another function to calculate my dt in the loop, however my dt always displays the value of 15 ms.

if I put the function "wait  until next ms multiple" 20ms in my dt displays 30ms.

Anyone know how to do this?

 

CP

0 Kudos
Message 1 of 7
(3,766 Views)

Hi ee charles,

 

you use 4 different DAQmx tasks and each is set to "1 sample on demand". This is the slowest mode you can have with any DAQmx task!

 

Set a sample rate for your tasks and provide data as fast as is needed!

 

And: use some kind of producer-consumer scheme. It will help you with your application…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 7
(3,754 Views)

Hi GerdW,

First of all, thank you for your answer.

 

do you know how mode is the best to use in my case?

 

Best regards

 

CP

0 Kudos
Message 3 of 7
(3,734 Views)

I think it's not what you said because I created a code with only the function dt and whenever the time is at 15 ms, even with the loop time in 10ms with the fonction wait until next ms multiple.

 

0 Kudos
Message 4 of 7
(3,707 Views)
If you are still using 1Samp mode, that would be wrong. If you are still using Wait Until Next, that would be wrong. You need the DAQ Timing function to set the sample rate with one task for all channels and NSamp mode with continuous samples. Look at the shipping examples.
0 Kudos
Message 5 of 7
(3,699 Views)

Bonjour,

 

Je vous suggère tout d'abord de consulter l'aide labVIEW concernant le cadencement d'applications. Il vous faudra d'abord déterminer si vous voulez un cadencement logiciel ou matériel (http://zone.ni.com/reference/en-XX/help/370466V-01/TOC11.htm).

 

Si vous voulez un cadencement matériel, partez d'un exemple de base fourni dans labVIEW, comme Voltage Finite Input 

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

 

Cordialement,

Pierre-Emmanuel BELLES
Certified LabVIEW Developper
Certified TestStand Architect

0 Kudos
Message 6 of 7
(3,649 Views)

Hello,

 

First of all, I would suggest checking the labVIEW help topic about application timing. You must determine if you need a software or hardware timing : http://zone.ni.com/reference/en-XX/help/370466V-01/TOC11.htm

 

If you go for a hardware timing, then start from a simple example provided in the library of labVIEW examples ; you might want to check Voltage Finite Input : https://decibel.ni.com/content/docs/DOC-25106

 

Regards,

Pierre-Emmanuel BELLES
Certified LabVIEW Developper
Certified TestStand Architect

0 Kudos
Message 7 of 7
(3,647 Views)