15 #ifndef Z1_COAP_STORE_H
16 #define Z1_COAP_STORE_H
21 #include "settings.pb.h"
22 #include "readings.pb.h"
104 #endif // ifndef Z1_COAP_STORE_H
bool store_get_latest_sample(Sample *sample)
Get the most recent sample from the flash.
bool store_save_config(SensorConfig *config)
Save the configuration to flash.
bool store_get_config(SensorConfig *config)
Get the configuration from the flash.
uint8_t store_get_raw_sample(uint16_t id, uint8_t buffer[Sample_size])
Get a given sample from the flash, in the form of an encoded protocol buffer.
uint16_t store_save_sample(Sample *sample)
Store a sample in the flash.
bool store_get_sample(uint16_t id, Sample *sample)
Get a given sample from the flash,.
bool store_delete_sample(uint16_t id)
Delete a given sample from the flash.
void store_init(void)
Initialize the data store.
uint8_t store_get_raw_config(uint8_t buffer[SensorConfig_size])
Get the configuration from the flash.
uint8_t store_get_latest_raw_sample(uint8_t buffer[Sample_size])
Get the most recent sample from the flash, in the form of an encoded protocol buffer.
uint16_t store_get_latest_sample_id(void)
Get the identifer of the most recent sample stored.