From f72f10dc58faac287f8064be564625f427d10ddc Mon Sep 17 00:00:00 2001 From: Nathael Pajani Date: Thu, 17 Apr 2014 11:19:26 +0200 Subject: [PATCH] Use a dummy fault handler in core and move the "user defined" one to main.c --- core/fault_handlers.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/core/fault_handlers.c b/core/fault_handlers.c index d1bfe25..56bc0d0 100644 --- a/core/fault_handlers.c +++ b/core/fault_handlers.c @@ -25,9 +25,10 @@ #include "core/lpc_regs_12xx.h" #include "drivers/serial.h" -void fault_info(const char* name, uint32_t len) -{ - serial_write(1, name, len); +void fault_info(const char* name, uint32_t len) __attribute__ ((weak, alias ("Dummy_Fault_Handler"))); + +void Dummy_Fault_Handler(const char* name, uint32_t len) { + while (1); } /* Cortex M0 core interrupt handlers */ -- 2.43.0