Parameters
| Documentation | /NGOS | /Signals | /Shells | /Cmds | /Ctrl | /HALs | /Conf | /Params | /Behaviors | /Receiver | /GPS | Next Chapter |
The NG Configuration Parameters
See the Documentation/Configs page for an explanation of configuration parameters and how to modify them.
The Global Parameters
Use the show globals command to list the current values of these parameters.
| Parameter name | Default value | Help text | Description |
| `name` | UAVP | Configuration name | The name of this configuration used in the 'list conf' output. |
| `RC.ch.throttle` | 0 | RC channel throttle | The RC.ch.* parameters define which RC channel represents which RC function: throttle, nick, roll, yaw. They also define the channels for the pot[0..7] channels. |
| `RC.ch.nick` | 2 | RC channel nick | |
| `RC.ch.roll` | 1 | RC channel roll | |
| `RC.ch.yaw` | 3 | RC channel yaw | |
| `RC.ch.pot0` | 8 | RC channel pot0 | |
| `RC.ch.pot1` | 4 | RC channel pot1 | |
| `RC.ch.pot2` | 6 | RC channel pot2 | |
| `RC.ch.pot3` | 5 | RC channel pot3 | |
| `RC.ch.pot4` | 7 | RC channel pot4 | |
| `RC.ch.pot5` | 9 | RC channel pot5 | |
| `RC.ch.pot6` | 10 | RC channel pot6 | |
| `RC.ch.pot7` | 11 | RC channel pot7 | |
| `RC.mode` | 2 | RC stick mode | Defines which of the four possible stick modes you use on your RC transmitter. Please see Documentation/HOWTO/RC-Modes for more information. |
| `BAT.minimum` | 9.80000000 | Battery minimum voltage | Defines the minimal value of the battery voltage measurement. If the battery's voltage falls below this voltage, the while.battery.low() behavior condition will trigger which is by default used to play the low-battery warning sound. |
| `BAT.offset` | 0.00000000 | Battery offset voltage | Can be used to calibrate the internal battery voltage measurement. The configured value is added to each measurement. |
| `TERM.mode` | user | Terminal mode | Limits the set of commads shown in the help output. Valid values are user, expert and api. This parameter can also be set using the `mode` command. |
| `HW.HAL` | none | HW HAL to use | The Hardware Abstraction Layer to use. |
| `HW.uart0.bootmsg` | yes | HW boot messages on UART0 | Whether to show boot messages on the given UART or not. Disable boot messages if you plan to use this UART for DSL or similar. |
| `HW.uart1.bootmsg` | yes | HW boot messages on UART1 | |
| `HW.uart0.baud` | 115200 | HW baud rate for UART0 | The baud rate for the given UART. Valid values are 1200, 2400, 4800, 9600, 19200, 38400, 57600, 100000 and 115200 Baud. |
| `HW.uart1.baud` | 115200 | HW baud rate for UART1 | |
| `HW.uart0.format` | 8N1 | HW format for UART0 | The format for the given UART. Valid values are 8N1, 7N1, 8N2, 7N2, 8E1, 7E1, 8E2, 7E2, 8O1, 7O1, 8O2 and 8O1. |
| `HW.uart1.format` | 8N1 | HW format for UART1 | |
| `HW.uart0.mode` | auto | HW mode for UART0 | Defines how to use the given UART. Valid values are auto, spektrum, [m-link|msb] and venus. /!\ To use DSL or M-Link/MSB/M-Bus on a port you need to switch that UART to 38400 baud first! |
| `HW.uart1.mode` | auto | HW mode for UART1 | |
| `HW.gyro.type` | ADXR300 | HW gyro type | Valid gyro types are ADXR300, MLX, ADXR610, MPU-2000deg, MPU-1000deg, MPU-500deg and MPU-250deg |
| `HW.gyro.scale.N` | 1000 | HW gyro N scaling | |
| `HW.gyro.scale.R` | 1000 | HW gyro R scaling | |
| `HW.gyro.scale.Y` | 1000 | HW gyro Y scaling | |
| `HW.acc.horizontal` | yes | HW acc mount orientation | |
| `HW.compass.inverted` | no | HW compass upside down | |
| `HW.compass.corr` | 0 | HW correct compass heading | |
| `HW.actor.init` | 0 | HW number of actors | |
| `HW.use.sound` | inverted | HW do use sound device | Defines if the buzzer is used. Valid values are yes, no and inverted. |
| `HW.use.acc` | yes | HW do use accelerometer | Defines if linear acceleration sensor is used. {i} We advise to set this to yes. /!\ Not all controllers support this parameter! |
| `HW.use.baro` | yes | HW do use barometer | |
| `HW.use.ngpp` | yes | HW do use NG peripherial protocol (may need NGPP) | |
| `HW.use.gps` | yes | HW do use Global Positioning System (may need NGPP) | |
| `HW.use.compass` | yes | HW do use compass (may need NGPP) | Defines if compass sensor is used. {i} We advise to set this to no for HW-0.10. |
| `CTRL.use.dtc` | yes | CTRL do use dynamic throttle control | Defines if the Dynamic Throttle Control (DTC) is used or if a simple limitter algorithm is used. {i} We advise to set this to yes. |
| `CTRL.use.PT1.comp` | no | CTRL do use PT1 compensation | |
| `CTRL.PT1.comp.k1` | 800 | CTRL PT1 parameter K1 | |
| `CTRL.PT1.comp.t1.down` | 148 | CTRL PT1 parameter T1 down | |
| `CTRL.PT1.comp.t1.up` | 148 | CTRL PT1 parameter T1 up | |
| `CTRL.rate.limit` | no | CTRL do angular rate limit | |
| `CAL.Ncorr` | 0 | CAL nick angle correction | |
| `CAL.Rcorr` | 0 | CAL roll angle correction | |
| `CAL.hmc.offset.X` | 0 | HW HMC5883L X Offset | |
| `CAL.hmc.offset.Y` | 0 | HW HMC5883L Y Offset | |
| `CAL.hmc.offset.Z` | 0 | HW HMC5883L Z Offset | |
| `CAL.hmc.range.X` | 32767 | HW HMC5883L X Range | |
| `CAL.hmc.range.Y` | 32767 | HW HMC5883L Y Range | |
| `CAL.hmc.range.Z` | 32767 | HW HMC5883L Z Range | |
| `ACC.nickcal` | 0 | Nick Acc calibration | These three parameters hold the linear accelerometer calibration done when the Quadcopter stands exactly horizontal. When the ACC calibration gets triggered by command or Behavior rules the NGOS stores the result in these parameters. |
| `ACC.rollcal` | 0 | Roll Acc calibration | |
| `ACC.yawcal` | 0 | Yaw Acc calibration | |
| `ACC.nickcorr` | 0 | Nick Acc correction | |
| `ACC.rollcorr` | 0 | Roll Acc correction | |
| `ACC.yawcorr` | 0 | Yaw Acc correction | |
| `RC.sum.jitter` | 16 | RC sum jitter range | |
| `RC.yaw.jitter` | 32 | RC yaw jitter range | |
| `RC.show.drops` | no | RC show frame drops | Defines if an error message should be printed to the console for each dropped RC packet. {i} We advise to set this to no. |
| `RC.dev.primary` | rcsum | RC primary input device | Defines the Primary Default RC Control. It can be set to the values rcsum, uart0 and uart1. |
| `RC.dev.secondary` | rcsum | RC secondary input device | Defines the Secondary RC Control used for Diversity or Teacher/Student mode. It can be set to the values rcsum, uart0 and uart1. |
| `RC.dev.mix` | primary | RC device mixing type | Defines the RC Mix Mode. It can be set to the values primary, secondary, ts-mix, ts-switch and diversity. |
Controller Dependent Parameters
Use the show conf command to list the current values of these parameters.
Shared Parameters
The following parameters are controller dependent but used by more than one controller:
| Parameter name | Default value | Help text | Description |
| `controller` | none | Closed-loop controller | Selects the closed-loop control algorithm to use. Use the list ctrl command to get a list of known controllers. |
| `T.idle` | 20 | Throttle idle speed | Represents the minimal output to the motor controllers when having finished the SPINUP flight-phase. This value assures that the motors will never stop since a controller will never output less as a motor signal. |
| `T.reserve` | 20 | Throttle control reserve | Represents the amount of control-reserve the closed-loop control will have when having finished the SPINGUP flight-phase. This means that a motor will receive an output signal of T.idle + T.reserve when having finished the SPINUP flight-phase. |
| `T.spinup` | 2 | Throttle spinup time (sec) | Represents the time the SPINUP flight-phase takes. Within that time-frame the closed-loop control will spinup the motors to their initial speed. The speed is defined by the parameters T.idle and T.reserve. |
| `P.nick` | 80 | Nick proportional factor | This are the Proportional Parameters meaning the P of the PID closed-loop control of the controller for the nick-, roll- and yaw-axis. {i} Note that the parameters have to be positive. The algorithms are implemented accordingly! |
| `P.roll` | 80 | Roll proportional factor | |
| `P.yaw` | 200 | Yaw proportional factor | |
| `D.nick` | 70 | Nick differential factor | This are the Differential Parameters meaning the D of the PID closed-loop control of the controller for the nick-, roll- and yaw-axis. {i} Note that the parameters have to be positive. The algorithms are implemented accordingly! |
| `D.roll` | 70 | Roll differential factor | |
| `D.yaw` | 70 | Yaw differential factor | |
| `I.nick` | 35 | Nick integral factor | This are the Integral Parameters meaning the I of the PID closed-loop control of the controller for the nick-, roll- and yaw-axis. {i} Note that the parameters have to be positive. The algorithms are implemented accordingly! |
| `I.roll` | 35 | Roll integral factor | |
| `I.yaw` | 0 | Yaw integral factor | |
| `CTRL.use.acc` | yes | CTRL do use accelerometer | |
| `CTRL.use.compass` | no | CTRL do use compass (needs NGPP) | |
| `RC.throttlehover` | -1600 | RC hover throttle | |
| `RC.fact.nick` | 40 | RC stick factor nick | The RC Factor Parameters define what factor gets used when calculating RC movements into the closed-loop control. A bigger value assures smaller stick movement for the same change. |
| `RC.fact.roll` | 40 | RC stick factor roll | |
| `RC.fact.yaw` | 50 | RC stick factor yaw |
‘wolferl’ Controller Parameters
| Parameter name | Default value | Help text | Description |
| `ACC.step` | 2 | Acc pull max step |
‘bearing’ Controller Parameters
| Parameter name | Default value | Help text | Description |
| `ACC.step` | 2 | Acc pull max step | |
| These parameters represent the usual Kalman parameters for the Kalman implementation for attitude. Be sure to check regular documentation on Kalman filters before changing these values! | |||
| `Kalman.Angle.Q` | 0.00030000 | Kalman angle process var | Defines the measurement noise of the gyro measurement. Raising it results in less trust into the gyro measurements. |
| `Kalman.Bias.Q` | 0.00010000 | Kalman bias process var | Defines the measurement noise of the "bias" measurement. Since we do not measure the bias but model it as a random walking process, this is not a real noise value. Raising it results in less trust into the pseudo bias measurements. |
| `Kalman.Acc.R` | 3.00000000 | Kalman system var | Defines the system noise of the modeled system. Raising it results in less trust into the guessed angle and in more trust to "reality", meaning the measurement from the accelerometer. |
| `Kalman.Cycle` | 1 | Kalman update intervall | Defines how often the linear accelerometer gets used to hold the value of the gyro integral. As you probably know the Kalman filter is separated into a "predict" and a "update" phase. This parameter defines how often the predict phase should happen until we do an update phase. |
‘amir’ Controller Parameters
| Parameter name | Default value | Help text | Description |
| `ACC.valid` | 125 | Allowed ACC divergence from (1000mg)^2 | |
| These parameters represent the usual Kalman parameters for the Kalman implementation for attitude. Be sure to check regular documentation on Kalman filters before changing these values! | |||
| `Kalman.Angle.Q` | 0.00030000 | Kalman angle process var | Defines the measurement noise of the gyro measurement. Raising it results in less trust into the gyro measurements. |
| `Kalman.Bias.Q` | 0.00010000 | Kalman bias process var | Defines the measurement noise of the "bias" measurement. Since we do not measure the bias but model it as a random walking process, this is not a real noise value. Raising it results in less trust into the pseudo bias measurements. |
| `Kalman.Acc.R` | 3.00000000 | Kalman system var | Defines the system noise of the modeled system. Raising it results in less trust into the guessed angle and in more trust to "reality", meaning the measurement from the accelerometer. |
| `Kalman.Cycle` | 1 | Kalman update intervall | Defines how often the linear accelerometer gets used to hold the value of the gyro integral. As you probably know the Kalman filter is separated into a "predict" and a "update" phase. This parameter defines how often the predict phase should happen until we do an update phase. |
| `Kalman.Limit` | 1 | Kalman gyro stationary limit | |
| `P.z` | 1950 | Height proportional factor | The PID closed-loop control parameters of the altitude hold controller. Use the ctrl.altitude.hold(x) behavior action to enable/disable altitude hold. |
| `D.z` | 5000 | Height differential factor | |
| `I.z` | 0 | Height integral factor | |
| `P.z.limit` | 20 | Height correction limiter | The maximum throttle adjustment made by the altitude hold controller. |
| `P.z.upfact` | 28 | Upwards height correction (%) | |
| `Z.Kalman.L1` | 1.29170001 | Height Kalman-Bucy L1 factor | These parameters represent the usual Kalman-Bucy parameters for the Kalman implementation for height. This implementation precalculates the Inverse in Matlab. Be sure to check regular documentation on Kalman filters before changing these values! |
| `Z.Kalman.L2` | 0.83420002 | Height Kalman-Bucy L2 factor | |
| `Z.Kalman.L3` | -0.26930001 | Height Kalman-Bucy L3 factor | |
| `Axis.decoupling` | yes | Axis decoupling |
KalmanZ.L[123]
The Kalman parameter for the Kalman-Bucy filter for height are represented by 3 precalculated constants called L1, L2 and L3. To find values for these, one needs to estimate the noise of the accelerometer and barometer sensor data.
To be able to precalculate L1, L2 and L3 we need to measure the standard deviation of the raw sensor data. Having done that, Matlab is able to calulate the standard deviation from the raw sensor data like this:
ACC_NOISE = std(accRaw)^2
BARO_NOISE = std(baroRaw)^2The value ACC_WALK needs to be guessed and represents the step-width of the random walk modelling the bias-walk.
The three constants then can get precalculated in Matlab with the following Matlab-Script:
% Standard deviation of the sensor noise signals:
ACC_NOISE = 0.0798;
BARO_NOISE = 0.7488;
ACC_WALK = 0.005;
% Build system matrix
A = [0,1,0;0,0,-1;0,0,0]
B = [0;1;0];
C = [1,0,0];
D = [0];
% Calculate covariance matrix
Q = diag([0,ACC_NOISE,ACC_WALK]);
R = BARO_NOISE;
% Calculate Kalman gain
L = lqr(A',C',Q,R,[])'The array L[] contains the 3 constants L1, L2 and L3 after the above script has run.
‘amir-ng’ Controller Parameters
The following parameters control the DCM attitude stabilization algorthm:
| Parameter name | Default value | Help text | Description |
| `I.yaw.delay` | 0 | Yaw integral activation delay [ms] | |
| `DCM.Kalman.corr.Q` | 0.00010000 | DCM Kalman process var (corr) | |
| `DCM.Kalman.bias.Q` | 0.00010000 | DCM Kalman process var (bias) | |
| `DCM.Kalman.Acc.R` | 0.00100000 | DCM Kalman system var (Acc) | |
| `DCM.Kalman.Compass.R` | 0.00010000 | DCM Kalman Compass system var | |
| `DCM.Kalman.weight.NR` | 100 | DCM Kalman correction weight N/R | |
| `DCM.Kalman.weight.Y` | 400 | DCM Kalman correction weight Y |
These parameters control the height hold stabilization algorithm:
| Parameter name | Default value | Help text | Description |
| `P.z` | 1950 | Height proportional factor | The PID closed-loop control parameters of the altitude hold controller. Use the ctrl.altitude.hold(x) behavior action to enable/disable altitude hold. |
| `D.z` | 5000 | Height differential factor | |
| `I.z` | 0 | Height integral factor | |
| `P.z.limit` | 20 | Height correction limiter | The maximum throttle adjustment made by the altitude hold controller. |
| `P.z.upfact` | 28 | Upwards height correction (%) |
And the following parameters control the GPS Position filter (POS.*) and the Position Navigation algorithm:
| Parameter name | Default value | Help text | Description |
| `POS.Kalman.Acc.Q` | 0.20000000 | Position Kalman process var (Acc) | |
| `POS.Kalman.GPS.R` | 0.05000000 | Position Kalman system var (GPS) | |
| `POS.Kalman.Baro.R` | 0.00001000 | Position Kalman system var (Baro) | |
| `NAV.angle.max` | 10 | Navigation maximum angle | |
| `NAV.angle.attack` | 50 | Navigation angle attack (more -> softer) | |
| `NAV.min.satellites` | 6 | Navigation mininal number of satellites |
Controller usage of each of the supported sensor devices may be enabled or disabled:
| Parameter name | Default value | Help text | Description |
| `CTRL.use.baro` | no | CTRL do use baro | |
| `CTRL.use.gps` | no | CTRL do use GPS (needs NGPP) |
The controller also supports ADTC - Attitude Dynamic Throttle Control which tries to compensate attitude induced height changes by dynamically ajust throttle:
| Parameter name | Default value | Help text | Description |
| `CTRL.use.ADTC` | no | CTRL do use attitude dependant throttle control |
Furthermore the controller supports Heading-Hold which can be switched on and off during the flight using behaviors too:
| Parameter name | Default value | Help text | Description |
| `CTRL.use.HH` | no | CTRL do use Heading Hold PID | |
| `CTRL.acc.hh.fact` | 40 | CTRL ACC/HH stick factor |
Ignore this parameter for now: ;)
| Parameter name | Default value | Help text | Description |
| `FLIP.turnrate` | 30 | Flip turnrate |