3D HELICOPTER SYSTEM (WITH ACTIVE DISTURBANCE)

Similar documents
SRV02-Series. Rotary Servo Plant. User Manual

Linear Motion Servo Plants: IP01 or IP02. Linear Experiment #0: Integration with WinCon. IP01 and IP02. Student Handout

SRV02-Series Rotary Experiment # 3. Ball & Beam. Student Handout

Lab 2: Introduction to Real Time Workshop

DEPARTMENT OF ELECTRICAL AND ELECTRONIC ENGINEERING BANGLADESH UNIVERSITY OF ENGINEERING & TECHNOLOGY EEE 402 : CONTROL SYSTEMS SESSIONAL

DC SERVO MOTOR CONTROL SYSTEM

Basic Tuning for the SERVOSTAR 400/600

Interfacing dspace to the Quanser Rotary Series of Experiments (SRV02ET)

Lab 1: Steady State Error and Step Response MAE 433, Spring 2012

Rotary Motion Servo Plant: SRV02. Rotary Experiment #02: Position Control. SRV02 Position Control using QuaRC. Student Manual

Rotary Motion Servo Plant: SRV02. Rotary Experiment #03: Speed Control. SRV02 Speed Control using QuaRC. Student Manual

Figure 1: Unity Feedback System. The transfer function of the PID controller looks like the following:

Brushed DC Motor Microcontroller PWM Speed Control with Optical Encoder and H-Bridge

Penn State Erie, The Behrend College School of Engineering

Lab 2: Quanser Hardware and Proportional Control

Performance Comparisons between PID and Adaptive PID Controllers for Travel Angle Control of a Bench-Top Helicopter

Brushed DC Motor PWM Speed Control with the NI myrio, Optical Encoder, and H-Bridge

Servo Tuning. Dr. Rohan Munasinghe Department. of Electronic and Telecommunication Engineering University of Moratuwa. Thanks to Dr.

Development of an Experimental Testbed for Multiple Vehicles Formation Flight Control

MTE 360 Automatic Control Systems University of Waterloo, Department of Mechanical & Mechatronics Engineering

Angle Encoder Modules

Laboratory Assignment 5 Digital Velocity and Position control of a D.C. motor

Brushed DC Motor System

Application Note # 5448

SRVODRV REV7 INSTALLATION NOTES

Application Note Loop Tuning

G320X MANUAL DC BRUSH SERVO MOTOR DRIVE

ECE 5670/ Lab 5. Closed-Loop Control of a Stepper Motor. Objectives

Introduction to Servo Control & PID Tuning

Load Observer and Tuning Basics

The Discussion of this exercise covers the following points: Angular position control block diagram and fundamentals. Power amplifier 0.

Magnetic Levitation System

Advanced Servo Tuning

Fundamentals of Servo Motion Control

Open Loop Frequency Response

X3M. Multi-Axis Absolute MEMS Inclinometer Page 1 of 13. Description. Software. Mechanical Drawing. Features

Sfwr Eng/TRON 3DX4, Lab 4 Introduction to Computer Based Control

Active Vibration Isolation of an Unbalanced Machine Tool Spindle

EE 560 Electric Machines and Drives. Autumn 2014 Final Project. Contents

Laboratory Tutorial#1

BLuAC5 Brushless Universal Servo Amplifier

AE2610 Introduction to Experimental Methods in Aerospace

PSF-520 Instruction Manual

The Allen-Bradley Servo Interface Module (Cat. No SF1) when used with the Micro Controller (Cat. No UC1) can control single axis

DC and AC Circuits. Objective. Theory. 1. Direct Current (DC) R-C Circuit

MTY (81)

Studuino Icon Programming Environment Guide

GE 320: Introduction to Control Systems

Comparative Study of PID and Fuzzy Controllers for Speed Control of DC Motor

BLuAC5 Brushless Universal Servo Amplifier

Position Control of DC Motor by Compensating Strategies

Using CME 2 with AccelNet

Introduction to MS150

Rectilinear System. Introduction. Hardware

n Measuring range ,02 N m to N m n Clockwise and counter-clockwise torque n Low linearity deviation of ± 0.05 % F.S.

SERVO INDEXING AT MECHANICAL INDEXER PRICES

MAE3. Absolute Magnetic Kit Encoder Page 1 of 8. Description. Mechanical Drawing. Features

