Need Help with My ODrive S1 UART Setup
My Setup:
Arduino with UART connection
ODrive S1
What I’ve Accomplished:
Successfully moved the motor to specific positions.
What I Need Help With:
- Safety Behavior: When moving from Position A to Position B, I want the motor to go to a safety position (C) if the measured
iq
exceeds a certain threshold. Is this achievable via UART communication?
- Speed/Velocity Control: How can I set a specific speed or velocity for the motor’s movement between positions using UART?
I’ve tried various approaches but haven’t been able to find solutions. Any guidance would be greatly appreciated!
Thank you for your answer!
- How do I poll for the iq-measured? I tried to do that but did not get any values in my testings.
odriveSerial.print(“r axis0.motor.current_control.Iq_measured\n”);
delay(10); // Wartezeit für Antwort
- Thank you!
You can use the getParameterAsFloat
function – e.g.:
float iq_measured = odrive.getParameterAsFloat("axis0.motor.foc.Iq_measured");
Thank you very much! Works!
Hi! I hope you can help me with a couple of questions:
-
Everything is working well so far, but I noticed some jitter in the iq_measured
value when observing it in the Inspector. The jitter range is around 0.6 (±0.3). Is there a way to reduce this jitter or perhaps a more precise parameter to use for triggering safety behaviors? Would additional controller tuning or enabling anticogging help address this issue?
-
For greater precision, is it recommended to perform extra controller tuning, or does running odrive.setState(AXIS_STATE_FULL_CALIBRATION_SEQUENCE);
achieve the same result? Also, if extra tuning is necessary, is it a one-time process for each new setup?
Thank you in advance for your assistance!