1.2-legacy
geeksville 2020-07-10 14:54:32 -07:00
rodzic e12c057c31
commit efd8b70089
2 zmienionych plików z 13 dodań i 2 usunięć

Wyświetl plik

@ -16,7 +16,11 @@ HardwareSerial *GPS::_serial_gps = &Serial1;
HardwareSerial *GPS::_serial_gps = NULL;
#endif
#ifdef GPS_I2C_ADDRESS
uint8_t GPS::i2cAddress = GPS_I2C_ADDRESS;
#else
uint8_t GPS::i2cAddress = 0;
#endif
bool timeSetFromGPS; // We try to set our time from GPS each time we wake from sleep

Wyświetl plik

@ -53,8 +53,15 @@ bool UBloxGPS::setup()
assert(ok);
return false;
} else {
ok = ublox.setUART1Output(COM_TYPE_UBX, 500); // Use native API
assert(ok);
if (_serial_gps) {
ok = ublox.setUART1Output(COM_TYPE_UBX, 500); // Use native API
assert(ok);
}
if (i2cAddress) {
ublox.setI2COutput(COM_TYPE_UBX, 500);
assert(ok);
}
ok = ublox.setNavigationFrequency(1, 500); // Produce 4x/sec to keep the amount of time we stall in getPVT low
assert(ok);
// ok = ublox.setAutoPVT(false); // Not implemented on NEO-6M