The Citrus Circuits 2023 Fall Workshop videos from Capital City Classic are now available on YouTube! There are presentations from teams 1678, 1671, and 5940, as well as the Woody Flowers panel. These workshops cover a wide range of topics of interest to both rookie and veteran teams, including game analysis, match strategy, effective driving, subsystem prototyping and design, fundraising, scouting development, youth STEM education, team organization, and FRC history. You can watch them all on our YouTube Channel. The videos will also be available through our website soon.
Thank you for your amazing video, I learn a lot from it. However, I have some questions, wondering where can I ask these.
You can ask questions right here!
Firstly, I were wondering if you could release your PPT, because the videos have low resolution.
My second question is about the control loop option of Design For Autonomous video, you mentioned that “control loop for both talon and spark run far fast than on rio”, but you then said that “You would recommend on rio”. Accroding to your explaination, it seem like on spark won’t go to end point if there is a issue. However, I don’t really understand this, could you give more information? And I were wondering if the neo is used on arm or elevator instead of drivetrain, on which one would be better? Moreover, will you recommend smartmotion? I think it similar to motion magic.
My understanding for these are:
Both motion profiling mean PID closed loop control.
On spark means code like rev example
****import com.revrobotics.SparkMaxPIDController;
****m_pidController = m_motor.getPIDController();
On rio means code like wpilib doc
****import edu.wpi.first.math.controller.PIDController
****PIDController​(double kp, double ki, double kd)
If there is any mistake, please feel free to let me know.
I havent worked with smart motion and amAndyMark not on 1678, but my understanding of smart motion from this forum is that it is not the same as motion magic because it does not run a pid loop on position, and therefore has issues holding position
When the videos are posted on our website, we will include a link to the slide decks for all of the presentations. This should be completed soon.
The presenter for Design for Autonomous was from team 5940, so hopefully he will see your question and respond. We’ll also try to pass this on to him just in case he doesn’t.
Sound good, thanks!
I’m not sure what they recommended in the video but for what I know. Control loops on device are generally faster, more responsive, less likely to overshoot. This is because the information is being processed on the device gathering the information and controlling the motor. Processing on the rio has to take the information send it over canbus to the rio the rio processes that information then send the updated control back over canbus to the device.
Never used smart motion. We explored it last year but found it probably won’t work well since it only uses the calculated gains and velocity acceleration values to figure out how fast it needs to go to get to the desired position. This means if when it finishes the profile it will just end up where it ends. There is no actual position control correcting for positional error. The second problem not including position error is if something keeps the mechanisms from moving part way through its motion it has no connection for that. If an elevator would take 2 seconds to move to the top but it stalled the first 1s of the motion profile it will only complete the last 1s of the profile and end up somewhere arbitrary. I’m not sure if there is anything maintaining position after the control loop ends (I’m just not familiar enough with it).
Also from what I understand is that some of the effects of smart motion can be mitigated by using large gear reductions the larger the gear reduction the less effect outside forces and change in force will have on the mechanism making it more reliable. It also means you have a much broader range of gains that will work and it makes it much more reliable at hitting is target. I belong 3739 used smart motion will little issue this year. Maybe @cad321 can elaborate.
CTRE has some good documentation on some of the more advanced this motion profiling can do
Disclaimer I’m not an expert on motion profiling tools so I may be misunderstanding how smart motion works.
Hey, I created and presented that Design for Autonomous presentation. The issue I was trying to highlight, which was correctly pointed out by @Smtopps , is that (to my knowledge, someone correct me if I’m wrong) REV has implemented the motion profile following in the SPARKMax firmware using a velocity control loop, as opposed to a position control loop.
What this means is when you request the SPARKMax to execute a motion profile, it requests the mechanism achieve a certain velocity as the time progresses along the profile. This works in theory, but if you imagine the mechanism hitting momentary resistance and slowing down, not achieving the commanded velocity, its position now lags behind where you intended it to be. Ultimately, the trajectory will not reach the end goal you request.
Contrast this to the CTRE implementation using a position control loop. The controller requests the mechanism go to a certain position as time progresses. This means that if the mechanism hits resistance, the position control loop is still commanding the mechanism go to the intended position. Depending on your tuning of the position PID loop, it might struggle to “make up that lag” in following the trajectory, but at least it tries.
If REV has since updated their SmartMotion software to use a better motion profiling system, please let me know.
The recommendation to use a motion profile on the rio essentially means you should setup your SPARKMax in just position PID mode, with no SmartMotion features. Then you execute a motion profile on the roborio, which at every update, sends a new position command to the SPARK in PID mode. The SPARK will only get positional PID updates at 50Hz or whatever your loop rate is, but that’s probably just fine. It’s the actual closing of the PID loop that benefits from the faster 1KHz rate more than the trajectory following.
Hope that helps.
It was mentioned in the driving video to get the best possible controllers. What are the best possible high end controllers for frc?
Team 1678 – Could you post a link to your website?
This game is from 2365. You cannot understand it yet.
1678 hasn’t attached your slideshow on their website quite yet, do you know if they will in the future? If not could you attach it in this thread? Thank you for sharing your knowledge with us!
Sure thing! Here are the slides, they should be publicly viewable: Design for Autonomous - Google Slides
@Griffin One part that confused me a little about your presentation, the part with control loop tuning, what are you trying to plot with the set-point vs achieved plots?
Is the set-point graph the ideal plot (based on target accel and velocities)? Obviously the achieved is what the sensor got to.
I’m just figuring out how you plot these values to then do the tuning. I agree that graphical tuning would be ideal, just need to figure out how to plot it.
Overall, I thought your presentation was excellent! I really liked the autonomous layer picture, I kinda knew those were the steps needed, but it was presented really well!
Thanks for the feedback! I made this presentation for CCC this year, so there is definitely a lot that can be improved.
Yep, you got it! I refer to it as “setpoint” because that value is the setpoint that is given to the underlying position PID loop that executes the motion profile.
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.