a25a1a61d0
Add freestanding S25FL256S read/program/erase/verify support and seed a newly formatted ephemeris store with stale records. Age-gate navigation readiness, persist the continuous Toe week, and regenerate the Genesys2 MAX2771 integration and flash image.
23 lines
716 B
C
23 lines
716 B
C
#ifndef BSP_SPI_FLASH_H
|
|
#define BSP_SPI_FLASH_H
|
|
|
|
#include <stdbool.h>
|
|
#include <stdint.h>
|
|
|
|
#define BSP_SPI_FLASH_SIZE 0x02000000UL
|
|
#define BSP_SPI_FLASH_PAGE_SIZE 256UL
|
|
#define BSP_SPI_FLASH_SECTOR_SIZE 0x00010000UL
|
|
#define BSP_SPI_FLASH_JEDEC_ID 0x00010219UL
|
|
#define BSP_SPI_FLASH_CONFIG_TBPARM (1u << 2)
|
|
|
|
void bsp_spi_flash_init(void);
|
|
void bsp_spi_flash_reset(void);
|
|
uint32_t bsp_spi_flash_read_id(void);
|
|
uint8_t bsp_spi_flash_read_status(void);
|
|
uint8_t bsp_spi_flash_read_config(void);
|
|
void bsp_spi_flash_read(uint32_t flash_addr, void *dst, uint32_t len);
|
|
bool bsp_spi_flash_erase_sector(uint32_t flash_addr);
|
|
bool bsp_spi_flash_program(uint32_t flash_addr, const void *src, uint32_t len);
|
|
|
|
#endif
|