hrvach / deskhop

Fast Desktop Switching Device
GNU General Public License v3.0
6.14k stars 173 forks source link

Suggestion: configuration file #72

Closed p3lim closed 3 months ago

p3lim commented 6 months ago

Instead of hard-coding options, requiring a recompile and "flash" for every change, use the RPI ROM to store a configuration file that the firmware reads on boot (or on a keybind to reload).

Would be extra nice if this could be mounted without interrupting the normal behavior, e.g. we could edit this file using the keyboard/mouse attached to it and then trigger a reload.

I've seen other firmware do things like this with the RP2040, KMK comes to mind.

hrvach commented 6 months ago

This is actually done, there is a configuration file stored in the last flash block, saving border switching details and some other things (order of outputs, which OS is an output connected to etc).

It's not a text config but a struct with some checksum data, etc. I opted out of uploading a traditional config file because implementing usb storage is potentially problematic from a security / data protection standpoint. Some options that currently need a rebuild to change will get keyboard config support.

hrvach commented 3 months ago

This is mostly addressed in the upcoming (alpha) release with a web UI. Most things don't need a recompile anymore...