EEC 284 Course project autopilot quadcopter Minjie Zhu

  • Slides: 19
Download presentation
EEC 284 Course project autopilot quadcopter Minjie Zhu Meitong Chen

EEC 284 Course project autopilot quadcopter Minjie Zhu Meitong Chen

INTRODUCTION Quadcopter --- a multirotor helicopter propelled by four rotors. Unlike traditional helicopter or

INTRODUCTION Quadcopter --- a multirotor helicopter propelled by four rotors. Unlike traditional helicopter or fixed-wing aircraft, it does not need to vary the rotor blade pitch angle. This simplifies the design and control of the vehicle. It is often used in applications such as aero-photography, aerial mapping. We use the quadcopter model ‘Hugo’ by Aerotestra for our project Image from aerotestra. com

Hardware Image from ardupilot. com

Hardware Image from ardupilot. com

Quad Frame Each motor/propeller spinning in the opposite direction from the two motors on

Quad Frame Each motor/propeller spinning in the opposite direction from the two motors on either side of it (i. e. motors on opposite corners of the frame spin in the same direction). A quad copter can control it’s roll and pitch rotation by speeding up two motors on one side and slowing down the other two. The copter can precess (yaw) CW or CCW by speeding up two motors that are diagonally across from each other, and slowing down the other two. Altitude is controlled by speeding up or slowing down all motors at the same time. Image from ardupilot. com

Manual control with telemetry: The remote controller sends out the throttle, yaw, pitch and

Manual control with telemetry: The remote controller sends out the throttle, yaw, pitch and row values through 4 channels of PWM RF signal. The RF receiver on the copter will response to the change of duty cycles and will interpret it, sends the value back to flight controller yaw Throttle pitch Roll

Software Mission planner It links data communication between quadcopter and PC. The software provides

Software Mission planner It links data communication between quadcopter and PC. The software provides convenient way to do the following: Calibrate sensors/motors/telemetry Monitor flight status Set GPS points for auto flight Running python script to do auto piloting

Autopilot by running a script #Force mode to be loiter while cs. mode !=

Autopilot by running a script #Force mode to be loiter while cs. mode != 'Loiter': Script. Change. Mode('Loiter') Script. Sleep(100) print 'mode switched to %s' %(cs. mode) Script. Sleep(1000) #Arming motors print_stage('arming') a=0 while cs. armed == False: Script. Send. RC(3, 1000, True) Script. Send. RC(4, 2000, True) print ("arming, count is", a, 'status is', cs. armed) a = a+1 Script. Sleep(250) print 'Motors Armed!' Script. Sleep(500)

Objective 1 Taking off and landing Instructed by the script, the copter will arm

Objective 1 Taking off and landing Instructed by the script, the copter will arm the motor and take off from ground (throttle = 1700). When it senses that it is at certain height, it will land immediately (throttle = 1200). http: //youtu. be/Z 9 aye. OXX 0 ug

Objective 2 Landing with PI controller To improve the landing process, we construct an

Objective 2 Landing with PI controller To improve the landing process, we construct an external PI control algorithm in the script. It makes the landing process smooth. http: //youtu. be/zy 1 l-LFvrp. E

Objective 3 Loitering at constant height (altitude hold) After the copter takes off, script

Objective 3 Loitering at constant height (altitude hold) After the copter takes off, script will instruct the copter to maintain its height by sending a constant throttle mid value (1500). Ideally the copter will balance itself utilizing the built in loiter mode, yet in practice it will go up and down. We add a boundary condition to force the altitude hold. http: //youtu. be/OUc 12 ylfj. Ms

Objective 4 Moving on a horizontal plane Assuming the copter can maintain height under

Objective 4 Moving on a horizontal plane Assuming the copter can maintain height under previous objective, the script will instruct the copter to move itself on a horizontal plane. It will send the copter with constant throttle value and change pitch/row value for it to move around. The timing module in the script will control the length for the copter to move horizontally. (Altitude hold is enabled at the same time) http: //youtu. be/9 cbul 5 d. Nbt 8

 Fly a route, forward, leftward, backward, rightward, then land

Fly a route, forward, leftward, backward, rightward, then land

Objective 5 Object evasion The quadcopter is still instructed to move on the horizontal

Objective 5 Object evasion The quadcopter is still instructed to move on the horizontal plane as previous. In this objective, the script will monitor the reading from ultrasound sensor to make a decision whethere is an object in front of it. If there is, it will make an attempt to bypass the object and continue with the original movement. Trial 1 Copter went forward, detects the object, went leftward to bypass and then landed. Screen capture of script running: http: //youtu. be/Qs. Cz. Ck. RLees Video of copter: http: //youtu. be/0 I 0 GSYVUei. I

Screen capture Video of copter (Start when screen capture has played 22 seconds)

Screen capture Video of copter (Start when screen capture has played 22 seconds)

Trial 2 Copter went forward, detects the object, went leftward to bypass and then

Trial 2 Copter went forward, detects the object, went leftward to bypass and then kept forward.

Acknowledgement Aerotestra, hardware provider, the Hugo quadcopter Ardupilot, provides flight controller APM 2. 6,

Acknowledgement Aerotestra, hardware provider, the Hugo quadcopter Ardupilot, provides flight controller APM 2. 6, PC software Mission planner and online instruction.

Some more to mention Get reading from ultrasound sensor We originally want to use

Some more to mention Get reading from ultrasound sensor We originally want to use Max. Botix XL-EZ 4 ultrasound sensor which outputs analogue voltage directly. Yet the sensors we ordered cannot detect distance properly so we have to switch to HC-SR 04 ultrasound sensor Echo Trigger Arduino microcontroller as sensor driver SPI Max 549 A DAC Analogue voltage Ardupilot APM 2. 6 controller

Video demo of ultrasound sensor assembled on quadcopter

Video demo of ultrasound sensor assembled on quadcopter