FlashBootloader Core

Description

Interface to internal flash.

Used for writing application images to the main flash.

Macros

#define SL_GBL_MSC_LDMA_CHANNEL   2
 DMA Channel for MSC write.
 

Functions

bool flash_erasePage (uint32_t address)
 
bool flash_writeBuffer_dma (uint32_t address, void *data, size_t length, int ch)
 
bool flash_writeBuffer (uint32_t address, void *data, size_t length)
 

Function Documentation

bool flash_erasePage ( uint32_t  address)

Erase a flash page

Parameters
[in]addressStart address of the flash page to erase.
Returns
True if operation was successful
bool flash_writeBuffer_dma ( uint32_t  address,
void *  data,
size_t  length,
int  ch 
)

Write buffer to internal flash

Parameters
addressStarting address to write data to. Must be half-word aligned.
dataData buffer to write to internal flash
lengthAmount of bytes in the data buffer to write
chDMA channel to use
Returns
True if operation was successful
bool flash_writeBuffer ( uint32_t  address,
void *  data,
size_t  length 
)

Write buffer to internal flash

Parameters
addressStarting address to write data to. Must be half-word aligned.
dataData buffer to write to internal flash
lengthAmount of bytes in the data buffer to write
Returns
True if operation was successful