From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
07-19-2019 06:41 AM - edited 07-19-2019 06:43 AM
Hi, I am trying to control a servo motor with a trapeze of velocity by NI 7330. After pressing a "start" button, the velocity will start from 0 with a acceleration, go to a constant speed, stay there for some seconds then go down with a desaceleracion.
I have search the forum but samples I found are too complex. For me, the hardest part is "start" button. If it is in python, it is like: "if t < ... ; v =...- else if... - else ....". But I dont know how to do the same thing with LabView.
Sorry for my bad english. If there is any help/examples/documents I would be very appreciated. Thanks!
Solved! Go to Solution.
07-19-2019 07:11 AM
Hi Giang,
For me, the hardest part is "start" button.
So your VI should wait until you press that Start button? Use an event structure…
If it is in python, it is like: "if t < ... ; v =...- else if... - else ....". But I dont know how to do the same thing with LabView.
The IF-THEN-ELSE is a case structure in LabVIEW…
(It seems you should take the Training resources offered in the header of this LabVIEW board…)
07-19-2019 07:59 AM
The term I have always heard and used for such a profile of Constant Acceleration, Constant Velocity, Constant Deceleration, particularly where the Start and End Velocity is zero, is a "Velocity Trapezoid". It is fairly easy to work out the timing of the stimulus waveform, particularly if the position is not constrained (in my case, I was using this stimulus to "Move from Position A to Position B", which effectively puts a maximum on the allowed Acceleration and/or Velocity values).
Do learn more LabVIEW, particularly the material covered in the Tutorials listed on the first page of this Forum. You will learn about Event Loops, which are excellent ways to "Do Something When I Push This Button". You may need to learn "more than you are ready to absorb", so a good strategy is to find a colleague, a teacher, a LabVIEW Guru whom you can consult who can help you organize the "facts", "structures", and "functions" of LabVIEW into an intelligently-designed Program (VI).
Bob Schor
07-19-2019 09:24 AM
After searching online for what you say, I finally make this VI. I hope it work!
Thank you for information, do you have any advise for my VI?
07-19-2019 09:28 AM
thank you, I will go to tutorials section now.
07-21-2019 09:54 AM
Yes, I have advice for your VI. Attach the VI rather than a "picture" of it -- it wastes too much of my time opening a Picture, then not being able to "see" the other Cases, adjust wires, test the logic, etc.
Bob Schor
07-22-2019 01:12 AM
Hi Giang,
do you have any advise for my VI?