View Full Version : Labview and programming gradual start/stop
crollison
02-03-2015, 13:53
How do you program so that the robot has to gradually start/stop. We are a little top heavy and need to reduce inertia. Looking at the examples and I don't think that the Joystick Response Curve is the right thing? Thanks for any help.
pastelpony
02-03-2015, 13:55
What do you mean "gradually start/stop" ? Do you want to throttle the speed of your drivetrain?
crollison
02-03-2015, 14:00
So that when you jam the joystick forward, it doesn't immediately go full speed.
pastelpony
02-03-2015, 14:22
So that when you jam the joystick forward, it doesn't immediately go full speed.
Multiply your joystck inputs by their absolute value. This squares the inputs, only allowing full speed at a full push. For example, what would normally be 0.5 would be 0.25 and -0.9 would be -8.1 etc.
Nyxyxylyth
02-03-2015, 14:24
If you're using CANTalons, consider letting them do the heavy lifting by using Set Voltage Ramp. See 6.1 in the TALON SRX Software Reference Manual. Consider something like 0.33 (1 second for 0-33%; 3 second ramp from 0-100%).
wt200999
02-03-2015, 14:31
Multiply your joystck inputs by their absolute value. This squares the inputs, only allowing full speed at a full push. For example, what would normally be 0.5 would be 0.25 and -0.9 would be -8.1 etc.
If you look closely at the Tank Drive and Arcade Drive VIs, this is already done for you by default. Though this will not accomplish what was asked. If you jam the joysticks forward with the squared inputs, you will still go full speed immediately.
What you are asking is described fairly well here starting at post #8: http://www.chiefdelphi.com/forums/showthread.php?t=125439
I attached a LabVIEW example at the end in post #10. If you search for the VI "PID Output Rate Limiter" you will get a VI that works well for this, and you can adjust the ramp time.
Chris Hibner
02-03-2015, 14:31
Use the PID rate limit VI which can be found in the control & simulation -> PID palette.
See attached image.
vBulletin® v3.6.4, Copyright ©2000-2017, Jelsoft Enterprises Ltd.