Safecast / onyxfirmware

20 stars 8 forks source link

need way to persist settings accross firmware updates #4

Open thinrope opened 11 years ago

thinrope commented 11 years ago

The simplest will be to always:

  1. download all settings
  2. flash firmware
  3. upload all settings

Alternatively, not all flash should be cleared, although this approach tends to create havoc. cmd_keyvaldump seems a good candidate for 1

A good thing to have will be a command util to connect to the serial and download/upload settings to/from a file as key=val.

new299 commented 11 years ago

Yes, I wouldn't want keyvals to persist on the device. The keyvaldump command is implemented to allow this to be implemented in the firmware loaders at a later date. User facing Windows and Mac firmware loaders are available here: https://github.com/new299/onyxloader

LucidOne commented 11 years ago

Following the principle of least astonishment, KEYVALDUMP should still return the default values if nothing is set.

thinrope commented 11 years ago

OK, now I see what you meant in issue #17... Yes, it should always return current (then) values.

To make things simple, I'd suggest having a config file with all settings described and on firmware compile those are read by the Makefile (similar to RELEASENUMBER) and get rid of literal DEFINEs in the code.