embassy-rp

Crates

git

Versions

rp2040

Flavors

embassy_rp::rom_data

Function reset_to_usb_boot

Source
pub extern "C" fn reset_to_usb_boot(
    gpio_activity_pin_mask: u32,
    disable_interface_mask: u32,
)
Expand description

Resets the RP2040 and uses the watchdog facility to re-start in BOOTSEL mode:

  • gpio_activity_pin_mask is provided to enable an ‘activity light’ via GPIO attached LED for the USB Mass Storage Device:
    • 0 No pins are used as per cold boot.
    • Otherwise a single bit set indicating which GPIO pin should be set to output and raised whenever there is mass storage activity from the host.
  • disable_interface_mask may be used to control the exposed USB interfaces:
    • 0 To enable both interfaces (as per cold boot).
    • 1 To disable the USB Mass Storage Interface.
    • 2 to Disable the USB PICOBOOT Interface.