Some Notes Bruce D. Kothmann 26 Oct 2009 MechaMiniSegway Some Notes Bruce D. Kothmann 26 Oct 2009
Simplified Model Weight Q=Motor Torque Pin Shear Force F= Friction Normal Force FBD of Body Sum Moments @ Center of Wheel (Ignore Wheel Inertia!) Forces Whose Line of Action Goes Through Pin Don’t Show Up! Sum Moments @ Pin in Body MechaMiniSegway Notes
Simple Model (Continued) Sum Forces Parallel to Slop on Both Bodies (Ignore Mass of Wheel!) Substitute Acceleration into Body Moment Equation & Assume Small-Angles MechaMiniSegway Notes
Now Include Motor Equations Voltages in Motor Motor Torque MechaMiniSegway Notes
Parameters Not Difficult to Measure Motor Constants R from Current & Voltage with No Rotation K from Voltage When Driven @ Known Speed Radius (r) Measured Directly Use Total Mass for m Balance Body on Fulcrum to Find CG Length (l) Inertia About Hinge From Pendulum Experiment Hold Wheels with Body Hanging Upside-Down Measure Frequency of Body Swinging Freely [rad / sec] I = (m*g*l) / (frequency)2 MechaMiniSegway Notes
Some Insights From Equations Steady-State Stuff Easy to Calculate & Useful d/dt0 in Trim Also Need Zero Acceleration (a=0Q=mgrg) Note That in Steady State on a Slope: q =(r/l)g ! Need to “Lean Into the Hill” to Counter Steady Torque, Because Total System CG Needs to Be Centered Over Contact Point! Simple Integral Feedback on q Won’t Work! Equations Easily Sort out “Torque versus Speed” Perspectives on Motor Voltage Effect Minimum Gain for Static Stability Easily Calculated MechaMiniSegway Notes
MechaMiniSegway Notes More Insights… Equations Too Simple—Motor Torque Response Won’t Be Instantaneous Proportional Feedback on Angle Will Be Dynamically Destabilizing Need Derivative Feedback How to Prevent Slow Drift & Deal with Slope? It Looks Like PD Feedback on q & Integral Feedback on Speed (W) Might Work? MechaMiniSegway Notes
MechaMiniSegway Notes Other Random Thoughts Scaling of accelerometer voltage into A/D: you really only care about +/- 5 deg, so make sure that is +/- 5 volts (requires simple op-amp?) If you want to do low-pass or high-pass filtering, the very high processor speed may cause problems, because digital filter coefficients may require very high precision. Also, digital filters are easiest to design with a fixed frame rate. MATLAB has a very convenient “C2D” function for converting analog filters to digital. MechaMiniSegway Notes