DevGuide/Settings
Jump to navigation
Jump to search
Settings is the generic mechanism that allows to get/set the value of any variable of the embedded code.
Overview
Problem Statement
Given an embedded program in C, we want a way to set/get the value of any variable without having to write any ad-hoc code.
- The variable can be of any base type (e.g. uint16, int32, float) or a structured type (not implemented yet).
- The variable can be directly accessed (declared in a header) or used through a pair of accessors (e.g. SetVar/GetVar).
- Typically the variable is manipulated through a graphical user interface on the ground station.
- The graphical interface can manipulate the variable in a different unit (e.g. the embedded code uses a binary fixed point representation)
Solution
The solution used in Paparazzi consist in describing the variables in a high level xml file, which is then processed to generate embedded code and used by the graphical user interface to display the suitable controls.