Skip to content

Commit

Permalink
Add TODO
Browse files Browse the repository at this point in the history
  • Loading branch information
fangpenlin committed Jan 7, 2025
1 parent 44e5354 commit cab245b
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/storage/spiflash.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,9 @@ impl SPIFlashStorage {
let mut drive: u8 = 0;
esp!(unsafe { ff_diskio_get_drive(&mut drive) })?;
let fatfs = unsafe { Fatfs::new_wl_part(drive, self.handle()) }?;
// TODO: handle file system not formatted issue.
// looks like esp-idf-svc didn't implement error handling at this moment:
// https://github.com/esp-rs/esp-idf-svc/blob/6453bedd5967ebc3bcb7d240492a0d5164e818c2/src/io.rs#L130
self.mounted_fatfs = Some(MountedFatfs::mount(fatfs, mount_path, max_fds)?);
Ok(())
}
Expand Down

0 comments on commit cab245b

Please sign in to comment.