diff options
author | JF <jf@codingfield.com> | 2020-10-27 19:38:45 +0100 |
---|---|---|
committer | JF <jf@codingfield.com> | 2020-10-27 19:38:45 +0100 |
commit | 1bb2eb9dcd59fbb198be157e34b7ff25367adea0 (patch) | |
tree | 6bebf5630cedb1cf0476e590563964616d8dc456 /src/drivers/SpiNorFlash.cpp | |
parent | ab7acd0f076899fafb1cb5ff233a9c6b6b1ca15b (diff) |
Disable sleep mode on the SPI NOR Flash when the version is unknown. This is because the current bootloader (which does not exposes its version) cannot initialize the chip when it's in sleep mode.
This feature will be re-enabled when the bootloader expses it's version.
Diffstat (limited to 'src/drivers/SpiNorFlash.cpp')
-rw-r--r-- | src/drivers/SpiNorFlash.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/drivers/SpiNorFlash.cpp b/src/drivers/SpiNorFlash.cpp index 351a9dfc..bd24834e 100644 --- a/src/drivers/SpiNorFlash.cpp +++ b/src/drivers/SpiNorFlash.cpp @@ -12,7 +12,7 @@ SpiNorFlash::SpiNorFlash(Spi& spi) : spi{spi} { void SpiNorFlash::Init() { device_id = ReadIdentificaion(); - NRF_LOG_INFO("[SPI FLASH] Manufacturer : %d, Memory type : %d, memory density : %d", device_id.manufacturer, device_id.type, device_id.density); + NRF_LOG_INFO("[SpiNorFlash] Manufacturer : %d, Memory type : %d, memory density : %d", device_id.manufacturer, device_id.type, device_id.density); } void SpiNorFlash::Uninit() { @@ -22,7 +22,7 @@ void SpiNorFlash::Uninit() { void SpiNorFlash::Sleep() { auto cmd = static_cast<uint8_t>(Commands::DeepPowerDown); spi.Write(&cmd, sizeof(uint8_t)); - NRF_LOG_INFO("[FLASH] Sleep") + NRF_LOG_INFO("[SpiNorFlash] Sleep") } void SpiNorFlash::Wakeup() { @@ -38,7 +38,7 @@ void SpiNorFlash::Wakeup() { else { NRF_LOG_INFO("[SpiNorFlash] ID on Wakeup: %d", id); } - NRF_LOG_INFO("[FLASH] Wakeup") + NRF_LOG_INFO("[SpiNorFlash] Wakeup") } SpiNorFlash::Identification SpiNorFlash::ReadIdentificaion() { |