From cbeb9c63d7fe5e4e1e5710dbd6d52a17c8718305 Mon Sep 17 00:00:00 2001 From: Wouter Horlings Date: Wed, 22 Jul 2020 16:47:23 +0200 Subject: [PATCH] Add stepper documentation --- .../SCARA/05_stepper/implementation.md | 32 +++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 implementation/SCARA/05_stepper/implementation.md diff --git a/implementation/SCARA/05_stepper/implementation.md b/implementation/SCARA/05_stepper/implementation.md new file mode 100644 index 0000000..2791625 --- /dev/null +++ b/implementation/SCARA/05_stepper/implementation.md @@ -0,0 +1,32 @@ +# Stepper motor + +## Motor model +Two detail steps ago we already looked in to stepper motors. +I implemented a model that I found on a [Github repository](https://github.com/SuYouge/Stepper-motor-modeling). +Sy Youge build a model of a stepper motor with a good explaination. + +I could easily implement this. +I expended his bondgraph model with a phase controller. +I only have to put in the desired angle. However, this phase controller does not have any limiting. +Therefore, some control in required to make sure the physical part of the motor can keep up with the electrical rotation. + +## Motor Control +This control is a seperate block. +There are two limitations to the controller. +First it has a limited speed, second it has a limited torque. +If you exceed this speed or torque the motor will stop operating. + +The torque requires a good feed-forward model of the dynamic system. +However, I can just assume the max moment of inertia and then convert the torque in to a maximum acceleration. +This was the easiest option. + +The result is that I have a setpoint for the angle. This is the setpoint for the first PD controller. +This is not a PID as the design of the stepper already solves the steady state error that would have been caused by gravity. +The first PD will then output the desired velocity. We limit this velocity and feed it in to the second PD controller. +This will output the desired acceleration. This is also limited. The acceleration is then integrated twice resulting in a position that is velocity and acceleration limited. +Which is fed in to the stepper motor model. + +A nice feature of this setup is that has no feedback outside of the controller. +Therefore, we do not need any sensors in the system. +Maybe some initial setpoint. +