r Ball and Beam Ө = c*Input Voltage(u) Y = a*x System Equations State Space Model
Hardware Issues and Calibration Wiring Issues Sharp Sensor Output Issues Potentiometer Issues Mechanical Grip Issues
Final Calibration Voltage = ( e-06)*distance^ *distance^ *distance^ *distance y = (4.3862e-07)*x^3 – (3.8462e-07)*x^2 – ( )*x
Control Strategy Also employed the strategy of On-Off Controller
Modeling of DC Motor Position
Open Loop Transfer function of System:
Calculated Stall current = 1.5 Amps Motor Internal Resistance = R = Vs/Is(stall) = 24/1.5 = 16 Ohm Motor torque constant KT = Ts(stall)/(Is(stall)-Is(no-load)) = 54e-3/( ) = Nm/Amp Motor Viscous Friction Constant = b = (KT*Is – Ts)/Rated Speed = e-6 Nms Electromotive force Constant: KE = (Vs – Is*Rm)/Rated Speed = V/rad/sec Value of Constants:
Linearized Model of DC Motor ( *(z+0.99)*(z+5.843e-08)) (z*(z-1)*(z )) Linearized Transfer Function: Sample time: Analysis: There is a pole and zero very near to z = 0 that effectively cancel. -> Makes computations simpler. So, now our transfer function becomes: (z+0.99) (z-1) (z )
State Variables Motor Position Motor Speed Armature Current Input: Armature Voltage Output: Rotational Position
DC Motor State Space Model
Step Response of Linearized Model of DC Motor
Dynamics of DC Motor: With command d2c(sys,'tustin'), we get Continuous-time zero/pole/gain model: e-07 (s+3.981e05) (s-2000) s (s+32.21) Analysis: Zero at 3.98 e05 contributes very little to the response of the plant. Step Closed Loop Response without Compensation
Gain Margin = 38.6 dB(at 254 rad/s); Phase Margin = 57.6 deg (at 20 rad/s) Gain crossover frequency = 3 Hz. So a sampling period of seconds (frequency of 1000 Hz) is significantly faster than the dynamics of the plant.
Rise time: ≤ 0.05 sec Settling time: ≤ 0.25 sec Overshoot: ≤ 5% No steady state Error Bandwidth must be significantly larger than overall ball and beam system. Design Requirement for DC Motor Controller:
Closed Loop for DC Motor P=10; I = 2; D= 0.1; N = *(z ) (z-0.9) Discretized PID Controller:
Overall Closed Loop Response of DC Motor with Controller
Mass of the ball = m= kg Radius of the ball = R = m Gravitational acceleration = 9.8 m/s^2 Length of the beam (on left side of pivot)= 0.357m Ball's moment of inertia = J = (2/5)*M*(R^2) = e-6 kg.m^2 Modeling of Ball and Beam Plant Value of Constants:
Overall Closed Loop Ball and Beam P=25; I = 1; D= 7; N = z z Discretized PID Controller:
Rise time: sec Settling time = 9 sec Overshoot = 5% Overall Closed Loop Ball and Beam Step Response
Product Information Sheet R2-1, Rotary Ball & Beam Experiment, Quanser Inc., Markham, ON, Canada. R. Hirsch, Shandor Motion Systems, "Ball on Beam Instructional System," Shandor Motion Systems, K. C. Craig, J. A. de Marchi, "Mechatronic System Design at Rensselaer," in 1995 International Conference on Recent Advances in Mechatronics, Istanbul, Turkey, August R. A. Pease, "What's All This Ball-On-Beam-Balancing Stuff, Anyhow," Electronic Design Analog Applications, p , November 20, G. J. Kenwood, "Modem control of the classic ball and beam problem," B.S. thesis, Massachusetts Institute of Technology, Cambridge, MA, References