mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-13 19:40:31 +03:00
added mincheck, maxcheck, vbatscale to settings configurable via cli
git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@120 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
This commit is contained in:
parent
c1cb4287b7
commit
8bcbf5e41e
7 changed files with 2280 additions and 2768 deletions
|
@ -71,6 +71,9 @@ const clivalue_t valueTable[] = {
|
|||
{ "minthrottle", VAR_UINT16, &cfg.minthrottle, 0, 2000 },
|
||||
{ "maxthrottle", VAR_UINT16, &cfg.maxthrottle, 0, 2000 },
|
||||
{ "mincommand", VAR_UINT16, &cfg.mincommand, 0, 2000 },
|
||||
{ "mincheck", VAR_UINT16, &cfg.mincheck, 0, 2000 },
|
||||
{ "maxcheck", VAR_UINT16, &cfg.maxcheck, 0, 2000 },
|
||||
{ "vbatscale", VAR_UINT8, &cfg.vbatscale, 10, 200 },
|
||||
{ "yaw_direction", VAR_INT8, &cfg.yaw_direction, -1, 1 },
|
||||
{ "wing_left_mid", VAR_UINT16, &cfg.wing_left_mid, 0, 2000 },
|
||||
{ "wing_right_mid", VAR_UINT16, &cfg.wing_right_mid, 0, 2000 },
|
||||
|
@ -273,7 +276,7 @@ static void cliSave(char *cmdline)
|
|||
|
||||
static void cliPrintVar(const clivalue_t *var)
|
||||
{
|
||||
int32_t value;
|
||||
int32_t value = 0;
|
||||
char buf[16];
|
||||
|
||||
switch (var->type) {
|
||||
|
@ -338,7 +341,7 @@ static void cliSet(char *cmdline)
|
|||
uartPrint("\r\n");
|
||||
delay(10);
|
||||
}
|
||||
} else if (eqptr = strstr(cmdline, "=")) {
|
||||
} else if ((eqptr = strstr(cmdline, "="))) {
|
||||
// has equal, set var
|
||||
eqptr++;
|
||||
len--;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue