Connect ESC32 to AutoQuad Widget in QGroundControl
The Autoquad version of QGroundControl (QGC) has a widget included to alter settings of ESC32
To use a command line interface via Putty, please read Max Levine´s forum post.
Open QGC, and choose “AutoQuad” from the main widget menu:
Then go to the tab “ESC32 settings”
On the left side of the screen you can see the “Link ESC32” Tab:
Connect UART adapter to ESC32 and computer and choose the UART adapter you are using and click connect.
When you connect the ESC to UART, it will go into disarmed state (Red LED blinking). Try and click “arm” – the ESC green LED should light up. If there is a main power source and motor hooked to the ESC you can run the motor by clicking “Start” and the motor will run at low duty (Remove props always when working with your multirotor)
Now you can alter the parameters in ESC32, but
Make sure you don’t change parameters unless you know how the different parameters affect operation. Certain parameter combinations can be fatal for the ESC and motor! |
Refer to the User configurable parameters section for more information on what each parameter controls.
When parameters have been altered, you can upload them to ESC32 by clicking “write config”
User configurable parameters:
Generally, no parameters will need to be changed for normal out of the box PWM operation. However, there are various parameters that can be set. Each parameter is a single numerical value.
Note that some combinations of parameters can cause damage to your motor or ESC. It is recommended to leave most values at their default values unless you are sure of how they impact function and operation. If you want to use the ESC32 with other FCs like MultiWii, APM2 (or Open Pilot Revo w/ APM firmware) or DJI NAZA please read the comments concerning certain values. |
Parameter | Factory Default | Description |
STATUP_MODE | 0 | This is the run mode that the ESC defaults to when first powered on. 0 == normal open loop operation, 1 == closed loop RPM mode, 2 == closed loop thrust mode (not yet implemented) |
BAUD_RATE | 230400 | The UART baud rate. Allowable range 9600 to 921600 |
PTERM | 0.5 | The P term for the RPM PI controller |
ITERM | 0.0006 | The I term for the RPM PI controller |
FF1TERM | 0.0 | Feed forward terms used for the RPM controller. Closed loop RPM mode will not function until FF1 & FF2 terms have been set. |
FF2TERM | 0.0 | These values should be calculated using the esc32Cal program with the –r2v option |
CL1TERM | 0.0 | CL1TERM through CL5TERM are used by the virtual current limiter which will not function until they are set. |
CL2TERM | 0.0 | If CL1TERM through CL5TERM is not set, a PI controller will be used for current limiting instead. |
CL3TERM | 0.0 | CL1TERM through CL5TERM can be calculated using the esc32Cal program with the –cl option. |
CL4TERM | 0.0 | |
CL5TERM | 0.0 | |
SHUNT_RESISTANCE | 0.5 | This parameter should NOT be changed from the factory default!!! (Value in milliohms) |
MIN_PERIOD | 50 | The minimum commutation period allowed in microseconds |
MAX_PERIOD | 12000 | The maximum commutation period allowed in microseconds |
BLANKING_MICROS | 30 | The number of microseconds to ignore back EMF after a commutation. |
ADVANCE | 15 | The amount of timing advance in electrical degrees. There are 60 electrical degrees in a commutation cycle. This value can be set from 0 to 30 degrees. |
START_VOLTAGE | 1.1 | The amount of voltage presented to the motor during startup. Allowable range is 0.1v to 3.0v |
GOOD_DETECTS_START | 75 | Once started, the number of good, in order zero crossings needed to be detected before the motor is considered to be in the running state. |
BAD_DETECTS_DISARM | 48 | The number of missed zero crossing detects allowed before the ESC considers the motor not to be running at which point will go into the disarmed state. |
MAX_CURRENT | 20 | The maximum amount of current in amps that the ESC will allow. Current is dynamically regulated. Always set this value low and only increase it if you know what you are doing. |
SWITCH_FREQ | 20 | The output PWM pulse frequency used to power the motor windings in KHz. Valid range is from 4KHz to 64KHz. |
MOTOR_POLS | 14 | The number of magnetic poles used in the motor’s construction. This value only needs to be set correctly if you want to use the RPM closed loop mode. |
PWM_MIN_PERIOD | 2200 | The minimum period in microseconds that the ESC will consider an input PWM waveform to be valid. Default value represents approx 450Hz. For MultiWii and ArduCopter APM (or Open Pilot Revo w/ APM fw) this value needs to be changed to 2000! |
PWM_MAX_PERIOD | 25000 | The maximum period in microseconds that the ESC will consider an input PWM waveform to be valid. Default value represents approx 40Hz |
PWM_MIN_VALUE | 750 | The minimum input PWM pulse length in microseconds which the ESC will consider to be valid. For DJI Naza this value has to be 900! |
PWM_LO_VALUE | 1000 | The input PWM pulse length in microseconds for the lowest throttle setting. For ArduCopter APM (or Open Pilot Revo w/ APM fw) this value needs to be changed to 1035! |
PWM_HI_VALUE | 1950 | The input PWM pulse length in microseconds for the highest throttle setting. |
PWM_MAX_VALUE | 2250 | The maximum input PWM pulse length in microseconds which the ESC will consider to be valid. |
PWM_MIN_START | 1100 | The input PWM pulse length in microseconds at which the motor will be started. Once running, the throttle can be brought as low as PWM_MIN_VALUE as long as the motor does not stall. |
PWM_RPM_SCALE | 6500 | The scale of the input PWM pulse length. In closed loop RPM run mode, PWM_LO_VALUE will indicate 0 RPM and PWM_HI_VALUE will indicate this RPM. Closed loop modes only! |
FET_BRAKING | 0 | Turns on regenerative braking in closed loop modes (experimental), 0 == off, 1 == on. Closed Loop modes only!! |
Closed loop calibration
The ESC32 offers a closed loop RPM mode and a Closed loop thrust mode (Experimental). It requires calibration of the specific motor and prop you will be using.
The calibration sequence is at an early stage in QGC and can be run under Linux and OSX from a terminal.
Closed loop calibration instructions
Please be very careful running a calibration! Your motors will perform certain patterns up to full power. Make sure to run these tests only in a secured environment! Only use it in closed rooms or boxes where propellors can fly off without hurting anyone or damaging anything! |
Refer to forum.autoquad.org for more details on how to perform closed loop calibration of ESC32 under Linux, OSX or from within QGC.