cleanup some of the parameter group code and add support for reset
commit9f4e94063cf65ad3600d9783b57de50aa0450f0a
authorDominic Clifton <me@dominicclifton.name>
Sun, 3 Apr 2016 15:42:52 +0000 (3 17:42 +0200)
committerDominic Clifton <me@dominicclifton.name>
Sun, 3 Apr 2016 15:47:53 +0000 (3 17:47 +0200)
tree042551ba6d4b8166ba8393d0ef08c9807808ea17
parent30c0909ccec2cf955ae39e66e10ba3fa028a65b3
cleanup some of the parameter group code and add support for reset
callback functions working examples for system, system arrays and
profiles in config_eeprom_unittest.

some of the macro code could likely be deduplicated.

de-duplicated some of the loadPg / pgLoad code and ensured that all pg's
are reset prior to being loaded via pgResetInstance.

The pgReset_*() methods are declared via the PG_* macros to help detect
linker errors when the user-defined reset methods don't match
expectations.
src/main/config/config_eeprom.c
src/main/config/parameter_group.c
src/main/config/parameter_group.h
src/main/config/parameter_group_ids.h
src/main/io/serial_msp.c
src/test/unit/config_eeprom_unittest.cc