V1.7
This commit is contained in:
@ -4,6 +4,9 @@
|
||||
#include "stm32f3xx_hal.h"
|
||||
|
||||
#include <stdint.h>
|
||||
#include <main.h>
|
||||
#include "AMS_HighLevel.h"
|
||||
#include "errors.h"
|
||||
|
||||
__attribute__((packed)) typedef struct {
|
||||
uint8_t id;
|
||||
@ -13,5 +16,8 @@ extern EEPROMConfig eeprom_config;
|
||||
|
||||
void eeprom_init(I2C_HandleTypeDef* hi2c);
|
||||
void eeprom_config_save();
|
||||
void eeprom_write_status();
|
||||
void eeprom_read(int8_t* data);
|
||||
void eeprom_write(uint8_t* data, uint8_t data_length);
|
||||
|
||||
#endif // INC_EEPROM_H_
|
||||
|
||||
19
Core/Inc/soc_estimation.h
Normal file
19
Core/Inc/soc_estimation.h
Normal file
@ -0,0 +1,19 @@
|
||||
#ifndef INC_SOC_ESTIMATION_H
|
||||
#define INC_SOC_ESTIMATION_H
|
||||
|
||||
#include <stdint.h>
|
||||
#include <main.h>
|
||||
|
||||
extern float current_soc;
|
||||
|
||||
void soc_init();
|
||||
void soc_update();
|
||||
|
||||
typedef struct {
|
||||
uint16_t ocv;
|
||||
float soc;
|
||||
} ocv_soc_pair_t;
|
||||
extern ocv_soc_pair_t OCV_SOC_PAIRS[];
|
||||
float soc_for_ocv(uint16_t ocv);
|
||||
|
||||
#endif // INC_SOC_ESTIMATION_H
|
||||
Reference in New Issue
Block a user