cpu/esp32: add support for ESP32-S3#18421
Conversation
e389aa0 to
55b1686
Compare
|
@kaspar030 This PR requires an update of CI workers. Is there a plan when it is done next time? How is it coordinated? |
|
@benpicco Do you think the CI workers are updated now? |
|
Well it's worth a try. And with the current CI run times the compilation will happen during the night anyway. If not we got something to point to showing that the automatic updates apparently do not work. |
| /** | ||
| * ESP32 specific sleep configuration (DO NOT CHANGE) | ||
| */ | ||
| #define CONFIG_ESP_SLEEP_RTC_BUS_ISO_WORKAROUND 1 |
There was a problem hiding this comment.
To be honest, I don't knwo. It's just a setting that comes from ESP-IDF's Kconfig without any explaination.
config ESP_SLEEP_RTC_BUS_ISO_WORKAROUND
bool
default y if IDF_TARGET_ESP32(=n) || IDF_TARGET_ESP32S2(=n) || IDF_TARGET_ESP32S3(=n)
There was a problem hiding this comment.
Interesting - better add a note that this is from the SDK and true for all XTensa ESPs
There was a problem hiding this comment.
Hm, but this is actually the case for all CONFIG_* definitions in the sdkconfig*.h files. They all define configurations that are only required for compiling ESP-IDF sources and are set to the default values of ESP-IDF's Kconfig. Maybe it is better to move them to a directory cpu/esp32/esp-idf/include/config so that it becomes better clear what these files are for.
| /** | ||
| * @brief Mapping configured ESP32 default clock to CLOCK_CORECLOCK define | ||
| */ | ||
| #define CLOCK_CORECLOCK (1000000UL * CONFIG_ESP32S3_DEFAULT_CPU_FREQ_MHZ) |
There was a problem hiding this comment.
| #define CLOCK_CORECLOCK (1000000UL * CONFIG_ESP32S3_DEFAULT_CPU_FREQ_MHZ) | |
| #define CLOCK_CORECLOCK MHZ(CONFIG_ESP32S3_DEFAULT_CPU_FREQ_MHZ) |
There was a problem hiding this comment.
This would require to include RIOT's macros.h which leads to a number of naming conflicts when compiling ESP IDF sources, including the MHZ macro. sdkconfig_*.h are mainly used for the configuration of ESP-IDF with this only acception. A solution could be to move CLOCK_CORECLOCK to cpu_conf.h. It's just still there since it was added there with 5ae5c40f26de541c1ac804623520f67442588f83`.
Should I try to move it to cpu_conf.h for all ESP32x SoCs with this PR?
There was a problem hiding this comment.
It would make more sense in cpu_conf.h since it's not for configuring the SDK but for RIOT consumption only.
There was a problem hiding this comment.
Should it be a separate PR which would require an additional rebase or could it be part of this PR?
There was a problem hiding this comment.
I don't really have a strong opinion there, whatever you prefer.
There was a problem hiding this comment.
Commit 066239d moves the define to the corresponding cpu_*.h files.
The toolchain is still missing 😟 |
The question is how we can get the CI worker up to date. |
|
I'd keep the ready for build label set - makes it easier to complain about it on Matrix 😄 |
211f299 to
07e484c
Compare
I have moved |
This define does not belong to the defines in `sdkconfig_*.h` that are used for the ESP-IDF SDK. It is therefore moved to the corresponding `periph_cpu_*.h` file.
07e484c to
e7bf789
Compare
|
@benpicco I am getting desperate as I am getting another unrelated error in the CI compilation. I was hoping to merge the PR today to be able to provide the PRs based on it for the ESP32-S3 before my vacation starting tomorrow 😟 |
|
The current CI run will fail due to unrelated issues. Failures that look like will be fixed by #18466 |
|
If it is passing mudock and acked there is no reason it can't be merged today or even after your vacation. Maybe we want to enable automerge? |
|
Sorry this didn’t make it, enjoy your vacation! Let’s hope we’re getting CI fixed by the time you’re back 😄 |
|
I will build once we fix the CI |
|
Thanks for reviewing and merging. |
Contribution description
This PR is a split-off from PR #18185, which provides
This PR requires PRs
#18408, #18409, #18410 and #18411to be compilable in CI.Furthermore the CI workers need an update with riotdocker #200Testing procedure
Beside of Green CI some basic tests should work (Of course, I have already tested all of them and many more):
tests/shelltests/periph_cpuidtests/periph_gpiotests/periph_hwrngtests/periph_i2ctests/periph_spitests/periph_rtttests/periph_timerexamples/gnrc_networkingusingesp_wifias optional module.Issues/PRs references
Depends on #18408Depends on #18409
Depends on #18410
Depends on #18411