diff options
Diffstat (limited to 'components/wisp_relay/flash_monitor.h')
| -rw-r--r-- | components/wisp_relay/flash_monitor.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/components/wisp_relay/flash_monitor.h b/components/wisp_relay/flash_monitor.h new file mode 100644 index 0000000..86f1b53 --- /dev/null +++ b/components/wisp_relay/flash_monitor.h | |||
| @@ -0,0 +1,16 @@ | |||
| 1 | #ifndef FLASH_MONITOR_H | ||
| 2 | #define FLASH_MONITOR_H | ||
| 3 | |||
| 4 | #include <stdint.h> | ||
| 5 | #include <stddef.h> | ||
| 6 | |||
| 7 | typedef struct { | ||
| 8 | size_t total_bytes; | ||
| 9 | size_t used_bytes; | ||
| 10 | size_t free_bytes; | ||
| 11 | float usage_percent; | ||
| 12 | } flash_health_t; | ||
| 13 | |||
| 14 | void flash_get_health(const char *partition_label, flash_health_t *health); | ||
| 15 | |||
| 16 | #endif | ||