From 3e3f539a6a9f5f6ee75534d669fd2b49a040d61e Mon Sep 17 00:00:00 2001 From: Michael du Breuil Date: Tue, 6 Sep 2016 00:16:01 -0700 Subject: [PATCH] AP_GPS: Raise target baud of u-blox devices A knockon effect is that we need less config strings as raw logging on u-blox will use the same baud rates --- libraries/AP_GPS/AP_GPS.cpp | 7 +------ libraries/AP_GPS/AP_GPS_UBLOX.h | 3 +-- 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/libraries/AP_GPS/AP_GPS.cpp b/libraries/AP_GPS/AP_GPS.cpp index 06a0cf658b..ddf5c94597 100644 --- a/libraries/AP_GPS/AP_GPS.cpp +++ b/libraries/AP_GPS/AP_GPS.cpp @@ -161,7 +161,6 @@ const uint32_t AP_GPS::_baudrates[] = {4800U, 19200U, 38400U, 115200U, 57600U, 9 // initialisation blobs to send to the GPS to try to get it into the // right mode const char AP_GPS::_initialisation_blob[] = UBLOX_SET_BINARY MTK_SET_BINARY SIRF_SET_BINARY; -const char AP_GPS::_initialisation_raw_blob[] = UBLOX_SET_BINARY_RAW_BAUD MTK_SET_BINARY SIRF_SET_BINARY; /* send some more initialisation string bytes if there is room in the @@ -268,11 +267,7 @@ AP_GPS::detect_instance(uint8_t instance) _port[instance]->begin(baudrate); _port[instance]->set_flow_control(AP_HAL::UARTDriver::FLOW_CONTROL_DISABLE); dstate->last_baud_change_ms = now; -#if UBLOX_RXM_RAW_LOGGING - if(_raw_data != 0) - send_blob_start(instance, _initialisation_raw_blob, sizeof(_initialisation_raw_blob)); - else -#endif + if(_auto_config == 1){ send_blob_start(instance, _initialisation_blob, sizeof(_initialisation_blob)); } diff --git a/libraries/AP_GPS/AP_GPS_UBLOX.h b/libraries/AP_GPS/AP_GPS_UBLOX.h index aa16e90ebd..1ebc28c0a7 100644 --- a/libraries/AP_GPS/AP_GPS_UBLOX.h +++ b/libraries/AP_GPS/AP_GPS_UBLOX.h @@ -38,8 +38,7 @@ * modules are configured with all ubx binary messages off, which * would mean we would never detect it. */ -#define UBLOX_SET_BINARY "\265\142\006\001\003\000\001\006\001\022\117$PUBX,41,1,0003,0001,38400,0*26\r\n" -#define UBLOX_SET_BINARY_RAW_BAUD "\265\142\006\001\003\000\001\006\001\022\117$PUBX,41,1,0003,0001,115200,0*1E\r\n" +#define UBLOX_SET_BINARY "\265\142\006\001\003\000\001\006\001\022\117$PUBX,41,1,0003,0001,115200,0*1E\r\n" #define UBLOX_RXM_RAW_LOGGING 1 #define UBLOX_MAX_RXM_RAW_SATS 22