File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -71,9 +71,10 @@ extern "C" {
7171// REG_SPI_BASE is not defined for S3/C3 ??
7272
7373#if CONFIG_IDF_TARGET_ESP32S3 || CONFIG_IDF_TARGET_ESP32C3
74- #ifndef REG_SPI_BASE
75- #define REG_SPI_BASE ( i ) (DR_REG_SPI1_BASE + (((i) > 1 ) ? (((i) * 0x1000 ) + 0x20000 ) : (((~(i)) & 1 ) * 0x1000 )))
74+ #ifdef REG_SPI_BASE
75+ #undef REG_SPI_BASE
7676#endif // REG_SPI_BASE
77+ #define REG_SPI_BASE (i ) (DR_REG_SPI1_BASE + (((i) > 1 ) ? (((i) * 0x1000 ) + 0x20000 ) : (((~(i)) & 1 ) * 0x1000 )))
7778#endif // TARGET
7879
7980/* *
Original file line number Diff line number Diff line change @@ -113,9 +113,10 @@ static void printFlashInfo(void) {
113113#endif
114114// REG_SPI_BASE is not defined for S3/C3 ??
115115#if CONFIG_IDF_TARGET_ESP32S3 || CONFIG_IDF_TARGET_ESP32C3
116- #ifndef REG_SPI_BASE
117- #define REG_SPI_BASE ( i ) (DR_REG_SPI1_BASE + (((i) > 1 ) ? (((i) * 0x1000 ) + 0x20000 ) : (((~(i)) & 1 ) * 0x1000 )))
116+ #ifdef REG_SPI_BASE
117+ #undef REG_SPI_BASE
118118#endif // REG_SPI_BASE
119+ #define REG_SPI_BASE (i ) (DR_REG_SPI1_BASE + (((i) > 1 ) ? (((i) * 0x1000 ) + 0x20000 ) : (((~(i)) & 1 ) * 0x1000 )))
119120#endif // TARGET
120121
121122 chip_report_printf (" Flash Info:\n " );
You can’t perform that action at this time.
0 commit comments