This repository has been archived on 2025-01-02. You can view files and clone it, but cannot push or open issues or pull requests.
torsion/User/system/bsp/eeprom.h

15 lines
705 B
C

#ifndef __EEPROM_H__
#define __EEPROM_H__
#include "lib.h"
/*
FALSH : bank1 0x0800 0000 - 0x0800 FFFF
bank2 0x0801 0000 - 0x0801 FFFF
EEPROM : bank1 0x0808 0000 - 0x0808 0BFF
bank2 0x0808 0C00 - 0x0808 17FF
6 Kbytes of data EEPROM with ECC
在写入EEPROM 的时候,如果发生了串口中断,那么就很容易出问题
*/
extern void chip_eeprom_config_read(uint32_t read_addr, uint8_t *data, uint16_t length); // 读取数据
extern void chip_eeprom_config_write(uint32_t write_addr, uint8_t *data, uint16_t length); // 写入数据
#endif // __EEPROM_H__