Utilities API Functions¶
The code for this module is contained in source/stl_util.c and
source/stl_util_s.asm, with include/stl_util.h containing
the API declarations for use by applications.
Module Details¶
-
group
stl_util -
Enums
-
enum
STL_Util_ErrorFlag¶ Values to be passed to STL_Util_setErrorFlag() and STL_Util_clearErrorFlag(). These correspond to different errors in the STL.
Values:
-
STL_UTIL_CRC= 0x00000001UL¶ CRC check.
-
STL_UTIL_CPU_REG= 0x00000002UL¶ CPU register test.
-
STL_UTIL_FPU_REG= 0x00000004UL¶ FPU register test.
-
STL_UTIL_VCRC_REG= 0x00000008UL¶ VCRC register test.
-
STL_UTIL_PIE_RAM_MISMATCH= 0x00000010UL¶ PIE RAM.
-
STL_UTIL_PIE_RAM_INT= 0x00000020UL¶ PIE RAM handler failed to execute.
-
STL_UTIL_OSC_TIMER2= 0x00000040UL¶ OSC timer 2.
-
STL_UTIL_OSC_HR_MEP_RANGE= 0x00000080UL¶ MEP out of range.
-
STL_UTIL_OSC_HR_SFO= 0x00000100UL¶ SFO calibration error.
-
STL_UTIL_OSC_HR_DELAY= 0x00000200UL¶ SFO delay error.
-
STL_UTIL_MARCH= 0x00000400UL¶ March RAM test.
-
STL_UTIL_CAN_RAM_PARITY= 0x00000800UL¶ March test for CAN message RAM.
-
STL_UTIL_MCAN_RAM_ECC= 0x00010000UL¶ March test for MCAN message RAM.
-
STL_UTIL_HWBIST_NMI_TEST= 0x00001000UL¶ HWBIST NMI test.
-
STL_UTIL_HWBIST_FAIL= 0x00002000UL¶ HWBIST fail.
-
STL_UTIL_HWBIST_NMI_INT= 0x00004000UL¶ HWBIST NMI interrupt.
-
STL_UTIL_HWBIST_OVERRUN= 0x00008000UL¶ HWBIST over-run.
-
STL_UTIL_ALL_ERRORS= 0xFFFFFFFFUL¶
-
Functions
-
static void
STL_Util_delayUS(uint32_t microseconds)¶ Delay for a specified number of microseconds
This function calls SysCtl_delay() to achieve a delay in microseconds. The function will convert the desired delay in microseconds to the count value expected by the function.
microseconds is the number of microseconds to delay.- Parameters
microseconds: is the number of microseconds to delay.
- Note
If this function does not get inlined (for instance, if the optimizer is turned off) the delay will be made less accurate by the overhead of the additional function call.
- Return
None.
-
void
STL_Util_setErrorFlag(const STL_Util_ErrorFlag errorFlag)¶ Sets a global error flag.
This function sets an error flag in the global globalErrorFlags.
- Parameters
errorFlag: is a STL_Util_ErrorFlag that will be set in globalErrorFlags.
- Return
None.
-
uint32_t
STL_Util_getErrorFlag(void)¶ Gets the error flag status of globalErrorFlags.
This function returns the global globalErrorFlags.
- Return
Returns the global globalErrorFlags.
-
void
STL_Util_clearErrorFlag(const STL_Util_ErrorFlag errorFlag)¶ Clears a flag of globalErrorFlags.
This function clears a flag of globalErrorFlags.
- Parameters
errorFlag: is a STL_Util_ErrorFlag that will be cleared in globalErrorFlags.
- Return
None.
-
enum