08-03-2013 11:46 AM
Bijay wrote:
Use "get waveform components" VI instead of dynamic to dbl conversion. Avoid use of express VIs like filter and "wait untill next ms multiple" not required.
This is not good advice. If the values the users wants are floating points, then change the DAQmx Read to an instance that returns a DBL array and skip the waveform entirely. Don't suggest replacing one unnecessary function with another equally unnecessary one.
A timing function such as Wait Until Next ms Multiple is highly recommended here; all LabVIEW loops that run indefinitely should include some kind of timing mechanism. The user could, however, drop the Tick Count function inside the loop, and instead use the output from the Wait Until Next ms Multiple.
08-03-2013 11:56 AM
I apologize for wrong advices Nathand.
But why timing function is required for this particular issue as Sampling rate & no. of samples per channel can take care of loop rate.
Regards,
Bijay
08-03-2013 11:56 AM
This is the 2010 version.
08-03-2013 12:16 PM
08-05-2013 07:46 AM
Hi,
Any improvement ?
08-05-2013 11:27 AM
sorry for not responding quickly.I am still working on the system.I will let you know soon.Many thanks again to both of you.
08-06-2013 06:20 AM
My system has improved thanks to both of you. I have one more question my sampling rate is 20kHz and the number of samples that I read is 1000,this give me loop time of 50ms.My PID integration time is 0.0007min.Do I have to keep the loop time the same as the integration time in the PID?
08-06-2013 06:55 AM
Good to hear about the improvement.
No, Loop time and integration time need not be same.
Regards,
Bijay
05-04-2014 01:52 PM
Hi nathand,
Here I have several questions about dt. Hope you can give me some instructions.
1. According to the PID user manual, the PID VI uses trapezoidal integration for the the integral action. The formula is shown in attachment. I wonder does the dt in PID VI the same with Δt in the formula?
2. If dt is leaved unwired, according to labview help, "this VI calculates the time since it was last called using an internal timer with 1 ms resolution." My question is if I use the PID Vi inside a while loop, does this mean the dt will be equal to the while loop rate?
Thanks,
CJ
05-04-2014 01:52 PM
Hi nathand,
Here I have several questions about dt. Hope you can give me some instructions.
1. According to the PID user manual, the PID VI uses trapezoidal integration for the the integral action. The formula is shown in attachment. I wonder does the dt in PID VI the same with Δt in the formula?
2. If dt is leaved unwired, according to labview help, "this VI calculates the time since it was last called using an internal timer with 1 ms resolution." My question is if I use the PID Vi inside a while loop, does this mean the dt will be equal to the while loop rate?
Thanks,
CJ