flip_store_storage.h 780 B

123456789101112131415161718192021222324252627282930
  1. #ifndef FLIP_STORE_STORAGE_H
  2. #define FLIP_STORE_STORAGE_H
  3. #include <furi.h>
  4. #include <storage/storage.h>
  5. #include <flip_store.h>
  6. #define SETTINGS_PATH STORAGE_EXT_PATH_PREFIX "/apps_data/flip_store/settings.bin"
  7. #define BUFFER_SIZE 64
  8. #define MAX_KEY_LENGTH 16
  9. #define MAX_VALUE_LENGTH 100
  10. void save_settings(
  11. const char *ssid,
  12. const char *password);
  13. bool load_settings(
  14. char *ssid,
  15. size_t ssid_size,
  16. char *password,
  17. size_t password_size);
  18. bool delete_app(const char *app_id, const char *app_category);
  19. bool app_exists(const char *app_id, const char *app_category);
  20. // Function to parse JSON incrementally from a file
  21. bool parse_json_incrementally(const char *file_path, const char *target_key, char *value_buffer, size_t value_buffer_size);
  22. #endif