Quanser Engineering Trainer for NI-ELVIS. QNET User Manual. QNET: HVACT, DCMCT, ROTPENT, MECHKIT, VTOL, and MYOELECTRIC

Servo Tuning Tutorial

Exercise 6. Range and Angle Tracking Performance (Radar-Dependent Errors) EXERCISE OBJECTIVE

PID Control with Derivative Filtering and Integral Anti-Windup for a DC Servo

MEM01: DC-Motor Servomechanism

Tech Note #3: Setting up a Servo Axis For Closed Loop Position Control Application note by Tim McIntosh September 10, 2001

Embedded Control Project -Iterative learning control for

Built-in soft-start feature. Up-Slope and Down-Slope. Power-Up safe start feature. Motor will only start if pulse of 1.5ms is detected.

Modeling and Analysis of Signal Estimation for Stepper Motor Control. Dan Simon Cleveland State University October 8, 2003

Motions and Forces Collision I

Ball and Beam. Workbook BB01. Student Version

MGL Avionics Autopilot. Servo. Specifications & Installation Manual. Last Update: 20 October Disclaimer:

Electric Drives Experiment 5 Four-Quadrant Operation of a PMDC Motor

SCS Automation and Control Ltd

5 Lab 5: Position Control Systems - Week 2

Automatic Control Systems 2017 Spring Semester

Root Locus Design. by Martin Hagan revised by Trevor Eckert 1 OBJECTIVE

ECE 203 LAB 6: INVERTED PENDULUM

Generator Operation with Speed and Voltage Regulation

VERTICAL ANEMOMETER YOUNG GILL PROPELLER 27105T & 27106T

Design of a Simulink-Based Control Workstation for Mobile Wheeled Vehicles with Variable-Velocity Differential Motor Drives

Screw Driven automation tables

3B SCIENTIFIC PHYSICS

GE420 Laboratory Assignment 8 Positioning Control of a Motor Using PD, PID, and Hybrid Control

A3 Pro INSTRUCTION MANUAL. Oct 25, 2017 Revision IMPORTANT NOTES

Software User Manual

UNIT 2: DC MOTOR POSITION CONTROL

Procidia Control Solutions Dead Time Compensation

ENGINEERING SPECIFICATION

Feedback Devices. By John Mazurkiewicz. Baldor Electric

Experiment 3. Performance of an induction motor drive under V/f and rotor flux oriented controllers.

Motomatic via Bode by Frank Owen, PhD, PE Mechanical Engineering Department California Polytechnic State University San Luis Obispo

USER MANUAL. SRV02 Rotary Servo Base Unit. Set Up and Configuration

MEM380 Applied Autonomous Robots I Winter Feedback Control USARSim

About this Manual: Chapter 1 provides a summary of the Servo System and all gains used for the Servo System loops.

sin(wt) y(t) Exciter Vibrating armature ENME599 1

A Searching Analyses for Best PID Tuning Method for CNC Servo Drive

STICKMAN MANUAL EINDHOVEN UNIVERSITY OF TECHNOLOGY 11/3/2010. Koolmees, H.B Moris, B Thevissen, T.A.J

Lab 2b: Dynamic Response of a Rotor with Shaft Imbalance

Speed Feedback and Current Control in PWM DC Motor Drives

Radiation characteristics of an array of two dipole antennas

Installation Tech Note Dallas, Texas

Computer Numeric Control

Transcription:

3D HELICOPTER SYSTEM (WITH ACTIVE DISTURBANCE)

1 SYSTEM DESCRIPTION The 3D Helicopter consists of a base upon which an arm is mounted. The arm carries the helicopter body on one end and a counterweight on the other. The arm can pitch about an elevation axis as well as swivel about a vertical (travel) axis. Encoders mounted on these axes allow for measuring the elevation and travel of the arm. The helicopter body is mounted at the end of the arm. The helicopter body is free to swivel about a pitch axis. The pitch angle is measured via a third encoder. Two motors with propellers mounted on the helicopter body can generate a force proportional to the voltage applied to the motors. The force generated by the propellers can cause the helicopter body to lift off the ground. The purpose of the counterweight is to reduce the power requirements on the Figure 1 3D Helicopter system - shown here with active disturbance option. motors. The counterweight is adjusted such that applying about 1.5 volts to each motor results in hover. All electrical signals to and from the arm are transmitted via a slipring thus eliminating the possibility of tangled wires and reducing the amount of friction and loading about 1

