distortos
v0.7.0
object-oriented C++ RTOS for microcontrollers
|
assertHook() header More...
Go to the source code of this file.
Functions | |
void | assertHook (const char *file, int line, const char *function, const char *failedExpression) |
Hook function called on failed assertion. More... | |
assertHook() header
void assertHook | ( | const char * | file, |
int | line, | ||
const char * | function, | ||
const char * | failedExpression | ||
) |
Hook function called on failed assertion.
This function is called at the beginning of __assert_func() when an assertion fails. It may be used to put the system into a safe state, log the failure, reset the device, etc. After this function returns, the system is halted by calling abort() with masked interrupts.
[in] | file | is a null-terminated string with the name of file in which assertion failed |
[in] | line | is a line number at which assertion failed |
[in] | function | is a null-terminated string with function in which assertion failed |
[in] | failedExpression | is a null-terminated string with the failed assert expression |