EasyManuals Logo

Espressif ESP32-S2 User Manual

Espressif ESP32-S2
1695 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #1228 background imageLoading...
Page #1228 background image
Chapter 2. API Reference
CONFIG_SPI_FLASH_WARN_SETTING_ZERO_TO_ONE
Log warning if writing zero bits to ones
Found in: Component config > SPI Flash driver > CONFIG_SPI_FLASH_VERIFY_WRITE
If this option is enabled, any SPI flash write which tries to set zero bits in the flash to ones will log a
warning. Such writes will not result in the requested data appearing identically in flash once written, as
SPI NOR flash can only set bits to one when an entire sector is erased. After erasing, individual bits can
only be written from one to zero.
Note that some software (such as SPIFFS) which is aware of SPI NOR flash may write one bits as an
optimisation, relying on the data in flash becoming a bitwise AND of the new data and any existing data.
Such software will log spurious warnings if this option is enabled.
Default value:
No (disabled) if CONFIG_SPI_FLASH_VERIFY_WRITE
CONFIG_SPI_FLASH_ENABLE_COUNTERS
Enable operation counters
Found in: Component config > SPI Flash driver
This option enables the following APIs:
spi_flash_reset_counters
spi_flash_dump_counters
spi_flash_get_counters
These APIs may be used to collect performance data for spi_flash APIs and to help understand behaviour
of libraries which use SPI flash.
Default value:
0
CONFIG_SPI_FLASH_ROM_DRIVER_PATCH
Enable SPI flash ROM driver patched functions
Found in: Component config > SPI Flash driver
Enable this flag to use patched versions of SPI flash ROM driver functions. This option should be
enabled, if any one of the following is true: (1) need to write to flash on ESP32-D2WD; (2) main SPI
flash is connected to non-default pins; (3) main SPI flash chip is manufactured by ISSI.
Default value:
Yes (enabled)
CONFIG_SPI_FLASH_DANGEROUS_WRITE
Writing to dangerous flash regions
Found in: Component config > SPI Flash driver
SPI flash APIs can optionally abort or return a failure code if erasing or writing addresses that fall at
the beginning of flash (covering the bootloader and partition table) or that overlap the app partition that
contains the running app.
It is not recommended to ever write to these regions from an IDF app, and this check prevents logic
errors or corrupted firmware memory from damaging these regions.
Note that this feature *does not* check calls to the esp_rom_xxx SPI flash ROM functions. These
functions should not be called directly from IDF applications.
Available options:
Espressif Systems 1217
Submit Document Feedback
Release v4.4

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Espressif ESP32-S2 and is the answer not in the manual?

Espressif ESP32-S2 Specifications

General IconGeneral
BrandEspressif
ModelESP32-S2
CategorySingle board computers
LanguageEnglish