the moving axes. The purpose of the experiment to design a controller that allows you to command the helicopter body to a desired elevation and a desired travel rate or position. If you have purchased the Active Disturbance Option, the system will also be equipped with a motorized lead screw that can drive a mass along the main arm in order to impose know controllable disturbances. 2 Mathematical Modelling Three differential equations are required to describe the dynamics of the system. A simple set of differential equations is developed as follows. 2.1 Elevation Axis Consider the diagram in Figure 2. Assuming the pitch is zero, then the elevation axis torque is controlled by the forces generated by the two propellers Ff+Fb. The body will not rise until the total force Fm = Ff + Fb is greater than the mass differential force Fg. Once the body is in the air, and assuming zero pitch, the differential equation is: Fm mw la Elevation Fg mh Figure 2 Simplified model for elevation dynamics 2

where J e is the moment of inertia of the system about the elevation axis, V f and V b are the voltages applied to the front and back motors resulting in forces Ff and Fb, K f is the force constant of the motor/propeller combination l a is the distance from the pivot point to the helicopter body T g is the effective gravitational torque due to the mass differential F g about the elevation axis (adjust counterweight so M g is. 70 gms or F g. 0.5 N). 2.2 PITCH AXIS Consider the diagram in Figure 3 and the associated photograph. The pitch axis is controlled by the difference of the forces generated by the propellers. If the force generated by the front motor is higher than the force generated by the back motor, the helicopter body will pitch up (positive). Fb lh Pitch Ff Figure 3 Simplified model of pitch axis dynamics J p is the moment of inertia of the helicopter body about the pitch axis. l h is the distance from the pitch axis to either motor. 3

4

2.3 Travel Axis The only way to apply a force in the travel direction is to pitch body of the helicopter. Assume the body has pitched up by an angle p as shown in Figure 3. For small angles, the force required to keep the body in the air is approximately F g. The horizontal component of F g will cause a torque about that the travel axis which results in an acceleration about the travel axis: Fb Fg Fg sin(p) Ff Pitch Travel la Figure 5 Simplified model of Travel axis where 5

r is the travel rate in rad/sec. K p is the force required to maintain the helicopter in flight and is approximately Fg. sin(p) is the trigonometric sin of the pitch angle. If the pitch angle is zero, no force is transmitted along the travel axis. Note that for the defined directions, a positive pitch causes a negative acceleration in the travel direction. That means that the elevation acceleration is a function of the sum of the voltages applied to the motors, the pitch is a function of the difference in the voltages applied to the motors and the travel is proportional to the pitch angle. 3 Control System Design : Pass #1 We will design three control loops that will allow us to command a desired elevation position and a desired travel rate 3.1 Elevation controller Neglecting the gravitational disturbance torque T g, we have the following linear system: where V s = V f + V b is the sum of the voltages applied to the motors. We design a PD controller of the form: resulting in the closed loop transfer function: The denominator is of the form 6

with a peak time of By selecting a desired peak time(t p ) and damping ratio (.) we can then solve for Kep and Ked to obtain a desired closed loop response. We then augment the controller to include an integral term to compensate for the gravitational disturbance T g. The controller now is: The gain K ei is tuned on-line. Typically a good starting value is K ei = 0.1 K ep. This design is performed using the supplied MATLAB script file elev_d.m 3.2 Pitch controller The pitch axis will be used to control the travel rate r. In order to control the travel rate we need to design a controller that will allow us to command the pitch angle. The open loop pitch axis equation of motion is: We design a proportional PD controller of the form: resulting in a closed loop transfer function: which can then be solved for K pp and K pd for a desired peak time and damping ratio. 3.3 Travel rate control 7

The linearized equation for the travel rate dynamics is given by: In order to achieve a desired travel rate r c we will design a closed loop controller that commands a desired pitch angle p c : assuming that p tracks p c instantaneously and accurately, we then have the following closed loop transfer function This controller can also be designed as a second order controller by selecting a desired peak time t p and damping ratio.. The attractive feature in the structure of this controller is that we can limit the pitch command p c not to exceed a desired value p max. For example, we can limit p c not to exceed 20 degrees so that we have a comfortable ride. This limits the acceleration in the system but maintains the helicopter body relatively horizontal. If you limit the pitch command to 60 degrees the system will start and stop faster but the body will pitch considerably and loss of altitude may result as well. Note that we are designing three loops with different peak times. It is very important to design the pitch axis closed loop system to be much faster than the travel axis closed loop system since the travel axis controller is designed assuming that the pitch axis responds immediately to the desired pitch command. 3.4 Final output The above controllers result in the control signals Vs and Vd given by: We still need to compute the voltages to each motor. The above equations are solved to obtain: 8

