nRF5 SDK for Mesh v5.0.0
Macros

Flash Manager definitions. More...

Macros

#define FLASH_MANAGER_DATA_PER_PAGE   (PAGE_SIZE - sizeof(flash_manager_metadata_t))
 Number of bytes of data one could fit on a single flash page.
 
#define FLASH_MANAGER_PAGE_COUNT_MINIMUM(DATA_SIZE, LARGEST_ENTRY_SIZE)   (1 + ((DATA_SIZE) / (FLASH_MANAGER_DATA_PER_PAGE - LARGEST_ENTRY_SIZE)))
 Minimum number of pages required to store the given amount of data. More...
 
#define FLASH_MANAGER_HANDLE_MAX   (0x7EFF)
 Highest handle number allowed. More...
 
#define FLASH_MANAGER_HANDLE_INVALID   (0x0000)
 Invalid handle. More...
 
#define FLASH_MANAGER_ENTRY_LEN_OVERHEAD   (sizeof(fm_header_t) / WORD_SIZE)
 Overhead in each entry's len field for the header. More...
 

Detailed Description

Flash Manager definitions.

Macro Definition Documentation

◆ FLASH_MANAGER_PAGE_COUNT_MINIMUM

#define FLASH_MANAGER_PAGE_COUNT_MINIMUM (   DATA_SIZE,
  LARGEST_ENTRY_SIZE 
)    (1 + ((DATA_SIZE) / (FLASH_MANAGER_DATA_PER_PAGE - LARGEST_ENTRY_SIZE)))

Minimum number of pages required to store the given amount of data.

Note
As we'll pad a page if the current page can't fit a new entry, we have to assume the worst case in this calculation, which is that the largest possible entry is added at the end of every page without fitting.

Definition at line 74 of file flash_manager.h.

◆ FLASH_MANAGER_HANDLE_MAX

#define FLASH_MANAGER_HANDLE_MAX   (0x7EFF)

Highest handle number allowed.

Definition at line 76 of file flash_manager.h.

◆ FLASH_MANAGER_HANDLE_INVALID

#define FLASH_MANAGER_HANDLE_INVALID   (0x0000)

Invalid handle.

Definition at line 77 of file flash_manager.h.

◆ FLASH_MANAGER_ENTRY_LEN_OVERHEAD

#define FLASH_MANAGER_ENTRY_LEN_OVERHEAD   (sizeof(fm_header_t) / WORD_SIZE)

Overhead in each entry's len field for the header.

Definition at line 79 of file flash_manager.h.


Documentation feedback | Developer Zone | Subscribe | Updated