Settings: Add preliminary functions to store Claibration data on SD Card. Not yet implemented correctly

This commit is contained in:
2020-08-16 01:24:20 +02:00
parent e7d150e8f5
commit 3c6200e08c
4 changed files with 102 additions and 3 deletions

View File

@@ -21,4 +21,8 @@
#ifndef __SETTINGS_SETTINGS_SD_CARD_H__
#define __SETTINGS_SETTINGS_SD_CARD_H__
#define CALIBRATION_FILE_NAME "cal.toml"
int sd_card_settings_save_calibration(float sens_deviation, float offset);
#endif /* __SETTINGS_SETTINGS_SD_CARD_H__ */

View File

@@ -22,6 +22,12 @@
#ifndef __SETTINGS_SETTINGS_H__
#define __SETTINGS_SETTINGS_H__
int settings_save_calibration();
/**
* @brief Save the calibration
* @param sens_deviation
* @param offset
* @return 0 if successful, -1 if generic error, -2 if medium unavailable
*/
int settings_save_calibration(float sens_deviation, float offset);
#endif /* __SETTINGS_SETTINGS_H__ */