which are the final control signals to the motors. The design parameters chosen for the controllers are: t p. design file Elevation 1.5 0.707 elev_d.m Pitch 1. 0.707 pitch_d.m Travel 10 0.707 travel_d.m These values can be changed by editing the m files supplied in order to obtain new gains. The file design1.m runs all three design files in one shot. With the above specifications, the gains obtained are: Gain Value Units Kep -0.4326 V / deg Ked -0.2065 V / deg sec -1 Kei -0.0433 V / deg sec Kpp -0.1437 V / deg Kpd -0.0457 V / deg sec -1 Krp 1.2679 deg / deg Kri 0.3983 deg / deg sec -1 9

3.5 Quick step to running WinCon All controllers are drawn in Simulink and run in realtime using WinCon. Please refer to the WinCon manual for more details. In order to run any controller however, here are the basic steps: Start Matlab and navigate to the desired directory Enter the filename of the Simulink model ( eg heli3r ) - This opens the Simulink diagram of the controller Enter the name of the design file (eg lqr_r or design) - this sets the feedback gains Click on WinCon/ Build in the diagram - this generates realtime code and downloads to the WinCon Client Click START in the WinCon main window or Simulation/Connect to target in the Simulink window For more details, please see the WinCon manual. 3.6 Results: Pass #1 The above controller is implemented in WinCon and the results are shown in the plots in Figure 6. The applied elevation command starts off at 40 degrees and then alternates between 40 and 60 degrees. We note that the first time the elevation slowly rises towards the desired value. This is because the integral gain is not large enough. Eventually however the desired levels are maintained. The commanded travel rate starts at 0 deg/sec and then switches to 30 deg/sec and then -30 deg/sec. The actual travel rate overshoots considerably. The commanded pitch PC which is generated by the rate loop and the actual pitch are shown in the second plot. We note that the commanded pitch is saturating at 20 deg. ( By saturating p c in the software) and that the pitch tracks the desired pitch relatively well. 4 Control System Design : Pass #2 The above controller is not intuitive to design. We have to select peak times and damping ratios for each loop with little knowledge of what they should be. We will now obtain an optimal LQR controller that is a little more intuitive to design. Let us rewrite the linearized equations in state space as: 10

