new device: Lilygo T-Eth-Elite (#6321)

This commit is contained in:
Thomas Göttgens
2025-03-15 14:15:35 +01:00
committed by GitHub
parent 99e42b4d22
commit 1640fb105d
21 changed files with 247 additions and 17 deletions

View File

@@ -1104,12 +1104,16 @@ int32_t GPS::runOnce()
return (powerState == GPS_ACTIVE) ? GPS_THREAD_INTERVAL : 5000;
}
// clear the GPS rx buffer as quickly as possible
// clear the GPS rx/tx buffer as quickly as possible
void GPS::clearBuffer()
{
#ifdef ARCH_ESP32
_serial_gps->flush(false);
#else
int x = _serial_gps->available();
while (x--)
_serial_gps->read();
#endif
}
/// Prepare the GPS for the cpu entering deep or light sleep, expect to be gone for at least 100s of msecs