esp32
esp32 copied to clipboard
Espressif SVD question
I see that there is an SVD repo in the Espressif org.
There is currently no Esp32 SVD and I am wondering if the initial SVD is going to be auto generated and then manually maintained or is there an alternate mechanism that will be used?
I have compiled an Esp32 SVD (compatible with CMSIS SVD 1.3) using the one in this repository, Esp-IDF 4.4 header files and the latest available Espressif technical reference manual. Svd2rust does not handle all the 1.3 features. I was thinking of preferably updating this SVD, or updating the existing YAML files.
I am wondering if it worth the time and effort if the SVD in this repo is going to be superseded by one from the Espressif/SVD repo?
@jessebraham may be better equipped to answer this.
My understanding (from our last meeting) is that the esp32c3 svd is the output of the tool being developed internally by Espressif to transform Espressifs internal format into SVD. I believe once we are happy with the esp32c3 this tool can then generate other chip SVD's too.
I am wondering if it worth the time and effort if the SVD in this repo is going to be superseded by one from the Espressif/SVD repo?
This repo is here to stay, but the initial SVD that was "created" by idf2svd will almost certainly scrapped in favour of the official one.
There is indeed work being done to create an SVD generator. During development the focus has been on the ESP32-C3 specifically, however additional chips should be supported in time. I am unfortunately unable to give a timeline, but hopefully soon™.
@jessebraham I see SVD files are recently updated in https://github.com/espressif/svd What is current state of it?
It's difficult to answer that, unfortunately. At this point I believe most of the peripherals are present in the SVD, and most seem to have a reasonable level of completeness with regard to registers and fields. There is definitely still a ways to go, however, for example we still do not provide enum values for multi-bit fields.
For context, we have created the esp-rs/esp-pacs repository which contains the new PAC for the ESP32 (yet unpublished) as well as esp-rs/esp-hal with the new HAL. The hope is to eventually archive esp-rs/esp32 and esp-rs/esp32-hal and replace them with their newer counterparts. The reason I mention all this is that these projects are being used to verify and find errors in the SVDs, so for whichever peripherals are currently implemented there you can be fairly confident the SVD is at least mostly correct. All other peripherals will have varying quality, but problems as fixed as they are reported so this should only improve with time.