1.8.19.4 SEFCx_PageWrite Function

C

bool SEFCx_PageWrite( uint32_t* data, uint32_t address ) // x - Instance of the SEFC peripheral

Summary

Writes data of size equivalent to page size to a given FLASH address.

Description

This function takes a 32-bit address, a pointer to data of size equivalent to page size and writes it to the given location in FLASH memory.

Precondition

Validate if SEFCx controller is ready to accept new request by calling SEFCx_IsBusy() The Page to be written should be in Erased State.

Parameters

Param Description
address FLASH address to be modified
data pointer to data buffer

Returns

Always returns true.

Example

SEFC0_PageWrite( (uint32_t *) buffer, 0x500000);

while(SEFC0_IsBusy());

Remarks

Application needs to poll for busy bit or wait for callback to be called before sending next request.