← All tools

Message & Error Explainer

What an ArduPilot message means and what to do about it

Українська

The flight log cannot be written

Stops itLogging and storage

What ArduPilot says:

Logging is on (LOG_BACKEND_TYPE) and the logger says it cannot write. With an SD card: opening a log file failed within the last 5 seconds, the last write failed, or the logging thread has stopped. With a flash chip: it was not found or is full. ArduPilot will not fly without the log you would need after a crash. A missing card normally shows as “Logging failed”, because that test comes first; “No SD card” means the same.

What to do, most likely first

  1. There is no SD card, or it is not pushed in all the way.

    FixInsert a card and reboot.

  2. The card cannot be read or written: wrong format, worn out, or a fake.

    CheckPut it in a computer: there should be an APM folder with a LOGS folder in it, and the newest files should open.

    FixFormat it as FAT32 on a computer, or replace it with a good brand-name card of 32 GB or less. If a good card fails only on this board, try BRD_SD_SLOWDOWN 1 or 2.

  3. LOG_BACKEND_TYPE asks for logging over MAVLink, and no ground station is taking the log.

    FixSet LOG_BACKEND_TYPE to your board's default: 1 for an SD card, 4 for a flash chip.

  4. The board logs to a flash chip, and it is full.

    FixDownload the logs you want to keep, then erase them all from the ground station's log screen.

With LOG_DISARMED 0 (the default) nothing is written before arming, so a missing card is often noticed only at that moment, as “Arm: Logging not started”.

Parameters to look at

ParameterWhat it is
LOG_BACKEND_TYPEAP_Logger Backend Storage type
LOG_DISARMEDEnable logging while disarmed
LOG_FILE_MB_FREEOld logs on the SD card will be deleted to maintain this amount of free space
BRD_SD_SLOWDOWNmicroSD slowdown
The code that sends it

PreArm: No SD card

libraries/AP_Arming/AP_Arming.cpp AP_Arming::logging_checks() · Open in ArduPilot Copter-4.7.1

PreArm: Logging failed

libraries/AP_Arming/AP_Arming.cpp AP_Arming::logging_checks() · Open in ArduPilot Copter-4.7.1

Written here for Copter 4.6. In the tool you choose your vehicle and version, see your own parameter values beside the ones named here, and drop a flight log to have every message in it explained.

Open it in the Message & Error Explainer