10.6.3.2.10 Function nvm_get_error()

Retrieves the error code of the last issued NVM operation.

enum nvm_error nvm_get_error( void )

Retrieves the error code from the last executed NVM operation. Once retrieved, any error state flags in the controller are cleared.

Note: The nvm_is_ready() function is an exception. Thus, errors retrieved after running this function should be valid for the function executed before nvm_is_ready().

Returns

Error caused by the last NVM operation.

Table 10-25. Return Values
Return valueDescription

NVM_ERROR_NONE

No error occurred in the last NVM operation

NVM_ERROR_LOCK

The last NVM operation attempted to access a locked region

NVM_ERROR_PROG

An invalid NVM command was issued