Merge pull request #2303 from embassy-rs/nor-flash-multiwrite

feat: support multiwrite flash traits if configured
This commit is contained in:
Dario Nieuwenhuis 2023-12-18 13:06:53 +00:00 committed by GitHub
commit 88e77c733c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 0 deletions

View File

@ -64,6 +64,11 @@ nfc-pins-as-gpio = []
# nrf52820, nrf52833, nrf52840: P0_18
reset-pin-as-gpio = []
# Implements the MultiwriteNorFlash trait for QSPI. Should only be enabled if your external
# flash supports the semantics described in
# https://docs.rs/embedded-storage/0.3.1/embedded_storage/nor_flash/trait.MultiwriteNorFlash.html
qspi-multiwrite-flash = []
# Features starting with `_` are for internal use only. They're not intended
# to be enabled by other crates, and are not covered by semver guarantees.

View File

@ -605,6 +605,9 @@ impl<'d, T: Instance> NorFlash for Qspi<'d, T> {
}
}
#[cfg(feature = "qspi-multiwrite-flash")]
impl<'d, T: Instance> embedded_storage::nor_flash::MultiwriteNorFlash for Qspi<'d, T> {}
mod _eh1 {
use embedded_storage_async::nor_flash::{NorFlash as AsyncNorFlash, ReadNorFlash as AsyncReadNorFlash};