| 941 | |
| 942 | static const uint32_t FOOTER_MAGIC = 0xd2f1e365; |
| 943 | bool save_empty() |
| 944 | { |
| 945 | |
| 946 | ConfigFooter *footer = reinterpret_cast<ConfigFooter *>(EEPROM.writeCache + EEPROM_SIZE_BYTES - sizeof(ConfigFooter)); |
| 947 | |
| 948 | footer->dataSize = 0; |
| 949 | footer->mainSize = 0; |
| 950 | footer->auxSize = 0; |
| 951 | footer->dataCrc = CRC32::calculate(EEPROM.writeCache, 0); |
| 952 | footer->magic = FOOTER_MAGIC; |
| 953 | footer->currentProfile = 0; |
| 954 | EEPROM.commit_now(); |
| 955 | return true; |
| 956 | } |
| 957 | |
| 958 | bool decode_cycle_input_states(pb_istream_t *stream, const pb_field_t *field, void **arg) |
| 959 | { |