1
0
Fork 0
mirror of https://github.com/opentx/opentx.git synced 2025-07-18 13:55:12 +03:00

Horus internal GPS: cmake changes, more CLI options, ability to send commands to the module

This commit is contained in:
Damjan Adamic 2016-08-30 21:23:20 +02:00
parent 1ef91597ca
commit ff37274e64
7 changed files with 75 additions and 13 deletions

View file

@ -712,7 +712,15 @@ int cliShowJitter(const char ** argv)
int cliGps(const char ** argv)
{
int baudrate = 0;
if (toInt(argv, 1, &baudrate) > 0 && baudrate > 0) {
if (argv[1][0] == '$') {
// send command to GPS
gpsSendFrame(argv[1]);
}
else if (!strcmp(argv[1], "trace")) {
gpsTraceEnabled = !gpsTraceEnabled;
}
else if (toInt(argv, 1, &baudrate) > 0 && baudrate > 0) {
gpsInit(baudrate);
serialPrint("GPS baudrate set to %d", baudrate);
}