Note that we have augmented the states to include the integrals of elevation ( ) and travel rate ( ). We can now design a controller that minimizes the performance index: voltages) ( where x are the states in the state equation and u are the input R = diag([1 1]) Q = diag([100 10 1 1 100 1.5 ]) results in the feedback gains : 11

or The full state feedback results in a controller that feeds back two voltages : This type of feedback does not take into consideration the pitch in the body. In attempting to track the desired rate, the pitch may be compromised and thus we could loose altitude or have an uncomfortable ride. We need a controller that would still allow us to limit the pitch angle no matter how fast the desired travel rate is. Looking at the feedback gains obtained from the LQR design we note the following (astonishing!) feature: The second row gains have the exact magnitudes of the first row! Furthermore the sum of the two rows results in: Compare this with the controller we designed in the second order case: They are exactly the same in structure! That means that the gains we obtain from LQR design can still be used for the elevation controller as follows: 12

How about the other gains, can we use those? Let us examine the difference between the gains (ie Vf-Vb): or Now let us look back at the second order controller we designed for pitch and travel rate: These are: and which results in: which when expanded is: which is exactly of the same form as the LQR controller for (Vf-Vb). That means that we can design an LQR controller and still maintain the same structure we used previously and thus limit the pitch angle! The feedback gains for the controller are obtained from the LQR gains as: 13

The advantage of this design approach over the second order approach is that we do not have to guess desired peak times and damping ratio s. We simply select the entries in the Q and R matrices to obtain a desired response. For example if we are not pleased with the speed in which the system tracks the desired elevation, we increase the values of q11 and q16. If the system is not damped enough we increase q13 and decrease q16. The design we have performed results in the gains ( see lqr_r.m) : Gain Value Units Kep -0.2640 V / deg Ked -0.1637 V / deg sec -1 Kei -0.0248 V / deg sec Kpp -0.1404 V / deg Kpd -0.0517 V / deg sec -1 Krp 1.9040 deg / deg Kri 0.1249 deg / deg sec -1 The design is performed using the MATLAB script file lqr_r.m 5 Results : Pass #2 The response of the system to the same command as in the previous design is shown in the plots in Figure 7. We note that the elevation response is much faster, the travel rate response is well damped and furthermore the coupling response is altogether better. 6 Position Control You may want to design a position controller instead of a rate controller for the travel 14

50 40 Elevation Command Travel rate Command Elevation Travel rate 30 20 10 0-10 -20-30 -40 0 10 20 30 40 50 60 70 Time Figure 6 System response with LQR controller axis. This would be done for example if you want to operate in automatic mode and start and land in the same position. In this case the travel differential equation becomes: where 8 is the travel in rad. In order to achieve a desired travel position we will design a closed loop controller that commands a desired pitch angle: The system can be re-written in state space form as: 15

Performing LQR design (see lqr_p.m ) design, we can obtain the gains: Gain Value Units Kep -0.39 V / deg Ked -0.27 V / deg sec -1 Kei -0.055 V / deg-sec Kpp -0.35 V / deg 16

Kpd -0.107 V / deg sec -1 Ktp 2.77 deg / deg Ktd 3.4 deg / deg sec -1 Kti 0.07 deg / deg-sec The response of the closed loop system is shown in Figure 8. We start by commanding the elevation to 40 degrees while maintaining the travel position at 0 degrees and then lift to 60 degrees. We then command the travel to +30 degrees and then travel to -30 degrees and so on. We note that the response is quite acceptable. There are slight errors which are eventually reduced fractions of a degree thanks to the integrators. 45 40 35 30 Elevation Command - Deg Travel position Command - Deg Elevation - Deg Travel - Deg 25 20 15 10 5 0-5 0 10 20 30 40 50 60 70 Time Figure 7 Response of position control system 17

7 Active Disturbance System (ADS) If your system has an active disturbance mass - you can then apply known controllable disturbances to the system while it is in operation. The active disturbance system consists of a lead screw driven by a motor. Attached to the lead screw is a mass that can be made to travel along the arm as shown in the Figure 9. Moving the mass results in changing the force F g depicted in Figure 2. Figure 8 Active Disturbance System The ADS has a DC motor and an encoder. A closed loop controller should be used to position the mass along the arm. Before you start your experiment, the ADS should be calibrated. An auto-calibration procedure is supplied with the system that moves the mass to the back end and detects the end of motion. Once the end of motion has been reached, the encoder counter is reset and the home position is established. This position is at the point furthest away from the helicopter body ( towards the base). The system is then commanded to move forward to the middle position which is referred to as the center position. The moving mass consists of one mass directly attached to the lead nut and two extra masses that can be attached if desired. The plot in Figure 10 shows the effective disturbance that is attained at various positions along the arm away from the home position. By attaching the extra masses, you can obtain a disturbance of about 100 gms at the end of the arm. That is the maximum allowable disturbance to the system before the propeller motor amplifiers saturate. 100 90 80 70 60 50 40 30 20 10 0 0 5 10 15 20 25 Figure 9 Effective disturbance in gms vs mass position(relative to the home position) Red is using the main mass, green is with one extra mass and blue is with two extra masses. 18

The following is information that you may require for the disturbance system: Parameter Value Units Motor Torque constant 0.0076 Nm/Amp Motor gearbox gear ratio 3.7 NA Lead screw lead 0.8467 cm / turn Encoder resolution 4096 counts/rev Motor voltage - nominal 6 Volts Maximum motor voltage - intermittent 15 Volts Gain cable to use 3 V/V Maximum travel 27.94 Cm Maximum speed of mass 50 cm/sec 7.1 Using the ADS In order to use the ADS, connect it as follows: Encoder Motor To encoder #3 on the MultiQ board To UPM 1503 using gain = 3 Cable UPM 1503 input To Analog output # 3 on MultiQ You then need to have a closed loop controller that will auto-calibrate and then allow you to command the mass to a desired position. 19

Generally you will need to run the ADS while a helicopter controller is running. In order to do that you will need to calibrate the ADS before you start the helicopter controller. It is recommended that you do this as shown in Figure 11. The Disturb subsystem is the ADS with autocalibration. When the system has finished calibrating, then it enables the helicopter controller. That would be the best way to test your controllers without inposing disturbances at startup. Signal Generator Position Disturb Cal OK Looking inside the Disturb: subsystem we have the blocks shown in Figure 12. When the controller starts, the output labeled OK is LOW. That means the switch selects the Home position command (0 cm.) Once the system is H3D Figure 10 General approach to using the ADS calibrated, the OK goes HIGH and using a 5 second delay the switch selects the value coming in from the input port labeled Position. At this point the ADS will track the desired position. Once calibrated, we also send a Cal OK signal to the helicopter controller with a 2 second delay. Looking inside the ADS block we have the system shown in Figure 13. 20

1 Position 0 Home Switch 1 z Unit Delay Position Cmd ADS OK 1 z Unit Delay1 1 Cal OK Figure 11 ADS auto-calibration subsystem The input section in Red simply measures the encoder from the ADS and converts to cm using the known calibration constants. When the controller starts, the output of the Flip-Flop is LOW and the MultiPort switch selects the (-3) to be applied to the motor. This causes the motor to start turning and the mass to move backwards. At some point, the mass hits the end and the motor stops turning. The measured velocity then drops to a value below a desired threshold ( MinSpeed = 2cm/sec in this case). When the minimum speed is attained, then the flip flop output is set and the the encoder counter is reset. The Multiport switch now selects the voltage being calculated using the PD controller (k1 and k2). This controller feeds back a voltage to the motor as: 21

Servo Error1 1 Position Cmd 13.97 Moving limit Rate Limiter Cmd Middle Servo Error 3 k1 Position Saturation Quanser Consulting MQ3 ENC Encoder Input -K- Calibration cm/count 15s s+15 Derivative Velocity.002 k2 Sum 1 Constant2 Volts Sum1-3 Clock Move back Slowly Quanser Consulting MQ3 DAC >= 0.5 Time limit1 Wait til it moves AND S Q Multiport Switch Analog Output 1 u Stopped OK Abs <= after 1 second R!Q 2 Stopped S-R Flip-Flop Min speed Quanser Consulting MQ3 ENCR Encoder Reset (edge-triggered) Figure 12 Inside the ADS block ( see heli3p_dist.mdl for details) Since the encoder reset occurs at the end of travel, we also add 13.97 cm to the incoming command so that the actual commands being applied can be between +/- 13.97 cm. The command is rate limited to 50 cm per second in order not to exceed the maximum speed of the motor. 7.2 Disturbance response The controller heli3p_dist.mdl is used to test the disturbance response of the system using the maximum mass. The helicopter controller is the same as the one described in section 6 but it has now been embedded into the H3D block shown in Figure 11. It becomes enabled only once the ADS has been calibrated. Once the ADS is calibrated the H3D block is enabled and the normal helicopter controller starts running. The signal generator feeding the disturbance command the mass to move to +/- 13 cm about the middle position thus causing a full positive and negative disturbance while the controller for the helicopter runs. The frequency of the disturbance is 0.05 Hz thus causing a change every 10 seconds. Figure 14 shows the response in elevation due to a step disturbance applied every 10 22

seconds. The disturbance mass moves +13 cm and -13 cm ( or 0 to 26 cm from the home position). The helicopter controller is supposed to maintain an elevation of 30 degrees and we see that each time the disturbance mass moves, a disturbance response is observed at the elevation axis which is slowly compensated for by the controller. 35 Mass Position from Home - cm Elevation Command - Degrees Actual Elevation - Degrees 30 25 20 15 10 5 0 0 10 20 30 40 50 60 Time Figure 13 Disturbance response - Blue trace is the position of the disturbance mass while the red trace is the actual elevation which should track the green line. 23

8 System Parameters 8.1 Electromechanical Symbol Name Value Units V m Maximum motor voltage (at input to amplifiers) 5 Volts Rm Armature resistance 0.83 Ohm Km Torque constant.017 Nm/Amp Kb Back emf.018 V/)rad/sec) G a Amplifier gain(in cable) 3 V/V Jm Motor & prop inertia 1.7e-5 Kg m 2 K f ** Motor Force Constant 0.5 N/Volt l a l h lw J e & J t J p Arm length from elevation axis to helicopter body distance from pitch axis to either motor distance from pitch axis to counterweight Moment of inertia about elevation & travel axes Moment of inertia about pitch axis 0.66 m. 0.177 m 0.47 m 0.91 Kgm 2 0.0364 Kgm 2 M h Mass of helicopter 1.15 Kg M w Counterweight 1.87 Kg M g Effective mass of helicopter 0.07 gm* K p Force required to keep body aloft (g. M g ) 0.686 N * Nominal. Adjust counterweight position to achieve this mass. ** The value of Kf is for the 8 x 6, 3 blade props. 24

You may want to perform better modeling and include the propeller dynamics. In order to obtain such a model, we have collected the following steady state data. V(D/A) Vm F(N) Im 0 0 0 0 1.0 3.098 0.35 2.0 6 0.41 0.93 3.0 9 0.84 1.7 4.0 12 1.37 2.7 5.0 15 1.94 3.7 The table shows the voltage output at the D/A, the motor voltage (using a gain = 5 cable), the effective lift force exerted by the motor/prop pair and the motor current. Using this data you can derive a Force constant for the actuator as well as a time constant using the motor equations: Note that the constants Kpt and Kp need to be derived from the collected data. These are obtained by performing a least squares fit to straight lines as shown below (see p086g3.m for details). Using the collected data we obtain: The step response to voltage is derived to be: and is shown in the fourth plot. 25

2.5 Force vs Volts (Kf) 0.08 Torque vs Speed (Kpt) 2 0.06 1.5 0.04 1 0.02 0.5 0 0-0.02-0.5 0 2 4 6-0.04 0 200 400 600 800 2.5 Force vs Speed (Fw) 2 Maximum Force Step Response 2 1.5 1.5 1 1 0.5 0 0.5-0.5 0 200 400 600 800 0 0 0.2 0.4 0.6 0.8 1 Figure 15 Calibration plots for propellers 26

8.2 Encoders Axis Counts / Rev (in quadrature) Calibration constant (Deg/Count) Travel 8192 0.0439453125 Pitch 4096 0.087890625 Elevation 4096-0.087890625 Note that to achieve the desired definitions for positive directions you have to multiply by the correct sign. 8.3 Control Software 8.4 Design and control programs The following MATLAB script files are supplied with the system to assist you in designing the controllers. elev_d.m pitch_d.m travel_d.m design1.m lqr_r.m lqr_p.m heli3r.mdl heli3p.mdl heli3p_dist.mdl second order elevation position loop second order pitch position loop second order travel rate loop all three above loops LQR design of travel rate controller LQR design of travel position controller Implementation of rate controller -run lqr_r to get gains Implementation of position controller- run lqr_p to get gains Implementation of position controller with ADS - run lqr_p to get gains Run the m files to obtain the gains. Open the Simulink files in Simulink and build for WinCon. 27

9 Setting Up Figure 16 Attach the Motor cable Figure 17 Attach the encoder cables Figure 18 Attach the motor RCA connectors - maintain red to red, black to black terminals 28

9.1 Mechanical setup 9.1.1 Place the support base on a table or on the floor. Align the elevation encoder frame with the top of the base and tighten the two thumb screws. Install the main arm ( Blue) by guiding it through the elevation encoder frame. Align the icons ( to and to ). Tighten the cap screw maintaining perpendicularity to the elevation encoder frame wall. Note that extreme loads in the vertical direction must not be applied. Attach the connectors protruding from the main arm to the two connectors on the elevation encoder fixture (6 Pin Din to 6 Pin Din are the motors, 5 Pin Din to 5 PIn Din are the pitch encoder). Ensure sufficient slack in the wiring harness to accommodate the total travel of the arm. Never lift the system using the blue arm. Always carry from the base with one hand and stabilize the blue arm with the other hand. 9.1.2 Attach the flat 5 pin encoder connector to the elevation encoder as labeled. Align connector pin #1 (GND) with the encoder body labeled GND and insert the connector. 9.1.3 Obstructions that may interfere with the complete axial motion of the system should be removed. Attach the helicopter body to the pitch encoder fixture as shown in the photographs. Align the icons ( to and to ). Note: the Front motor and Back motors are marked. Tighten the screw into the encoder fixture. Adjust the helicopter body such that it is perpendicular to the arm. 9.1.4 Attach the secondary arm to the end of the main arm at the angle as shown in Figure 20. Tighten the three screws supplied. Only when the secondary arm is securely tightened attach the counterweight to the hole marked 70 gms. and tighten the thumb screw to secure the weight. Caution - this item is very heavy! Figure 19 Counterweight 9.1.5 Utilizing a weigh scale ( eg a postage scale) weigh the body of the helicopter with the counterweight attached at the other end. The desired mass differential is approximately 70 gm. If the body does not weigh 70 gm, adjust the position of the weight (forward or backward) until the body weighs approximately 70 gm. Once in place the weight adjustment does not have to be repeated. If you do not have a scale, leave the mass at marked position. Note that the secondary arm angle relative to the main arm has been selected such that the effective mass at the helicopter end is relatively constant. 29

