FindMy: Fix battery level edge cases (eg. at boot) and cleanup

- Generate config struct only when necessary
- Centralize last few things to use state values
- Uniform state apply and save process
- Simplify battery level handling
This commit is contained in:
Willy-JL
2024-05-02 06:46:06 +01:00
parent f3c1c09e39
commit ff2bb16492
9 changed files with 61 additions and 118 deletions

View File

@@ -54,4 +54,3 @@ void findmy_change_transmit_power(FindMy* app, uint8_t value);
void findmy_toggle_show_mac(FindMy* app, bool show_mac);
void findmy_set_tag_type(FindMy* app, FindMyType type);
void findmy_toggle_beacon(FindMy* app);
void findmy_state_save_and_apply(FindMy* app, FindMyState* state);