AP_GPS: Added const just to be explicit (NFC)
Signed-off-by: Dr.-Ing. Amilcar Do Carmo Lucas <amilcar.lucas@iav.de>
This commit is contained in:
parent
175b7c5389
commit
8b9fb19061
@ -403,7 +403,7 @@ void AP_GPS::detect_instance(uint8_t instance)
|
||||
{
|
||||
AP_GPS_Backend *new_gps = nullptr;
|
||||
struct detect_state *dstate = &detect_state[instance];
|
||||
uint32_t now = AP_HAL::millis();
|
||||
const uint32_t now = AP_HAL::millis();
|
||||
|
||||
state[instance].status = NO_GPS;
|
||||
state[instance].hdop = GPS_UNKNOWN_DOP;
|
||||
@ -612,7 +612,7 @@ void AP_GPS::update_instance(uint8_t instance)
|
||||
|
||||
// we have an active driver for this instance
|
||||
bool result = drivers[instance]->read();
|
||||
uint32_t tnow = AP_HAL::millis();
|
||||
const uint32_t tnow = AP_HAL::millis();
|
||||
|
||||
// if we did not get a message, and the idle timer of 2 seconds
|
||||
// has expired, re-initialise the GPS. This will cause GPS
|
||||
@ -786,7 +786,7 @@ void AP_GPS::setHIL(uint8_t instance, GPS_Status _status, uint64_t time_epoch_ms
|
||||
if (instance >= GPS_MAX_RECEIVERS) {
|
||||
return;
|
||||
}
|
||||
uint32_t tnow = AP_HAL::millis();
|
||||
const uint32_t tnow = AP_HAL::millis();
|
||||
GPS_State &istate = state[instance];
|
||||
istate.status = _status;
|
||||
istate.location = _location;
|
||||
@ -951,7 +951,7 @@ uint8_t AP_GPS::first_unconfigured_gps(void) const
|
||||
|
||||
void AP_GPS::broadcast_first_configuration_failure_reason(void) const
|
||||
{
|
||||
uint8_t unconfigured = first_unconfigured_gps();
|
||||
const uint8_t unconfigured = first_unconfigured_gps();
|
||||
if (drivers[unconfigured] == nullptr) {
|
||||
gcs().send_text(MAV_SEVERITY_INFO, "GPS %d: was not found", unconfigured + 1);
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user