9.2 Electrical Setup THE COMPUTER SHOULD BE OFF - Please refer to the MultiQ manual to install the MultiQ. Please refer to the Systems and Procedures manual to learn how to run controllers using WinCon. The subsequent images will illustrate various connections. 9.2.1 Motor Connections on the 3D Heli system: Attach the RCA motor connectors on the body to the terminals protruding from the end of the arm. Maintain red to red and black to black connections. Attach the Motor 6 pin DIN connector to the 6 pin din socket located under the elevation encoder frame. 9.2.2 Encoder connections to the MultiQ Attach the encoders to the MultiQ terminal board as follows (Note that grey cells are only for system equipped with ADS) : From Experiment To MultiQ Terminal board Cable Travel encoder Encoder input #0 5 PIn Pitch encoder Encoder input #1 5 Pin Elevation encoder Encoder input #2 5 PIn ADS encoder Encoder input #3 5 Pin 9.2.3 Motor connections to amplifiers From Power Modules To Experiment Cable UPM2405 #1 Front Motor 6 Pin Din 4 PIn Din UPM2405 #2 Back Motor 6 Pin Din 4 PIn Din UMP1503 ADS motor 6 Pin Din 4 PIn Din Gain 5 5 3 9.2.4 Analog output connections to the amplifiers From MultiQ Terminal board To UPM From D/A Cable 30

Analog Output D/A #0 UPM2405 #1 5PIN DIN / RCA Analog Output D/A #1 UPM2405 #2 5PIN DIN / RCA Analog Output D/A # 3 UPM1503 5PIN DIN / RCA 9.2.5 Joystick connections to the amplifier Attach the joystick to the quick connect module on UMP#1, X!S3 & Y! S4. The joystick voltages are measured in the simulink block using Analog Input Channels 2 (X) & 3 (Y). They may be used to create commands to the system instead of the square waves. Figure 20 UPM Conections 9.2.6 Analog input connections to the amplifier Attach from the UPM which has the joystick attached a cable from To A/D to channels 0, 1 2 & 3 of the MultiQ Terminal board Analog inputs. ( S1! 0, S2!1, S3! & S4! 3. (Cable: 5 Pin Din to 4 x RCA) 31

Figure 21 MultiQ terminal board connections 32

9.3 Caring for your system Please take care of the system. Although robust, you should treat it delicately. Note: Rotating propellers can cut injure fingures. The slipring may eventually get soiled. Clean it by spraying it only with a contact cleaner. Do not touch the contacts unless they are visibly bent. If they are bent, bend them back slowly using soft plastic TWEEZERS and nothing bigger! (They should never bend really). In normal operation mode, the fingers will not distort or misalign. If they do the contact support plate must be disassembled by a qualified technician. If measurements are not as expected, it is likely that the connectors to the encoders may have come loose. Check these and ALWAYS insert them with the correct orientation. Occasionally you may need to tighten the propellers onto the motor shaft. You should regularly check if that is required. 33

Figure 23 A healthy slipring 34

Power Supply Joystick +Vs GND -Vs Test Points To A/D S 1 & S 2 S 3 S 4 S 1 S 2 G F R O M S 3 S 4 A N A L O G SENSORS Power Amplifier - O U T S1 S2 To MultiQ Analog Inputs S3 - Joystick X To A/D #2 S4 -Joystick Y To A/D #3 From D/A MultiQ Analog Output Ch0 + G N D UPM2405 #1 To Load Gain = 3 Cable Motors Test Points F R O M A N A L O G SENSORS S 1 & S 2 From D/A + S 3 S 4 Power Amplifier - O U T G N D UPM2405 #2 To A/D S 2 G S 3 S1 S 4 To Load Gain = 3 Cable Front Encoders Back Travel Pitch Elevation To Encoder #0 on MultiQ To Encoder #1 on MultiQ To Encoder #2 on MultiQ 35