Skip to content

Commit

Permalink
small changes
Browse files Browse the repository at this point in the history
  • Loading branch information
MatthewKuKanich committed Apr 19, 2024
1 parent 7a9e122 commit 5f260af
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 11 deletions.
1 change: 0 additions & 1 deletion applications/system/findmy/findmy_i.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ struct FindMy {

uint8_t mac_buf[EXTRA_BEACON_MAC_ADDR_SIZE];
uint8_t packet_buf[EXTRA_BEACON_MAX_DATA_SIZE];
uint8_t battery_level;

FindMyState state;
};
Expand Down
10 changes: 0 additions & 10 deletions applications/system/findmy/findmy_state.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,6 @@ bool findmy_state_load(FindMyState* out_state) {
}
state.tag_type = tmp;

if(!flipper_format_read_uint32(file, "battery_level", &tmp, 1)) {
tmp = 0x00; // Default battery level set to Full
flipper_format_rewind(file);
}
FURI_LOG_I("findmy_load", "Saved Battery: %ld", tmp);
state.battery_level = tmp;

if(!flipper_format_read_hex(file, "mac", state.mac, sizeof(state.mac))) break;

if(!flipper_format_read_hex(
Expand Down Expand Up @@ -171,9 +164,6 @@ void findmy_state_save(FindMyState* state) {
tmp = state->tag_type;
if(!flipper_format_write_uint32(file, "tag_type", &tmp, 1)) break;

tmp = state->battery_level;
if(!flipper_format_write_uint32(file, "battery_level", &tmp, 1)) break;

if(!flipper_format_write_bool(file, "show_mac", &state->show_mac, 1)) break;

if(!flipper_format_write_hex(file, "mac", state->mac, sizeof(state->mac))) break;
Expand Down

0 comments on commit 5f260af

Please sign in to comment.