Module f3::exception
[−]
[src]
Exceptions
All the exceptions prefixed with an underscore (_
) can overridden by the top crate:
//! Override the hard fault exception #![feature(asm)] #![no_main] #![no_std] #[macro_use] extern crate cortex_m; extern crate f3; use core::ptr; #[export_name = "main"] pub fn main() -> ! { unsafe { // Trigger a `hard_fault` exception (using UNSAFE code, of course!) and ... ptr::write_volatile(0x0000_0000 as *mut u32, 0xdead_beef); } loop {} } #[export_name = "_hard_fault"] // <-- Important! Note the underscore. pub extern "C" fn my_hard_fault_handler() { unsafe { // .. you should reach THIS breakpoint! bkpt!(); } loop {} }Run
Enums
Exception |
Kind of exception |
Statics
EXCEPTIONS |
List of all the exceptions minus the reset handler as allocated in the vector table. |
Functions
_bus_fault |
Pre-fetch fault, memory access fault. |
_default_handler | |
_hard_fault |
All class of fault. |
_memmanage_fault |
Memory management. |
_nmi |
Non-maskable interrupt. |
_pendsv |
Pendable request for system service |
_svcall |
System service call via SWI instruction |
_systick |
System tick timer |
_usage_fault |
Undefined instruction or illegal state. |
reset |
Reset handler |