motor.control.limits() #1715
FLL-Team-24277
started this conversation in
General
Replies: 1 comment 2 replies
-
Your interpretation of the document is correct. How are you measuring the speed? If I run the following program, speed limiting does appear to work. The speed peaks at about 500 deg/s, and you can hear that it doesn't get to top speed. Can you share a program that we can run to reproduce what you are seeing? |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Trying to understand control.limits(). This might just be a documentation issue. Or I'm just not understanding....
The documentation states:
Configures the maximum speed, acceleration, and torque.
If no arguments are given, this will return the current values.
The new acceleration and speed limit will become effective when you give a new motor command. Ongoing maneuvers are not affected.
So I was thinking that given the name "control.limits", and the docs saying it sets the maximum speed & acceleration, it would seems that running this command wouldn't set the ACTUAL speed & acceleration, but the MAXIMUM speed & acceleration. In other words, if I ran this
I thought the motor would run at speed 500, but instead it runs at speed 1000. On the other hand, I set the acceleration (presumably the MAX accel) to 4000 (the default acceleration seems to be 2000 deg/sec^2). But indeed, the motor clearly accelerates much faster.
So, what is the purpose of setting the speed with the control.limits() command? As near as I can tell, it doesn't seem to do anything. On the other hand, it does seem that the control.limit acceleration sets the actual acceleration, rather than the maximum.
Beta Was this translation helpful? Give feedback.
All reactions