PX4/Firmware — pull request #874 by jean-m-cyr (2014-04-28 04:58:53+00:00)
Title: Proper data manager restart handling

Introduce SYS_RESTART_TYPE parameter having one of 3 values: power on restart, inflight restart, or unknown restart, and defaulting to unknown restart.

px4io.cpp sets this parameter according to the type of restart detected.

All data manager items specify a persistence level when they are written. At startup dataman.c retrieves this parameter and clears data entries according to their persistence level. Does nothing if unknown restart. Not sure how px4fmu only controller deals with restarts but it should perhaps also set the SYS_RESTART_TYPE parameter. Presently it does not so the data manager will handle restarts as unknown.