1.15.12.7 NVM_IsBusy Function

C

bool NVM_IsBusy( void )

Summary

Returns the current status of NVM controller.

Description

This function returns the busy status of the NVM Controller. This function should be called to check for module readiness before initiating a Erase or a Write operation. The controller becomes busy on a NVM Write, Erase. Once initiated, this function can be called to poll the completion of the Erase or Write operation.

This function can be used as an alternative to the callback function. In that, the application can call this function periodically to check for operation completion instead of waiting for callback to be called.

Precondition

None.

Parameters

None

Returns

true - NVM controller is busy.

false - NVM controller is ready for a new operation.

Example

// Erase the row. This will erase all the pages in the row.
NVM_PageErase(0x9D100000);
while(NVM_IsBusy());

// Now write the page.
NVM_RowWrite((uint32_t *)buffer, 0x9D100000);
while(NVM_IsBusy());

Remarks

None