Microchip® Advanced Software Framework

pal_flash.h File Reference

Flash writting support functionality.

Id:
pal_flash.h 26812 2011-05-23 08:27:09Z pawan.jadia
Author
Microchip Technology Inc: http://www.microchip.com
Support: https://www.microchip.com/support/

Functions

void flash_fill_page_buffer (uint16_t start_offset, uint16_t length, uint8_t *data)
 Writes data to flash location. More...
 
void flash_program_page (uint32_t page_start_addr)
 Writes the actual flash page. More...
 
void flash_swap (uint32_t image_start_addr, uint32_t image_size)
 Swaps the firmware image. More...
 

Variables

void noinline
 

void flash_fill_page_buffer ( uint16_t  start_offset,
uint16_t  length,
uint8_t *  data 
)

Writes data to flash location.

Parameters
start_offsetOffset of start address
lengthNumber of bytes to write
dataPointer to data location Fills the temporary page buffer

This function fills the temporay flash page buffer.

Parameters
start_offsetOffset of start address
lengthLength of provide data buffer
dataPointer to data buffer

Referenced by flash_write().

void flash_program_page ( uint32_t  page_start_addr)

Writes the actual flash page.

This function writes the data from the temporary flash page buffer to the actual flash page.

Parameters
page_start_addrStart address of the flash page

Referenced by flash_write().

void flash_swap ( uint32_t  image_start_addr,
uint32_t  image_size 
)

Swaps the firmware image.

This function swapes the image with the current application program.

Parameters
image_start_addrStart address of the image within the flash
image_sizeSize of the firmware image

void noinline