Merge pull request #8231 from Staars/GPS

revert serial related ESP32-changes of the GPS-driver, not needed anymore
This commit is contained in:
Theo Arends 2020-04-19 22:30:19 +02:00 committed by GitHub
commit fc74cb299f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 0 additions and 16 deletions

View File

@ -119,10 +119,6 @@ rule3 on tele-FLOG#sec do DisplayText [f0c1l4]SAV:%value% endon on tele-FLOG#r
#include "NTPServer.h"
#include "NTPPacket.h"
#ifdef ESP32
#include <HardwareSerial.h>
#endif
/*********************************************************************************************\
* constants
\*********************************************************************************************/
@ -299,11 +295,7 @@ enum UBXMsgType {
#ifdef USE_FLOG
FLOG *Flog = nullptr;
#endif //USE_FLOG
#ifdef ESP8266
TasmotaSerial *UBXSerial;
#else
HardwareSerial *UBXSerial;
#endif
NtpServer timeServer(PortUdp);
@ -363,21 +355,13 @@ void UBXDetect(void)
{
UBX.mode.init = 0;
if ((pin[GPIO_GPS_RX] < 99) && (pin[GPIO_GPS_TX] < 99)) {
#ifdef ESP8266
UBXSerial = new TasmotaSerial(pin[GPIO_GPS_RX], pin[GPIO_GPS_TX], 1, 0, UBX_SERIAL_BUFFER_SIZE); // 64 byte buffer is NOT enough
if (UBXSerial->begin(9600)) {
#else
UBXSerial = new HardwareSerial(2);
UBXSerial->begin(9600,SERIAL_8N1,pin[GPIO_GPS_RX], pin[GPIO_GPS_TX]);
{
#endif
DEBUG_SENSOR_LOG(PSTR("UBX: started serial"));
#ifdef ESP8266
if (UBXSerial->hardwareSerial()) {
ClaimSerial();
DEBUG_SENSOR_LOG(PSTR("UBX: claim HW"));
}
#endif
}
}
else {