Introduction to-cleanflight

22
BASIC INTRODUCTION TO CLEANFLIGHT V1.9.0 By: Zach Scally ([email protected]) Presented: to FPV Race League.

Transcript of Introduction to-cleanflight

Page 1: Introduction to-cleanflight

BASIC INTRODUCTION TO CLEANFLIGHT V1.9.0

By: Zach Scally ([email protected])Presented: to FPV Race League.

Page 2: Introduction to-cleanflight

What is Cleanflight?• Cleanflight is a open source flight controller software used by 32bit processors.• Cleanflight can be used on multirotor aircraft and fixed-wing aircraft, it supports a variety for shapes and motor counts, not limited to quadcopters, hexacopters, octocopters, tricopters and planes.

Page 3: Introduction to-cleanflight

Supported 32bit Flight Controllers• Naze32 (most popular)• AlienWii32• CC3D• CJMCU• ChebuzzF3 F3 board (new upcoming technology)

• Olimexino• Paris Air Hero• SPRacingF3 F3 board (new upcoming technology)

• Sparky F3 board (new upcoming technology)

• Flip32• RMRC DODO F3 board (new upcoming technology)

Page 4: Introduction to-cleanflight

The Basics (what we’re going to need)

• Some sort of cleanflight enabled board.• Some boards require you to solder header pins on.• A computer with cleanflight installed. (http://tinyurl.com/

mdek2lq )• Sometimes a SMT32 driver is required (out of scope).

• A USB Cable (to plug up the flight controller)• RC receiver and Transmitter• Battery (optional)

Page 5: Introduction to-cleanflight

Flashing• Updates newest version of cleanflight to the flight controller• Improves performance and add new features• Internet connection makes things easier but not required.

Page 6: Introduction to-cleanflight
Page 7: Introduction to-cleanflight

Start of Basic SetupCleanflight is broken up in tabs

• Setup (general overall view of what's going on)• Ports (Ic2 and UART communication pipes)• Configuration (General Configuration)• PID Tuning (PID controllers and RC Rate)• Receiver (Receiver Monitor and Configuration)• Modes (Flight modes and other features)• Adjustments (Custom mixes)• Servos • GPS• Motors • LED Strip• Sensors• Logging• DataFlash• CLI (Command line Interface)

Page 8: Introduction to-cleanflight

Ports• Ability to setup GPS module • Ability to setup PPM receiver• Ability to setup blackbox logging

• I will briefly speak about PPM receivers but I Will not go in depth, I’ve experienced a lot of issues with certain types of PPM receiver modules and the one’s I find to work the best are the Lemon RX PPM satellite receivers found here

http://tinyurl.com/n8ljzds

Page 9: Introduction to-cleanflight

Configuration

Page 10: Introduction to-cleanflight

PID Tuning

Page 11: Introduction to-cleanflight

PID Tuning Continued • Good resource for tuning your PIDS

• https://www.youtube.com/watch?v=30Au6sEv6-o

Page 12: Introduction to-cleanflight

Receiver

Page 13: Introduction to-cleanflight

Modes

Page 14: Introduction to-cleanflight

Motors

Page 15: Introduction to-cleanflight

CLI (Command Line Interface)

Page 16: Introduction to-cleanflight

CLI Commands• Set looptime = 1600 (press enter) NOTE: May very from ESC to ESC.

• Set Acc_lpf_factor = 100 (press enter)

• Set emf_avoidance = 1 (press enter)

• acc_hardware (press enter) - WARNING: ONLY DO THIS IF YOU CHOOSE NOT TO RUN AUTO LEVEL

• Save (press enter)

Page 17: Introduction to-cleanflight

looptimeThis is the main loop time (in us). Changing this affects PID effect with some PID controllers (see PID section for details). Default of 3500us/285Hz should work for everyone. Setting it to zero does not limit loop time, so it will go as fast as possible.

So basically the communication speed to your ESC’s

Page 18: Introduction to-cleanflight

Acc_lpf_factor This setting controls the Low Pass Filter factor for ACC. Increasing this value reduces ACC noise (visible in GUI), but would increase ACC lag time. Zero = no filter

Smooth's out Accelerometer noise!!

Page 19: Introduction to-cleanflight

emf_avoidanceDefault value is 0 for 72MHz processor speed. Setting this to 1 increases the processor speed, to move the 6th harmonic away from 432MHz.

Again another setting to smooth out communication speed to your processor.

Page 20: Introduction to-cleanflight

acc_hardware WARNING: ONLY DO THIS IF YOU CHOOSE NOT TO RUN AUTO LEVEL

This is used to suggest which accelerometer driver should load, or to force no accelerometer in case gyro-only flight is needed. Default (0) will attempt to auto-detect among enabled drivers. Otherwise, to force a particular device, set it to 2 for ADXL345, 3 for MPU6050 integrated accelerometer, 4 for MMA8452, 5 for BMA280, 6 for LSM303DLHC, 7 for SPI_MPU6000, 8 for SPI_MPU6500 or 1 to disable accelerometer altogether - resulting in gyro-only operation.

Another setting to improve performance of your 32bit processor.

Page 21: Introduction to-cleanflight

Setup

Page 22: Introduction to-cleanflight

That’s a WrapSomething's to note.• All flight controllers are a little different but all should function the same.• Setting loop time is based of the speed of your ESC• Always remember to take off your props when working in cleanflight.• And this picture