Speeduino
Loading...
Searching...
No Matches
Functions
Page save & load

Functions to save & load "pages" to/from durable storage. More...

Functions

void saveAllPages (void)
 Write all pages from RAM to durable storage.
 
void savePage (uint8_t pageNum)
 Write one page from RAM to durable storage.
 
void loadAllPages (void)
 Load all pages from durable storage. I.e. load the tune.
 
bool isEepromWritePending (void)
 Do we have page data that needs to be written to durable storage?
 
void setEepromWritePending (bool isPending)
 Set or clear the Write Pending flag.
 

Detailed Description

Functions to save & load "pages" to/from durable storage.

A "page" is a TunerStudio concept: they are defined in the project ini file. It's basically the tune, minus calibration tables.

Function Documentation

◆ isEepromWritePending()

bool isEepromWritePending ( void  )

Do we have page data that needs to be written to durable storage?

Returns
true Page data needs to be written
false Nothing needs to be written

◆ loadAllPages()

void loadAllPages ( void  )

Load all pages from durable storage. I.e. load the tune.

◆ saveAllPages()

void saveAllPages ( void  )

Write all pages from RAM to durable storage.

Note that this might not save everything due to write throttling. Callers can keep calling this function until isEepromWritePending returns false.

◆ savePage()

void savePage ( uint8_t  pageNum)

Write one page from RAM to durable storage.

Note that this might not save everything due to write throttling. Callers can keep calling this function until isEepromWritePending returns false.

◆ setEepromWritePending()

void setEepromWritePending ( bool  isPending)

Set or clear the Write Pending flag.

Parameters
isPendingTrue if data needs to be written, false otherwise.