diff --git a/libraries/AP_InertialSensor/BatchSampler.cpp b/libraries/AP_InertialSensor/BatchSampler.cpp index 0da3f31bb5..6f0eed83eb 100644 --- a/libraries/AP_InertialSensor/BatchSampler.cpp +++ b/libraries/AP_InertialSensor/BatchSampler.cpp @@ -56,7 +56,7 @@ void AP_InertialSensor::BatchSampler::init() _required_count -= _required_count % 32; // round down to nearest multiple of 32 const uint32_t total_allocation = 3*_required_count*sizeof(uint16_t); - gcs().send_text(MAV_SEVERITY_DEBUG, "INS: alloc %u bytes for ISB (free=%u)", total_allocation, hal.util->available_memory()); + gcs().send_text(MAV_SEVERITY_DEBUG, "INS: alloc %u bytes for ISB (free=%u)", (unsigned int)total_allocation, (unsigned int)hal.util->available_memory()); data_x = (int16_t*)calloc(_required_count, sizeof(int16_t)); data_y = (int16_t*)calloc(_required_count, sizeof(int16_t)); @@ -68,7 +68,7 @@ void AP_InertialSensor::BatchSampler::init() data_x = nullptr; data_y = nullptr; data_z = nullptr; - gcs().send_text(MAV_SEVERITY_WARNING, "Failed to allocate %u bytes for IMU batch sampling", total_allocation); + gcs().send_text(MAV_SEVERITY_WARNING, "Failed to allocate %u bytes for IMU batch sampling", (unsigned int)total_allocation); return; }