Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ version = "0.1.0"

[dependencies]
cortex-m = "0.7.0"
flash-algorithm = "0.4.0"
flash-algorithm = { version = "0.4.0", default-features = false, features = [
"panic-handler",
] }

# this lets you use `cargo fix`!
[[bin]]
Expand Down
1 change: 0 additions & 1 deletion build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,4 @@ cat <<EOF
pc_uninit: $(sym UnInit)
pc_program_page: $(sym ProgramPage)
pc_erase_sector: $(sym EraseSector)
pc_erase_all: $(sym EraseChip)
EOF
File renamed without changes.
5 changes: 0 additions & 5 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -74,11 +74,6 @@ impl FlashAlgorithm for RP2040Algo {
Ok(Self { funcs })
}

fn erase_all(&mut self) -> Result<(), ErrorCode> {
// todo
Err(ErrorCode::new(0x70d0).unwrap())
}

fn erase_sector(&mut self, addr: u32) -> Result<(), ErrorCode> {
(self.funcs.flash_range_erase)(
addr - FlashDevice.dev_addr,
Expand Down