This commit is contained in:
parent
7f3c71f4dc
commit
388dc0a813
@ -169,18 +169,17 @@ bool GpsHyperionLinuxController::readGpsDataFromGpsd() {
|
|||||||
if (readMode == ReadModes::SOCKET) {
|
if (readMode == ReadModes::SOCKET) {
|
||||||
// Poll the GPS.
|
// Poll the GPS.
|
||||||
if (gps_waiting(&gps, 0)) {
|
if (gps_waiting(&gps, 0)) {
|
||||||
if (-1 == gps_read(&gps)) {
|
int retval = gps_read(&gps);
|
||||||
|
if (retval < 0) {
|
||||||
readError();
|
readError();
|
||||||
return false;
|
return false;
|
||||||
}
|
} else if (retval == 0) {
|
||||||
oneShotSwitches.gpsReadFailedSwitch = true;
|
oneShotSwitches.gpsReadFailedSwitch = true;
|
||||||
ReturnValue_t result = handleGpsReadData();
|
ReturnValue_t result = handleGpsReadData();
|
||||||
if (result == returnvalue::OK) {
|
if (result != returnvalue::OK) {
|
||||||
return true;
|
|
||||||
} else {
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
noModeSetCntr = 0;
|
}
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -81,7 +81,6 @@ class GpsHyperionLinuxController : public ExtendedControllerBase {
|
|||||||
} oneShotSwitches;
|
} oneShotSwitches;
|
||||||
|
|
||||||
bool debugHyperionGps = false;
|
bool debugHyperionGps = false;
|
||||||
int32_t noModeSetCntr = 0;
|
|
||||||
|
|
||||||
// Returns true if the function should be called again or false if other
|
// Returns true if the function should be called again or false if other
|
||||||
// controller handling can be done.
|
// controller handling can be done.
|
||||||
|
Loading…
Reference in New Issue
Block a user