View Single Post
  #2   Spotlight this post!  
Unread 08-05-2015, 19:22
GeeTwo's Avatar
GeeTwo GeeTwo is online now
Technical Director
AKA: Gus Michel II
FRC #3946 (Tiger Robotics)
Team Role: Mentor
 
Join Date: Jan 2014
Rookie Year: 2013
Location: Slidell, LA
Posts: 3,614
GeeTwo has a reputation beyond reputeGeeTwo has a reputation beyond reputeGeeTwo has a reputation beyond reputeGeeTwo has a reputation beyond reputeGeeTwo has a reputation beyond reputeGeeTwo has a reputation beyond reputeGeeTwo has a reputation beyond reputeGeeTwo has a reputation beyond reputeGeeTwo has a reputation beyond reputeGeeTwo has a reputation beyond reputeGeeTwo has a reputation beyond repute
Re: Help with S-Curve Generator

As with so many questions on Chief Delphi, "it depends."

If ending up at the right spot is much more important than controlling the jerk, then yes, go with the positional control. Ex: placing a heavy piece into a tight-fit cradle.

If controlling jerk is more important, and end position doesn't matter too much, control velocity. Ex: Place the glass about there on the table without spilling a drop.

If both are important, you will need to use a true closed-loop control. One of the features of the Talon SRX is that it will perform an internal closed loop. This enables you to drive it using an open loop control as far as the computer is concerned, provided that the SRX will do what you desire. However, this increase in simplicity comes with limitations as to what it actually will do. To achieve both results simultaneously, a simple PID loop as implemented on the SRX will not solve your problem; you will need to bring the sensor results back to the computer to make adjustments for a multi-variable closed loop. As I recall, the CAN driver software provides methods to get these numbers.

Whether you drive the SRX in its own closed loop to control one variable, and tweak it with the computer to get to the final endpoint, or do both parts within the computer is a matter of personal preference/ability and finer details of the task. For example, if the load is not always the same weight, you will more likely find success controlling the motor directly from the computer; you may even find it helpful to use an encoder and let the 'RIO do the integration into position for you rather than install a position sensor and differentiate to turn that into speed. If the process is highly repeatable, then letting the SRX do its thing with just a tweak here or there is probably viable.
__________________

If you can't find time to do it right, how are you going to find time to do it over?
If you don't pass it on, it never happened.
Robots are great, but inspiration is the reason we're here.
Friends don't let friends use master links.

Last edited by GeeTwo : 08-05-2015 at 19:26.