mirror of
https://github.com/opentx/opentx.git
synced 2025-07-17 21:35:27 +03:00
Horus internal GPS: settable baudrate, misc fixes, new cmake options, cosmetics, cli
This commit is contained in:
parent
f0c2f10e27
commit
1ef91597ca
8 changed files with 75 additions and 21 deletions
|
@ -708,6 +708,20 @@ int cliShowJitter(const char ** argv)
|
|||
}
|
||||
#endif
|
||||
|
||||
#if defined(INTERNAL_GPS)
|
||||
int cliGps(const char ** argv)
|
||||
{
|
||||
int baudrate = 0;
|
||||
if (toInt(argv, 1, &baudrate) > 0 && baudrate > 0) {
|
||||
gpsInit(baudrate);
|
||||
serialPrint("GPS baudrate set to %d", baudrate);
|
||||
}
|
||||
else {
|
||||
serialPrint("%s: Invalid arguments", argv[0]);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
const CliCommand cliCommands[] = {
|
||||
{ "beep", cliBeep, "[<frequency>] [<duration>]" },
|
||||
|
@ -731,6 +745,9 @@ const CliCommand cliCommands[] = {
|
|||
{ "repeat", cliRepeat, "<interval> <command>" },
|
||||
#if defined(JITTER_MEASURE)
|
||||
{ "jitter", cliShowJitter, "" },
|
||||
#endif
|
||||
#if defined(INTERNAL_GPS)
|
||||
{ "gps", cliGps, "<baudrate>" },
|
||||
#endif
|
||||
{ NULL, NULL, NULL } /* sentinel */
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue