esp_flash_os_functions_t struct
OS-level integration hooks for accessing flash chips inside a running OS It's in the public header because some instances should be allocated statically in the startup code. May be updated according to hardware version and new flash chip feature requirements, shouldn't be treated as public API. For advanced developers, you may replace some of them with your implementations at your own risk.
Fields
Called before commencing any flash operation. Does not need to be recursive (ie is called at most once for each call to 'end').
Called after completing any flash operation.
esp_err_t (*)(void* arg, size_t start_addr, size_t size) Called before any erase/write operations to check whether the region is limited by the OS.
Delay for at least 'us' microseconds. Called in between 'start' and 'end'.
void *(*)(void* arg, size_t reqest_size, size_t* out_size)
Called for get temp buffer when buffer from application cannot be directly read into/write from.
void (*)(void* arg, void *temp_buf)
Called for release temp buffer.
esp_err_t (*)(void *arg, uint32_t chip_status, uint32_t* out_request) Yield to other tasks. Called during erase operations.
esp_err_t (*)(void *arg, uint32_t* out_status) Yield to other tasks. Called during erase operations.
Called for get system time.
void (*)(uint32_t op_status)
Call to set flash operation status.
![]()
typedef struct {