From d12c473985f6b4e30d98aa00170fa2410383f52c Mon Sep 17 00:00:00 2001 From: PaulZC Date: Tue, 16 Nov 2021 16:50:38 +0000 Subject: [PATCH] Change boolean to bool --- src/SparkFun_u-blox_GNSS_Arduino_Library.cpp | 700 +++++++++---------- src/SparkFun_u-blox_GNSS_Arduino_Library.h | 566 +++++++-------- src/u-blox_structs.h | 4 +- 3 files changed, 635 insertions(+), 635 deletions(-) diff --git a/src/SparkFun_u-blox_GNSS_Arduino_Library.cpp b/src/SparkFun_u-blox_GNSS_Arduino_Library.cpp index 880c1c3..f9d26d1 100644 --- a/src/SparkFun_u-blox_GNSS_Arduino_Library.cpp +++ b/src/SparkFun_u-blox_GNSS_Arduino_Library.cpp @@ -406,7 +406,7 @@ void SFE_UBLOX_GNSS::setPacketCfgPayloadSize(size_t payloadSize) } //Initialize the I2C port -boolean SFE_UBLOX_GNSS::begin(TwoWire &wirePort, uint8_t deviceAddress) +bool SFE_UBLOX_GNSS::begin(TwoWire &wirePort, uint8_t deviceAddress) { commType = COMM_TYPE_I2C; _i2cPort = &wirePort; //Grab which port the user wants us to use @@ -429,7 +429,7 @@ boolean SFE_UBLOX_GNSS::begin(TwoWire &wirePort, uint8_t deviceAddress) createFileBuffer(); // Call isConnected up to three times - tests on the NEO-M8U show the CFG RATE poll occasionally being ignored - boolean connected = isConnected(); + bool connected = isConnected(); if (!connected) connected = isConnected(); @@ -441,7 +441,7 @@ boolean SFE_UBLOX_GNSS::begin(TwoWire &wirePort, uint8_t deviceAddress) } //Initialize the Serial port -boolean SFE_UBLOX_GNSS::begin(Stream &serialPort) +bool SFE_UBLOX_GNSS::begin(Stream &serialPort) { commType = COMM_TYPE_SERIAL; _serialPort = &serialPort; //Grab which port the user wants us to use @@ -454,7 +454,7 @@ boolean SFE_UBLOX_GNSS::begin(Stream &serialPort) createFileBuffer(); // Call isConnected up to three times - tests on the NEO-M8U show the CFG RATE poll occasionally being ignored - boolean connected = isConnected(); + bool connected = isConnected(); if (!connected) connected = isConnected(); @@ -466,7 +466,7 @@ boolean SFE_UBLOX_GNSS::begin(Stream &serialPort) } // Initialize for SPI -boolean SFE_UBLOX_GNSS::begin(SPIClass &spiPort, uint8_t csPin, uint32_t spiSpeed) +bool SFE_UBLOX_GNSS::begin(SPIClass &spiPort, uint8_t csPin, uint32_t spiSpeed) { commType = COMM_TYPE_SPI; _spiPort = &spiPort; @@ -507,7 +507,7 @@ boolean SFE_UBLOX_GNSS::begin(SPIClass &spiPort, uint8_t csPin, uint32_t spiSpee } // Call isConnected up to three times - boolean connected = isConnected(); + bool connected = isConnected(); if (!connected) connected = isConnected(); @@ -587,7 +587,7 @@ int8_t SFE_UBLOX_GNSS::getMaxNMEAByteCount(void) } //Returns true if I2C device ack's -boolean SFE_UBLOX_GNSS::isConnected(uint16_t maxWait) +bool SFE_UBLOX_GNSS::isConnected(uint16_t maxWait) { if (commType == COMM_TYPE_I2C) { @@ -602,7 +602,7 @@ boolean SFE_UBLOX_GNSS::isConnected(uint16_t maxWait) //Enable or disable the printing of sent/response HEX values. //Use this in conjunction with 'Transport Logging' from the Universal Reader Assistant to see what they're doing that we're not -void SFE_UBLOX_GNSS::enableDebugging(Stream &debugPort, boolean printLimitedDebug) +void SFE_UBLOX_GNSS::enableDebugging(Stream &debugPort, bool printLimitedDebug) { _debugSerial = &debugPort; //Grab which port the user wants us to use for debugging if (printLimitedDebug == false) @@ -693,19 +693,19 @@ const char *SFE_UBLOX_GNSS::statusString(sfe_ublox_status_e stat) // Check for the arrival of new I2C/Serial/SPI data //Allow the user to disable the "7F" check (e.g.) when logging RAWX data -void SFE_UBLOX_GNSS::disableUBX7Fcheck(boolean disabled) +void SFE_UBLOX_GNSS::disableUBX7Fcheck(bool disabled) { ubx7FcheckDisabled = disabled; } //Called regularly to check for available bytes on the user' specified port -boolean SFE_UBLOX_GNSS::checkUblox(uint8_t requestedClass, uint8_t requestedID) +bool SFE_UBLOX_GNSS::checkUblox(uint8_t requestedClass, uint8_t requestedID) { return checkUbloxInternal(&packetCfg, requestedClass, requestedID); } //PRIVATE: Called regularly to check for available bytes on the user' specified port -boolean SFE_UBLOX_GNSS::checkUbloxInternal(ubxPacket *incomingUBX, uint8_t requestedClass, uint8_t requestedID) +bool SFE_UBLOX_GNSS::checkUbloxInternal(ubxPacket *incomingUBX, uint8_t requestedClass, uint8_t requestedID) { if (commType == COMM_TYPE_I2C) return (checkUbloxI2C(incomingUBX, requestedClass, requestedID)); @@ -718,7 +718,7 @@ boolean SFE_UBLOX_GNSS::checkUbloxInternal(ubxPacket *incomingUBX, uint8_t reque //Polls I2C for data, passing any new bytes to process() //Returns true if new bytes are available -boolean SFE_UBLOX_GNSS::checkUbloxI2C(ubxPacket *incomingUBX, uint8_t requestedClass, uint8_t requestedID) +bool SFE_UBLOX_GNSS::checkUbloxI2C(ubxPacket *incomingUBX, uint8_t requestedClass, uint8_t requestedID) { if (millis() - lastCheck >= i2cPollingWait) { @@ -917,7 +917,7 @@ boolean SFE_UBLOX_GNSS::checkUbloxI2C(ubxPacket *incomingUBX, uint8_t requestedC } //end checkUbloxI2C() //Checks Serial for data, passing any new bytes to process() -boolean SFE_UBLOX_GNSS::checkUbloxSerial(ubxPacket *incomingUBX, uint8_t requestedClass, uint8_t requestedID) +bool SFE_UBLOX_GNSS::checkUbloxSerial(ubxPacket *incomingUBX, uint8_t requestedClass, uint8_t requestedID) { while (_serialPort->available()) { @@ -929,7 +929,7 @@ boolean SFE_UBLOX_GNSS::checkUbloxSerial(ubxPacket *incomingUBX, uint8_t request //Checks SPI for data, passing any new bytes to process() -boolean SFE_UBLOX_GNSS::checkUbloxSpi(ubxPacket *incomingUBX, uint8_t requestedClass, uint8_t requestedID) +bool SFE_UBLOX_GNSS::checkUbloxSpi(ubxPacket *incomingUBX, uint8_t requestedClass, uint8_t requestedID) { // Process the contents of the SPI buffer if not empty! for (uint8_t i = 0; i < spiBufferIndex; i++) { @@ -967,9 +967,9 @@ boolean SFE_UBLOX_GNSS::checkUbloxSpi(ubxPacket *incomingUBX, uint8_t requestedC //PRIVATE: Check if we have storage allocated for an incoming "automatic" message -boolean SFE_UBLOX_GNSS::checkAutomatic(uint8_t Class, uint8_t ID) +bool SFE_UBLOX_GNSS::checkAutomatic(uint8_t Class, uint8_t ID) { - boolean result = false; + bool result = false; switch (Class) { case UBX_CLASS_NAV: @@ -1530,7 +1530,7 @@ void SFE_UBLOX_GNSS::process(uint8_t incoming, ubxPacket *incomingUBX, uint8_t r } // PRIVATE: Return true if we should add this NMEA message to the file buffer for logging -boolean SFE_UBLOX_GNSS::logThisNMEA() +bool SFE_UBLOX_GNSS::logThisNMEA() { if (_logNMEA.bits.all == 1) return (true); if ((nmeaAddressField[3] == 'D') && (nmeaAddressField[4] == 'T') && (nmeaAddressField[5] == 'M') && (_logNMEA.bits.UBX_NMEA_DTM == 1)) return (true); @@ -1561,7 +1561,7 @@ boolean SFE_UBLOX_GNSS::logThisNMEA() } // PRIVATE: Return true if we should pass this NMEA message to processNMEA -boolean SFE_UBLOX_GNSS::processThisNMEA() +bool SFE_UBLOX_GNSS::processThisNMEA() { if (_processNMEA.bits.all == 1) return (true); if ((nmeaAddressField[3] == 'D') && (nmeaAddressField[4] == 'T') && (nmeaAddressField[5] == 'M') && (_processNMEA.bits.UBX_NMEA_DTM == 1)) return (true); @@ -2866,7 +2866,7 @@ void SFE_UBLOX_GNSS::addToChecksum(uint8_t incoming) } //Given a packet and payload, send everything including CRC bytes via I2C port -sfe_ublox_status_e SFE_UBLOX_GNSS::sendCommand(ubxPacket *outgoingUBX, uint16_t maxWait, boolean expectACKonly) +sfe_ublox_status_e SFE_UBLOX_GNSS::sendCommand(ubxPacket *outgoingUBX, uint16_t maxWait, bool expectACKonly) { sfe_ublox_status_e retVal = SFE_UBLOX_STATUS_SUCCESS; @@ -3177,7 +3177,7 @@ void SFE_UBLOX_GNSS::sendSpiCommand(ubxPacket *outgoingUBX) } //Pretty prints the current ubxPacket -void SFE_UBLOX_GNSS::printPacket(ubxPacket *packet, boolean alwaysPrintPayload) +void SFE_UBLOX_GNSS::printPacket(ubxPacket *packet, bool alwaysPrintPayload) { #ifndef SFE_UBLOX_REDUCED_PROG_MEM if (_printDebug == true) @@ -3819,7 +3819,7 @@ void SFE_UBLOX_GNSS::checkCallbacks(void) // Warning: this function does not check that the data is valid. It is the user's responsibility to ensure the data is valid before pushing. // Default to using a restart between transmissions. But processors like ESP32 seem to need a stop (#30). Set stop to true to use a stop instead. // On processors like the ESP32, you can use setI2CTransactionSize to increase the size of each transmission - to e.g. 128 bytes -boolean SFE_UBLOX_GNSS::pushRawData(uint8_t *dataBytes, size_t numDataBytes, boolean stop) +bool SFE_UBLOX_GNSS::pushRawData(uint8_t *dataBytes, size_t numDataBytes, bool stop) { // Return now if numDataBytes is zero if (numDataBytes == 0) @@ -3994,7 +3994,7 @@ void SFE_UBLOX_GNSS::clearMaxFileBufferAvail(void) } // PRIVATE: Create the file buffer. Called by .begin -boolean SFE_UBLOX_GNSS::createFileBuffer(void) +bool SFE_UBLOX_GNSS::createFileBuffer(void) { if (fileBufferSize == 0) // Bail if the user has not called setFileBufferSize { @@ -4065,7 +4065,7 @@ uint16_t SFE_UBLOX_GNSS::fileBufferSpaceUsed(void) } // PRIVATE: Add a UBX packet to the file buffer -boolean SFE_UBLOX_GNSS::storePacket(ubxPacket *msg) +bool SFE_UBLOX_GNSS::storePacket(ubxPacket *msg) { // First, check that the file buffer has been created if ((ubxFileBuffer == NULL) || (fileBufferSize == 0)) @@ -4115,7 +4115,7 @@ boolean SFE_UBLOX_GNSS::storePacket(ubxPacket *msg) } // PRIVATE: Add theBytes to the file buffer -boolean SFE_UBLOX_GNSS::storeFileBytes(uint8_t *theBytes, uint16_t numBytes) +bool SFE_UBLOX_GNSS::storeFileBytes(uint8_t *theBytes, uint16_t numBytes) { // First, check that the file buffer has been created if ((ubxFileBuffer == NULL) || (fileBufferSize == 0)) @@ -4178,7 +4178,7 @@ void SFE_UBLOX_GNSS::writeToFileBuffer(uint8_t *theBytes, uint16_t numBytes) //=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-==-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= //Loads the payloadCfg array with the current protocol bits located the UBX-CFG-PRT register for a given port -boolean SFE_UBLOX_GNSS::getPortSettings(uint8_t portID, uint16_t maxWait) +bool SFE_UBLOX_GNSS::getPortSettings(uint8_t portID, uint16_t maxWait) { packetCfg.cls = UBX_CLASS_CFG; packetCfg.id = UBX_CFG_PRT; @@ -4193,7 +4193,7 @@ boolean SFE_UBLOX_GNSS::getPortSettings(uint8_t portID, uint16_t maxWait) //Configure a given port to output UBX, NMEA, RTCM3 or a combination thereof //Port 0=I2c, 1=UART1, 2=UART2, 3=USB, 4=SPI //Bit:0 = UBX, :1=NMEA, :5=RTCM3 -boolean SFE_UBLOX_GNSS::setPortOutput(uint8_t portID, uint8_t outStreamSettings, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setPortOutput(uint8_t portID, uint8_t outStreamSettings, uint16_t maxWait) { //Get the current config values for this port ID if (getPortSettings(portID, maxWait) == false) @@ -4213,7 +4213,7 @@ boolean SFE_UBLOX_GNSS::setPortOutput(uint8_t portID, uint8_t outStreamSettings, //Configure a given port to input UBX, NMEA, RTCM3 or a combination thereof //Port 0=I2c, 1=UART1, 2=UART2, 3=USB, 4=SPI //Bit:0 = UBX, :1=NMEA, :5=RTCM3 -boolean SFE_UBLOX_GNSS::setPortInput(uint8_t portID, uint8_t inStreamSettings, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setPortInput(uint8_t portID, uint8_t inStreamSettings, uint16_t maxWait) { //Get the current config values for this port ID //This will load the payloadCfg array with current port settings @@ -4233,7 +4233,7 @@ boolean SFE_UBLOX_GNSS::setPortInput(uint8_t portID, uint8_t inStreamSettings, u //Changes the I2C address that the u-blox module responds to //0x42 is the default but can be changed with this command -boolean SFE_UBLOX_GNSS::setI2CAddress(uint8_t deviceAddress, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setI2CAddress(uint8_t deviceAddress, uint16_t maxWait) { //Get the current config values for the I2C port //This will load the payloadCfg array with current port settings @@ -4304,23 +4304,23 @@ void SFE_UBLOX_GNSS::setSerialRate(uint32_t baudrate, uint8_t uartPort, uint16_t } //Configure a port to output UBX, NMEA, RTCM3 or a combination thereof -boolean SFE_UBLOX_GNSS::setI2COutput(uint8_t comSettings, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setI2COutput(uint8_t comSettings, uint16_t maxWait) { return (setPortOutput(COM_PORT_I2C, comSettings, maxWait)); } -boolean SFE_UBLOX_GNSS::setUART1Output(uint8_t comSettings, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setUART1Output(uint8_t comSettings, uint16_t maxWait) { return (setPortOutput(COM_PORT_UART1, comSettings, maxWait)); } -boolean SFE_UBLOX_GNSS::setUART2Output(uint8_t comSettings, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setUART2Output(uint8_t comSettings, uint16_t maxWait) { return (setPortOutput(COM_PORT_UART2, comSettings, maxWait)); } -boolean SFE_UBLOX_GNSS::setUSBOutput(uint8_t comSettings, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setUSBOutput(uint8_t comSettings, uint16_t maxWait) { return (setPortOutput(COM_PORT_USB, comSettings, maxWait)); } -boolean SFE_UBLOX_GNSS::setSPIOutput(uint8_t comSettings, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setSPIOutput(uint8_t comSettings, uint16_t maxWait) { return (setPortOutput(COM_PORT_SPI, comSettings, maxWait)); } @@ -4368,7 +4368,7 @@ void SFE_UBLOX_GNSS::hardReset() //Reset module to factory defaults //This still works but it is the old way of configuring ublox modules. See getVal and setVal for the new methods -boolean SFE_UBLOX_GNSS::factoryDefault(uint16_t maxWait) +bool SFE_UBLOX_GNSS::factoryDefault(uint16_t maxWait) { packetCfg.cls = UBX_CLASS_CFG; packetCfg.id = UBX_CFG_CFG; @@ -4390,7 +4390,7 @@ boolean SFE_UBLOX_GNSS::factoryDefault(uint16_t maxWait) //Save current configuration to flash and BBR (battery backed RAM) //This still works but it is the old way of configuring ublox modules. See getVal and setVal for the new methods -boolean SFE_UBLOX_GNSS::saveConfiguration(uint16_t maxWait) +bool SFE_UBLOX_GNSS::saveConfiguration(uint16_t maxWait) { packetCfg.cls = UBX_CLASS_CFG; packetCfg.id = UBX_CFG_CFG; @@ -4408,7 +4408,7 @@ boolean SFE_UBLOX_GNSS::saveConfiguration(uint16_t maxWait) //Save the selected configuration sub-sections to flash and BBR (battery backed RAM) //This still works but it is the old way of configuring ublox modules. See getVal and setVal for the new methods -boolean SFE_UBLOX_GNSS::saveConfigSelective(uint32_t configMask, uint16_t maxWait) +bool SFE_UBLOX_GNSS::saveConfigSelective(uint32_t configMask, uint16_t maxWait) { packetCfg.cls = UBX_CLASS_CFG; packetCfg.id = UBX_CFG_CFG; @@ -4427,7 +4427,7 @@ boolean SFE_UBLOX_GNSS::saveConfigSelective(uint32_t configMask, uint16_t maxWai } //Configure a given message type for a given port (UART1, I2C, SPI, etc) -boolean SFE_UBLOX_GNSS::configureMessage(uint8_t msgClass, uint8_t msgID, uint8_t portID, uint8_t sendRate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::configureMessage(uint8_t msgClass, uint8_t msgID, uint8_t portID, uint8_t sendRate, uint16_t maxWait) { //Poll for the current settings for a given message packetCfg.cls = UBX_CLASS_CFG; @@ -4452,21 +4452,21 @@ boolean SFE_UBLOX_GNSS::configureMessage(uint8_t msgClass, uint8_t msgID, uint8_ } //Enable a given message type, default of 1 per update rate (usually 1 per second) -boolean SFE_UBLOX_GNSS::enableMessage(uint8_t msgClass, uint8_t msgID, uint8_t portID, uint8_t rate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::enableMessage(uint8_t msgClass, uint8_t msgID, uint8_t portID, uint8_t rate, uint16_t maxWait) { return (configureMessage(msgClass, msgID, portID, rate, maxWait)); } //Disable a given message type on a given port -boolean SFE_UBLOX_GNSS::disableMessage(uint8_t msgClass, uint8_t msgID, uint8_t portID, uint16_t maxWait) +bool SFE_UBLOX_GNSS::disableMessage(uint8_t msgClass, uint8_t msgID, uint8_t portID, uint16_t maxWait) { return (configureMessage(msgClass, msgID, portID, 0, maxWait)); } -boolean SFE_UBLOX_GNSS::enableNMEAMessage(uint8_t msgID, uint8_t portID, uint8_t rate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::enableNMEAMessage(uint8_t msgID, uint8_t portID, uint8_t rate, uint16_t maxWait) { return (configureMessage(UBX_CLASS_NMEA, msgID, portID, rate, maxWait)); } -boolean SFE_UBLOX_GNSS::disableNMEAMessage(uint8_t msgID, uint8_t portID, uint16_t maxWait) +bool SFE_UBLOX_GNSS::disableNMEAMessage(uint8_t msgID, uint8_t portID, uint16_t maxWait) { return (enableNMEAMessage(msgID, portID, 0, maxWait)); } @@ -4486,13 +4486,13 @@ boolean SFE_UBLOX_GNSS::disableNMEAMessage(uint8_t msgID, uint8_t portID, uint16 //1005, 1074, 1084, 1094, 1124, 1230 //Much of this configuration is not documented and instead discerned from u-center binary console -boolean SFE_UBLOX_GNSS::enableRTCMmessage(uint8_t messageNumber, uint8_t portID, uint8_t sendRate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::enableRTCMmessage(uint8_t messageNumber, uint8_t portID, uint8_t sendRate, uint16_t maxWait) { return (configureMessage(UBX_RTCM_MSB, messageNumber, portID, sendRate, maxWait)); } //Disable a given message on a given port by setting secondsBetweenMessages to zero -boolean SFE_UBLOX_GNSS::disableRTCMmessage(uint8_t messageNumber, uint8_t portID, uint16_t maxWait) +bool SFE_UBLOX_GNSS::disableRTCMmessage(uint8_t messageNumber, uint8_t portID, uint16_t maxWait) { return (enableRTCMmessage(messageNumber, portID, 0, maxWait)); } @@ -4500,7 +4500,7 @@ boolean SFE_UBLOX_GNSS::disableRTCMmessage(uint8_t messageNumber, uint8_t portID //Functions used for RTK and base station setup //Get the current TimeMode3 settings - these contain survey in statuses -boolean SFE_UBLOX_GNSS::getSurveyMode(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getSurveyMode(uint16_t maxWait) { packetCfg.cls = UBX_CLASS_CFG; packetCfg.id = UBX_CFG_TMODE3; @@ -4511,7 +4511,7 @@ boolean SFE_UBLOX_GNSS::getSurveyMode(uint16_t maxWait) } //Control Survey-In for NEO-M8P -boolean SFE_UBLOX_GNSS::setSurveyMode(uint8_t mode, uint16_t observationTime, float requiredAccuracy, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setSurveyMode(uint8_t mode, uint16_t observationTime, float requiredAccuracy, uint16_t maxWait) { if (getSurveyMode(maxWait) == false) //Ask module for the current TimeMode3 settings. Loads into payloadCfg. return (false); @@ -4541,13 +4541,13 @@ boolean SFE_UBLOX_GNSS::setSurveyMode(uint8_t mode, uint16_t observationTime, fl } //Begin Survey-In for NEO-M8P -boolean SFE_UBLOX_GNSS::enableSurveyMode(uint16_t observationTime, float requiredAccuracy, uint16_t maxWait) +bool SFE_UBLOX_GNSS::enableSurveyMode(uint16_t observationTime, float requiredAccuracy, uint16_t maxWait) { return (setSurveyMode(SVIN_MODE_ENABLE, observationTime, requiredAccuracy, maxWait)); } //Stop Survey-In for NEO-M8P -boolean SFE_UBLOX_GNSS::disableSurveyMode(uint16_t maxWait) +bool SFE_UBLOX_GNSS::disableSurveyMode(uint16_t maxWait) { return (setSurveyMode(SVIN_MODE_DISABLE, 0, 0, maxWait)); } @@ -4637,7 +4637,7 @@ uint8_t SFE_UBLOX_GNSS::getProtocolVersionLow(uint16_t maxWait) //Get the current protocol version of the u-blox module we're communicating with //This is helpful when deciding if we should call the high-precision Lat/Long (HPPOSLLH) or the regular (POSLLH) -boolean SFE_UBLOX_GNSS::getProtocolVersion(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getProtocolVersion(uint16_t maxWait) { if (moduleSWVersion == NULL) initModuleSWVersion(); //Check that RAM has been allocated for the SW version if (moduleSWVersion == NULL) //Bail if the RAM allocation failed @@ -4694,7 +4694,7 @@ boolean SFE_UBLOX_GNSS::getProtocolVersion(uint16_t maxWait) } // PRIVATE: Allocate RAM for moduleSWVersion and initialize it -boolean SFE_UBLOX_GNSS::initModuleSWVersion() +bool SFE_UBLOX_GNSS::initModuleSWVersion() { moduleSWVersion = new moduleSWVersion_t; //Allocate RAM for the main struct if (moduleSWVersion == NULL) @@ -4712,7 +4712,7 @@ boolean SFE_UBLOX_GNSS::initModuleSWVersion() // Geofences //Add a new geofence using UBX-CFG-GEOFENCE -boolean SFE_UBLOX_GNSS::addGeofence(int32_t latitude, int32_t longitude, uint32_t radius, byte confidence, byte pinPolarity, byte pin, uint16_t maxWait) +bool SFE_UBLOX_GNSS::addGeofence(int32_t latitude, int32_t longitude, uint32_t radius, byte confidence, byte pinPolarity, byte pin, uint16_t maxWait) { if (currentGeofenceParams == NULL) initGeofenceParams(); // Check if RAM has been allocated for currentGeofenceParams if (currentGeofenceParams == NULL) // Abort if the RAM allocation failed @@ -4808,7 +4808,7 @@ boolean SFE_UBLOX_GNSS::addGeofence(int32_t latitude, int32_t longitude, uint32_ } //Clear all geofences using UBX-CFG-GEOFENCE -boolean SFE_UBLOX_GNSS::clearGeofences(uint16_t maxWait) +bool SFE_UBLOX_GNSS::clearGeofences(uint16_t maxWait) { if (currentGeofenceParams == NULL) initGeofenceParams(); // Check if RAM has been allocated for currentGeofenceParams if (currentGeofenceParams == NULL) // Abort if the RAM allocation failed @@ -4836,7 +4836,7 @@ boolean SFE_UBLOX_GNSS::clearGeofences(uint16_t maxWait) //Clear the antenna control settings using UBX-CFG-ANT //This function is hopefully redundant but may be needed to release //any PIO pins pre-allocated for antenna functions -boolean SFE_UBLOX_GNSS::clearAntPIO(uint16_t maxWait) +bool SFE_UBLOX_GNSS::clearAntPIO(uint16_t maxWait) { packetCfg.cls = UBX_CLASS_CFG; packetCfg.id = UBX_CFG_ANT; @@ -4852,7 +4852,7 @@ boolean SFE_UBLOX_GNSS::clearAntPIO(uint16_t maxWait) } //Returns the combined geofence state using UBX-NAV-GEOFENCE -boolean SFE_UBLOX_GNSS::getGeofenceState(geofenceState ¤tGeofenceState, uint16_t maxWait) +bool SFE_UBLOX_GNSS::getGeofenceState(geofenceState ¤tGeofenceState, uint16_t maxWait) { packetCfg.cls = UBX_CLASS_NAV; packetCfg.id = UBX_NAV_GEOFENCE; @@ -4879,7 +4879,7 @@ boolean SFE_UBLOX_GNSS::getGeofenceState(geofenceState ¤tGeofenceState, ui } // PRIVATE: Allocate RAM for currentGeofenceParams and initialize it -boolean SFE_UBLOX_GNSS::initGeofenceParams() +bool SFE_UBLOX_GNSS::initGeofenceParams() { currentGeofenceParams = new geofenceParams_t; //Allocate RAM for the main struct if (currentGeofenceParams == NULL) @@ -4894,7 +4894,7 @@ boolean SFE_UBLOX_GNSS::initGeofenceParams() //Power Save Mode //Enables/Disables Low Power Mode using UBX-CFG-RXM -boolean SFE_UBLOX_GNSS::powerSaveMode(bool power_save, uint16_t maxWait) +bool SFE_UBLOX_GNSS::powerSaveMode(bool power_save, uint16_t maxWait) { // Let's begin by checking the Protocol Version as UBX_CFG_RXM is not supported on the ZED (protocol >= 27) uint8_t protVer = getProtocolVersionHigh(maxWait); @@ -4979,7 +4979,7 @@ uint8_t SFE_UBLOX_GNSS::getPowerSaveMode(uint16_t maxWait) // NOTE: Querying the device before the duration is complete, for example by "getLatitude()" will wake it up! // Returns true if command has not been not acknowledged. // Returns false if command has not been acknowledged or maxWait = 0. -boolean SFE_UBLOX_GNSS::powerOff(uint32_t durationInMs, uint16_t maxWait) +bool SFE_UBLOX_GNSS::powerOff(uint32_t durationInMs, uint16_t maxWait) { // use durationInMs = 0 for infinite duration #ifndef SFE_UBLOX_REDUCED_PROG_MEM @@ -5027,7 +5027,7 @@ boolean SFE_UBLOX_GNSS::powerOff(uint32_t durationInMs, uint16_t maxWait) // NOTE: Querying the device before the duration is complete, for example by "getLatitude()" will wake it up! // Returns true if command has not been not acknowledged. // Returns false if command has not been acknowledged or maxWait = 0. -boolean SFE_UBLOX_GNSS::powerOffWithInterrupt(uint32_t durationInMs, uint32_t wakeupSources, boolean forceWhileUsb, uint16_t maxWait) +bool SFE_UBLOX_GNSS::powerOffWithInterrupt(uint32_t durationInMs, uint32_t wakeupSources, bool forceWhileUsb, uint16_t maxWait) { // use durationInMs = 0 for infinite duration #ifndef SFE_UBLOX_REDUCED_PROG_MEM @@ -5110,7 +5110,7 @@ boolean SFE_UBLOX_GNSS::powerOffWithInterrupt(uint32_t durationInMs, uint32_t wa //AIRBORNE1g,AIRBORNE2g,AIRBORNE4g,WRIST,BIKE //WRIST is not supported in protocol versions less than 18 //BIKE is supported in protocol versions 19.2 -boolean SFE_UBLOX_GNSS::setDynamicModel(dynModel newDynamicModel, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setDynamicModel(dynModel newDynamicModel, uint16_t maxWait) { packetCfg.cls = UBX_CLASS_CFG; packetCfg.id = UBX_CFG_NAV5; @@ -5148,7 +5148,7 @@ uint8_t SFE_UBLOX_GNSS::getDynamicModel(uint16_t maxWait) } //Reset the odometer -boolean SFE_UBLOX_GNSS::resetOdometer(uint16_t maxWait) +bool SFE_UBLOX_GNSS::resetOdometer(uint16_t maxWait) { packetCfg.cls = UBX_CLASS_NAV; packetCfg.id = UBX_NAV_RESETODO; @@ -5160,7 +5160,7 @@ boolean SFE_UBLOX_GNSS::resetOdometer(uint16_t maxWait) } //Enable/Disable individual GNSS systems using UBX-CFG-GNSS -boolean SFE_UBLOX_GNSS::enableGNSS(boolean enable, sfe_ublox_gnss_ids_e id, uint16_t maxWait) +bool SFE_UBLOX_GNSS::enableGNSS(bool enable, sfe_ublox_gnss_ids_e id, uint16_t maxWait) { packetCfg.cls = UBX_CLASS_CFG; packetCfg.id = UBX_CFG_GNSS; @@ -5188,7 +5188,7 @@ boolean SFE_UBLOX_GNSS::enableGNSS(boolean enable, sfe_ublox_gnss_ids_e id, uint } //Check if an individual GNSS system is enabled -boolean SFE_UBLOX_GNSS::isGNSSenabled(sfe_ublox_gnss_ids_e id, uint16_t maxWait) +bool SFE_UBLOX_GNSS::isGNSSenabled(sfe_ublox_gnss_ids_e id, uint16_t maxWait) { packetCfg.cls = UBX_CLASS_CFG; packetCfg.id = UBX_CFG_GNSS; @@ -5198,7 +5198,7 @@ boolean SFE_UBLOX_GNSS::isGNSSenabled(sfe_ublox_gnss_ids_e id, uint16_t maxWait) if (sendCommand(&packetCfg, maxWait) != SFE_UBLOX_STATUS_DATA_RECEIVED) // We are expecting data and an ACK return (false); - boolean retVal = false; + bool retVal = false; uint8_t numConfigBlocks = payloadCfg[3]; // Extract the numConfigBlocks @@ -5216,7 +5216,7 @@ boolean SFE_UBLOX_GNSS::isGNSSenabled(sfe_ublox_gnss_ids_e id, uint16_t maxWait) } //Reset ESF automatic IMU-mount alignment -boolean SFE_UBLOX_GNSS::resetIMUalignment(uint16_t maxWait) +bool SFE_UBLOX_GNSS::resetIMUalignment(uint16_t maxWait) { packetCfg.cls = UBX_CLASS_ESF; packetCfg.id = UBX_ESF_RESETALG; @@ -5294,7 +5294,7 @@ bool SFE_UBLOX_GNSS::setESFAutoAlignment(bool enable, uint16_t maxWait) //Get the time pulse parameters using UBX_CFG_TP5 -boolean SFE_UBLOX_GNSS::getTimePulseParameters(UBX_CFG_TP5_data_t *data, uint16_t maxWait) +bool SFE_UBLOX_GNSS::getTimePulseParameters(UBX_CFG_TP5_data_t *data, uint16_t maxWait) { if (data == NULL) // Check if the user forgot to include the data pointer return (false); // Bail @@ -5323,7 +5323,7 @@ boolean SFE_UBLOX_GNSS::getTimePulseParameters(UBX_CFG_TP5_data_t *data, uint16_ } //Set the time pulse parameters using UBX_CFG_TP5 -boolean SFE_UBLOX_GNSS::setTimePulseParameters(UBX_CFG_TP5_data_t *data, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setTimePulseParameters(UBX_CFG_TP5_data_t *data, uint16_t maxWait) { if (data == NULL) // Check if the user forgot to include the data pointer return (false); // Bail @@ -5787,7 +5787,7 @@ uint8_t SFE_UBLOX_GNSS::sendCfgValset8(uint32_t key, uint8_t value, uint16_t max // ***** NAV POSECEF automatic support -boolean SFE_UBLOX_GNSS::getNAVPOSECEF(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getNAVPOSECEF(uint16_t maxWait) { if (packetUBXNAVPOSECEF == NULL) initPacketUBXNAVPOSECEF(); //Check that RAM has been allocated for the POSECEF data if (packetUBXNAVPOSECEF == NULL) //Bail if the RAM allocation failed @@ -5829,21 +5829,21 @@ boolean SFE_UBLOX_GNSS::getNAVPOSECEF(uint16_t maxWait) //Enable or disable automatic navigation message generation by the GNSS. This changes the way getPOSECEF //works. -boolean SFE_UBLOX_GNSS::setAutoNAVPOSECEF(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVPOSECEF(bool enable, uint16_t maxWait) { return setAutoNAVPOSECEFrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getPOSECEF //works. -boolean SFE_UBLOX_GNSS::setAutoNAVPOSECEF(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVPOSECEF(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoNAVPOSECEFrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getPOSECEF //works. -boolean SFE_UBLOX_GNSS::setAutoNAVPOSECEFrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVPOSECEFrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXNAVPOSECEF == NULL) initPacketUBXNAVPOSECEF(); //Check that RAM has been allocated for the data if (packetUBXNAVPOSECEF == NULL) //Only attempt this if RAM allocation was successful @@ -5859,7 +5859,7 @@ boolean SFE_UBLOX_GNSS::setAutoNAVPOSECEFrate(uint8_t rate, boolean implicitUpda payloadCfg[1] = UBX_NAV_POSECEF; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXNAVPOSECEF->automaticFlags.flags.bits.automatic = (rate > 0); @@ -5870,10 +5870,10 @@ boolean SFE_UBLOX_GNSS::setAutoNAVPOSECEFrate(uint8_t rate, boolean implicitUpda } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoNAVPOSECEFcallback(void (*callbackPointer)(UBX_NAV_POSECEF_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVPOSECEFcallback(void (*callbackPointer)(UBX_NAV_POSECEF_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoNAVPOSECEF(true, false, maxWait); + bool result = setAutoNAVPOSECEF(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -5895,13 +5895,13 @@ boolean SFE_UBLOX_GNSS::setAutoNAVPOSECEFcallback(void (*callbackPointer)(UBX_NA //In case no config access to the GNSS is possible and POSECEF is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoNAVPOSECEF(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoNAVPOSECEF(bool enabled, bool implicitUpdate) { if (packetUBXNAVPOSECEF == NULL) initPacketUBXNAVPOSECEF(); //Check that RAM has been allocated for the data if (packetUBXNAVPOSECEF == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXNAVPOSECEF->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVPOSECEF->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXNAVPOSECEF->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVPOSECEF->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXNAVPOSECEF->automaticFlags.flags.bits.automatic = enabled; @@ -5911,7 +5911,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoNAVPOSECEF(boolean enabled, boolean implicitUp } // PRIVATE: Allocate RAM for packetUBXNAVPOSECEF and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXNAVPOSECEF() +bool SFE_UBLOX_GNSS::initPacketUBXNAVPOSECEF() { packetUBXNAVPOSECEF = new UBX_NAV_POSECEF_t; //Allocate RAM for the main struct if (packetUBXNAVPOSECEF == NULL) @@ -5936,7 +5936,7 @@ void SFE_UBLOX_GNSS::flushNAVPOSECEF() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logNAVPOSECEF(boolean enabled) +void SFE_UBLOX_GNSS::logNAVPOSECEF(bool enabled) { if (packetUBXNAVPOSECEF == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXNAVPOSECEF->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -5944,7 +5944,7 @@ void SFE_UBLOX_GNSS::logNAVPOSECEF(boolean enabled) // ***** NAV STATUS automatic support -boolean SFE_UBLOX_GNSS::getNAVSTATUS(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getNAVSTATUS(uint16_t maxWait) { if (packetUBXNAVSTATUS == NULL) initPacketUBXNAVSTATUS(); //Check that RAM has been allocated for the STATUS data if (packetUBXNAVSTATUS == NULL) //Bail if the RAM allocation failed @@ -5986,21 +5986,21 @@ boolean SFE_UBLOX_GNSS::getNAVSTATUS(uint16_t maxWait) //Enable or disable automatic navigation message generation by the GNSS. This changes the way getNAVSTATUS //works. -boolean SFE_UBLOX_GNSS::setAutoNAVSTATUS(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVSTATUS(bool enable, uint16_t maxWait) { return setAutoNAVSTATUSrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getNAVSTATUS //works. -boolean SFE_UBLOX_GNSS::setAutoNAVSTATUS(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVSTATUS(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoNAVSTATUSrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getNAVSTATUS //works. -boolean SFE_UBLOX_GNSS::setAutoNAVSTATUSrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVSTATUSrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXNAVSTATUS == NULL) initPacketUBXNAVSTATUS(); //Check that RAM has been allocated for the data if (packetUBXNAVSTATUS == NULL) //Only attempt this if RAM allocation was successful @@ -6016,7 +6016,7 @@ boolean SFE_UBLOX_GNSS::setAutoNAVSTATUSrate(uint8_t rate, boolean implicitUpdat payloadCfg[1] = UBX_NAV_STATUS; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXNAVSTATUS->automaticFlags.flags.bits.automatic = (rate > 0); @@ -6027,10 +6027,10 @@ boolean SFE_UBLOX_GNSS::setAutoNAVSTATUSrate(uint8_t rate, boolean implicitUpdat } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoNAVSTATUScallback(void (*callbackPointer)(UBX_NAV_STATUS_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVSTATUScallback(void (*callbackPointer)(UBX_NAV_STATUS_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoNAVSTATUS(true, false, maxWait); + bool result = setAutoNAVSTATUS(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -6052,13 +6052,13 @@ boolean SFE_UBLOX_GNSS::setAutoNAVSTATUScallback(void (*callbackPointer)(UBX_NAV //In case no config access to the GNSS is possible and STATUS is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoNAVSTATUS(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoNAVSTATUS(bool enabled, bool implicitUpdate) { if (packetUBXNAVSTATUS == NULL) initPacketUBXNAVSTATUS(); //Check that RAM has been allocated for the data if (packetUBXNAVSTATUS == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXNAVSTATUS->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVSTATUS->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXNAVSTATUS->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVSTATUS->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXNAVSTATUS->automaticFlags.flags.bits.automatic = enabled; @@ -6068,7 +6068,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoNAVSTATUS(boolean enabled, boolean implicitUpd } // PRIVATE: Allocate RAM for packetUBXNAVSTATUS and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXNAVSTATUS() +bool SFE_UBLOX_GNSS::initPacketUBXNAVSTATUS() { packetUBXNAVSTATUS = new UBX_NAV_STATUS_t; //Allocate RAM for the main struct if (packetUBXNAVSTATUS == NULL) @@ -6093,7 +6093,7 @@ void SFE_UBLOX_GNSS::flushNAVSTATUS() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logNAVSTATUS(boolean enabled) +void SFE_UBLOX_GNSS::logNAVSTATUS(bool enabled) { if (packetUBXNAVSTATUS == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXNAVSTATUS->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -6101,7 +6101,7 @@ void SFE_UBLOX_GNSS::logNAVSTATUS(boolean enabled) // ***** DOP automatic support -boolean SFE_UBLOX_GNSS::getDOP(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getDOP(uint16_t maxWait) { if (packetUBXNAVDOP == NULL) initPacketUBXNAVDOP(); //Check that RAM has been allocated for the DOP data if (packetUBXNAVDOP == NULL) //Bail if the RAM allocation failed @@ -6165,21 +6165,21 @@ boolean SFE_UBLOX_GNSS::getDOP(uint16_t maxWait) //Enable or disable automatic navigation message generation by the GNSS. This changes the way getDOP //works. -boolean SFE_UBLOX_GNSS::setAutoDOP(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoDOP(bool enable, uint16_t maxWait) { return setAutoDOPrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getDOP //works. -boolean SFE_UBLOX_GNSS::setAutoDOP(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoDOP(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoDOPrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getDOP //works. -boolean SFE_UBLOX_GNSS::setAutoDOPrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoDOPrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXNAVDOP == NULL) initPacketUBXNAVDOP(); //Check that RAM has been allocated for the data if (packetUBXNAVDOP == NULL) //Only attempt this if RAM allocation was successful @@ -6193,7 +6193,7 @@ boolean SFE_UBLOX_GNSS::setAutoDOPrate(uint8_t rate, boolean implicitUpdate, uin payloadCfg[1] = UBX_NAV_DOP; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXNAVDOP->automaticFlags.flags.bits.automatic = (rate > 0); @@ -6204,10 +6204,10 @@ boolean SFE_UBLOX_GNSS::setAutoDOPrate(uint8_t rate, boolean implicitUpdate, uin } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoDOPcallback(void (*callbackPointer)(UBX_NAV_DOP_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoDOPcallback(void (*callbackPointer)(UBX_NAV_DOP_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoDOP(true, false, maxWait); + bool result = setAutoDOP(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -6229,13 +6229,13 @@ boolean SFE_UBLOX_GNSS::setAutoDOPcallback(void (*callbackPointer)(UBX_NAV_DOP_d //In case no config access to the GNSS is possible and DOP is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoDOP(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoDOP(bool enabled, bool implicitUpdate) { if (packetUBXNAVDOP == NULL) initPacketUBXNAVDOP(); //Check that RAM has been allocated for the data if (packetUBXNAVDOP == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXNAVDOP->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVDOP->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXNAVDOP->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVDOP->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXNAVDOP->automaticFlags.flags.bits.automatic = enabled; @@ -6245,7 +6245,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoDOP(boolean enabled, boolean implicitUpdate) } // PRIVATE: Allocate RAM for packetUBXNAVDOP and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXNAVDOP() +bool SFE_UBLOX_GNSS::initPacketUBXNAVDOP() { packetUBXNAVDOP = new UBX_NAV_DOP_t; //Allocate RAM for the main struct if (packetUBXNAVDOP == NULL) @@ -6269,7 +6269,7 @@ void SFE_UBLOX_GNSS::flushDOP() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logNAVDOP(boolean enabled) +void SFE_UBLOX_GNSS::logNAVDOP(bool enabled) { if (packetUBXNAVDOP == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXNAVDOP->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -6277,12 +6277,12 @@ void SFE_UBLOX_GNSS::logNAVDOP(boolean enabled) // ***** VEH ATT automatic support -boolean SFE_UBLOX_GNSS::getVehAtt(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getVehAtt(uint16_t maxWait) { return (getNAVATT(maxWait)); } -boolean SFE_UBLOX_GNSS::getNAVATT(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getNAVATT(uint16_t maxWait) { if (packetUBXNAVATT == NULL) initPacketUBXNAVATT(); //Check that RAM has been allocated for the ESF RAW data if (packetUBXNAVATT == NULL) //Only attempt this if RAM allocation was successful @@ -6326,21 +6326,21 @@ boolean SFE_UBLOX_GNSS::getNAVATT(uint16_t maxWait) //Enable or disable automatic NAV ATT message generation by the GNSS. This changes the way getVehAtt //works. -boolean SFE_UBLOX_GNSS::setAutoNAVATT(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVATT(bool enable, uint16_t maxWait) { return setAutoNAVATTrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic NAV ATT message generation by the GNSS. This changes the way getVehAtt //works. -boolean SFE_UBLOX_GNSS::setAutoNAVATT(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVATT(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoNAVATTrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic NAV ATT attitude message generation by the GNSS. This changes the way getVehAtt //works. -boolean SFE_UBLOX_GNSS::setAutoNAVATTrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVATTrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXNAVATT == NULL) initPacketUBXNAVATT(); //Check that RAM has been allocated for the data if (packetUBXNAVATT == NULL) //Only attempt this if RAM allocation was successful @@ -6356,7 +6356,7 @@ boolean SFE_UBLOX_GNSS::setAutoNAVATTrate(uint8_t rate, boolean implicitUpdate, payloadCfg[1] = UBX_NAV_ATT; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXNAVATT->automaticFlags.flags.bits.automatic = (rate > 0); @@ -6367,10 +6367,10 @@ boolean SFE_UBLOX_GNSS::setAutoNAVATTrate(uint8_t rate, boolean implicitUpdate, } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoNAVATTcallback(void (*callbackPointer)(UBX_NAV_ATT_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVATTcallback(void (*callbackPointer)(UBX_NAV_ATT_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoNAVATT(true, false, maxWait); + bool result = setAutoNAVATT(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -6392,13 +6392,13 @@ boolean SFE_UBLOX_GNSS::setAutoNAVATTcallback(void (*callbackPointer)(UBX_NAV_AT //In case no config access to the GNSS is possible and NAV ATT attitude is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoNAVATT(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoNAVATT(bool enabled, bool implicitUpdate) { if (packetUBXNAVATT == NULL) initPacketUBXNAVATT(); //Check that RAM has been allocated for the ESF RAW data if (packetUBXNAVATT == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXNAVATT->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVATT->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXNAVATT->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVATT->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXNAVATT->automaticFlags.flags.bits.automatic = enabled; @@ -6408,7 +6408,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoNAVATT(boolean enabled, boolean implicitUpdate } // PRIVATE: Allocate RAM for packetUBXNAVATT and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXNAVATT() +bool SFE_UBLOX_GNSS::initPacketUBXNAVATT() { packetUBXNAVATT = new UBX_NAV_ATT_t; //Allocate RAM for the main struct if (packetUBXNAVATT == NULL) @@ -6432,7 +6432,7 @@ void SFE_UBLOX_GNSS::flushNAVATT() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logNAVATT(boolean enabled) +void SFE_UBLOX_GNSS::logNAVATT(bool enabled) { if (packetUBXNAVATT == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXNAVATT->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -6441,7 +6441,7 @@ void SFE_UBLOX_GNSS::logNAVATT(boolean enabled) // ***** PVT automatic support //Get the latest Position/Velocity/Time solution and fill all global variables -boolean SFE_UBLOX_GNSS::getPVT(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getPVT(uint16_t maxWait) { if (packetUBXNAVPVT == NULL) initPacketUBXNAVPVT(); //Check that RAM has been allocated for the PVT data if (packetUBXNAVPVT == NULL) //Bail if the RAM allocation failed @@ -6506,21 +6506,21 @@ boolean SFE_UBLOX_GNSS::getPVT(uint16_t maxWait) //Enable or disable automatic navigation message generation by the GNSS. This changes the way getPVT //works. -boolean SFE_UBLOX_GNSS::setAutoPVT(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoPVT(bool enable, uint16_t maxWait) { return setAutoPVTrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getPVT //works. -boolean SFE_UBLOX_GNSS::setAutoPVT(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoPVT(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoPVTrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getPVT //works. -boolean SFE_UBLOX_GNSS::setAutoPVTrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoPVTrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXNAVPVT == NULL) initPacketUBXNAVPVT(); //Check that RAM has been allocated for the PVT data if (packetUBXNAVPVT == NULL) //Only attempt this if RAM allocation was successful @@ -6536,7 +6536,7 @@ boolean SFE_UBLOX_GNSS::setAutoPVTrate(uint8_t rate, boolean implicitUpdate, uin payloadCfg[1] = UBX_NAV_PVT; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXNAVPVT->automaticFlags.flags.bits.automatic = (rate > 0); @@ -6547,10 +6547,10 @@ boolean SFE_UBLOX_GNSS::setAutoPVTrate(uint8_t rate, boolean implicitUpdate, uin } //Enable automatic navigation message generation by the GNSS. This changes the way getPVT works. -boolean SFE_UBLOX_GNSS::setAutoPVTcallback(void (*callbackPointer)(UBX_NAV_PVT_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoPVTcallback(void (*callbackPointer)(UBX_NAV_PVT_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoPVT(true, false, maxWait); + bool result = setAutoPVT(true, false, maxWait); if (!result) return (result); // Bail if setAutoPVT failed @@ -6573,13 +6573,13 @@ boolean SFE_UBLOX_GNSS::setAutoPVTcallback(void (*callbackPointer)(UBX_NAV_PVT_d //In case no config access to the GNSS is possible and PVT is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoPVT(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoPVT(bool enabled, bool implicitUpdate) { if (packetUBXNAVPVT == NULL) initPacketUBXNAVPVT(); //Check that RAM has been allocated for the PVT data if (packetUBXNAVPVT == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXNAVPVT->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVPVT->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXNAVPVT->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVPVT->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXNAVPVT->automaticFlags.flags.bits.automatic = enabled; @@ -6589,7 +6589,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoPVT(boolean enabled, boolean implicitUpdate) } // PRIVATE: Allocate RAM for packetUBXNAVPVT and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXNAVPVT() +bool SFE_UBLOX_GNSS::initPacketUBXNAVPVT() { packetUBXNAVPVT = new UBX_NAV_PVT_t; //Allocate RAM for the main struct if (packetUBXNAVPVT == NULL) @@ -6615,7 +6615,7 @@ void SFE_UBLOX_GNSS::flushPVT() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logNAVPVT(boolean enabled) +void SFE_UBLOX_GNSS::logNAVPVT(bool enabled) { if (packetUBXNAVPVT == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXNAVPVT->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -6623,7 +6623,7 @@ void SFE_UBLOX_GNSS::logNAVPVT(boolean enabled) // ***** NAV ODO automatic support -boolean SFE_UBLOX_GNSS::getNAVODO(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getNAVODO(uint16_t maxWait) { if (packetUBXNAVODO == NULL) initPacketUBXNAVODO(); //Check that RAM has been allocated for the ODO data if (packetUBXNAVODO == NULL) //Bail if the RAM allocation failed @@ -6665,21 +6665,21 @@ boolean SFE_UBLOX_GNSS::getNAVODO(uint16_t maxWait) //Enable or disable automatic navigation message generation by the GNSS. This changes the way getODO //works. -boolean SFE_UBLOX_GNSS::setAutoNAVODO(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVODO(bool enable, uint16_t maxWait) { return setAutoNAVODOrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getODO //works. -boolean SFE_UBLOX_GNSS::setAutoNAVODO(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVODO(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoNAVODOrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getODO //works. -boolean SFE_UBLOX_GNSS::setAutoNAVODOrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVODOrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXNAVODO == NULL) initPacketUBXNAVODO(); //Check that RAM has been allocated for the data if (packetUBXNAVODO == NULL) //Only attempt this if RAM allocation was successful @@ -6695,7 +6695,7 @@ boolean SFE_UBLOX_GNSS::setAutoNAVODOrate(uint8_t rate, boolean implicitUpdate, payloadCfg[1] = UBX_NAV_ODO; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXNAVODO->automaticFlags.flags.bits.automatic = (rate > 0); @@ -6706,10 +6706,10 @@ boolean SFE_UBLOX_GNSS::setAutoNAVODOrate(uint8_t rate, boolean implicitUpdate, } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoNAVODOcallback(void (*callbackPointer)(UBX_NAV_ODO_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVODOcallback(void (*callbackPointer)(UBX_NAV_ODO_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoNAVODO(true, false, maxWait); + bool result = setAutoNAVODO(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -6731,13 +6731,13 @@ boolean SFE_UBLOX_GNSS::setAutoNAVODOcallback(void (*callbackPointer)(UBX_NAV_OD //In case no config access to the GNSS is possible and ODO is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoNAVODO(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoNAVODO(bool enabled, bool implicitUpdate) { if (packetUBXNAVODO == NULL) initPacketUBXNAVODO(); //Check that RAM has been allocated for the data if (packetUBXNAVODO == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXNAVODO->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVODO->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXNAVODO->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVODO->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXNAVODO->automaticFlags.flags.bits.automatic = enabled; @@ -6747,7 +6747,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoNAVODO(boolean enabled, boolean implicitUpdate } // PRIVATE: Allocate RAM for packetUBXNAVODO and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXNAVODO() +bool SFE_UBLOX_GNSS::initPacketUBXNAVODO() { packetUBXNAVODO = new UBX_NAV_ODO_t; //Allocate RAM for the main struct if (packetUBXNAVODO == NULL) @@ -6771,7 +6771,7 @@ void SFE_UBLOX_GNSS::flushNAVODO() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logNAVODO(boolean enabled) +void SFE_UBLOX_GNSS::logNAVODO(bool enabled) { if (packetUBXNAVODO == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXNAVODO->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -6779,7 +6779,7 @@ void SFE_UBLOX_GNSS::logNAVODO(boolean enabled) // ***** NAV VELECEF automatic support -boolean SFE_UBLOX_GNSS::getNAVVELECEF(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getNAVVELECEF(uint16_t maxWait) { if (packetUBXNAVVELECEF == NULL) initPacketUBXNAVVELECEF(); //Check that RAM has been allocated for the VELECEF data if (packetUBXNAVVELECEF == NULL) //Bail if the RAM allocation failed @@ -6821,21 +6821,21 @@ boolean SFE_UBLOX_GNSS::getNAVVELECEF(uint16_t maxWait) //Enable or disable automatic navigation message generation by the GNSS. This changes the way getVELECEF //works. -boolean SFE_UBLOX_GNSS::setAutoNAVVELECEF(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVVELECEF(bool enable, uint16_t maxWait) { return setAutoNAVVELECEFrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getVELECEF //works. -boolean SFE_UBLOX_GNSS::setAutoNAVVELECEF(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVVELECEF(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoNAVVELECEFrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getVELECEF //works. -boolean SFE_UBLOX_GNSS::setAutoNAVVELECEFrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVVELECEFrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXNAVVELECEF == NULL) initPacketUBXNAVVELECEF(); //Check that RAM has been allocated for the data if (packetUBXNAVVELECEF == NULL) //Only attempt this if RAM allocation was successful @@ -6851,7 +6851,7 @@ boolean SFE_UBLOX_GNSS::setAutoNAVVELECEFrate(uint8_t rate, boolean implicitUpda payloadCfg[1] = UBX_NAV_VELECEF; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXNAVVELECEF->automaticFlags.flags.bits.automatic = (rate > 0); @@ -6862,10 +6862,10 @@ boolean SFE_UBLOX_GNSS::setAutoNAVVELECEFrate(uint8_t rate, boolean implicitUpda } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoNAVVELECEFcallback(void (*callbackPointer)(UBX_NAV_VELECEF_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVVELECEFcallback(void (*callbackPointer)(UBX_NAV_VELECEF_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoNAVVELECEF(true, false, maxWait); + bool result = setAutoNAVVELECEF(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -6887,13 +6887,13 @@ boolean SFE_UBLOX_GNSS::setAutoNAVVELECEFcallback(void (*callbackPointer)(UBX_NA //In case no config access to the GNSS is possible and VELECEF is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoNAVVELECEF(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoNAVVELECEF(bool enabled, bool implicitUpdate) { if (packetUBXNAVVELECEF == NULL) initPacketUBXNAVVELECEF(); //Check that RAM has been allocated for the data if (packetUBXNAVVELECEF == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXNAVVELECEF->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVVELECEF->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXNAVVELECEF->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVVELECEF->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXNAVVELECEF->automaticFlags.flags.bits.automatic = enabled; @@ -6903,7 +6903,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoNAVVELECEF(boolean enabled, boolean implicitUp } // PRIVATE: Allocate RAM for packetUBXNAVVELECEF and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXNAVVELECEF() +bool SFE_UBLOX_GNSS::initPacketUBXNAVVELECEF() { packetUBXNAVVELECEF = new UBX_NAV_VELECEF_t; //Allocate RAM for the main struct if (packetUBXNAVVELECEF == NULL) @@ -6927,7 +6927,7 @@ void SFE_UBLOX_GNSS::flushNAVVELECEF() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logNAVVELECEF(boolean enabled) +void SFE_UBLOX_GNSS::logNAVVELECEF(bool enabled) { if (packetUBXNAVVELECEF == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXNAVVELECEF->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -6935,7 +6935,7 @@ void SFE_UBLOX_GNSS::logNAVVELECEF(boolean enabled) // ***** NAV VELNED automatic support -boolean SFE_UBLOX_GNSS::getNAVVELNED(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getNAVVELNED(uint16_t maxWait) { if (packetUBXNAVVELNED == NULL) initPacketUBXNAVVELNED(); //Check that RAM has been allocated for the VELNED data if (packetUBXNAVVELNED == NULL) //Bail if the RAM allocation failed @@ -6977,21 +6977,21 @@ boolean SFE_UBLOX_GNSS::getNAVVELNED(uint16_t maxWait) //Enable or disable automatic navigation message generation by the GNSS. This changes the way getVELNED //works. -boolean SFE_UBLOX_GNSS::setAutoNAVVELNED(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVVELNED(bool enable, uint16_t maxWait) { return setAutoNAVVELNEDrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getVELNED //works. -boolean SFE_UBLOX_GNSS::setAutoNAVVELNED(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVVELNED(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoNAVVELNEDrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getVELNED //works. -boolean SFE_UBLOX_GNSS::setAutoNAVVELNEDrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVVELNEDrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXNAVVELNED == NULL) initPacketUBXNAVVELNED(); //Check that RAM has been allocated for the data if (packetUBXNAVVELNED == NULL) //Only attempt this if RAM allocation was successful @@ -7005,7 +7005,7 @@ boolean SFE_UBLOX_GNSS::setAutoNAVVELNEDrate(uint8_t rate, boolean implicitUpdat payloadCfg[1] = UBX_NAV_VELNED; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXNAVVELNED->automaticFlags.flags.bits.automatic = (rate > 0); @@ -7016,10 +7016,10 @@ boolean SFE_UBLOX_GNSS::setAutoNAVVELNEDrate(uint8_t rate, boolean implicitUpdat } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoNAVVELNEDcallback(void (*callbackPointer)(UBX_NAV_VELNED_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVVELNEDcallback(void (*callbackPointer)(UBX_NAV_VELNED_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoNAVVELNED(true, false, maxWait); + bool result = setAutoNAVVELNED(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -7041,13 +7041,13 @@ boolean SFE_UBLOX_GNSS::setAutoNAVVELNEDcallback(void (*callbackPointer)(UBX_NAV //In case no config access to the GNSS is possible and VELNED is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoNAVVELNED(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoNAVVELNED(bool enabled, bool implicitUpdate) { if (packetUBXNAVVELNED == NULL) initPacketUBXNAVVELNED(); //Check that RAM has been allocated for the data if (packetUBXNAVVELNED == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXNAVVELNED->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVVELNED->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXNAVVELNED->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVVELNED->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXNAVVELNED->automaticFlags.flags.bits.automatic = enabled; @@ -7057,7 +7057,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoNAVVELNED(boolean enabled, boolean implicitUpd } // PRIVATE: Allocate RAM for packetUBXNAVVELNED and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXNAVVELNED() +bool SFE_UBLOX_GNSS::initPacketUBXNAVVELNED() { packetUBXNAVVELNED = new UBX_NAV_VELNED_t; //Allocate RAM for the main struct if (packetUBXNAVVELNED == NULL) @@ -7081,7 +7081,7 @@ void SFE_UBLOX_GNSS::flushNAVVELNED() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logNAVVELNED(boolean enabled) +void SFE_UBLOX_GNSS::logNAVVELNED(bool enabled) { if (packetUBXNAVVELNED == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXNAVVELNED->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -7089,7 +7089,7 @@ void SFE_UBLOX_GNSS::logNAVVELNED(boolean enabled) // ***** NAV HPPOSECEF automatic support -boolean SFE_UBLOX_GNSS::getNAVHPPOSECEF(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getNAVHPPOSECEF(uint16_t maxWait) { if (packetUBXNAVHPPOSECEF == NULL) initPacketUBXNAVHPPOSECEF(); //Check that RAM has been allocated for the HPPOSECEF data if (packetUBXNAVHPPOSECEF == NULL) //Bail if the RAM allocation failed @@ -7131,21 +7131,21 @@ boolean SFE_UBLOX_GNSS::getNAVHPPOSECEF(uint16_t maxWait) //Enable or disable automatic navigation message generation by the GNSS. This changes the way getHPPOSECEF //works. -boolean SFE_UBLOX_GNSS::setAutoNAVHPPOSECEF(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVHPPOSECEF(bool enable, uint16_t maxWait) { return setAutoNAVHPPOSECEFrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getHPPOSECEF //works. -boolean SFE_UBLOX_GNSS::setAutoNAVHPPOSECEF(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVHPPOSECEF(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoNAVHPPOSECEFrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getHPPOSECEF //works. -boolean SFE_UBLOX_GNSS::setAutoNAVHPPOSECEFrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVHPPOSECEFrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXNAVHPPOSECEF == NULL) initPacketUBXNAVHPPOSECEF(); //Check that RAM has been allocated for the data if (packetUBXNAVHPPOSECEF == NULL) //Only attempt this if RAM allocation was successful @@ -7161,7 +7161,7 @@ boolean SFE_UBLOX_GNSS::setAutoNAVHPPOSECEFrate(uint8_t rate, boolean implicitUp payloadCfg[1] = UBX_NAV_HPPOSECEF; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXNAVHPPOSECEF->automaticFlags.flags.bits.automatic = (rate > 0); @@ -7172,10 +7172,10 @@ boolean SFE_UBLOX_GNSS::setAutoNAVHPPOSECEFrate(uint8_t rate, boolean implicitUp } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoNAVHPPOSECEFcallback(void (*callbackPointer)(UBX_NAV_HPPOSECEF_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVHPPOSECEFcallback(void (*callbackPointer)(UBX_NAV_HPPOSECEF_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoNAVHPPOSECEF(true, false, maxWait); + bool result = setAutoNAVHPPOSECEF(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -7197,13 +7197,13 @@ boolean SFE_UBLOX_GNSS::setAutoNAVHPPOSECEFcallback(void (*callbackPointer)(UBX_ //In case no config access to the GNSS is possible and HPPOSECEF is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoNAVHPPOSECEF(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoNAVHPPOSECEF(bool enabled, bool implicitUpdate) { if (packetUBXNAVHPPOSECEF == NULL) initPacketUBXNAVHPPOSECEF(); //Check that RAM has been allocated for the data if (packetUBXNAVHPPOSECEF == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXNAVHPPOSECEF->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVHPPOSECEF->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXNAVHPPOSECEF->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVHPPOSECEF->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXNAVHPPOSECEF->automaticFlags.flags.bits.automatic = enabled; @@ -7213,7 +7213,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoNAVHPPOSECEF(boolean enabled, boolean implicit } // PRIVATE: Allocate RAM for packetUBXNAVHPPOSECEF and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXNAVHPPOSECEF() +bool SFE_UBLOX_GNSS::initPacketUBXNAVHPPOSECEF() { packetUBXNAVHPPOSECEF = new UBX_NAV_HPPOSECEF_t; //Allocate RAM for the main struct if (packetUBXNAVHPPOSECEF == NULL) @@ -7237,7 +7237,7 @@ void SFE_UBLOX_GNSS::flushNAVHPPOSECEF() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logNAVHPPOSECEF(boolean enabled) +void SFE_UBLOX_GNSS::logNAVHPPOSECEF(bool enabled) { if (packetUBXNAVHPPOSECEF == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXNAVHPPOSECEF->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -7245,7 +7245,7 @@ void SFE_UBLOX_GNSS::logNAVHPPOSECEF(boolean enabled) // ***** NAV HPPOSLLH automatic support -boolean SFE_UBLOX_GNSS::getHPPOSLLH(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getHPPOSLLH(uint16_t maxWait) { if (packetUBXNAVHPPOSLLH == NULL) initPacketUBXNAVHPPOSLLH(); //Check that RAM has been allocated for the HPPOSLLH data if (packetUBXNAVHPPOSLLH == NULL) //Bail if the RAM allocation failed @@ -7309,21 +7309,21 @@ boolean SFE_UBLOX_GNSS::getHPPOSLLH(uint16_t maxWait) //Enable or disable automatic navigation message generation by the GNSS. This changes the way getHPPOSLLH //works. -boolean SFE_UBLOX_GNSS::setAutoHPPOSLLH(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoHPPOSLLH(bool enable, uint16_t maxWait) { return setAutoHPPOSLLHrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getHPPOSLLH //works. -boolean SFE_UBLOX_GNSS::setAutoHPPOSLLH(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoHPPOSLLH(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoHPPOSLLHrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getHPPOSLLH //works. -boolean SFE_UBLOX_GNSS::setAutoHPPOSLLHrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoHPPOSLLHrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXNAVHPPOSLLH == NULL) initPacketUBXNAVHPPOSLLH(); //Check that RAM has been allocated for the data if (packetUBXNAVHPPOSLLH == NULL) //Only attempt this if RAM allocation was successful @@ -7339,7 +7339,7 @@ boolean SFE_UBLOX_GNSS::setAutoHPPOSLLHrate(uint8_t rate, boolean implicitUpdate payloadCfg[1] = UBX_NAV_HPPOSLLH; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXNAVHPPOSLLH->automaticFlags.flags.bits.automatic = (rate > 0); @@ -7350,10 +7350,10 @@ boolean SFE_UBLOX_GNSS::setAutoHPPOSLLHrate(uint8_t rate, boolean implicitUpdate } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoHPPOSLLHcallback(void (*callbackPointer)(UBX_NAV_HPPOSLLH_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoHPPOSLLHcallback(void (*callbackPointer)(UBX_NAV_HPPOSLLH_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoHPPOSLLH(true, false, maxWait); + bool result = setAutoHPPOSLLH(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -7375,13 +7375,13 @@ boolean SFE_UBLOX_GNSS::setAutoHPPOSLLHcallback(void (*callbackPointer)(UBX_NAV_ //In case no config access to the GNSS is possible and HPPOSLLH is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoHPPOSLLH(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoHPPOSLLH(bool enabled, bool implicitUpdate) { if (packetUBXNAVHPPOSLLH == NULL) initPacketUBXNAVHPPOSLLH(); //Check that RAM has been allocated for the data if (packetUBXNAVHPPOSLLH == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXNAVHPPOSLLH->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVHPPOSLLH->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXNAVHPPOSLLH->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVHPPOSLLH->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXNAVHPPOSLLH->automaticFlags.flags.bits.automatic = enabled; @@ -7391,7 +7391,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoHPPOSLLH(boolean enabled, boolean implicitUpda } // PRIVATE: Allocate RAM for packetUBXNAVHPPOSLLH and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXNAVHPPOSLLH() +bool SFE_UBLOX_GNSS::initPacketUBXNAVHPPOSLLH() { packetUBXNAVHPPOSLLH = new UBX_NAV_HPPOSLLH_t; //Allocate RAM for the main struct if (packetUBXNAVHPPOSLLH == NULL) @@ -7415,7 +7415,7 @@ void SFE_UBLOX_GNSS::flushHPPOSLLH() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logNAVHPPOSLLH(boolean enabled) +void SFE_UBLOX_GNSS::logNAVHPPOSLLH(bool enabled) { if (packetUBXNAVHPPOSLLH == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXNAVHPPOSLLH->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -7423,7 +7423,7 @@ void SFE_UBLOX_GNSS::logNAVHPPOSLLH(boolean enabled) // ***** NAV CLOCK automatic support -boolean SFE_UBLOX_GNSS::getNAVCLOCK(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getNAVCLOCK(uint16_t maxWait) { if (packetUBXNAVCLOCK == NULL) initPacketUBXNAVCLOCK(); //Check that RAM has been allocated for the CLOCK data if (packetUBXNAVCLOCK == NULL) //Bail if the RAM allocation failed @@ -7465,21 +7465,21 @@ boolean SFE_UBLOX_GNSS::getNAVCLOCK(uint16_t maxWait) //Enable or disable automatic CLOCK message generation by the GNSS. This changes the way getNAVCLOCK //works. -boolean SFE_UBLOX_GNSS::setAutoNAVCLOCK(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVCLOCK(bool enable, uint16_t maxWait) { return setAutoNAVCLOCKrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic CLOCK message generation by the GNSS. This changes the way getNAVCLOCK //works. -boolean SFE_UBLOX_GNSS::setAutoNAVCLOCK(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVCLOCK(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoNAVCLOCKrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic CLOCK attitude message generation by the GNSS. This changes the way getNAVCLOCK //works. -boolean SFE_UBLOX_GNSS::setAutoNAVCLOCKrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVCLOCKrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXNAVCLOCK == NULL) initPacketUBXNAVCLOCK(); //Check that RAM has been allocated for the data if (packetUBXNAVCLOCK == NULL) //Only attempt this if RAM allocation was successful @@ -7495,7 +7495,7 @@ boolean SFE_UBLOX_GNSS::setAutoNAVCLOCKrate(uint8_t rate, boolean implicitUpdate payloadCfg[1] = UBX_NAV_CLOCK; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXNAVCLOCK->automaticFlags.flags.bits.automatic = (rate > 0); @@ -7506,10 +7506,10 @@ boolean SFE_UBLOX_GNSS::setAutoNAVCLOCKrate(uint8_t rate, boolean implicitUpdate } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoNAVCLOCKcallback(void (*callbackPointer)(UBX_NAV_CLOCK_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoNAVCLOCKcallback(void (*callbackPointer)(UBX_NAV_CLOCK_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoNAVCLOCK(true, false, maxWait); + bool result = setAutoNAVCLOCK(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -7531,13 +7531,13 @@ boolean SFE_UBLOX_GNSS::setAutoNAVCLOCKcallback(void (*callbackPointer)(UBX_NAV_ //In case no config access to the GNSS is possible and HNR attitude is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoNAVCLOCK(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoNAVCLOCK(bool enabled, bool implicitUpdate) { if (packetUBXNAVCLOCK == NULL) initPacketUBXNAVCLOCK(); //Check that RAM has been allocated for the CLOCK data if (packetUBXNAVCLOCK == NULL) //Bail if the RAM allocation failed return (false); - boolean changes = packetUBXNAVCLOCK->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVCLOCK->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXNAVCLOCK->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVCLOCK->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXNAVCLOCK->automaticFlags.flags.bits.automatic = enabled; @@ -7547,7 +7547,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoNAVCLOCK(boolean enabled, boolean implicitUpda } // PRIVATE: Allocate RAM for packetUBXNAVCLOCK and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXNAVCLOCK() +bool SFE_UBLOX_GNSS::initPacketUBXNAVCLOCK() { packetUBXNAVCLOCK = new UBX_NAV_CLOCK_t ; //Allocate RAM for the main struct if (packetUBXNAVCLOCK == NULL) @@ -7571,7 +7571,7 @@ void SFE_UBLOX_GNSS::flushNAVCLOCK() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logNAVCLOCK(boolean enabled) +void SFE_UBLOX_GNSS::logNAVCLOCK(bool enabled) { if (packetUBXNAVCLOCK == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXNAVCLOCK->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -7582,7 +7582,7 @@ void SFE_UBLOX_GNSS::logNAVCLOCK(boolean enabled) //Reads leap second event information and sets the global variables //for future leap second change and number of leap seconds since GPS epoch //Returns true if commands was successful -boolean SFE_UBLOX_GNSS::getLeapSecondEvent(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getLeapSecondEvent(uint16_t maxWait) { if (packetUBXNAVTIMELS == NULL) initPacketUBXNAVTIMELS(); //Check that RAM has been allocated for the TIMELS data if (packetUBXNAVTIMELS == NULL) // Abort if the RAM allocation failed @@ -7608,7 +7608,7 @@ boolean SFE_UBLOX_GNSS::getLeapSecondEvent(uint16_t maxWait) } // PRIVATE: Allocate RAM for packetUBXNAVTIMELS and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXNAVTIMELS() +bool SFE_UBLOX_GNSS::initPacketUBXNAVTIMELS() { packetUBXNAVTIMELS = new UBX_NAV_TIMELS_t; //Allocate RAM for the main struct if (packetUBXNAVTIMELS == NULL) @@ -7629,7 +7629,7 @@ boolean SFE_UBLOX_GNSS::initPacketUBXNAVTIMELS() //Reads survey in status and sets the global variables //for status, position valid, observation time, and mean 3D StdDev //Returns true if commands was successful -boolean SFE_UBLOX_GNSS::getSurveyStatus(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getSurveyStatus(uint16_t maxWait) { if (packetUBXNAVSVIN == NULL) initPacketUBXNAVSVIN(); //Check that RAM has been allocated for the SVIN data if (packetUBXNAVSVIN == NULL) // Abort if the RAM allocation failed @@ -7655,7 +7655,7 @@ boolean SFE_UBLOX_GNSS::getSurveyStatus(uint16_t maxWait) } // PRIVATE: Allocate RAM for packetUBXNAVSVIN and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXNAVSVIN() +bool SFE_UBLOX_GNSS::initPacketUBXNAVSVIN() { packetUBXNAVSVIN = new UBX_NAV_SVIN_t; //Allocate RAM for the main struct if (packetUBXNAVSVIN == NULL) @@ -7678,7 +7678,7 @@ boolean SFE_UBLOX_GNSS::initPacketUBXNAVSVIN() //Note: // RELPOSNED on the M8 is only 40 bytes long // RELPOSNED on the F9 is 64 bytes long and contains much more information -boolean SFE_UBLOX_GNSS::getRELPOSNED(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getRELPOSNED(uint16_t maxWait) { if (packetUBXNAVRELPOSNED == NULL) initPacketUBXNAVRELPOSNED(); //Check that RAM has been allocated for the RELPOSNED data if (packetUBXNAVRELPOSNED == NULL) //Bail if the RAM allocation failed @@ -7720,21 +7720,21 @@ boolean SFE_UBLOX_GNSS::getRELPOSNED(uint16_t maxWait) //Enable or disable automatic RELPOSNED message generation by the GNSS. This changes the way getRELPOSNED //works. -boolean SFE_UBLOX_GNSS::setAutoRELPOSNED(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoRELPOSNED(bool enable, uint16_t maxWait) { return setAutoRELPOSNEDrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic RELPOSNED message generation by the GNSS. This changes the way getRELPOSNED //works. -boolean SFE_UBLOX_GNSS::setAutoRELPOSNED(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoRELPOSNED(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoRELPOSNEDrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic HNR attitude message generation by the GNSS. This changes the way getRELPOSNED //works. -boolean SFE_UBLOX_GNSS::setAutoRELPOSNEDrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoRELPOSNEDrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXNAVRELPOSNED == NULL) initPacketUBXNAVRELPOSNED(); //Check that RAM has been allocated for the data if (packetUBXNAVRELPOSNED == NULL) //Only attempt this if RAM allocation was successful @@ -7750,7 +7750,7 @@ boolean SFE_UBLOX_GNSS::setAutoRELPOSNEDrate(uint8_t rate, boolean implicitUpdat payloadCfg[1] = UBX_NAV_RELPOSNED; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXNAVRELPOSNED->automaticFlags.flags.bits.automatic = (rate > 0); @@ -7761,10 +7761,10 @@ boolean SFE_UBLOX_GNSS::setAutoRELPOSNEDrate(uint8_t rate, boolean implicitUpdat } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoRELPOSNEDcallback(void (*callbackPointer)(UBX_NAV_RELPOSNED_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoRELPOSNEDcallback(void (*callbackPointer)(UBX_NAV_RELPOSNED_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoRELPOSNED(true, false, maxWait); + bool result = setAutoRELPOSNED(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -7786,13 +7786,13 @@ boolean SFE_UBLOX_GNSS::setAutoRELPOSNEDcallback(void (*callbackPointer)(UBX_NAV //In case no config access to the GNSS is possible and HNR attitude is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoRELPOSNED(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoRELPOSNED(bool enabled, bool implicitUpdate) { if (packetUBXNAVRELPOSNED == NULL) initPacketUBXNAVRELPOSNED(); //Check that RAM has been allocated for the RELPOSNED data if (packetUBXNAVRELPOSNED == NULL) //Bail if the RAM allocation failed return (false); - boolean changes = packetUBXNAVRELPOSNED->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVRELPOSNED->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXNAVRELPOSNED->automaticFlags.flags.bits.automatic != enabled || packetUBXNAVRELPOSNED->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXNAVRELPOSNED->automaticFlags.flags.bits.automatic = enabled; @@ -7802,7 +7802,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoRELPOSNED(boolean enabled, boolean implicitUpd } // PRIVATE: Allocate RAM for packetUBXNAVRELPOSNED and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXNAVRELPOSNED() +bool SFE_UBLOX_GNSS::initPacketUBXNAVRELPOSNED() { packetUBXNAVRELPOSNED = new UBX_NAV_RELPOSNED_t ; //Allocate RAM for the main struct if (packetUBXNAVRELPOSNED == NULL) @@ -7826,7 +7826,7 @@ void SFE_UBLOX_GNSS::flushNAVRELPOSNED() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logNAVRELPOSNED(boolean enabled) +void SFE_UBLOX_GNSS::logNAVRELPOSNED(bool enabled) { if (packetUBXNAVRELPOSNED == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXNAVRELPOSNED->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -7834,7 +7834,7 @@ void SFE_UBLOX_GNSS::logNAVRELPOSNED(boolean enabled) // ***** RXM SFRBX automatic support -boolean SFE_UBLOX_GNSS::getRXMSFRBX(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getRXMSFRBX(uint16_t maxWait) { if (packetUBXRXMSFRBX == NULL) initPacketUBXRXMSFRBX(); //Check that RAM has been allocated for the TM2 data if (packetUBXRXMSFRBX == NULL) //Bail if the RAM allocation failed @@ -7876,21 +7876,21 @@ boolean SFE_UBLOX_GNSS::getRXMSFRBX(uint16_t maxWait) //Enable or disable automatic navigation message generation by the GNSS. This changes the way getRXMSFRBX //works. -boolean SFE_UBLOX_GNSS::setAutoRXMSFRBX(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoRXMSFRBX(bool enable, uint16_t maxWait) { return setAutoRXMSFRBXrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getRXMSFRBX //works. -boolean SFE_UBLOX_GNSS::setAutoRXMSFRBX(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoRXMSFRBX(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoRXMSFRBXrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getRXMSFRBX //works. -boolean SFE_UBLOX_GNSS::setAutoRXMSFRBXrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoRXMSFRBXrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXRXMSFRBX == NULL) initPacketUBXRXMSFRBX(); //Check that RAM has been allocated for the data if (packetUBXRXMSFRBX == NULL) //Only attempt this if RAM allocation was successful @@ -7906,7 +7906,7 @@ boolean SFE_UBLOX_GNSS::setAutoRXMSFRBXrate(uint8_t rate, boolean implicitUpdate payloadCfg[1] = UBX_RXM_SFRBX; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXRXMSFRBX->automaticFlags.flags.bits.automatic = (rate > 0); @@ -7917,10 +7917,10 @@ boolean SFE_UBLOX_GNSS::setAutoRXMSFRBXrate(uint8_t rate, boolean implicitUpdate } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoRXMSFRBXcallback(void (*callbackPointer)(UBX_RXM_SFRBX_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoRXMSFRBXcallback(void (*callbackPointer)(UBX_RXM_SFRBX_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoRXMSFRBX(true, false, maxWait); + bool result = setAutoRXMSFRBX(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -7942,13 +7942,13 @@ boolean SFE_UBLOX_GNSS::setAutoRXMSFRBXcallback(void (*callbackPointer)(UBX_RXM_ //In case no config access to the GNSS is possible and SFRBX is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoRXMSFRBX(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoRXMSFRBX(bool enabled, bool implicitUpdate) { if (packetUBXRXMSFRBX == NULL) initPacketUBXRXMSFRBX(); //Check that RAM has been allocated for the data if (packetUBXRXMSFRBX == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXRXMSFRBX->automaticFlags.flags.bits.automatic != enabled || packetUBXRXMSFRBX->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXRXMSFRBX->automaticFlags.flags.bits.automatic != enabled || packetUBXRXMSFRBX->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXRXMSFRBX->automaticFlags.flags.bits.automatic = enabled; @@ -7958,7 +7958,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoRXMSFRBX(boolean enabled, boolean implicitUpda } // PRIVATE: Allocate RAM for packetUBXRXMSFRBX and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXRXMSFRBX() +bool SFE_UBLOX_GNSS::initPacketUBXRXMSFRBX() { packetUBXRXMSFRBX = new UBX_RXM_SFRBX_t; //Allocate RAM for the main struct if (packetUBXRXMSFRBX == NULL) @@ -7982,7 +7982,7 @@ void SFE_UBLOX_GNSS::flushRXMSFRBX() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logRXMSFRBX(boolean enabled) +void SFE_UBLOX_GNSS::logRXMSFRBX(bool enabled) { if (packetUBXRXMSFRBX == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXRXMSFRBX->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -7990,7 +7990,7 @@ void SFE_UBLOX_GNSS::logRXMSFRBX(boolean enabled) // ***** RXM RAWX automatic support -boolean SFE_UBLOX_GNSS::getRXMRAWX(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getRXMRAWX(uint16_t maxWait) { if (packetUBXRXMRAWX == NULL) initPacketUBXRXMRAWX(); //Check that RAM has been allocated for the TM2 data if (packetUBXRXMRAWX == NULL) //Bail if the RAM allocation failed @@ -8032,21 +8032,21 @@ boolean SFE_UBLOX_GNSS::getRXMRAWX(uint16_t maxWait) //Enable or disable automatic navigation message generation by the GNSS. This changes the way getRXMRAWX //works. -boolean SFE_UBLOX_GNSS::setAutoRXMRAWX(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoRXMRAWX(bool enable, uint16_t maxWait) { return setAutoRXMRAWXrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getRXMRAWX //works. -boolean SFE_UBLOX_GNSS::setAutoRXMRAWX(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoRXMRAWX(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoRXMRAWXrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getRXMRAWX //works. -boolean SFE_UBLOX_GNSS::setAutoRXMRAWXrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoRXMRAWXrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXRXMRAWX == NULL) initPacketUBXRXMRAWX(); //Check that RAM has been allocated for the data if (packetUBXRXMRAWX == NULL) //Only attempt this if RAM allocation was successful @@ -8062,7 +8062,7 @@ boolean SFE_UBLOX_GNSS::setAutoRXMRAWXrate(uint8_t rate, boolean implicitUpdate, payloadCfg[1] = UBX_RXM_RAWX; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXRXMRAWX->automaticFlags.flags.bits.automatic = (rate > 0); @@ -8073,10 +8073,10 @@ boolean SFE_UBLOX_GNSS::setAutoRXMRAWXrate(uint8_t rate, boolean implicitUpdate, } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoRXMRAWXcallback(void (*callbackPointer)(UBX_RXM_RAWX_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoRXMRAWXcallback(void (*callbackPointer)(UBX_RXM_RAWX_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoRXMRAWX(true, false, maxWait); + bool result = setAutoRXMRAWX(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -8098,13 +8098,13 @@ boolean SFE_UBLOX_GNSS::setAutoRXMRAWXcallback(void (*callbackPointer)(UBX_RXM_R //In case no config access to the GNSS is possible and VELNED is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoRXMRAWX(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoRXMRAWX(bool enabled, bool implicitUpdate) { if (packetUBXRXMRAWX == NULL) initPacketUBXRXMRAWX(); //Check that RAM has been allocated for the data if (packetUBXRXMRAWX == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXRXMRAWX->automaticFlags.flags.bits.automatic != enabled || packetUBXRXMRAWX->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXRXMRAWX->automaticFlags.flags.bits.automatic != enabled || packetUBXRXMRAWX->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXRXMRAWX->automaticFlags.flags.bits.automatic = enabled; @@ -8114,7 +8114,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoRXMRAWX(boolean enabled, boolean implicitUpdat } // PRIVATE: Allocate RAM for packetUBXRXMRAWX and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXRXMRAWX() +bool SFE_UBLOX_GNSS::initPacketUBXRXMRAWX() { packetUBXRXMRAWX = new UBX_RXM_RAWX_t; //Allocate RAM for the main struct if (packetUBXRXMRAWX == NULL) @@ -8138,7 +8138,7 @@ void SFE_UBLOX_GNSS::flushRXMRAWX() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logRXMRAWX(boolean enabled) +void SFE_UBLOX_GNSS::logRXMRAWX(bool enabled) { if (packetUBXRXMRAWX == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXRXMRAWX->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -8147,7 +8147,7 @@ void SFE_UBLOX_GNSS::logRXMRAWX(boolean enabled) // ***** CFG automatic support //Get the latest CFG RATE - as used by isConnected -boolean SFE_UBLOX_GNSS::getNavigationFrequencyInternal(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getNavigationFrequencyInternal(uint16_t maxWait) { if (packetUBXCFGRATE == NULL) initPacketUBXCFGRATE(); //Check that RAM has been allocated for the data if (packetUBXCFGRATE == NULL) //Bail if the RAM allocation failed @@ -8175,7 +8175,7 @@ boolean SFE_UBLOX_GNSS::getNavigationFrequencyInternal(uint16_t maxWait) } // PRIVATE: Allocate RAM for packetUBXCFGRATE and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXCFGRATE() +bool SFE_UBLOX_GNSS::initPacketUBXCFGRATE() { packetUBXCFGRATE = new UBX_CFG_RATE_t; //Allocate RAM for the main struct if (packetUBXCFGRATE == NULL) @@ -8193,7 +8193,7 @@ boolean SFE_UBLOX_GNSS::initPacketUBXCFGRATE() // ***** TIM TM2 automatic support -boolean SFE_UBLOX_GNSS::getTIMTM2(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getTIMTM2(uint16_t maxWait) { if (packetUBXTIMTM2 == NULL) initPacketUBXTIMTM2(); //Check that RAM has been allocated for the TM2 data if (packetUBXTIMTM2 == NULL) //Bail if the RAM allocation failed @@ -8235,21 +8235,21 @@ boolean SFE_UBLOX_GNSS::getTIMTM2(uint16_t maxWait) //Enable or disable automatic navigation message generation by the GNSS. This changes the way getTIMTM2 //works. -boolean SFE_UBLOX_GNSS::setAutoTIMTM2(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoTIMTM2(bool enable, uint16_t maxWait) { return setAutoTIMTM2rate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getTIMTM2 //works. -boolean SFE_UBLOX_GNSS::setAutoTIMTM2(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoTIMTM2(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoTIMTM2rate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic navigation message generation by the GNSS. This changes the way getTIMTM2 //works. -boolean SFE_UBLOX_GNSS::setAutoTIMTM2rate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoTIMTM2rate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXTIMTM2 == NULL) initPacketUBXTIMTM2(); //Check that RAM has been allocated for the data if (packetUBXTIMTM2 == NULL) //Only attempt this if RAM allocation was successful @@ -8265,7 +8265,7 @@ boolean SFE_UBLOX_GNSS::setAutoTIMTM2rate(uint8_t rate, boolean implicitUpdate, payloadCfg[1] = UBX_TIM_TM2; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXTIMTM2->automaticFlags.flags.bits.automatic = (rate > 0); @@ -8276,10 +8276,10 @@ boolean SFE_UBLOX_GNSS::setAutoTIMTM2rate(uint8_t rate, boolean implicitUpdate, } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoTIMTM2callback(void (*callbackPointer)(UBX_TIM_TM2_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoTIMTM2callback(void (*callbackPointer)(UBX_TIM_TM2_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoTIMTM2(true, false, maxWait); + bool result = setAutoTIMTM2(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -8301,13 +8301,13 @@ boolean SFE_UBLOX_GNSS::setAutoTIMTM2callback(void (*callbackPointer)(UBX_TIM_TM //In case no config access to the GNSS is possible and VELNED is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoTIMTM2(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoTIMTM2(bool enabled, bool implicitUpdate) { if (packetUBXTIMTM2 == NULL) initPacketUBXTIMTM2(); //Check that RAM has been allocated for the data if (packetUBXTIMTM2 == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXTIMTM2->automaticFlags.flags.bits.automatic != enabled || packetUBXTIMTM2->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXTIMTM2->automaticFlags.flags.bits.automatic != enabled || packetUBXTIMTM2->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXTIMTM2->automaticFlags.flags.bits.automatic = enabled; @@ -8317,7 +8317,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoTIMTM2(boolean enabled, boolean implicitUpdate } // PRIVATE: Allocate RAM for packetUBXTIMTM2 and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXTIMTM2() +bool SFE_UBLOX_GNSS::initPacketUBXTIMTM2() { packetUBXTIMTM2 = new UBX_TIM_TM2_t; //Allocate RAM for the main struct if (packetUBXTIMTM2 == NULL) @@ -8341,7 +8341,7 @@ void SFE_UBLOX_GNSS::flushTIMTM2() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logTIMTM2(boolean enabled) +void SFE_UBLOX_GNSS::logTIMTM2(bool enabled) { if (packetUBXTIMTM2 == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXTIMTM2->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -8349,12 +8349,12 @@ void SFE_UBLOX_GNSS::logTIMTM2(boolean enabled) // ***** ESF ALG automatic support -boolean SFE_UBLOX_GNSS::getEsfAlignment(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getEsfAlignment(uint16_t maxWait) { return (getESFALG(maxWait)); } -boolean SFE_UBLOX_GNSS::getESFALG(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getESFALG(uint16_t maxWait) { if (packetUBXESFALG == NULL) initPacketUBXESFALG(); //Check that RAM has been allocated for the ESF alignment data if (packetUBXESFALG == NULL) //Only attempt this if RAM allocation was successful @@ -8420,21 +8420,21 @@ boolean SFE_UBLOX_GNSS::getESFALG(uint16_t maxWait) //Enable or disable automatic ESF ALG message generation by the GNSS. This changes the way getEsfAlignment //works. -boolean SFE_UBLOX_GNSS::setAutoESFALG(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFALG(bool enable, uint16_t maxWait) { return setAutoESFALGrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic ESF ALG message generation by the GNSS. This changes the way getEsfAlignment //works. -boolean SFE_UBLOX_GNSS::setAutoESFALG(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFALG(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoESFALGrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic ESF ALG message generation by the GNSS. This changes the way getEsfAlignment //works. -boolean SFE_UBLOX_GNSS::setAutoESFALGrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFALGrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXESFALG == NULL) initPacketUBXESFALG(); //Check that RAM has been allocated for the data if (packetUBXESFALG == NULL) //Only attempt this if RAM allocation was successful @@ -8450,7 +8450,7 @@ boolean SFE_UBLOX_GNSS::setAutoESFALGrate(uint8_t rate, boolean implicitUpdate, payloadCfg[1] = UBX_ESF_ALG; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXESFALG->automaticFlags.flags.bits.automatic = (rate > 0); @@ -8461,10 +8461,10 @@ boolean SFE_UBLOX_GNSS::setAutoESFALGrate(uint8_t rate, boolean implicitUpdate, } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoESFALGcallback(void (*callbackPointer)(UBX_ESF_ALG_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFALGcallback(void (*callbackPointer)(UBX_ESF_ALG_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoESFALG(true, false, maxWait); + bool result = setAutoESFALG(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -8486,13 +8486,13 @@ boolean SFE_UBLOX_GNSS::setAutoESFALGcallback(void (*callbackPointer)(UBX_ESF_AL //In case no config access to the GNSS is possible and ESF ALG is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoESFALG(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoESFALG(bool enabled, bool implicitUpdate) { if (packetUBXESFALG == NULL) initPacketUBXESFALG(); //Check that RAM has been allocated for the ESF alignment data if (packetUBXESFALG == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXESFALG->automaticFlags.flags.bits.automatic != enabled || packetUBXESFALG->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXESFALG->automaticFlags.flags.bits.automatic != enabled || packetUBXESFALG->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXESFALG->automaticFlags.flags.bits.automatic = enabled; @@ -8502,7 +8502,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoESFALG(boolean enabled, boolean implicitUpdate } // PRIVATE: Allocate RAM for packetUBXESFALG and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXESFALG() +bool SFE_UBLOX_GNSS::initPacketUBXESFALG() { packetUBXESFALG = new UBX_ESF_ALG_t; //Allocate RAM for the main struct if (packetUBXESFALG == NULL) @@ -8526,7 +8526,7 @@ void SFE_UBLOX_GNSS::flushESFALG() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logESFALG(boolean enabled) +void SFE_UBLOX_GNSS::logESFALG(bool enabled) { if (packetUBXESFALG == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXESFALG->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -8534,12 +8534,12 @@ void SFE_UBLOX_GNSS::logESFALG(boolean enabled) // ***** ESF STATUS automatic support -boolean SFE_UBLOX_GNSS::getEsfInfo(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getEsfInfo(uint16_t maxWait) { return (getESFSTATUS(maxWait)); } -boolean SFE_UBLOX_GNSS::getESFSTATUS(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getESFSTATUS(uint16_t maxWait) { if (packetUBXESFSTATUS == NULL) initPacketUBXESFSTATUS(); //Check that RAM has been allocated for the ESF status data if (packetUBXESFSTATUS == NULL) //Only attempt this if RAM allocation was successful @@ -8605,21 +8605,21 @@ boolean SFE_UBLOX_GNSS::getESFSTATUS(uint16_t maxWait) //Enable or disable automatic ESF STATUS message generation by the GNSS. This changes the way getESFInfo //works. -boolean SFE_UBLOX_GNSS::setAutoESFSTATUS(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFSTATUS(bool enable, uint16_t maxWait) { return setAutoESFSTATUSrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic ESF STATUS message generation by the GNSS. This changes the way getESFInfo //works. -boolean SFE_UBLOX_GNSS::setAutoESFSTATUS(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFSTATUS(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoESFSTATUSrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic ESF STATUS message generation by the GNSS. This changes the way getESFInfo //works. -boolean SFE_UBLOX_GNSS::setAutoESFSTATUSrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFSTATUSrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXESFSTATUS == NULL) initPacketUBXESFSTATUS(); //Check that RAM has been allocated for the data if (packetUBXESFSTATUS == NULL) //Only attempt this if RAM allocation was successful @@ -8635,7 +8635,7 @@ boolean SFE_UBLOX_GNSS::setAutoESFSTATUSrate(uint8_t rate, boolean implicitUpdat payloadCfg[1] = UBX_ESF_STATUS; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXESFSTATUS->automaticFlags.flags.bits.automatic = (rate > 0); @@ -8646,10 +8646,10 @@ boolean SFE_UBLOX_GNSS::setAutoESFSTATUSrate(uint8_t rate, boolean implicitUpdat } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoESFSTATUScallback(void (*callbackPointer)(UBX_ESF_STATUS_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFSTATUScallback(void (*callbackPointer)(UBX_ESF_STATUS_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoESFSTATUS(true, false, maxWait); + bool result = setAutoESFSTATUS(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -8671,13 +8671,13 @@ boolean SFE_UBLOX_GNSS::setAutoESFSTATUScallback(void (*callbackPointer)(UBX_ESF //In case no config access to the GNSS is possible and ESF STATUS is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoESFSTATUS(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoESFSTATUS(bool enabled, bool implicitUpdate) { if (packetUBXESFSTATUS == NULL) initPacketUBXESFSTATUS(); //Check that RAM has been allocated for the ESF status data if (packetUBXESFSTATUS == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXESFSTATUS->automaticFlags.flags.bits.automatic != enabled || packetUBXESFSTATUS->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXESFSTATUS->automaticFlags.flags.bits.automatic != enabled || packetUBXESFSTATUS->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXESFSTATUS->automaticFlags.flags.bits.automatic = enabled; @@ -8687,7 +8687,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoESFSTATUS(boolean enabled, boolean implicitUpd } // PRIVATE: Allocate RAM for packetUBXESFSTATUS and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXESFSTATUS() +bool SFE_UBLOX_GNSS::initPacketUBXESFSTATUS() { packetUBXESFSTATUS = new UBX_ESF_STATUS_t; //Allocate RAM for the main struct @@ -8712,7 +8712,7 @@ void SFE_UBLOX_GNSS::flushESFSTATUS() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logESFSTATUS(boolean enabled) +void SFE_UBLOX_GNSS::logESFSTATUS(bool enabled) { if (packetUBXESFSTATUS == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXESFSTATUS->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -8720,12 +8720,12 @@ void SFE_UBLOX_GNSS::logESFSTATUS(boolean enabled) // ***** ESF INS automatic support -boolean SFE_UBLOX_GNSS::getEsfIns(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getEsfIns(uint16_t maxWait) { return (getESFINS(maxWait)); } -boolean SFE_UBLOX_GNSS::getESFINS(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getESFINS(uint16_t maxWait) { if (packetUBXESFINS == NULL) initPacketUBXESFINS(); //Check that RAM has been allocated for the ESF INS data if (packetUBXESFINS == NULL) //Only attempt this if RAM allocation was successful @@ -8791,21 +8791,21 @@ boolean SFE_UBLOX_GNSS::getESFINS(uint16_t maxWait) //Enable or disable automatic ESF INS message generation by the GNSS. This changes the way getESFIns //works. -boolean SFE_UBLOX_GNSS::setAutoESFINS(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFINS(bool enable, uint16_t maxWait) { return setAutoESFINSrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic ESF INS message generation by the GNSS. This changes the way getESFIns //works. -boolean SFE_UBLOX_GNSS::setAutoESFINS(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFINS(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoESFINSrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic ESF INS message generation by the GNSS. This changes the way getESFIns //works. -boolean SFE_UBLOX_GNSS::setAutoESFINSrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFINSrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXESFINS == NULL) initPacketUBXESFINS(); //Check that RAM has been allocated for the data if (packetUBXESFINS == NULL) //Only attempt this if RAM allocation was successful @@ -8821,7 +8821,7 @@ boolean SFE_UBLOX_GNSS::setAutoESFINSrate(uint8_t rate, boolean implicitUpdate, payloadCfg[1] = UBX_ESF_INS; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXESFINS->automaticFlags.flags.bits.automatic = (rate > 0); @@ -8832,10 +8832,10 @@ boolean SFE_UBLOX_GNSS::setAutoESFINSrate(uint8_t rate, boolean implicitUpdate, } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoESFINScallback(void (*callbackPointer)(UBX_ESF_INS_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFINScallback(void (*callbackPointer)(UBX_ESF_INS_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoESFINS(true, false, maxWait); + bool result = setAutoESFINS(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -8857,13 +8857,13 @@ boolean SFE_UBLOX_GNSS::setAutoESFINScallback(void (*callbackPointer)(UBX_ESF_IN //In case no config access to the GNSS is possible and ESF INS is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoESFINS(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoESFINS(bool enabled, bool implicitUpdate) { if (packetUBXESFINS == NULL) initPacketUBXESFINS(); //Check that RAM has been allocated for the ESF INS data if (packetUBXESFINS == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXESFINS->automaticFlags.flags.bits.automatic != enabled || packetUBXESFINS->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXESFINS->automaticFlags.flags.bits.automatic != enabled || packetUBXESFINS->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXESFINS->automaticFlags.flags.bits.automatic = enabled; @@ -8873,7 +8873,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoESFINS(boolean enabled, boolean implicitUpdate } // PRIVATE: Allocate RAM for packetUBXESFINS and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXESFINS() +bool SFE_UBLOX_GNSS::initPacketUBXESFINS() { packetUBXESFINS = new UBX_ESF_INS_t; //Allocate RAM for the main struct if (packetUBXESFINS == NULL) @@ -8897,7 +8897,7 @@ void SFE_UBLOX_GNSS::flushESFINS() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logESFINS(boolean enabled) +void SFE_UBLOX_GNSS::logESFINS(bool enabled) { if (packetUBXESFINS == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXESFINS->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -8905,12 +8905,12 @@ void SFE_UBLOX_GNSS::logESFINS(boolean enabled) // ***** ESF MEAS automatic support -boolean SFE_UBLOX_GNSS::getEsfDataInfo(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getEsfDataInfo(uint16_t maxWait) { return (getESFMEAS(maxWait)); } -boolean SFE_UBLOX_GNSS::getESFMEAS(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getESFMEAS(uint16_t maxWait) { if (packetUBXESFMEAS == NULL) initPacketUBXESFMEAS(); //Check that RAM has been allocated for the ESF MEAS data if (packetUBXESFMEAS == NULL) //Only attempt this if RAM allocation was successful @@ -8976,21 +8976,21 @@ boolean SFE_UBLOX_GNSS::getESFMEAS(uint16_t maxWait) //Enable or disable automatic ESF MEAS message generation by the GNSS. This changes the way getESFDataInfo //works. -boolean SFE_UBLOX_GNSS::setAutoESFMEAS(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFMEAS(bool enable, uint16_t maxWait) { return setAutoESFMEASrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic ESF MEAS message generation by the GNSS. This changes the way getESFDataInfo //works. -boolean SFE_UBLOX_GNSS::setAutoESFMEAS(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFMEAS(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoESFMEASrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic ESF MEAS message generation by the GNSS. This changes the way getESFDataInfo //works. -boolean SFE_UBLOX_GNSS::setAutoESFMEASrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFMEASrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXESFMEAS == NULL) initPacketUBXESFMEAS(); //Check that RAM has been allocated for the data if (packetUBXESFMEAS == NULL) //Only attempt this if RAM allocation was successful @@ -9006,7 +9006,7 @@ boolean SFE_UBLOX_GNSS::setAutoESFMEASrate(uint8_t rate, boolean implicitUpdate, payloadCfg[1] = UBX_ESF_MEAS; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXESFMEAS->automaticFlags.flags.bits.automatic = (rate > 0); @@ -9017,10 +9017,10 @@ boolean SFE_UBLOX_GNSS::setAutoESFMEASrate(uint8_t rate, boolean implicitUpdate, } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoESFMEAScallback(void (*callbackPointer)(UBX_ESF_MEAS_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFMEAScallback(void (*callbackPointer)(UBX_ESF_MEAS_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoESFMEAS(true, false, maxWait); + bool result = setAutoESFMEAS(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -9042,13 +9042,13 @@ boolean SFE_UBLOX_GNSS::setAutoESFMEAScallback(void (*callbackPointer)(UBX_ESF_M //In case no config access to the GNSS is possible and ESF MEAS is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoESFMEAS(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoESFMEAS(bool enabled, bool implicitUpdate) { if (packetUBXESFMEAS == NULL) initPacketUBXESFMEAS(); //Check that RAM has been allocated for the ESF MEAS data if (packetUBXESFMEAS == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXESFMEAS->automaticFlags.flags.bits.automatic != enabled || packetUBXESFMEAS->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXESFMEAS->automaticFlags.flags.bits.automatic != enabled || packetUBXESFMEAS->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXESFMEAS->automaticFlags.flags.bits.automatic = enabled; @@ -9058,7 +9058,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoESFMEAS(boolean enabled, boolean implicitUpdat } // PRIVATE: Allocate RAM for packetUBXESFMEAS and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXESFMEAS() +bool SFE_UBLOX_GNSS::initPacketUBXESFMEAS() { packetUBXESFMEAS = new UBX_ESF_MEAS_t; //Allocate RAM for the main struct if (packetUBXESFMEAS == NULL) @@ -9082,7 +9082,7 @@ void SFE_UBLOX_GNSS::flushESFMEAS() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logESFMEAS(boolean enabled) +void SFE_UBLOX_GNSS::logESFMEAS(bool enabled) { if (packetUBXESFMEAS == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXESFMEAS->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -9090,12 +9090,12 @@ void SFE_UBLOX_GNSS::logESFMEAS(boolean enabled) // ***** ESF RAW automatic support -boolean SFE_UBLOX_GNSS::getEsfRawDataInfo(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getEsfRawDataInfo(uint16_t maxWait) { return (getESFRAW(maxWait)); } -boolean SFE_UBLOX_GNSS::getESFRAW(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getESFRAW(uint16_t maxWait) { if (packetUBXESFRAW == NULL) initPacketUBXESFRAW(); //Check that RAM has been allocated for the ESF RAW data if (packetUBXESFRAW == NULL) //Only attempt this if RAM allocation was successful @@ -9161,21 +9161,21 @@ boolean SFE_UBLOX_GNSS::getESFRAW(uint16_t maxWait) //Enable or disable automatic ESF RAW message generation by the GNSS. This changes the way getESFRawDataInfo //works. -boolean SFE_UBLOX_GNSS::setAutoESFRAW(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFRAW(bool enable, uint16_t maxWait) { return setAutoESFRAWrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic ESF RAW message generation by the GNSS. This changes the way getESFRawDataInfo //works. -boolean SFE_UBLOX_GNSS::setAutoESFRAW(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFRAW(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoESFRAWrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic ESF RAW message generation by the GNSS. This changes the way getESFRawDataInfo //works. -boolean SFE_UBLOX_GNSS::setAutoESFRAWrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFRAWrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXESFRAW == NULL) initPacketUBXESFRAW(); //Check that RAM has been allocated for the data if (packetUBXESFRAW == NULL) //Only attempt this if RAM allocation was successful @@ -9191,7 +9191,7 @@ boolean SFE_UBLOX_GNSS::setAutoESFRAWrate(uint8_t rate, boolean implicitUpdate, payloadCfg[1] = UBX_ESF_RAW; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXESFRAW->automaticFlags.flags.bits.automatic = (rate > 0); @@ -9202,10 +9202,10 @@ boolean SFE_UBLOX_GNSS::setAutoESFRAWrate(uint8_t rate, boolean implicitUpdate, } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoESFRAWcallback(void (*callbackPointer)(UBX_ESF_RAW_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoESFRAWcallback(void (*callbackPointer)(UBX_ESF_RAW_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoESFRAW(true, false, maxWait); + bool result = setAutoESFRAW(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -9227,13 +9227,13 @@ boolean SFE_UBLOX_GNSS::setAutoESFRAWcallback(void (*callbackPointer)(UBX_ESF_RA //In case no config access to the GNSS is possible and ESF RAW is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoESFRAW(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoESFRAW(bool enabled, bool implicitUpdate) { if (packetUBXESFRAW == NULL) initPacketUBXESFRAW(); //Check that RAM has been allocated for the ESF RAW data if (packetUBXESFRAW == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXESFRAW->automaticFlags.flags.bits.automatic != enabled || packetUBXESFRAW->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXESFRAW->automaticFlags.flags.bits.automatic != enabled || packetUBXESFRAW->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXESFRAW->automaticFlags.flags.bits.automatic = enabled; @@ -9243,7 +9243,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoESFRAW(boolean enabled, boolean implicitUpdate } // PRIVATE: Allocate RAM for packetUBXESFRAW and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXESFRAW() +bool SFE_UBLOX_GNSS::initPacketUBXESFRAW() { packetUBXESFRAW = new UBX_ESF_RAW_t; //Allocate RAM for the main struct if (packetUBXESFRAW == NULL) @@ -9267,7 +9267,7 @@ void SFE_UBLOX_GNSS::flushESFRAW() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logESFRAW(boolean enabled) +void SFE_UBLOX_GNSS::logESFRAW(bool enabled) { if (packetUBXESFRAW == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXESFRAW->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -9275,7 +9275,7 @@ void SFE_UBLOX_GNSS::logESFRAW(boolean enabled) // ***** HNR ATT automatic support -boolean SFE_UBLOX_GNSS::getHNRAtt(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getHNRAtt(uint16_t maxWait) { return (getHNRATT(maxWait)); } @@ -9285,7 +9285,7 @@ boolean SFE_UBLOX_GNSS::getHNRAtt(uint16_t maxWait) // Note: if hnrAttQueried is true, it gets set to false by this function since we assume // that the user will read hnrAtt immediately after this. I.e. this function will // only return true _once_ after each auto HNR Att is processed -boolean SFE_UBLOX_GNSS::getHNRATT(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getHNRATT(uint16_t maxWait) { if (packetUBXHNRATT == NULL) initPacketUBXHNRATT(); //Check that RAM has been allocated for the data if (packetUBXHNRATT == NULL) //Bail if the RAM allocation failed @@ -9351,21 +9351,21 @@ boolean SFE_UBLOX_GNSS::getHNRATT(uint16_t maxWait) //Enable or disable automatic HNR attitude message generation by the GNSS. This changes the way getHNRAtt //works. -boolean SFE_UBLOX_GNSS::setAutoHNRATT(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoHNRATT(bool enable, uint16_t maxWait) { return setAutoHNRATTrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic HNR attitude message generation by the GNSS. This changes the way getHNRAtt //works. -boolean SFE_UBLOX_GNSS::setAutoHNRATT(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoHNRATT(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoHNRATTrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic HNR attitude message generation by the GNSS. This changes the way getHNRAtt //works. -boolean SFE_UBLOX_GNSS::setAutoHNRATTrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoHNRATTrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXHNRATT == NULL) initPacketUBXHNRATT(); //Check that RAM has been allocated for the data if (packetUBXHNRATT == NULL) //Only attempt this if RAM allocation was successful @@ -9381,7 +9381,7 @@ boolean SFE_UBLOX_GNSS::setAutoHNRATTrate(uint8_t rate, boolean implicitUpdate, payloadCfg[1] = UBX_HNR_ATT; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXHNRATT->automaticFlags.flags.bits.automatic = (rate > 0); @@ -9392,10 +9392,10 @@ boolean SFE_UBLOX_GNSS::setAutoHNRATTrate(uint8_t rate, boolean implicitUpdate, } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoHNRATTcallback(void (*callbackPointer)(UBX_HNR_ATT_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoHNRATTcallback(void (*callbackPointer)(UBX_HNR_ATT_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoHNRATT(true, false, maxWait); + bool result = setAutoHNRATT(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -9417,13 +9417,13 @@ boolean SFE_UBLOX_GNSS::setAutoHNRATTcallback(void (*callbackPointer)(UBX_HNR_AT //In case no config access to the GNSS is possible and HNR attitude is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoHNRATT(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoHNRATT(bool enabled, bool implicitUpdate) { if (packetUBXHNRATT == NULL) initPacketUBXHNRATT(); //Check that RAM has been allocated for the data if (packetUBXHNRATT == NULL) //Bail if the RAM allocation failed return (false); - boolean changes = packetUBXHNRATT->automaticFlags.flags.bits.automatic != enabled || packetUBXHNRATT->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXHNRATT->automaticFlags.flags.bits.automatic != enabled || packetUBXHNRATT->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXHNRATT->automaticFlags.flags.bits.automatic = enabled; @@ -9433,7 +9433,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoHNRATT(boolean enabled, boolean implicitUpdate } // PRIVATE: Allocate RAM for packetUBXHNRATT and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXHNRATT() +bool SFE_UBLOX_GNSS::initPacketUBXHNRATT() { packetUBXHNRATT = new UBX_HNR_ATT_t; //Allocate RAM for the main struct if (packetUBXHNRATT == NULL) @@ -9458,7 +9458,7 @@ void SFE_UBLOX_GNSS::flushHNRATT() //Log this data in file buffer -void SFE_UBLOX_GNSS::logHNRATT(boolean enabled) +void SFE_UBLOX_GNSS::logHNRATT(bool enabled) { if (packetUBXHNRATT == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXHNRATT->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -9466,7 +9466,7 @@ void SFE_UBLOX_GNSS::logHNRATT(boolean enabled) // ***** HNR DYN automatic support -boolean SFE_UBLOX_GNSS::getHNRDyn(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getHNRDyn(uint16_t maxWait) { return (getHNRINS(maxWait)); } @@ -9476,7 +9476,7 @@ boolean SFE_UBLOX_GNSS::getHNRDyn(uint16_t maxWait) // Note: if hnrDynQueried is true, it gets set to false by this function since we assume // that the user will read hnrVehDyn immediately after this. I.e. this function will // only return true _once_ after each auto HNR Dyn is processed -boolean SFE_UBLOX_GNSS::getHNRINS(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getHNRINS(uint16_t maxWait) { if (packetUBXHNRINS == NULL) initPacketUBXHNRINS(); //Check that RAM has been allocated for the data if (packetUBXHNRINS == NULL) //Bail if the RAM allocation failed @@ -9542,21 +9542,21 @@ boolean SFE_UBLOX_GNSS::getHNRINS(uint16_t maxWait) //Enable or disable automatic HNR vehicle dynamics message generation by the GNSS. This changes the way getHNRDyn //works. -boolean SFE_UBLOX_GNSS::setAutoHNRINS(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoHNRINS(bool enable, uint16_t maxWait) { return setAutoHNRINSrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic HNR vehicle dynamics message generation by the GNSS. This changes the way getHNRDyn //works. -boolean SFE_UBLOX_GNSS::setAutoHNRINS(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoHNRINS(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoHNRINSrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic HNR vehicle dynamics message generation by the GNSS. This changes the way getHNRDyn //works. -boolean SFE_UBLOX_GNSS::setAutoHNRINSrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoHNRINSrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXHNRINS == NULL) initPacketUBXHNRINS(); //Check that RAM has been allocated for the data if (packetUBXHNRINS == NULL) //Only attempt this if RAM allocation was successful @@ -9572,7 +9572,7 @@ boolean SFE_UBLOX_GNSS::setAutoHNRINSrate(uint8_t rate, boolean implicitUpdate, payloadCfg[1] = UBX_HNR_INS; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXHNRINS->automaticFlags.flags.bits.automatic = (rate > 0); @@ -9583,10 +9583,10 @@ boolean SFE_UBLOX_GNSS::setAutoHNRINSrate(uint8_t rate, boolean implicitUpdate, } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoHNRINScallback(void (*callbackPointer)(UBX_HNR_INS_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoHNRINScallback(void (*callbackPointer)(UBX_HNR_INS_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoHNRINS(true, false, maxWait); + bool result = setAutoHNRINS(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -9608,13 +9608,13 @@ boolean SFE_UBLOX_GNSS::setAutoHNRINScallback(void (*callbackPointer)(UBX_HNR_IN //In case no config access to the GNSS is possible and HNR vehicle dynamics is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoHNRINS(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoHNRINS(bool enabled, bool implicitUpdate) { if (packetUBXHNRINS == NULL) initPacketUBXHNRINS(); //Check that RAM has been allocated for the data if (packetUBXHNRINS == NULL) //Bail if the RAM allocation failed return (false); - boolean changes = packetUBXHNRINS->automaticFlags.flags.bits.automatic != enabled || packetUBXHNRINS->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXHNRINS->automaticFlags.flags.bits.automatic != enabled || packetUBXHNRINS->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXHNRINS->automaticFlags.flags.bits.automatic = enabled; @@ -9624,7 +9624,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoHNRINS(boolean enabled, boolean implicitUpdate } // PRIVATE: Allocate RAM for packetUBXHNRINS and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXHNRINS() +bool SFE_UBLOX_GNSS::initPacketUBXHNRINS() { packetUBXHNRINS = new UBX_HNR_INS_t; //Allocate RAM for the main struct if (packetUBXHNRINS == NULL) @@ -9648,7 +9648,7 @@ void SFE_UBLOX_GNSS::flushHNRINS() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logHNRINS(boolean enabled) +void SFE_UBLOX_GNSS::logHNRINS(bool enabled) { if (packetUBXHNRINS == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXHNRINS->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -9661,7 +9661,7 @@ void SFE_UBLOX_GNSS::logHNRINS(boolean enabled) // Note: if hnrPVTQueried is true, it gets set to false by this function since we assume // that the user will read hnrPVT immediately after this. I.e. this function will // only return true _once_ after each auto HNR PVT is processed -boolean SFE_UBLOX_GNSS::getHNRPVT(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getHNRPVT(uint16_t maxWait) { if (packetUBXHNRPVT == NULL) initPacketUBXHNRPVT(); //Check that RAM has been allocated for the PVT data if (packetUBXHNRPVT == NULL) //Only attempt this if RAM allocation was successful @@ -9727,21 +9727,21 @@ boolean SFE_UBLOX_GNSS::getHNRPVT(uint16_t maxWait) //Enable or disable automatic HNR PVT message generation by the GNSS. This changes the way getHNRPVT //works. -boolean SFE_UBLOX_GNSS::setAutoHNRPVT(boolean enable, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoHNRPVT(bool enable, uint16_t maxWait) { return setAutoHNRPVTrate(enable ? 1 : 0, true, maxWait); } //Enable or disable automatic HNR PVT message generation by the GNSS. This changes the way getHNRPVT //works. -boolean SFE_UBLOX_GNSS::setAutoHNRPVT(boolean enable, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoHNRPVT(bool enable, bool implicitUpdate, uint16_t maxWait) { return setAutoHNRPVTrate(enable ? 1 : 0, implicitUpdate, maxWait); } //Enable or disable automatic HNR PVT message generation by the GNSS. This changes the way getHNRPVT //works. -boolean SFE_UBLOX_GNSS::setAutoHNRPVTrate(uint8_t rate, boolean implicitUpdate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoHNRPVTrate(uint8_t rate, bool implicitUpdate, uint16_t maxWait) { if (packetUBXHNRPVT == NULL) initPacketUBXHNRPVT(); //Check that RAM has been allocated for the data if (packetUBXHNRPVT == NULL) //Only attempt this if RAM allocation was successful @@ -9757,7 +9757,7 @@ boolean SFE_UBLOX_GNSS::setAutoHNRPVTrate(uint8_t rate, boolean implicitUpdate, payloadCfg[1] = UBX_HNR_PVT; payloadCfg[2] = rate; // rate relative to navigation freq. - boolean ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool ok = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK if (ok) { packetUBXHNRPVT->automaticFlags.flags.bits.automatic = (rate > 0); @@ -9768,10 +9768,10 @@ boolean SFE_UBLOX_GNSS::setAutoHNRPVTrate(uint8_t rate, boolean implicitUpdate, } //Enable automatic navigation message generation by the GNSS. -boolean SFE_UBLOX_GNSS::setAutoHNRPVTcallback(void (*callbackPointer)(UBX_HNR_PVT_data_t), uint16_t maxWait) +bool SFE_UBLOX_GNSS::setAutoHNRPVTcallback(void (*callbackPointer)(UBX_HNR_PVT_data_t), uint16_t maxWait) { // Enable auto messages. Set implicitUpdate to false as we expect the user to call checkUblox manually. - boolean result = setAutoHNRPVT(true, false, maxWait); + bool result = setAutoHNRPVT(true, false, maxWait); if (!result) return (result); // Bail if setAuto failed @@ -9793,13 +9793,13 @@ boolean SFE_UBLOX_GNSS::setAutoHNRPVTcallback(void (*callbackPointer)(UBX_HNR_PV //In case no config access to the GNSS is possible and HNR PVT is send cyclically already //set config to suitable parameters -boolean SFE_UBLOX_GNSS::assumeAutoHNRPVT(boolean enabled, boolean implicitUpdate) +bool SFE_UBLOX_GNSS::assumeAutoHNRPVT(bool enabled, bool implicitUpdate) { if (packetUBXHNRPVT == NULL) initPacketUBXHNRPVT(); //Check that RAM has been allocated for the PVT data if (packetUBXHNRPVT == NULL) //Only attempt this if RAM allocation was successful return false; - boolean changes = packetUBXHNRPVT->automaticFlags.flags.bits.automatic != enabled || packetUBXHNRPVT->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; + bool changes = packetUBXHNRPVT->automaticFlags.flags.bits.automatic != enabled || packetUBXHNRPVT->automaticFlags.flags.bits.implicitUpdate != implicitUpdate; if (changes) { packetUBXHNRPVT->automaticFlags.flags.bits.automatic = enabled; @@ -9809,7 +9809,7 @@ boolean SFE_UBLOX_GNSS::assumeAutoHNRPVT(boolean enabled, boolean implicitUpdate } // PRIVATE: Allocate RAM for packetUBXHNRPVT and initialize it -boolean SFE_UBLOX_GNSS::initPacketUBXHNRPVT() +bool SFE_UBLOX_GNSS::initPacketUBXHNRPVT() { packetUBXHNRPVT = new UBX_HNR_PVT_t; //Allocate RAM for the main struct if (packetUBXHNRPVT == NULL) @@ -9833,7 +9833,7 @@ void SFE_UBLOX_GNSS::flushHNRPVT() } //Log this data in file buffer -void SFE_UBLOX_GNSS::logHNRPVT(boolean enabled) +void SFE_UBLOX_GNSS::logHNRPVT(bool enabled) { if (packetUBXHNRPVT == NULL) return; // Bail if RAM has not been allocated (otherwise we could be writing anywhere!) packetUBXHNRPVT->automaticFlags.flags.bits.addToFileBuffer = (uint8_t)enabled; @@ -9867,7 +9867,7 @@ uint32_t SFE_UBLOX_GNSS::getProcessNMEAMask() //Set the rate at which the module will give us an updated navigation solution //Expects a number that is the updates per second. For example 1 = 1Hz, 2 = 2Hz, etc. //Max is 40Hz(?!) -boolean SFE_UBLOX_GNSS::setNavigationFrequency(uint8_t navFreq, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setNavigationFrequency(uint8_t navFreq, uint16_t maxWait) { if (navFreq > 40) navFreq = 40; // Limit navFreq to 40Hz so i2cPollingWait is set correctly @@ -9893,7 +9893,7 @@ boolean SFE_UBLOX_GNSS::setNavigationFrequency(uint8_t navFreq, uint16_t maxWait payloadCfg[0] = measurementRate & 0xFF; //measRate LSB payloadCfg[1] = measurementRate >> 8; //measRate MSB - boolean result = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool result = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK flushCFGRATE(); // Mark the polled measurement and navigation rate data as stale @@ -9919,7 +9919,7 @@ uint8_t SFE_UBLOX_GNSS::getNavigationFrequency(uint16_t maxWait) } //Set the elapsed time between GNSS measurements in milliseconds, which defines the rate -boolean SFE_UBLOX_GNSS::setMeasurementRate(uint16_t rate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setMeasurementRate(uint16_t rate, uint16_t maxWait) { if (rate < 25) // "Measurement rate should be greater than or equal to 25 ms." rate = 25; @@ -9942,7 +9942,7 @@ boolean SFE_UBLOX_GNSS::setMeasurementRate(uint16_t rate, uint16_t maxWait) payloadCfg[0] = rate & 0xFF; //measRate LSB payloadCfg[1] = rate >> 8; //measRate MSB - boolean result = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool result = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK flushCFGRATE(); // Mark the polled measurement and navigation rate data as stale @@ -9965,7 +9965,7 @@ uint16_t SFE_UBLOX_GNSS::getMeasurementRate(uint16_t maxWait) } //Set the ratio between the number of measurements and the number of navigation solutions. Unit is cycles. Max is 127. -boolean SFE_UBLOX_GNSS::setNavigationRate(uint16_t rate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setNavigationRate(uint16_t rate, uint16_t maxWait) { //Query the module packetCfg.cls = UBX_CLASS_CFG; @@ -9981,7 +9981,7 @@ boolean SFE_UBLOX_GNSS::setNavigationRate(uint16_t rate, uint16_t maxWait) payloadCfg[2] = rate & 0xFF; //navRate LSB payloadCfg[3] = rate >> 8; //navRate MSB - boolean result = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK + bool result = ((sendCommand(&packetCfg, maxWait)) == SFE_UBLOX_STATUS_DATA_SENT); // We are only expecting an ACK flushCFGRATE(); // Mark the polled measurement and navigation rate data as stale @@ -10911,7 +10911,7 @@ uint32_t SFE_UBLOX_GNSS::getVerticalAccuracy(uint16_t maxWait) // ***** SVIN Helper Functions -boolean SFE_UBLOX_GNSS::getSurveyInActive(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getSurveyInActive(uint16_t maxWait) { if (packetUBXNAVSVIN == NULL) initPacketUBXNAVSVIN(); //Check that RAM has been allocated for the SVIN data if (packetUBXNAVSVIN == NULL) //Bail if the RAM allocation failed @@ -10921,10 +10921,10 @@ boolean SFE_UBLOX_GNSS::getSurveyInActive(uint16_t maxWait) getSurveyStatus(maxWait); packetUBXNAVSVIN->moduleQueried.moduleQueried.bits.active = false; //Since we are about to give this to user, mark this data as stale packetUBXNAVSVIN->moduleQueried.moduleQueried.bits.all = false; - return ((boolean)packetUBXNAVSVIN->data.active); + return ((bool)packetUBXNAVSVIN->data.active); } -boolean SFE_UBLOX_GNSS::getSurveyInValid(uint16_t maxWait) +bool SFE_UBLOX_GNSS::getSurveyInValid(uint16_t maxWait) { if (packetUBXNAVSVIN == NULL) initPacketUBXNAVSVIN(); //Check that RAM has been allocated for the SVIN data if (packetUBXNAVSVIN == NULL) //Bail if the RAM allocation failed @@ -10934,7 +10934,7 @@ boolean SFE_UBLOX_GNSS::getSurveyInValid(uint16_t maxWait) getSurveyStatus(maxWait); packetUBXNAVSVIN->moduleQueried.moduleQueried.bits.valid = false; //Since we are about to give this to user, mark this data as stale packetUBXNAVSVIN->moduleQueried.moduleQueried.bits.all = false; - return ((boolean)packetUBXNAVSVIN->data.valid); + return ((bool)packetUBXNAVSVIN->data.valid); } uint16_t SFE_UBLOX_GNSS::getSurveyInObservationTime(uint16_t maxWait) // Truncated to 65535 seconds @@ -10997,7 +10997,7 @@ uint8_t SFE_UBLOX_GNSS::getLeapIndicator(int32_t& timeToLsEvent, uint16_t maxWai // 1 -last minute of the day has 61 seconds // 2 -last minute of the day has 59 seconds // 3 -unknown (clock unsynchronized) - return ((boolean)packetUBXNAVTIMELS->data.valid.bits.validTimeToLsEvent ? (uint8_t)(packetUBXNAVTIMELS->data.lsChange == -1 ? 2 : packetUBXNAVTIMELS->data.lsChange) : 3); + return ((bool)packetUBXNAVTIMELS->data.valid.bits.validTimeToLsEvent ? (uint8_t)(packetUBXNAVTIMELS->data.lsChange == -1 ? 2 : packetUBXNAVTIMELS->data.lsChange) : 3); } int8_t SFE_UBLOX_GNSS::getCurrentLeapSeconds(sfe_ublox_ls_src_e& source, uint16_t maxWait) @@ -11137,7 +11137,7 @@ float SFE_UBLOX_GNSS::getESFyaw(uint16_t maxWait) // Returned as degrees return (((float)packetUBXESFALG->data.yaw) / 100.0); // Convert to degrees } -boolean SFE_UBLOX_GNSS::getSensorFusionMeasurement(UBX_ESF_MEAS_sensorData_t *sensorData, uint8_t sensor, uint16_t maxWait) +bool SFE_UBLOX_GNSS::getSensorFusionMeasurement(UBX_ESF_MEAS_sensorData_t *sensorData, uint8_t sensor, uint16_t maxWait) { if (packetUBXESFMEAS == NULL) initPacketUBXESFMEAS(); //Check that RAM has been allocated for the ESF MEAS data if (packetUBXESFMEAS == NULL) //Bail if the RAM allocation failed @@ -11151,13 +11151,13 @@ boolean SFE_UBLOX_GNSS::getSensorFusionMeasurement(UBX_ESF_MEAS_sensorData_t *se return (true); } -boolean SFE_UBLOX_GNSS::getSensorFusionMeasurement(UBX_ESF_MEAS_sensorData_t *sensorData, UBX_ESF_MEAS_data_t ubxDataStruct, uint8_t sensor) +bool SFE_UBLOX_GNSS::getSensorFusionMeasurement(UBX_ESF_MEAS_sensorData_t *sensorData, UBX_ESF_MEAS_data_t ubxDataStruct, uint8_t sensor) { sensorData->data.all = ubxDataStruct.data[sensor].data.all; return (true); } -boolean SFE_UBLOX_GNSS::getRawSensorMeasurement(UBX_ESF_RAW_sensorData_t *sensorData, uint8_t sensor, uint16_t maxWait) +bool SFE_UBLOX_GNSS::getRawSensorMeasurement(UBX_ESF_RAW_sensorData_t *sensorData, uint8_t sensor, uint16_t maxWait) { if (packetUBXESFRAW == NULL) initPacketUBXESFRAW(); //Check that RAM has been allocated for the ESF RAW data if (packetUBXESFRAW == NULL) //Bail if the RAM allocation failed @@ -11172,14 +11172,14 @@ boolean SFE_UBLOX_GNSS::getRawSensorMeasurement(UBX_ESF_RAW_sensorData_t *sensor return (true); } -boolean SFE_UBLOX_GNSS::getRawSensorMeasurement(UBX_ESF_RAW_sensorData_t *sensorData, UBX_ESF_RAW_data_t ubxDataStruct, uint8_t sensor) +bool SFE_UBLOX_GNSS::getRawSensorMeasurement(UBX_ESF_RAW_sensorData_t *sensorData, UBX_ESF_RAW_data_t ubxDataStruct, uint8_t sensor) { sensorData->data.all = ubxDataStruct.data[sensor].data.all; sensorData->sTag = ubxDataStruct.data[sensor].sTag; return (true); } -boolean SFE_UBLOX_GNSS::getSensorFusionStatus(UBX_ESF_STATUS_sensorStatus_t *sensorStatus, uint8_t sensor, uint16_t maxWait) +bool SFE_UBLOX_GNSS::getSensorFusionStatus(UBX_ESF_STATUS_sensorStatus_t *sensorStatus, uint8_t sensor, uint16_t maxWait) { if (packetUBXESFSTATUS == NULL) initPacketUBXESFSTATUS(); //Check that RAM has been allocated for the ESF STATUS data if (packetUBXESFSTATUS == NULL) //Bail if the RAM allocation failed @@ -11196,7 +11196,7 @@ boolean SFE_UBLOX_GNSS::getSensorFusionStatus(UBX_ESF_STATUS_sensorStatus_t *sen return (true); } -boolean SFE_UBLOX_GNSS::getSensorFusionStatus(UBX_ESF_STATUS_sensorStatus_t *sensorStatus, UBX_ESF_STATUS_data_t ubxDataStruct, uint8_t sensor) +bool SFE_UBLOX_GNSS::getSensorFusionStatus(UBX_ESF_STATUS_sensorStatus_t *sensorStatus, UBX_ESF_STATUS_data_t ubxDataStruct, uint8_t sensor) { sensorStatus->sensStatus1.all = ubxDataStruct.status[sensor].sensStatus1.all; sensorStatus->sensStatus2.all = ubxDataStruct.status[sensor].sensStatus2.all; @@ -11209,7 +11209,7 @@ boolean SFE_UBLOX_GNSS::getSensorFusionStatus(UBX_ESF_STATUS_sensorStatus_t *sen // Set the High Navigation Rate // Returns true if the setHNRNavigationRate is successful -boolean SFE_UBLOX_GNSS::setHNRNavigationRate(uint8_t rate, uint16_t maxWait) +bool SFE_UBLOX_GNSS::setHNRNavigationRate(uint8_t rate, uint16_t maxWait) { if (rate > 40) rate = 40; // Limit rate to 40Hz so i2cPollingWait is set correctly diff --git a/src/SparkFun_u-blox_GNSS_Arduino_Library.h b/src/SparkFun_u-blox_GNSS_Arduino_Library.h index 420fed3..1bc37b9 100644 --- a/src/SparkFun_u-blox_GNSS_Arduino_Library.h +++ b/src/SparkFun_u-blox_GNSS_Arduino_Library.h @@ -576,11 +576,11 @@ public: void setPacketCfgPayloadSize(size_t payloadSize); // Set packetCfgPayloadSize //By default use the default I2C address, and use Wire port - boolean begin(TwoWire &wirePort = Wire, uint8_t deviceAddress = 0x42); //Returns true if module is detected + bool begin(TwoWire &wirePort = Wire, uint8_t deviceAddress = 0x42); //Returns true if module is detected //serialPort needs to be perviously initialized to correct baud rate - boolean begin(Stream &serialPort); //Returns true if module is detected + bool begin(Stream &serialPort); //Returns true if module is detected //SPI - supply instance of SPIClass, chip select pin and SPI speed (in Hz) - boolean begin(SPIClass &spiPort, uint8_t csPin, uint32_t spiSpeed); + bool begin(SPIClass &spiPort, uint8_t csPin, uint32_t spiSpeed); void end(void); //Stop all automatic message processing. Free all used RAM @@ -597,8 +597,8 @@ public: // Support for platforms like ESP32 which do not support multiple I2C restarts // If _i2cStopRestart is true, endTransmission will always use a stop. If false, a restart will be used where needed. // The default value for _i2cStopRestart is set in the class instantiation code. - void setI2cStopRestart(boolean stop) { _i2cStopRestart = stop; }; - boolean getI2cStopRestart(void) { return (_i2cStopRestart); }; + void setI2cStopRestart(bool stop) { _i2cStopRestart = stop; }; + bool getI2cStopRestart(void) { return (_i2cStopRestart); }; //Control the size of the spi buffer. If the buffer isn't big enough, we'll start to lose bytes //That we receive if the buffer is full! @@ -610,7 +610,7 @@ public: int8_t getMaxNMEAByteCount(void); //Returns true if device answers on _gpsI2Caddress address or via Serial - boolean isConnected(uint16_t maxWait = 1100); + bool isConnected(uint16_t maxWait = 1100); // Enable debug messages using the chosen Serial port (Stream) // Boards like the RedBoard Turbo use SerialUSB (not Serial). @@ -620,18 +620,18 @@ public: #if defined(USB_VID) // Is the USB Vendor ID defined? #if (USB_VID == 0x1B4F) // Is this a SparkFun board? #if !defined(ARDUINO_SAMD51_THING_PLUS) & !defined(ARDUINO_SAMD51_MICROMOD) // If it is not a SAMD51 Thing Plus or SAMD51 MicroMod - void enableDebugging(Stream &debugPort = SerialUSB, boolean printLimitedDebug = false); //Given a port to print to, enable debug messages. Default to all, not limited. + void enableDebugging(Stream &debugPort = SerialUSB, bool printLimitedDebug = false); //Given a port to print to, enable debug messages. Default to all, not limited. #else - void enableDebugging(Stream &debugPort = Serial, boolean printLimitedDebug = false); //Given a port to print to, enable debug messages. Default to all, not limited. + void enableDebugging(Stream &debugPort = Serial, bool printLimitedDebug = false); //Given a port to print to, enable debug messages. Default to all, not limited. #endif #else - void enableDebugging(Stream &debugPort = Serial, boolean printLimitedDebug = false); //Given a port to print to, enable debug messages. Default to all, not limited. + void enableDebugging(Stream &debugPort = Serial, bool printLimitedDebug = false); //Given a port to print to, enable debug messages. Default to all, not limited. #endif #else - void enableDebugging(Stream &debugPort = Serial, boolean printLimitedDebug = false); //Given a port to print to, enable debug messages. Default to all, not limited. + void enableDebugging(Stream &debugPort = Serial, bool printLimitedDebug = false); //Given a port to print to, enable debug messages. Default to all, not limited. #endif #else - void enableDebugging(Stream &debugPort = Serial, boolean printLimitedDebug = false); //Given a port to print to, enable debug messages. Default to all, not limited. + void enableDebugging(Stream &debugPort = Serial, bool printLimitedDebug = false); //Given a port to print to, enable debug messages. Default to all, not limited. #endif void disableDebugging(void); //Turn off debug statements @@ -641,15 +641,15 @@ public: // Check for the arrival of new I2C/Serial data - void disableUBX7Fcheck(boolean disabled = true); // When logging RAWX data, we need to be able to disable the "7F" check in checkUbloxI2C + void disableUBX7Fcheck(bool disabled = true); // When logging RAWX data, we need to be able to disable the "7F" check in checkUbloxI2C //Changed in V1.8.1: provides backward compatibility for the examples that call checkUblox directly //Will default to using packetCfg to look for explicit autoPVT packets so they get processed correctly by processUBX - boolean checkUblox(uint8_t requestedClass = 0, uint8_t requestedID = 0); //Checks module with user selected commType + bool checkUblox(uint8_t requestedClass = 0, uint8_t requestedID = 0); //Checks module with user selected commType - boolean checkUbloxI2C(ubxPacket *incomingUBX, uint8_t requestedClass, uint8_t requestedID); //Method for I2C polling of data, passing any new bytes to process() - boolean checkUbloxSerial(ubxPacket *incomingUBX, uint8_t requestedClass, uint8_t requestedID); //Method for serial polling of data, passing any new bytes to process() - boolean checkUbloxSpi(ubxPacket *incomingUBX, uint8_t requestedClass, uint8_t requestedID); //Method for spi polling of data, passing any new bytes to process() + bool checkUbloxI2C(ubxPacket *incomingUBX, uint8_t requestedClass, uint8_t requestedID); //Method for I2C polling of data, passing any new bytes to process() + bool checkUbloxSerial(ubxPacket *incomingUBX, uint8_t requestedClass, uint8_t requestedID); //Method for serial polling of data, passing any new bytes to process() + bool checkUbloxSpi(ubxPacket *incomingUBX, uint8_t requestedClass, uint8_t requestedID); //Method for spi polling of data, passing any new bytes to process() // Process the incoming data @@ -663,12 +663,12 @@ public: // Send I2C/Serial/SPI commands to the module void calcChecksum(ubxPacket *msg); //Sets the checksumA and checksumB of a given messages - sfe_ublox_status_e sendCommand(ubxPacket *outgoingUBX, uint16_t maxWait = defaultMaxWait, boolean expectACKonly = false); //Given a packet and payload, send everything including CRC bytes, return true if we got a response + sfe_ublox_status_e sendCommand(ubxPacket *outgoingUBX, uint16_t maxWait = defaultMaxWait, bool expectACKonly = false); //Given a packet and payload, send everything including CRC bytes, return true if we got a response sfe_ublox_status_e sendI2cCommand(ubxPacket *outgoingUBX, uint16_t maxWait = defaultMaxWait); void sendSerialCommand(ubxPacket *outgoingUBX); void sendSpiCommand(ubxPacket *outgoingUBX); - void printPacket(ubxPacket *packet, boolean alwaysPrintPayload = false); //Useful for debugging + void printPacket(ubxPacket *packet, bool alwaysPrintPayload = false); //Useful for debugging // After sending a message to the module, wait for the expected response (data+ACK or just data) @@ -681,7 +681,7 @@ public: // Push (e.g.) RTCM data directly to the module // Warning: this function does not check that the data is valid. It is the user's responsibility to ensure the data is valid before pushing. // Default to using a restart between transmissions. But processors like ESP32 seem to need a stop (#30). Set stop to true to use a stop instead. - boolean pushRawData(uint8_t *dataBytes, size_t numDataBytes, boolean stop = false); + bool pushRawData(uint8_t *dataBytes, size_t numDataBytes, bool stop = false); // Support for data logging void setFileBufferSize(uint16_t bufferSize); // Set the size of the file buffer. This must be called _before_ .begin. @@ -695,46 +695,46 @@ public: // Specific commands //Port configurations - boolean getPortSettings(uint8_t portID, uint16_t maxWait = defaultMaxWait); //Returns the current protocol bits in the UBX-CFG-PRT command for a given port - boolean setPortOutput(uint8_t portID, uint8_t comSettings, uint16_t maxWait = defaultMaxWait); //Configure a given port to output UBX, NMEA, RTCM3 or a combination thereof - boolean setPortInput(uint8_t portID, uint8_t comSettings, uint16_t maxWait = defaultMaxWait); //Configure a given port to input UBX, NMEA, RTCM3 or a combination thereof + bool getPortSettings(uint8_t portID, uint16_t maxWait = defaultMaxWait); //Returns the current protocol bits in the UBX-CFG-PRT command for a given port + bool setPortOutput(uint8_t portID, uint8_t comSettings, uint16_t maxWait = defaultMaxWait); //Configure a given port to output UBX, NMEA, RTCM3 or a combination thereof + bool setPortInput(uint8_t portID, uint8_t comSettings, uint16_t maxWait = defaultMaxWait); //Configure a given port to input UBX, NMEA, RTCM3 or a combination thereof - boolean setI2CAddress(uint8_t deviceAddress, uint16_t maxTime = defaultMaxWait); //Changes the I2C address of the u-blox module + bool setI2CAddress(uint8_t deviceAddress, uint16_t maxTime = defaultMaxWait); //Changes the I2C address of the u-blox module void setSerialRate(uint32_t baudrate, uint8_t uartPort = COM_PORT_UART1, uint16_t maxTime = defaultMaxWait); //Changes the serial baud rate of the u-blox module, uartPort should be COM_PORT_UART1/2 - boolean setI2COutput(uint8_t comSettings, uint16_t maxWait = defaultMaxWait); //Configure I2C port to output UBX, NMEA, RTCM3 or a combination thereof - boolean setUART1Output(uint8_t comSettings, uint16_t maxWait = defaultMaxWait); //Configure UART1 port to output UBX, NMEA, RTCM3 or a combination thereof - boolean setUART2Output(uint8_t comSettings, uint16_t maxWait = defaultMaxWait); //Configure UART2 port to output UBX, NMEA, RTCM3 or a combination thereof - boolean setUSBOutput(uint8_t comSettings, uint16_t maxWait = defaultMaxWait); //Configure USB port to output UBX, NMEA, RTCM3 or a combination thereof - boolean setSPIOutput(uint8_t comSettings, uint16_t maxWait = defaultMaxWait); //Configure SPI port to output UBX, NMEA, RTCM3 or a combination thereof + bool setI2COutput(uint8_t comSettings, uint16_t maxWait = defaultMaxWait); //Configure I2C port to output UBX, NMEA, RTCM3 or a combination thereof + bool setUART1Output(uint8_t comSettings, uint16_t maxWait = defaultMaxWait); //Configure UART1 port to output UBX, NMEA, RTCM3 or a combination thereof + bool setUART2Output(uint8_t comSettings, uint16_t maxWait = defaultMaxWait); //Configure UART2 port to output UBX, NMEA, RTCM3 or a combination thereof + bool setUSBOutput(uint8_t comSettings, uint16_t maxWait = defaultMaxWait); //Configure USB port to output UBX, NMEA, RTCM3 or a combination thereof + bool setSPIOutput(uint8_t comSettings, uint16_t maxWait = defaultMaxWait); //Configure SPI port to output UBX, NMEA, RTCM3 or a combination thereof void setNMEAOutputPort(Stream &nmeaOutputPort); //Sets the internal variable for the port to direct NMEA characters to //Reset to defaults void factoryReset(); //Send factory reset sequence (i.e. load "default" configuration and perform hardReset) void hardReset(); //Perform a reset leading to a cold start (zero info start-up) - boolean factoryDefault(uint16_t maxWait = defaultMaxWait); //Reset module to factory defaults + bool factoryDefault(uint16_t maxWait = defaultMaxWait); //Reset module to factory defaults //Save configuration to BBR / Flash - boolean saveConfiguration(uint16_t maxWait = defaultMaxWait); //Save current configuration to flash and BBR (battery backed RAM) - boolean saveConfigSelective(uint32_t configMask, uint16_t maxWait = defaultMaxWait); //Save the selected configuration sub-sections to flash and BBR (battery backed RAM) + bool saveConfiguration(uint16_t maxWait = defaultMaxWait); //Save current configuration to flash and BBR (battery backed RAM) + bool saveConfigSelective(uint32_t configMask, uint16_t maxWait = defaultMaxWait); //Save the selected configuration sub-sections to flash and BBR (battery backed RAM) //Functions to turn on/off message types for a given port ID (see COM_PORT_I2C, etc above) - boolean configureMessage(uint8_t msgClass, uint8_t msgID, uint8_t portID, uint8_t sendRate, uint16_t maxWait = defaultMaxWait); - boolean enableMessage(uint8_t msgClass, uint8_t msgID, uint8_t portID, uint8_t sendRate = 1, uint16_t maxWait = defaultMaxWait); - boolean disableMessage(uint8_t msgClass, uint8_t msgID, uint8_t portID, uint16_t maxWait = defaultMaxWait); - boolean enableNMEAMessage(uint8_t msgID, uint8_t portID, uint8_t sendRate = 1, uint16_t maxWait = defaultMaxWait); - boolean disableNMEAMessage(uint8_t msgID, uint8_t portID, uint16_t maxWait = defaultMaxWait); - boolean enableRTCMmessage(uint8_t messageNumber, uint8_t portID, uint8_t sendRate, uint16_t maxWait = defaultMaxWait); //Given a message number turns on a message ID for output over given PortID - boolean disableRTCMmessage(uint8_t messageNumber, uint8_t portID, uint16_t maxWait = defaultMaxWait); //Turn off given RTCM message from a given port + bool configureMessage(uint8_t msgClass, uint8_t msgID, uint8_t portID, uint8_t sendRate, uint16_t maxWait = defaultMaxWait); + bool enableMessage(uint8_t msgClass, uint8_t msgID, uint8_t portID, uint8_t sendRate = 1, uint16_t maxWait = defaultMaxWait); + bool disableMessage(uint8_t msgClass, uint8_t msgID, uint8_t portID, uint16_t maxWait = defaultMaxWait); + bool enableNMEAMessage(uint8_t msgID, uint8_t portID, uint8_t sendRate = 1, uint16_t maxWait = defaultMaxWait); + bool disableNMEAMessage(uint8_t msgID, uint8_t portID, uint16_t maxWait = defaultMaxWait); + bool enableRTCMmessage(uint8_t messageNumber, uint8_t portID, uint8_t sendRate, uint16_t maxWait = defaultMaxWait); //Given a message number turns on a message ID for output over given PortID + bool disableRTCMmessage(uint8_t messageNumber, uint8_t portID, uint16_t maxWait = defaultMaxWait); //Turn off given RTCM message from a given port //Functions used for RTK and base station setup //It is probably safe to assume that users of the RTK will be using I2C / Qwiic. So let's leave maxWait set to 250ms. - boolean getSurveyMode(uint16_t maxWait = 250); //Get the current TimeMode3 settings - boolean setSurveyMode(uint8_t mode, uint16_t observationTime, float requiredAccuracy, uint16_t maxWait = 250); //Control survey in mode - boolean enableSurveyMode(uint16_t observationTime, float requiredAccuracy, uint16_t maxWait = 250); //Begin Survey-In for NEO-M8P - boolean disableSurveyMode(uint16_t maxWait = 250); //Stop Survey-In mode + bool getSurveyMode(uint16_t maxWait = 250); //Get the current TimeMode3 settings + bool setSurveyMode(uint8_t mode, uint16_t observationTime, float requiredAccuracy, uint16_t maxWait = 250); //Control survey in mode + bool enableSurveyMode(uint16_t observationTime, float requiredAccuracy, uint16_t maxWait = 250); //Begin Survey-In for NEO-M8P + bool disableSurveyMode(uint16_t maxWait = 250); //Stop Survey-In mode // Given coordinates, put receiver into static position. Set latlong to true to pass in lat/long values instead of ecef. // For ECEF the units are: cm, 0.1mm, cm, 0.1mm, cm, 0.1mm // For Lat/Lon/Alt the units are: degrees^-7, degrees^-9, degrees^-7, degrees^-9, cm, 0.1mm @@ -744,46 +744,46 @@ public: //Read the module's protocol version uint8_t getProtocolVersionHigh(uint16_t maxWait = defaultMaxWait); //Returns the PROTVER XX.00 from UBX-MON-VER register uint8_t getProtocolVersionLow(uint16_t maxWait = defaultMaxWait); //Returns the PROTVER 00.XX from UBX-MON-VER register - boolean getProtocolVersion(uint16_t maxWait = defaultMaxWait); //Queries module, loads low/high bytes + bool getProtocolVersion(uint16_t maxWait = defaultMaxWait); //Queries module, loads low/high bytes moduleSWVersion_t *moduleSWVersion = NULL; // Pointer to struct. RAM will be allocated for this if/when necessary //Support for geofences - boolean addGeofence(int32_t latitude, int32_t longitude, uint32_t radius, byte confidence = 0, byte pinPolarity = 0, byte pin = 0, uint16_t maxWait = defaultMaxWait); // Add a new geofence - boolean clearGeofences(uint16_t maxWait = defaultMaxWait); //Clears all geofences - boolean clearAntPIO(uint16_t maxWait = defaultMaxWait); //Clears the antenna control pin settings to release the PIOs - boolean getGeofenceState(geofenceState ¤tGeofenceState, uint16_t maxWait = defaultMaxWait); //Returns the combined geofence state + bool addGeofence(int32_t latitude, int32_t longitude, uint32_t radius, byte confidence = 0, byte pinPolarity = 0, byte pin = 0, uint16_t maxWait = defaultMaxWait); // Add a new geofence + bool clearGeofences(uint16_t maxWait = defaultMaxWait); //Clears all geofences + bool clearAntPIO(uint16_t maxWait = defaultMaxWait); //Clears the antenna control pin settings to release the PIOs + bool getGeofenceState(geofenceState ¤tGeofenceState, uint16_t maxWait = defaultMaxWait); //Returns the combined geofence state // Storage for the geofence parameters. RAM is allocated for this if/when required. geofenceParams_t *currentGeofenceParams = NULL; // Pointer to struct. RAM will be allocated for this if/when necessary //Power save / off - boolean powerSaveMode(bool power_save = true, uint16_t maxWait = defaultMaxWait); + bool powerSaveMode(bool power_save = true, uint16_t maxWait = defaultMaxWait); uint8_t getPowerSaveMode(uint16_t maxWait = defaultMaxWait); // Returns 255 if the sendCommand fails - boolean powerOff(uint32_t durationInMs, uint16_t maxWait = defaultMaxWait); - boolean powerOffWithInterrupt(uint32_t durationInMs, uint32_t wakeupSources = VAL_RXM_PMREQ_WAKEUPSOURCE_EXTINT0, boolean forceWhileUsb = true, uint16_t maxWait = 1100); + bool powerOff(uint32_t durationInMs, uint16_t maxWait = defaultMaxWait); + bool powerOffWithInterrupt(uint32_t durationInMs, uint32_t wakeupSources = VAL_RXM_PMREQ_WAKEUPSOURCE_EXTINT0, bool forceWhileUsb = true, uint16_t maxWait = 1100); //Change the dynamic platform model using UBX-CFG-NAV5 - boolean setDynamicModel(dynModel newDynamicModel = DYN_MODEL_PORTABLE, uint16_t maxWait = defaultMaxWait); + bool setDynamicModel(dynModel newDynamicModel = DYN_MODEL_PORTABLE, uint16_t maxWait = defaultMaxWait); uint8_t getDynamicModel(uint16_t maxWait = defaultMaxWait); // Get the dynamic model - returns 255 if the sendCommand fails //Reset the odometer - boolean resetOdometer(uint16_t maxWait = defaultMaxWait); // Reset the odometer + bool resetOdometer(uint16_t maxWait = defaultMaxWait); // Reset the odometer //Enable/Disable individual GNSS systems using UBX-CFG-GNSS //Note: you must leave at least one major GNSS enabled! If in doubt, enable GPS before disabling the others //TO DO: Add support for sigCfgMask and maxTrkCh. (Need to resolve ambiguity with maxWait) - boolean enableGNSS(boolean enable, sfe_ublox_gnss_ids_e id, uint16_t maxWait = defaultMaxWait); - boolean isGNSSenabled(sfe_ublox_gnss_ids_e id, uint16_t maxWait = defaultMaxWait); + bool enableGNSS(bool enable, sfe_ublox_gnss_ids_e id, uint16_t maxWait = defaultMaxWait); + bool isGNSSenabled(sfe_ublox_gnss_ids_e id, uint16_t maxWait = defaultMaxWait); //Reset ESF automatic IMU-mount alignment - boolean resetIMUalignment(uint16_t maxWait = defaultMaxWait); + bool resetIMUalignment(uint16_t maxWait = defaultMaxWait); //Enable/disable esfAutoAlignment bool getESFAutoAlignment(uint16_t maxWait = defaultMaxWait); bool setESFAutoAlignment(bool enable, uint16_t maxWait = defaultMaxWait); //Configure Time Pulse Parameters - boolean getTimePulseParameters(UBX_CFG_TP5_data_t *data = NULL, uint16_t maxWait = defaultMaxWait); // Get the time pulse parameters using UBX_CFG_TP5 - boolean setTimePulseParameters(UBX_CFG_TP5_data_t *data = NULL, uint16_t maxWait = defaultMaxWait); // Set the time pulse parameters using UBX_CFG_TP5 + bool getTimePulseParameters(UBX_CFG_TP5_data_t *data = NULL, uint16_t maxWait = defaultMaxWait); // Get the time pulse parameters using UBX_CFG_TP5 + bool setTimePulseParameters(UBX_CFG_TP5_data_t *data = NULL, uint16_t maxWait = defaultMaxWait); // Set the time pulse parameters using UBX_CFG_TP5 //General configuration (used only on protocol v27 and higher - ie, ZED-F9P) @@ -820,239 +820,239 @@ public: // Navigation (NAV) - boolean getNAVPOSECEF(uint16_t maxWait = defaultMaxWait); // NAV POSECEF - boolean setAutoNAVPOSECEF(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic POSECEF reports at the navigation frequency - boolean setAutoNAVPOSECEF(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic POSECEF reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoNAVPOSECEFrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic POSECEF reports - boolean setAutoNAVPOSECEFcallback(void (*callbackPointer)(UBX_NAV_POSECEF_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic POSECEF reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoNAVPOSECEF(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and POSECEF is send cyclically already + bool getNAVPOSECEF(uint16_t maxWait = defaultMaxWait); // NAV POSECEF + bool setAutoNAVPOSECEF(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic POSECEF reports at the navigation frequency + bool setAutoNAVPOSECEF(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic POSECEF reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoNAVPOSECEFrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic POSECEF reports + bool setAutoNAVPOSECEFcallback(void (*callbackPointer)(UBX_NAV_POSECEF_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic POSECEF reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoNAVPOSECEF(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and POSECEF is send cyclically already void flushNAVPOSECEF(); //Mark all the data as read/stale - void logNAVPOSECEF(boolean enabled = true); // Log data to file buffer + void logNAVPOSECEF(bool enabled = true); // Log data to file buffer - boolean getNAVSTATUS(uint16_t maxWait = defaultMaxWait); // NAV STATUS - boolean setAutoNAVSTATUS(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic STATUS reports at the navigation frequency - boolean setAutoNAVSTATUS(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic STATUS reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoNAVSTATUSrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic STATUS reports - boolean setAutoNAVSTATUScallback(void (*callbackPointer)(UBX_NAV_STATUS_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic STATUS reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoNAVSTATUS(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and STATUS is send cyclically already + bool getNAVSTATUS(uint16_t maxWait = defaultMaxWait); // NAV STATUS + bool setAutoNAVSTATUS(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic STATUS reports at the navigation frequency + bool setAutoNAVSTATUS(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic STATUS reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoNAVSTATUSrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic STATUS reports + bool setAutoNAVSTATUScallback(void (*callbackPointer)(UBX_NAV_STATUS_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic STATUS reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoNAVSTATUS(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and STATUS is send cyclically already void flushNAVSTATUS(); //Mark all the data as read/stale - void logNAVSTATUS(boolean enabled = true); // Log data to file buffer + void logNAVSTATUS(bool enabled = true); // Log data to file buffer - boolean getDOP(uint16_t maxWait = defaultMaxWait); //Query module for latest dilution of precision values and load global vars:. If autoDOP is disabled, performs an explicit poll and waits, if enabled does not block. Returns true if new DOP is available. - boolean setAutoDOP(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic DOP reports at the navigation frequency - boolean setAutoDOP(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic DOP reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoDOPrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic DOP reports - boolean setAutoDOPcallback(void (*callbackPointer)(UBX_NAV_DOP_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic DOP reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoDOP(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and DOP is send cyclically already + bool getDOP(uint16_t maxWait = defaultMaxWait); //Query module for latest dilution of precision values and load global vars:. If autoDOP is disabled, performs an explicit poll and waits, if enabled does not block. Returns true if new DOP is available. + bool setAutoDOP(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic DOP reports at the navigation frequency + bool setAutoDOP(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic DOP reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoDOPrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic DOP reports + bool setAutoDOPcallback(void (*callbackPointer)(UBX_NAV_DOP_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic DOP reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoDOP(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and DOP is send cyclically already void flushDOP(); //Mark all the DOP data as read/stale - void logNAVDOP(boolean enabled = true); // Log data to file buffer + void logNAVDOP(bool enabled = true); // Log data to file buffer - boolean getVehAtt(uint16_t maxWait = defaultMaxWait); // NAV ATT Helper - boolean getNAVATT(uint16_t maxWait = defaultMaxWait); // NAV ATT - boolean setAutoNAVATT(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic vehicle attitude reports at the navigation frequency - boolean setAutoNAVATT(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic vehicle attitude reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoNAVATTrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic ATT reports - boolean setAutoNAVATTcallback(void (*callbackPointer)(UBX_NAV_ATT_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic ATT reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoNAVATT(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and vehicle attitude is send cyclically already + bool getVehAtt(uint16_t maxWait = defaultMaxWait); // NAV ATT Helper + bool getNAVATT(uint16_t maxWait = defaultMaxWait); // NAV ATT + bool setAutoNAVATT(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic vehicle attitude reports at the navigation frequency + bool setAutoNAVATT(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic vehicle attitude reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoNAVATTrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic ATT reports + bool setAutoNAVATTcallback(void (*callbackPointer)(UBX_NAV_ATT_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic ATT reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoNAVATT(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and vehicle attitude is send cyclically already void flushNAVATT(); //Mark all the data as read/stale - void logNAVATT(boolean enabled = true); // Log data to file buffer + void logNAVATT(bool enabled = true); // Log data to file buffer - boolean getPVT(uint16_t maxWait = defaultMaxWait); //Query module for latest group of datums and load global vars: lat, long, alt, speed, SIV, accuracies, etc. If autoPVT is disabled, performs an explicit poll and waits, if enabled does not block. Returns true if new PVT is available. - boolean setAutoPVT(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic PVT reports at the navigation frequency - boolean setAutoPVT(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic PVT reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoPVTrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic PVT reports - boolean setAutoPVTcallback(void (*callbackPointer)(UBX_NAV_PVT_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic PVT reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoPVT(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and PVT is send cyclically already + bool getPVT(uint16_t maxWait = defaultMaxWait); //Query module for latest group of datums and load global vars: lat, long, alt, speed, SIV, accuracies, etc. If autoPVT is disabled, performs an explicit poll and waits, if enabled does not block. Returns true if new PVT is available. + bool setAutoPVT(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic PVT reports at the navigation frequency + bool setAutoPVT(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic PVT reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoPVTrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic PVT reports + bool setAutoPVTcallback(void (*callbackPointer)(UBX_NAV_PVT_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic PVT reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoPVT(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and PVT is send cyclically already void flushPVT(); //Mark all the PVT data as read/stale - void logNAVPVT(boolean enabled = true); // Log data to file buffer + void logNAVPVT(bool enabled = true); // Log data to file buffer - boolean getNAVODO(uint16_t maxWait = defaultMaxWait); // NAV ODO - boolean setAutoNAVODO(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ODO reports at the navigation frequency - boolean setAutoNAVODO(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ODO reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoNAVODOrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic ODO reports - boolean setAutoNAVODOcallback(void (*callbackPointer)(UBX_NAV_ODO_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic ODO reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoNAVODO(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and ODO is send cyclically already + bool getNAVODO(uint16_t maxWait = defaultMaxWait); // NAV ODO + bool setAutoNAVODO(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ODO reports at the navigation frequency + bool setAutoNAVODO(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ODO reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoNAVODOrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic ODO reports + bool setAutoNAVODOcallback(void (*callbackPointer)(UBX_NAV_ODO_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic ODO reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoNAVODO(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and ODO is send cyclically already void flushNAVODO(); //Mark all the data as read/stale - void logNAVODO(boolean enabled = true); // Log data to file buffer + void logNAVODO(bool enabled = true); // Log data to file buffer - boolean getNAVVELECEF(uint16_t maxWait = defaultMaxWait); // NAV VELECEF - boolean setAutoNAVVELECEF(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic VELECEF reports at the navigation frequency - boolean setAutoNAVVELECEF(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic VELECEF reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoNAVVELECEFrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic VELECEF reports - boolean setAutoNAVVELECEFcallback(void (*callbackPointer)(UBX_NAV_VELECEF_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic VELECEF reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoNAVVELECEF(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and VELECEF is send cyclically already + bool getNAVVELECEF(uint16_t maxWait = defaultMaxWait); // NAV VELECEF + bool setAutoNAVVELECEF(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic VELECEF reports at the navigation frequency + bool setAutoNAVVELECEF(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic VELECEF reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoNAVVELECEFrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic VELECEF reports + bool setAutoNAVVELECEFcallback(void (*callbackPointer)(UBX_NAV_VELECEF_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic VELECEF reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoNAVVELECEF(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and VELECEF is send cyclically already void flushNAVVELECEF(); //Mark all the data as read/stale - void logNAVVELECEF(boolean enabled = true); // Log data to file buffer + void logNAVVELECEF(bool enabled = true); // Log data to file buffer - boolean getNAVVELNED(uint16_t maxWait = defaultMaxWait); // NAV VELNED - boolean setAutoNAVVELNED(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic VELNED reports at the navigation frequency - boolean setAutoNAVVELNED(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic VELNED reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoNAVVELNEDrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic VELNED reports - boolean setAutoNAVVELNEDcallback(void (*callbackPointer)(UBX_NAV_VELNED_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic VELNED reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoNAVVELNED(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and VELNED is send cyclically already + bool getNAVVELNED(uint16_t maxWait = defaultMaxWait); // NAV VELNED + bool setAutoNAVVELNED(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic VELNED reports at the navigation frequency + bool setAutoNAVVELNED(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic VELNED reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoNAVVELNEDrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic VELNED reports + bool setAutoNAVVELNEDcallback(void (*callbackPointer)(UBX_NAV_VELNED_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic VELNED reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoNAVVELNED(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and VELNED is send cyclically already void flushNAVVELNED(); //Mark all the data as read/stale - void logNAVVELNED(boolean enabled = true); // Log data to file buffer + void logNAVVELNED(bool enabled = true); // Log data to file buffer - boolean getNAVHPPOSECEF(uint16_t maxWait = defaultMaxWait); // NAV HPPOSECEF - boolean setAutoNAVHPPOSECEF(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HPPOSECEF reports at the navigation frequency - boolean setAutoNAVHPPOSECEF(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HPPOSECEF reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoNAVHPPOSECEFrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic HPPOSECEF reports - boolean setAutoNAVHPPOSECEFcallback(void (*callbackPointer)(UBX_NAV_HPPOSECEF_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic HPPOSECEF reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoNAVHPPOSECEF(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and HPPOSECEF is send cyclically already + bool getNAVHPPOSECEF(uint16_t maxWait = defaultMaxWait); // NAV HPPOSECEF + bool setAutoNAVHPPOSECEF(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HPPOSECEF reports at the navigation frequency + bool setAutoNAVHPPOSECEF(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HPPOSECEF reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoNAVHPPOSECEFrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic HPPOSECEF reports + bool setAutoNAVHPPOSECEFcallback(void (*callbackPointer)(UBX_NAV_HPPOSECEF_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic HPPOSECEF reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoNAVHPPOSECEF(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and HPPOSECEF is send cyclically already void flushNAVHPPOSECEF(); //Mark all the data as read/stale - void logNAVHPPOSECEF(boolean enabled = true); // Log data to file buffer + void logNAVHPPOSECEF(bool enabled = true); // Log data to file buffer - boolean getHPPOSLLH(uint16_t maxWait = defaultMaxWait); //Query module for latest group of datums and load global vars: lat, long, alt, speed, SIV, accuracies, etc. If autoPVT is disabled, performs an explicit poll and waits, if enabled does not block. Returns true if new HPPOSLLH is available. - boolean setAutoHPPOSLLH(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HPPOSLLH reports at the navigation frequency - boolean setAutoHPPOSLLH(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HPPOSLLH reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoHPPOSLLHrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic HPPOSLLH reports - boolean setAutoHPPOSLLHcallback(void (*callbackPointer)(UBX_NAV_HPPOSLLH_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic HPPOSLLH reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoHPPOSLLH(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and HPPOSLLH is send cyclically already + bool getHPPOSLLH(uint16_t maxWait = defaultMaxWait); //Query module for latest group of datums and load global vars: lat, long, alt, speed, SIV, accuracies, etc. If autoPVT is disabled, performs an explicit poll and waits, if enabled does not block. Returns true if new HPPOSLLH is available. + bool setAutoHPPOSLLH(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HPPOSLLH reports at the navigation frequency + bool setAutoHPPOSLLH(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HPPOSLLH reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoHPPOSLLHrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic HPPOSLLH reports + bool setAutoHPPOSLLHcallback(void (*callbackPointer)(UBX_NAV_HPPOSLLH_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic HPPOSLLH reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoHPPOSLLH(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and HPPOSLLH is send cyclically already void flushHPPOSLLH(); //Mark all the HPPPOSLLH data as read/stale. This is handy to get data alignment after CRC failure - void logNAVHPPOSLLH(boolean enabled = true); // Log data to file buffer + void logNAVHPPOSLLH(bool enabled = true); // Log data to file buffer - boolean getNAVCLOCK(uint16_t maxWait = defaultMaxWait); // NAV CLOCK - boolean setAutoNAVCLOCK(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic clock reports at the navigation frequency - boolean setAutoNAVCLOCK(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic clock reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoNAVCLOCKrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic CLOCK reports - boolean setAutoNAVCLOCKcallback(void (*callbackPointer)(UBX_NAV_CLOCK_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic CLOCK reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoNAVCLOCK(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and clock is send cyclically already + bool getNAVCLOCK(uint16_t maxWait = defaultMaxWait); // NAV CLOCK + bool setAutoNAVCLOCK(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic clock reports at the navigation frequency + bool setAutoNAVCLOCK(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic clock reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoNAVCLOCKrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic CLOCK reports + bool setAutoNAVCLOCKcallback(void (*callbackPointer)(UBX_NAV_CLOCK_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic CLOCK reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoNAVCLOCK(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and clock is send cyclically already void flushNAVCLOCK(); //Mark all the data as read/stale - void logNAVCLOCK(boolean enabled = true); // Log data to file buffer + void logNAVCLOCK(bool enabled = true); // Log data to file buffer // Add "auto" support for NAV SVIN - to avoid needing 'global' storage - boolean getSurveyStatus(uint16_t maxWait); //Reads survey in status + bool getSurveyStatus(uint16_t maxWait); //Reads survey in status // Add "auto" support for NAV TIMELS - to avoid needing 'global' storage - boolean getLeapSecondEvent(uint16_t maxWait); //Reads leap second event info + bool getLeapSecondEvent(uint16_t maxWait); //Reads leap second event info - boolean getRELPOSNED(uint16_t maxWait = defaultMaxWait); //Get Relative Positioning Information of the NED frame - boolean setAutoRELPOSNED(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic RELPOSNED reports - boolean setAutoRELPOSNED(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic RELPOSNED, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoRELPOSNEDrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic RELPOSNEDreports - boolean setAutoRELPOSNEDcallback(void (*callbackPointer)(UBX_NAV_RELPOSNED_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic RELPOSNED reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoRELPOSNED(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and RELPOSNED is send cyclically already + bool getRELPOSNED(uint16_t maxWait = defaultMaxWait); //Get Relative Positioning Information of the NED frame + bool setAutoRELPOSNED(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic RELPOSNED reports + bool setAutoRELPOSNED(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic RELPOSNED, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoRELPOSNEDrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic RELPOSNEDreports + bool setAutoRELPOSNEDcallback(void (*callbackPointer)(UBX_NAV_RELPOSNED_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic RELPOSNED reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoRELPOSNED(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and RELPOSNED is send cyclically already void flushNAVRELPOSNED(); //Mark all the data as read/stale - void logNAVRELPOSNED(boolean enabled = true); // Log data to file buffer + void logNAVRELPOSNED(bool enabled = true); // Log data to file buffer // Receiver Manager Messages (RXM) - boolean getRXMSFRBX(uint16_t maxWait = defaultMaxWait); // RXM SFRBX - boolean setAutoRXMSFRBX(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic RXM SFRBX reports at the navigation frequency - boolean setAutoRXMSFRBX(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic RXM SFRBX reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoRXMSFRBXrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic SFRBX reports - boolean setAutoRXMSFRBXcallback(void (*callbackPointer)(UBX_RXM_SFRBX_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic SFRBX reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoRXMSFRBX(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and RXM SFRBX is send cyclically already + bool getRXMSFRBX(uint16_t maxWait = defaultMaxWait); // RXM SFRBX + bool setAutoRXMSFRBX(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic RXM SFRBX reports at the navigation frequency + bool setAutoRXMSFRBX(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic RXM SFRBX reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoRXMSFRBXrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic SFRBX reports + bool setAutoRXMSFRBXcallback(void (*callbackPointer)(UBX_RXM_SFRBX_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic SFRBX reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoRXMSFRBX(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and RXM SFRBX is send cyclically already void flushRXMSFRBX(); //Mark all the data as read/stale - void logRXMSFRBX(boolean enabled = true); // Log data to file buffer + void logRXMSFRBX(bool enabled = true); // Log data to file buffer - boolean getRXMRAWX(uint16_t maxWait = defaultMaxWait); // RXM RAWX - boolean setAutoRXMRAWX(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic RXM RAWX reports at the navigation frequency - boolean setAutoRXMRAWX(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic RXM RAWX reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoRXMRAWXrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic RAWX reports - boolean setAutoRXMRAWXcallback(void (*callbackPointer)(UBX_RXM_RAWX_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic RAWX reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoRXMRAWX(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and RXM RAWX is send cyclically already + bool getRXMRAWX(uint16_t maxWait = defaultMaxWait); // RXM RAWX + bool setAutoRXMRAWX(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic RXM RAWX reports at the navigation frequency + bool setAutoRXMRAWX(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic RXM RAWX reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoRXMRAWXrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic RAWX reports + bool setAutoRXMRAWXcallback(void (*callbackPointer)(UBX_RXM_RAWX_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic RAWX reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoRXMRAWX(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and RXM RAWX is send cyclically already void flushRXMRAWX(); //Mark all the data as read/stale - void logRXMRAWX(boolean enabled = true); // Log data to file buffer + void logRXMRAWX(bool enabled = true); // Log data to file buffer // Configuration (CFG) // Add "auto" support for CFG RATE - because we use it for isConnected (to stop it being mugged by other messages) - boolean getNavigationFrequencyInternal(uint16_t maxWait = defaultMaxWait); //Get the number of nav solutions sent per second currently being output by module + bool getNavigationFrequencyInternal(uint16_t maxWait = defaultMaxWait); //Get the number of nav solutions sent per second currently being output by module // Timing messages (TIM) - boolean getTIMTM2(uint16_t maxWait = defaultMaxWait); // TIM TM2 - boolean setAutoTIMTM2(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic TIM TM2 reports at the navigation frequency - boolean setAutoTIMTM2(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic TIM TM2 reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoTIMTM2rate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic TIM TM2 reports - boolean setAutoTIMTM2callback(void (*callbackPointer)(UBX_TIM_TM2_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic TM2 reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoTIMTM2(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and TIM TM2 is send cyclically already + bool getTIMTM2(uint16_t maxWait = defaultMaxWait); // TIM TM2 + bool setAutoTIMTM2(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic TIM TM2 reports at the navigation frequency + bool setAutoTIMTM2(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic TIM TM2 reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoTIMTM2rate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic TIM TM2 reports + bool setAutoTIMTM2callback(void (*callbackPointer)(UBX_TIM_TM2_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic TM2 reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoTIMTM2(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and TIM TM2 is send cyclically already void flushTIMTM2(); //Mark all the data as read/stale - void logTIMTM2(boolean enabled = true); // Log data to file buffer + void logTIMTM2(bool enabled = true); // Log data to file buffer // Sensor fusion (dead reckoning) (ESF) - boolean getEsfAlignment(uint16_t maxWait = defaultMaxWait); // ESF ALG Helper - boolean getESFALG(uint16_t maxWait = defaultMaxWait); // ESF ALG - boolean setAutoESFALG(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF ALG reports - boolean setAutoESFALG(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF ALG reports, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoESFALGrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic ALG reports - boolean setAutoESFALGcallback(void (*callbackPointer)(UBX_ESF_ALG_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic ALG reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoESFALG(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and ESF ALG is send cyclically already + bool getEsfAlignment(uint16_t maxWait = defaultMaxWait); // ESF ALG Helper + bool getESFALG(uint16_t maxWait = defaultMaxWait); // ESF ALG + bool setAutoESFALG(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF ALG reports + bool setAutoESFALG(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF ALG reports, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoESFALGrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic ALG reports + bool setAutoESFALGcallback(void (*callbackPointer)(UBX_ESF_ALG_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic ALG reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoESFALG(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and ESF ALG is send cyclically already void flushESFALG(); //Mark all the data as read/stale - void logESFALG(boolean enabled = true); // Log data to file buffer + void logESFALG(bool enabled = true); // Log data to file buffer - boolean getEsfInfo(uint16_t maxWait = defaultMaxWait); // ESF STATUS Helper - boolean getESFSTATUS(uint16_t maxWait = defaultMaxWait); // ESF STATUS - boolean setAutoESFSTATUS(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF STATUS reports - boolean setAutoESFSTATUS(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF STATUS reports, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoESFSTATUSrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic STATUS reports - boolean setAutoESFSTATUScallback(void (*callbackPointer)(UBX_ESF_STATUS_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic STATUS reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoESFSTATUS(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and ESF STATUS is send cyclically already + bool getEsfInfo(uint16_t maxWait = defaultMaxWait); // ESF STATUS Helper + bool getESFSTATUS(uint16_t maxWait = defaultMaxWait); // ESF STATUS + bool setAutoESFSTATUS(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF STATUS reports + bool setAutoESFSTATUS(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF STATUS reports, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoESFSTATUSrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic STATUS reports + bool setAutoESFSTATUScallback(void (*callbackPointer)(UBX_ESF_STATUS_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic STATUS reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoESFSTATUS(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and ESF STATUS is send cyclically already void flushESFSTATUS(); //Mark all the data as read/stale - void logESFSTATUS(boolean enabled = true); // Log data to file buffer + void logESFSTATUS(bool enabled = true); // Log data to file buffer - boolean getEsfIns(uint16_t maxWait = defaultMaxWait); // ESF INS Helper - boolean getESFINS(uint16_t maxWait = defaultMaxWait); // ESF INS - boolean setAutoESFINS(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF INS reports - boolean setAutoESFINS(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF INS reports, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoESFINSrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic INS reports - boolean setAutoESFINScallback(void (*callbackPointer)(UBX_ESF_INS_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic INS reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoESFINS(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and ESF INS is send cyclically already + bool getEsfIns(uint16_t maxWait = defaultMaxWait); // ESF INS Helper + bool getESFINS(uint16_t maxWait = defaultMaxWait); // ESF INS + bool setAutoESFINS(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF INS reports + bool setAutoESFINS(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF INS reports, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoESFINSrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic INS reports + bool setAutoESFINScallback(void (*callbackPointer)(UBX_ESF_INS_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic INS reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoESFINS(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and ESF INS is send cyclically already void flushESFINS(); //Mark all the data as read/stale - void logESFINS(boolean enabled = true); // Log data to file buffer + void logESFINS(bool enabled = true); // Log data to file buffer - boolean getEsfDataInfo(uint16_t maxWait = defaultMaxWait); // ESF MEAS Helper - boolean getESFMEAS(uint16_t maxWait = defaultMaxWait); // ESF MEAS - boolean setAutoESFMEAS(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF MEAS reports - boolean setAutoESFMEAS(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF MEAS reports, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoESFMEASrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic MEAS reports - boolean setAutoESFMEAScallback(void (*callbackPointer)(UBX_ESF_MEAS_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic MEAS reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoESFMEAS(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and ESF MEAS is send cyclically already + bool getEsfDataInfo(uint16_t maxWait = defaultMaxWait); // ESF MEAS Helper + bool getESFMEAS(uint16_t maxWait = defaultMaxWait); // ESF MEAS + bool setAutoESFMEAS(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF MEAS reports + bool setAutoESFMEAS(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF MEAS reports, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoESFMEASrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic MEAS reports + bool setAutoESFMEAScallback(void (*callbackPointer)(UBX_ESF_MEAS_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic MEAS reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoESFMEAS(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and ESF MEAS is send cyclically already void flushESFMEAS(); //Mark all the data as read/stale - void logESFMEAS(boolean enabled = true); // Log data to file buffer + void logESFMEAS(bool enabled = true); // Log data to file buffer - boolean getEsfRawDataInfo(uint16_t maxWait = defaultMaxWait); // ESF RAW Helper - boolean getESFRAW(uint16_t maxWait = defaultMaxWait); // ESF RAW - boolean setAutoESFRAW(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF RAW reports - boolean setAutoESFRAW(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF RAW reports, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoESFRAWrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic RAW reports - boolean setAutoESFRAWcallback(void (*callbackPointer)(UBX_ESF_RAW_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic RAW reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoESFRAW(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and ESF RAW is send cyclically already + bool getEsfRawDataInfo(uint16_t maxWait = defaultMaxWait); // ESF RAW Helper + bool getESFRAW(uint16_t maxWait = defaultMaxWait); // ESF RAW + bool setAutoESFRAW(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF RAW reports + bool setAutoESFRAW(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic ESF RAW reports, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoESFRAWrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic RAW reports + bool setAutoESFRAWcallback(void (*callbackPointer)(UBX_ESF_RAW_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic RAW reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoESFRAW(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and ESF RAW is send cyclically already void flushESFRAW(); //Mark all the data as read/stale - void logESFRAW(boolean enabled = true); // Log data to file buffer + void logESFRAW(bool enabled = true); // Log data to file buffer // High navigation rate (HNR) - boolean getHNRAtt(uint16_t maxWait = defaultMaxWait); // HNR ATT Helper - boolean getHNRATT(uint16_t maxWait = defaultMaxWait); // Returns true if the get HNR attitude is successful - boolean setAutoHNRATT(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HNR Attitude reports at the HNR rate - boolean setAutoHNRATT(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HNR Attitude reports at the HNR rate, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoHNRATTrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic ATT reports - boolean setAutoHNRATTcallback(void (*callbackPointer)(UBX_HNR_ATT_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic ATT reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoHNRATT(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and HNR Attitude is send cyclically already + bool getHNRAtt(uint16_t maxWait = defaultMaxWait); // HNR ATT Helper + bool getHNRATT(uint16_t maxWait = defaultMaxWait); // Returns true if the get HNR attitude is successful + bool setAutoHNRATT(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HNR Attitude reports at the HNR rate + bool setAutoHNRATT(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HNR Attitude reports at the HNR rate, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoHNRATTrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic ATT reports + bool setAutoHNRATTcallback(void (*callbackPointer)(UBX_HNR_ATT_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic ATT reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoHNRATT(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and HNR Attitude is send cyclically already void flushHNRATT(); //Mark all the data as read/stale - void logHNRATT(boolean enabled = true); // Log data to file buffer + void logHNRATT(bool enabled = true); // Log data to file buffer - boolean getHNRDyn(uint16_t maxWait = defaultMaxWait); // HNR INS Helper - boolean getHNRINS(uint16_t maxWait = defaultMaxWait); // Returns true if the get HNR dynamics is successful - boolean setAutoHNRINS(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HNR dynamics reports at the HNR rate - boolean setAutoHNRINS(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HNR dynamics reports at the HNR rate, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoHNRINSrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic INS reports - boolean setAutoHNRINScallback(void (*callbackPointer)(UBX_HNR_INS_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic INS reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoHNRINS(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and HNR dynamics is send cyclically already + bool getHNRDyn(uint16_t maxWait = defaultMaxWait); // HNR INS Helper + bool getHNRINS(uint16_t maxWait = defaultMaxWait); // Returns true if the get HNR dynamics is successful + bool setAutoHNRINS(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HNR dynamics reports at the HNR rate + bool setAutoHNRINS(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HNR dynamics reports at the HNR rate, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoHNRINSrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic INS reports + bool setAutoHNRINScallback(void (*callbackPointer)(UBX_HNR_INS_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic INS reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoHNRINS(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and HNR dynamics is send cyclically already void flushHNRINS(); //Mark all the data as read/stale - void logHNRINS(boolean enabled = true); // Log data to file buffer + void logHNRINS(bool enabled = true); // Log data to file buffer - boolean getHNRPVT(uint16_t maxWait = defaultMaxWait); // Returns true if the get HNR PVT is successful - boolean setAutoHNRPVT(boolean enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HNR PVT reports at the HNR rate - boolean setAutoHNRPVT(boolean enabled, boolean implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HNR PVT reports at the HNR rate, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update - boolean setAutoHNRPVTrate(uint8_t rate, boolean implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic PVT reports - boolean setAutoHNRPVTcallback(void (*callbackPointer)(UBX_HNR_PVT_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic PVT reports at the navigation frequency. Data is accessed from the callback. - boolean assumeAutoHNRPVT(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and HNR PVT is send cyclically already + bool getHNRPVT(uint16_t maxWait = defaultMaxWait); // Returns true if the get HNR PVT is successful + bool setAutoHNRPVT(bool enabled, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HNR PVT reports at the HNR rate + bool setAutoHNRPVT(bool enabled, bool implicitUpdate, uint16_t maxWait = defaultMaxWait); //Enable/disable automatic HNR PVT reports at the HNR rate, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update + bool setAutoHNRPVTrate(uint8_t rate, bool implicitUpdate = true, uint16_t maxWait = defaultMaxWait); //Set the rate for automatic PVT reports + bool setAutoHNRPVTcallback(void (*callbackPointer)(UBX_HNR_PVT_data_t), uint16_t maxWait = defaultMaxWait); //Enable automatic PVT reports at the navigation frequency. Data is accessed from the callback. + bool assumeAutoHNRPVT(bool enabled, bool implicitUpdate = true); //In case no config access to the GPS is possible and HNR PVT is send cyclically already void flushHNRPVT(); //Mark all the data as read/stale - void logHNRPVT(boolean enabled = true); // Log data to file buffer + void logHNRPVT(bool enabled = true); // Log data to file buffer // Helper functions for NMEA logging void setNMEALoggingMask(uint32_t messages = SFE_UBLOX_FILTER_NMEA_ALL); // Add selected NMEA messages to file buffer - if enabled. Default to adding ALL messages to the file buffer @@ -1064,11 +1064,11 @@ public: // Helper functions for CFG RATE - boolean setNavigationFrequency(uint8_t navFreq, uint16_t maxWait = defaultMaxWait); //Set the number of nav solutions sent per second + bool setNavigationFrequency(uint8_t navFreq, uint16_t maxWait = defaultMaxWait); //Set the number of nav solutions sent per second uint8_t getNavigationFrequency(uint16_t maxWait = defaultMaxWait); //Get the number of nav solutions sent per second currently being output by module - boolean setMeasurementRate(uint16_t rate, uint16_t maxWait = defaultMaxWait); //Set the elapsed time between GNSS measurements in milliseconds, which defines the rate + bool setMeasurementRate(uint16_t rate, uint16_t maxWait = defaultMaxWait); //Set the elapsed time between GNSS measurements in milliseconds, which defines the rate uint16_t getMeasurementRate(uint16_t maxWait = defaultMaxWait); //Return the elapsed time between GNSS measurements in milliseconds - boolean setNavigationRate(uint16_t rate, uint16_t maxWait = defaultMaxWait); //Set the ratio between the number of measurements and the number of navigation solutions. Unit is cycles. Max is 127 + bool setNavigationRate(uint16_t rate, uint16_t maxWait = defaultMaxWait); //Set the ratio between the number of measurements and the number of navigation solutions. Unit is cycles. Max is 127 uint16_t getNavigationRate(uint16_t maxWait = defaultMaxWait); //Return the ratio between the number of measurements and the number of navigation solutions. Unit is cycles void flushCFGRATE(); // Mark the measurement and navigation rate data as stale - used by the set rate functions @@ -1159,8 +1159,8 @@ public: // Helper functions for SVIN - boolean getSurveyInActive(uint16_t maxWait = defaultMaxWait); - boolean getSurveyInValid(uint16_t maxWait = defaultMaxWait); + bool getSurveyInActive(uint16_t maxWait = defaultMaxWait); + bool getSurveyInValid(uint16_t maxWait = defaultMaxWait); uint16_t getSurveyInObservationTime(uint16_t maxWait = defaultMaxWait); // Truncated to 65535 seconds float getSurveyInMeanAccuracy(uint16_t maxWait = defaultMaxWait); // Returned as m @@ -1183,16 +1183,16 @@ public: float getESFroll(uint16_t maxWait = defaultMaxWait); // Returned as degrees float getESFpitch(uint16_t maxWait = defaultMaxWait); // Returned as degrees float getESFyaw(uint16_t maxWait = defaultMaxWait); // Returned as degrees - boolean getSensorFusionMeasurement(UBX_ESF_MEAS_sensorData_t *sensorData, uint8_t sensor, uint16_t maxWait = defaultMaxWait); - boolean getSensorFusionMeasurement(UBX_ESF_MEAS_sensorData_t *sensorData, UBX_ESF_MEAS_data_t ubxDataStruct, uint8_t sensor); - boolean getRawSensorMeasurement(UBX_ESF_RAW_sensorData_t *sensorData, uint8_t sensor, uint16_t maxWait = defaultMaxWait); - boolean getRawSensorMeasurement(UBX_ESF_RAW_sensorData_t *sensorData, UBX_ESF_RAW_data_t ubxDataStruct, uint8_t sensor); - boolean getSensorFusionStatus(UBX_ESF_STATUS_sensorStatus_t *sensorStatus, uint8_t sensor, uint16_t maxWait = defaultMaxWait); - boolean getSensorFusionStatus(UBX_ESF_STATUS_sensorStatus_t *sensorStatus, UBX_ESF_STATUS_data_t ubxDataStruct, uint8_t sensor); + bool getSensorFusionMeasurement(UBX_ESF_MEAS_sensorData_t *sensorData, uint8_t sensor, uint16_t maxWait = defaultMaxWait); + bool getSensorFusionMeasurement(UBX_ESF_MEAS_sensorData_t *sensorData, UBX_ESF_MEAS_data_t ubxDataStruct, uint8_t sensor); + bool getRawSensorMeasurement(UBX_ESF_RAW_sensorData_t *sensorData, uint8_t sensor, uint16_t maxWait = defaultMaxWait); + bool getRawSensorMeasurement(UBX_ESF_RAW_sensorData_t *sensorData, UBX_ESF_RAW_data_t ubxDataStruct, uint8_t sensor); + bool getSensorFusionStatus(UBX_ESF_STATUS_sensorStatus_t *sensorStatus, uint8_t sensor, uint16_t maxWait = defaultMaxWait); + bool getSensorFusionStatus(UBX_ESF_STATUS_sensorStatus_t *sensorStatus, UBX_ESF_STATUS_data_t ubxDataStruct, uint8_t sensor); // Helper functions for HNR - boolean setHNRNavigationRate(uint8_t rate, uint16_t maxWait = 1100); // Returns true if the setHNRNavigationRate is successful + bool setHNRNavigationRate(uint8_t rate, uint16_t maxWait = 1100); // Returns true if the setHNRNavigationRate is successful uint8_t getHNRNavigationRate(uint16_t maxWait = 1100); // Returns 0 if the getHNRNavigationRate fails float getHNRroll(uint16_t maxWait = defaultMaxWait); // Returned as degrees float getHNRpitch(uint16_t maxWait = defaultMaxWait); // Returned as degrees @@ -1270,11 +1270,11 @@ private: } commType = COMM_TYPE_I2C; //Controls which port we look to for incoming bytes //Functions - boolean checkUbloxInternal(ubxPacket *incomingUBX, uint8_t requestedClass = 255, uint8_t requestedID = 255); //Checks module with user selected commType + bool checkUbloxInternal(ubxPacket *incomingUBX, uint8_t requestedClass = 255, uint8_t requestedID = 255); //Checks module with user selected commType void addToChecksum(uint8_t incoming); //Given an incoming byte, adjust rollingChecksumA/B //Return true if this "automatic" message has storage allocated for it - boolean checkAutomatic(uint8_t Class, uint8_t ID); + bool checkAutomatic(uint8_t Class, uint8_t ID); //Calculate how much RAM is needed to store the payload for a given automatic message uint16_t getMaxPayloadSize(uint8_t Class, uint8_t ID); @@ -1282,37 +1282,37 @@ private: //Do the actual transfer to SPI void spiTransfer(uint8_t byteToTransfer); - boolean initGeofenceParams(); // Allocate RAM for currentGeofenceParams and initialize it - boolean initModuleSWVersion(); // Allocate RAM for moduleSWVersion and initialize it + bool initGeofenceParams(); // Allocate RAM for currentGeofenceParams and initialize it + bool initModuleSWVersion(); // Allocate RAM for moduleSWVersion and initialize it // The initPacket functions need to be private as they don't check if memory has already been allocated. // Functions like setAutoNAVPOSECEF will check that memory has not been allocated before calling initPacket. - boolean initPacketUBXNAVPOSECEF(); // Allocate RAM for packetUBXNAVPOSECEF and initialize it - boolean initPacketUBXNAVSTATUS(); // Allocate RAM for packetUBXNAVSTATUS and initialize it - boolean initPacketUBXNAVDOP(); // Allocate RAM for packetUBXNAVDOP and initialize it - boolean initPacketUBXNAVATT(); // Allocate RAM for packetUBXNAVATT and initialize it - boolean initPacketUBXNAVPVT(); // Allocate RAM for packetUBXNAVPVT and initialize it - boolean initPacketUBXNAVODO(); // Allocate RAM for packetUBXNAVODO and initialize it - boolean initPacketUBXNAVVELECEF(); // Allocate RAM for packetUBXNAVVELECEF and initialize it - boolean initPacketUBXNAVVELNED(); // Allocate RAM for packetUBXNAVVELNED and initialize it - boolean initPacketUBXNAVHPPOSECEF(); // Allocate RAM for packetUBXNAVHPPOSECEF and initialize it - boolean initPacketUBXNAVHPPOSLLH(); // Allocate RAM for packetUBXNAVHPPOSLLH and initialize it - boolean initPacketUBXNAVCLOCK(); // Allocate RAM for packetUBXNAVCLOCK and initialize it - boolean initPacketUBXNAVTIMELS(); // Allocate RAM for packetUBXNAVTIMELS and initialize it - boolean initPacketUBXNAVSVIN(); // Allocate RAM for packetUBXNAVSVIN and initialize it - boolean initPacketUBXNAVRELPOSNED(); // Allocate RAM for packetUBXNAVRELPOSNED and initialize it - boolean initPacketUBXRXMSFRBX(); // Allocate RAM for packetUBXRXMSFRBX and initialize it - boolean initPacketUBXRXMRAWX(); // Allocate RAM for packetUBXRXMRAWX and initialize it - boolean initPacketUBXCFGRATE(); // Allocate RAM for packetUBXCFGRATE and initialize it - boolean initPacketUBXTIMTM2(); // Allocate RAM for packetUBXTIMTM2 and initialize it - boolean initPacketUBXESFALG(); // Allocate RAM for packetUBXESFALG and initialize it - boolean initPacketUBXESFSTATUS(); // Allocate RAM for packetUBXESFSTATUS and initialize it - boolean initPacketUBXESFINS(); // Allocate RAM for packetUBXESFINS and initialize it - boolean initPacketUBXESFMEAS(); // Allocate RAM for packetUBXESFMEAS and initialize it - boolean initPacketUBXESFRAW(); // Allocate RAM for packetUBXESFRAW and initialize it - boolean initPacketUBXHNRATT(); // Allocate RAM for packetUBXHNRATT and initialize it - boolean initPacketUBXHNRINS(); // Allocate RAM for packetUBXHNRINS and initialize it - boolean initPacketUBXHNRPVT(); // Allocate RAM for packetUBXHNRPVT and initialize it + bool initPacketUBXNAVPOSECEF(); // Allocate RAM for packetUBXNAVPOSECEF and initialize it + bool initPacketUBXNAVSTATUS(); // Allocate RAM for packetUBXNAVSTATUS and initialize it + bool initPacketUBXNAVDOP(); // Allocate RAM for packetUBXNAVDOP and initialize it + bool initPacketUBXNAVATT(); // Allocate RAM for packetUBXNAVATT and initialize it + bool initPacketUBXNAVPVT(); // Allocate RAM for packetUBXNAVPVT and initialize it + bool initPacketUBXNAVODO(); // Allocate RAM for packetUBXNAVODO and initialize it + bool initPacketUBXNAVVELECEF(); // Allocate RAM for packetUBXNAVVELECEF and initialize it + bool initPacketUBXNAVVELNED(); // Allocate RAM for packetUBXNAVVELNED and initialize it + bool initPacketUBXNAVHPPOSECEF(); // Allocate RAM for packetUBXNAVHPPOSECEF and initialize it + bool initPacketUBXNAVHPPOSLLH(); // Allocate RAM for packetUBXNAVHPPOSLLH and initialize it + bool initPacketUBXNAVCLOCK(); // Allocate RAM for packetUBXNAVCLOCK and initialize it + bool initPacketUBXNAVTIMELS(); // Allocate RAM for packetUBXNAVTIMELS and initialize it + bool initPacketUBXNAVSVIN(); // Allocate RAM for packetUBXNAVSVIN and initialize it + bool initPacketUBXNAVRELPOSNED(); // Allocate RAM for packetUBXNAVRELPOSNED and initialize it + bool initPacketUBXRXMSFRBX(); // Allocate RAM for packetUBXRXMSFRBX and initialize it + bool initPacketUBXRXMRAWX(); // Allocate RAM for packetUBXRXMRAWX and initialize it + bool initPacketUBXCFGRATE(); // Allocate RAM for packetUBXCFGRATE and initialize it + bool initPacketUBXTIMTM2(); // Allocate RAM for packetUBXTIMTM2 and initialize it + bool initPacketUBXESFALG(); // Allocate RAM for packetUBXESFALG and initialize it + bool initPacketUBXESFSTATUS(); // Allocate RAM for packetUBXESFSTATUS and initialize it + bool initPacketUBXESFINS(); // Allocate RAM for packetUBXESFINS and initialize it + bool initPacketUBXESFMEAS(); // Allocate RAM for packetUBXESFMEAS and initialize it + bool initPacketUBXESFRAW(); // Allocate RAM for packetUBXESFRAW and initialize it + bool initPacketUBXHNRATT(); // Allocate RAM for packetUBXHNRATT and initialize it + bool initPacketUBXHNRINS(); // Allocate RAM for packetUBXHNRINS and initialize it + bool initPacketUBXHNRPVT(); // Allocate RAM for packetUBXHNRPVT and initialize it //Variables TwoWire *_i2cPort; //The generic connection to user's chosen I2C hardware @@ -1327,10 +1327,10 @@ private: uint8_t _gpsI2Caddress = 0x42; //Default 7-bit unshifted address of the ublox 6/7/8/M8/F9 series //This can be changed using the ublox configuration software - boolean _printDebug = false; //Flag to print the serial commands we are sending to the Serial port for debug - boolean _printLimitedDebug = false; //Flag to print limited debug messages. Useful for I2C debugging or high navigation rates + bool _printDebug = false; //Flag to print the serial commands we are sending to the Serial port for debug + bool _printLimitedDebug = false; //Flag to print limited debug messages. Useful for I2C debugging or high navigation rates - boolean ubx7FcheckDisabled = false; // Flag to indicate if the "7F" check should be ignored in checkUbloxI2C + bool ubx7FcheckDisabled = false; // Flag to indicate if the "7F" check should be ignored in checkUbloxI2C sfe_ublox_nmea_filtering_t _logNMEA; // Flags to indicate which NMEA messages should be added to the file buffer for logging sfe_ublox_nmea_filtering_t _processNMEA; // Flags to indicate which NMEA messages should be passed to processNMEA @@ -1354,7 +1354,7 @@ private: ubxPacket packetAuto = {0, 0, 0, 0, 0, payloadAuto, 0, 0, SFE_UBLOX_PACKET_VALIDITY_NOT_DEFINED, SFE_UBLOX_PACKET_VALIDITY_NOT_DEFINED}; //Flag if this packet is unrequested (and so should be ignored and not copied into packetCfg or packetAck) - boolean ignoreThisPayload = false; + bool ignoreThisPayload = false; //Identify which buffer is in use //Data is stored in packetBuf until the requested class and ID can be validated @@ -1384,14 +1384,14 @@ private: // The user can adjust maxNMEAByteCount by calling setMaxNMEAByteCount int8_t maxNMEAByteCount = SFE_UBLOX_MAX_NMEA_BYTE_COUNT; uint8_t nmeaAddressField[6]; // NMEA Address Field - includes the start character (*) - boolean logThisNMEA(); // Return true if we should log this NMEA message - boolean processThisNMEA(); // Return true if we should pass this NMEA message to processNMEA + bool logThisNMEA(); // Return true if we should log this NMEA message + bool processThisNMEA(); // Return true if we should pass this NMEA message to processNMEA uint16_t rtcmLen = 0; // Flag to prevent reentry into checkCallbacks // Prevent badness if the user accidentally calls checkCallbacks from inside a callback - volatile boolean checkCallbacksReentrant = false; + volatile bool checkCallbacksReentrant = false; // Support for data logging uint8_t *ubxFileBuffer = NULL; // Pointer to the file buffer. RAM is allocated for this if required in .begin @@ -1399,20 +1399,20 @@ private: uint16_t fileBufferHead; // The incoming byte is written into the file buffer at this location uint16_t fileBufferTail; // The next byte to be read from the buffer will be read from this location uint16_t fileBufferMaxAvail = 0; // The maximum number of bytes the file buffer has contained. Handy for checking the buffer is large enough to handle all the incoming data. - boolean createFileBuffer(void); // Create the file buffer. Called by .begin + bool createFileBuffer(void); // Create the file buffer. Called by .begin uint16_t fileBufferSpaceAvailable(void); // Check how much space is available in the buffer uint16_t fileBufferSpaceUsed(void); // Check how much space is used in the buffer - boolean storePacket(ubxPacket *msg); // Add a UBX packet to the file buffer - boolean storeFileBytes(uint8_t *theBytes, uint16_t numBytes); // Add theBytes to the file buffer + bool storePacket(ubxPacket *msg); // Add a UBX packet to the file buffer + bool storeFileBytes(uint8_t *theBytes, uint16_t numBytes); // Add theBytes to the file buffer void writeToFileBuffer(uint8_t *theBytes, uint16_t numBytes); // Write theBytes to the file buffer // Support for platforms like ESP32 which do not support multiple I2C restarts // If _i2cStopRestart is true, endTransmission will always use a stop. If false, a restart will be used where needed. // The default value for _i2cStopRestart is set in the class instantiation code. - boolean _i2cStopRestart; + bool _i2cStopRestart; // Storage just in case the user tries to push a single byte using pushRawBytes - boolean _pushSingleByte = false; + bool _pushSingleByte = false; uint8_t _pushThisSingleByte; }; diff --git a/src/u-blox_structs.h b/src/u-blox_structs.h index 8f39453..94431cf 100644 --- a/src/u-blox_structs.h +++ b/src/u-blox_structs.h @@ -1097,7 +1097,7 @@ typedef struct { ubxAutomaticFlags automaticFlags; UBX_RXM_SFRBX_data_t data; - boolean moduleQueried; + bool moduleQueried; void (*callbackPointer)(UBX_RXM_SFRBX_data_t); UBX_RXM_SFRBX_data_t *callbackData; } UBX_RXM_SFRBX_t; @@ -1164,7 +1164,7 @@ typedef struct { ubxAutomaticFlags automaticFlags; UBX_RXM_RAWX_data_t data; - boolean moduleQueried; + bool moduleQueried; void (*callbackPointer)(UBX_RXM_RAWX_data_t); UBX_RXM_RAWX_data_t *callbackData; } UBX_RXM_RAWX_t;