LP-173 Initialize all settings objects automatically

Merged
#467 · Created  · Last updated

Merged pull request

Merged in mindnever/librepilot/LP-173-Init_all_settings_objects_automatically (pull request #467)

754eca9·Author: ·Closed by: ·2017-10-29

Description

This PR fixes LP-173 and also other instances where settings being saved from GCS are unitialized. (autotune module, txpid, etc..).

It adds new pios_initcall that handles settings objects (ones marked with settings="true" in xml) initialization in similar way modules are done.

uavobject.c.template is modified so it marks *Initialize() function as initcall.

pios_board files are doing SETTINGS_INITIALISE_ALL; because it needs to be done just after settings storage has been initialized, but before first settings is used (usually Hw*Settings).

And finally, all explicit calls to *SettingsInitialize() are removed as redundant.

About the memory issue: The impact on F4 targets is negligible. However on F1 and F3, memory footprint is significantly increased, not only because of memory required for objects data storage, but even more is consumed by telemetry module and memory inefficient way of registering periodic updates (both telemetry & logging). Therefore, LP-432 is required to offset for increased usage.

0 attachments

0 comments

Loading commits...