Initial commit

This commit is contained in:
Yury Shuvakin
2022-11-12 23:42:55 +03:00
parent 9a18b5d8e7
commit 190522943f
228 changed files with 141037 additions and 0 deletions

View File

@@ -0,0 +1,25 @@
#ifndef __DRIVERSWSTORAGEMANAGER_H
#define __DRIVERSWSTORAGEMANAGER_H
#include "stdint.h"
#include "stdbool.h"
#include "driverHWEEPROM.h"
extern bool driverSWStorageManagerConfigEmpty;
extern bool driverSWStorageManagerStateOfChargeEmpty;
extern uint16_t driverSWStorageManagerConfigStructSize;
extern uint16_t driverSWStorageManagerStateOfChargeStructSize;
typedef enum {
STORAGE_CONFIG = 0,
STORAGE_STATEOFCHARGE,
} StorageLocationTypedef;
void driverSWStorageManagerInit(void);
bool driverSWStorageManagerEraseData(void);
bool driverSWStorageManagerStoreStruct(void *configStruct, StorageLocationTypedef storageLocation);
bool driverSWStorageManagerGetStruct(void *configStruct, StorageLocationTypedef storageLocation);
uint16_t driverSWStorageManagerGetOffsetFromLocation(StorageLocationTypedef storageLocation);
uint16_t driverSWStorageManagerGetStructSize(StorageLocationTypedef storageLocation);
#endif