rp: add example code to flash bluetooth fw (#3290)

This commit is contained in:
Pedro Ferreira 2024-08-26 20:28:30 +02:00 committed by GitHub
parent a7bfec2467
commit 9347571fea
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -43,8 +43,10 @@ async fn main(spawner: Spawner) {
// at hardcoded addresses, instead of baking them into the program with `include_bytes!`:
// probe-rs download 43439A0.bin --format bin --chip RP2040 --base-address 0x10100000
// probe-rs download 43439A0_clm.bin --format bin --chip RP2040 --base-address 0x10140000
// probe-rs download 43439A0_btfw.bin --format bin --chip RP2040 --base-address 0x10141400
//let fw = unsafe { core::slice::from_raw_parts(0x10100000 as *const u8, 224190) };
//let clm = unsafe { core::slice::from_raw_parts(0x10140000 as *const u8, 4752) };
//let btfw = unsafe { core::slice::from_raw_parts(0x10141400 as *const u8, 6164) };
let pwr = Output::new(p.PIN_23, Level::Low);
let cs = Output::new(p.PIN_25, Level::High);