#include <nitro/os.h>
u32 OS_GetResetParameter( void );
None.
The value of the reset parameter. This function returns 0 from the time that power is turned on until the OS_ResetSystem
function is called.
This function acquires the value of the reset parameter. The reset parameter is the value that is provided by the parameter argument of the most recent
function. This function returns 0 from the time that power is turned on until the OS_ResetSystem
OS_ResetSystem
function is called.
Example:
In the above example, 0 will be displayed first. Then each reset will display 1, 2, 3 ....u32 n;
NitroMain()
{
:
n = OS_GetResetParameter();
OS_Printf( "%d\n", n );
:
OS_ResetSystem( n + 1 );
}
The reset parameter is held in the 4-byte region that comes after HW_RESET_PARAMETER_BUF
. The 4-byte region is placed in the system shared region and is not cleared by a reset. This function reads and returns the value in this region.
09/01/2004 Initial Version