Open tudortimi opened 1 month ago
Hi @tudortimi,
We do not have immediate plans to enhance CMSIS definitions. Please feel free to raise a suggestion as a Pull-request.
I am happy to accept your contributions.
Thanks, Jonatan
Do you use any tool for the definitions of the pos/msk defines which takes the register descriptions from the architecture? I could see how to plug something like this in there.
No, we are not using any tools. The CMSIS core header files are manually maintained so far.
I'll raise a PR to add this for one of the cores (e.g. CM33) first, to have a first look. It's gonna take some time, though, do you mind that the issue stays open? Also, could you assign it to me so it shows up in my TODO list?
Are there any plans to also define structs for the memory mapped core registers? Currently, only bitmasking is supported. Structs would make code easier to read (at the cost of more instructions, I guess).
For example, the SAU registers only have mask/pos defines:
For the non-memory mapped SFRs, there are also structs (e.g. APSR) in addition to the mask/pos defines: