17 #if !defined(PLATFORM_IS_EVB_2) 19 #include "IS_internal.h" 21 #include "../../../hdw-src/uINS-3/IS_uINS/src/misc/debug_gpio.h" 33 const char *
const pcName,
34 unsigned short usStackDepth,
68 #if (configGENERATE_RUN_TIME_STATS == 1) 70 float fTotalRunTime = ((float)ulTotalRunTime) * 1e-2;
71 #endif // (configGENERATE_RUN_TIME_STATS == 1) 75 for (i=0; i<numRtosTasks; i++)
88 #if (configGENERATE_RUN_TIME_STATS == 1) 118 #if !defined(PLATFORM_IS_EVB_2) 151 #if defined(PLATFORM_IS_EVB_2) || defined(DEBUG) 168 #if defined(PLATFORM_IS_EVB_2) || defined(DEBUG) 198 #if defined(PLATFORM_IS_EVB_2) || defined(DEBUG) 213 #if defined(PLATFORM_IS_EVB_2) || defined(DEBUG) 228 #if defined(PLATFORM_IS_EVB_2) || defined(DEBUG) 245 #pragma GCC push_options 246 #pragma GCC optimize ("O0") 250 #if defined(PLATFORM_IS_EVB_2) || defined(DEBUG) 264 " ldr r1, [r0, #24] \n" 265 " ldr r2, handler_address_const_hard_fault \n" 267 " handler_address_const_hard_fault: .word prvGetRegistersFromStack \n" 287 void HardFault_HandlerC(
unsigned long *hardfault_args){
288 volatile unsigned long stacked_r0;
289 volatile unsigned long stacked_r1;
290 volatile unsigned long stacked_r2;
291 volatile unsigned long stacked_r3;
292 volatile unsigned long stacked_r12;
293 volatile unsigned long stacked_lr;
294 volatile unsigned long stacked_pc;
295 volatile unsigned long stacked_psr;
296 volatile unsigned long _CFSR;
297 volatile unsigned long _HFSR;
298 volatile unsigned long _DFSR;
299 volatile unsigned long _AFSR;
300 volatile unsigned long _BFAR;
301 volatile unsigned long _MMAR;
303 stacked_r0 = ((
unsigned long)hardfault_args[0]);
304 stacked_r1 = ((
unsigned long)hardfault_args[1]);
305 stacked_r2 = ((
unsigned long)hardfault_args[2]);
306 stacked_r3 = ((
unsigned long)hardfault_args[3]);
307 stacked_r12 = ((
unsigned long)hardfault_args[4]);
308 stacked_lr = ((
unsigned long)hardfault_args[5]);
309 stacked_pc = ((
unsigned long)hardfault_args[6]);
310 stacked_psr = ((
unsigned long)hardfault_args[7]);
314 _CFSR = (*((
volatile unsigned long *)(0xE000ED28)));
317 _HFSR = (*((
volatile unsigned long *)(0xE000ED2C)));
320 _DFSR = (*((
volatile unsigned long *)(0xE000ED30)));
323 _AFSR = (*((
volatile unsigned long *)(0xE000ED3C)));
328 _MMAR = (*((
volatile unsigned long *)(0xE000ED34)));
330 _BFAR = (*((
volatile unsigned long *)(0xE000ED38)));
349 " ldr r1,[r0,#20] \n" 350 " b HardFault_HandlerC\n" 358 #pragma GCC pop_options 365 volatile uint8_t* ptr = (
volatile uint8_t*)0x30000000;
366 volatile uint8_t val = *ptr;
370 typedef void (*t_funcPtr)(void);
371 t_funcPtr MyFunc = (t_funcPtr)(0x0001000 | 0x0);
376 volatile int i, j = 0;
388 #if defined(PLATFORM_IS_EVB_2) 414 #ifdef _SAME70_HSMCI_INSTANCE_ 424 #ifdef _SAME70_TC1_INSTANCE_ 427 #ifdef _SAME70_TC1_INSTANCE_ 430 #ifdef _SAME70_TC1_INSTANCE_ 434 #ifdef _SAME70_DACC_INSTANCE_ 447 #ifdef _SAME70_TWIHS2_INSTANCE_ 455 #ifdef _SAME70_TC2_INSTANCE_ 458 #ifdef _SAME70_TC2_INSTANCE_ 461 #ifdef _SAME70_TC2_INSTANCE_ 472 #ifdef _SAME70_SDRAMC_INSTANCE_ #define GPBR_IDX_G4_FLASH_MIG
UBaseType_t uxCurrentPriority
void vApplicationMallocFailedHook(uint32_t size, uint32_t remaining, uint32_t prevLR)
uint32_t ulRunTimeCounter
uint16_t usStackHighWaterMark
void MemManage_Handler(void)
size_t xPortGetMinimumEverFreeHeapSize(void) PRIVILEGED_FUNCTION
TaskHandle_t xTaskGetCurrentTaskHandle(void) PRIVILEGED_FUNCTION
void pmc_enable_sleepmode(uint8_t uc_type)
Enable Sleep Mode. Enter condition: (WFE or WFI) + (SLEEPDEEP bit = 0) + (LPM bit = 0) ...
#define GPBR
(GPBR ) Base Address
#define SYS_FAULT_STATUS_STACK_OVERFLOW
#define GPBR_IDX_G3_LINE_NUM
void HardFault_Handler(void)
void TWIHS0_Handler(void)
#define portGET_RUN_TIME_COUNTER_VALUE()
rtos_task_t task[UINS_RTOS_NUM_TASKS]
static void setGpbrWithTaskInfo(void)
#define GPBR_IDX_G2_FILE_NUM
#define SYS_FAULT_STATUS_MALLOC_FAILED
#define DBGPIO_TOGGLE(pin)
uint32_t g_faultFileNumber
void vApplicationIdleHook(void)
void soft_reset_no_backup_register(void)
static void HardFault_Test(void)
void DebugMon_Handler(void)
void rtosResetStats(void)
#define SYS_FAULT_STATUS_MEM_MANGE
void TWIHS1_Handler(void)
#define SYS_FAULT_STATUS_USAGE_FAULT
void TWIHS2_Handler(void)
#define SYS_FAULT_STATUS_HARD_FAULT
void rtos_monitor(int numRtosTasks)
void UsageFault_Handler(void)
void vApplicationStackOverflowHook(xTaskHandle *pxTask, signed char *pcTaskName)
#define MAX_TASK_NAME_LEN
void vApplicationTickHook(void)
uint32_t g_faultLineNumber
void prvGetRegistersFromStack(uint32_t *pulFaultStackAddress)
#define configMAX_TASK_NAME_LEN
void vTaskGetInfo(TaskHandle_t xTask, TaskStatus_t *pxTaskStatus, BaseType_t xGetFreeStackSpace, eTaskState eState) PRIVILEGED_FUNCTION
char name[MAX_TASK_NAME_LEN]
int createTask(int index, pdTASK_CODE pxTaskCode, const char *const pcName, unsigned short usStackDepth, void *pvParameters, unsigned portBASE_TYPE uxPriority, portTickType xTimeIncrement)
#define SYS_FAULT_STATUS_BUS_FAULT
void SDRAMC_Handler(void)
void BusFault_Handler(void)