Files CCore/inc/sys/SysAbort.h CCore/src/sys/SysAbort.cpp
This part provides a target dependent abort functions Abort(). Calling one of these functions stop the board (and may hold or reset it). This function is a 0-priority function. I.e. if it is required some initialization, it must be done using the CCORE_INITPRI_0 priority qualifier. But normally these functions are provided by the STD core and not required additional initialization.
#ifndef CCore_inc_sys_SysAbort_h
#define CCore_inc_sys_SysAbort_h
#include <CCore/inc/Gadget.h>
namespace CCore {
namespace Sys {
/* functions */
void Abort(StrLen str);
void Abort(const char *zstr);
} // namespace Sys
} // namespace CCore
#endif
The STD implementation is
#include <CCore/inc/sys/SysAbort.h>
#include <__std_init.h>
namespace CCore {
namespace Sys {
/* functions */
void Abort(StrLen str)
{
__std_abort2(str.ptr,str.len);
}
void Abort(const char *zstr)
{
__std_abort(zstr);
}
} // namespace Sys
} // namespace CCore