#usb #panic-handler #boot #panic #micro-controller #picoboot

no-std panic-usb-boot

Set panicking behavior to reset to usb boot inteface

3 releases (breaking)

0.3.0 Feb 4, 2024
0.2.0 Nov 10, 2023
0.1.0 May 28, 2023

#312 in No standard library

MIT/Apache

7KB

panic-usb-boot

Set the panicking behavior to reset to usb boot interface, based on panic-halt by @korken89 and rom function lookup from rp2040-hal. Only works on the rp2040 microcontroller.

License

Licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.


lib.rs:

Set the panicking behavior to reset into the usb boot interface

This crate contains an implementation of panic_fmt that calls the rp2040's ROM function to reset to usb boot

Usage

#![no_std]

extern crate panic_usb_boot;

fn main() {
    panic!("argument is ignored");
}

Breakable symbols

With the panic handler being #[inline(never)] the symbol rust_begin_unwind will be available to place a breakpoint on to halt when a panic is happening.

No runtime deps

Features