PPR1 - GPS serial now works

This commit is contained in:
Kevin Hester
2020-10-25 17:07:54 +08:00
parent 1a8891c33d
commit 7597d5b3fd
5 changed files with 27 additions and 13 deletions

View File

@@ -25,6 +25,22 @@ uint8_t GPS::i2cAddress = 0;
GPS *gps;
bool GPS::setupGPS()
{
if (_serial_gps) {
#ifdef GPS_RX_PIN
_serial_gps->begin(GPS_BAUDRATE, SERIAL_8N1, GPS_RX_PIN, GPS_TX_PIN);
#else
_serial_gps->begin(GPS_BAUDRATE);
#endif
#ifndef NO_ESP32
_serial_gps->setRxBufferSize(2048); // the default is 256
#endif
}
return true;
}
bool GPS::setup()
{
// Master power for the GPS