Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
cluster contents in .svd not shown in reg viewer
#1
Using an .svd file with <cluster> does not seem to show the cluster contents in the register window.  Do I possibly have a mistake somewhere?

The .svd file was too large to upload to the forum.
https://drive.google.com/file/d/1iiogSY6...sp=sharing


Attached Files Thumbnail(s)
   
Reply
#2
I think that clusters are not implemented (yet).
Thanks for the SVD file.
Reply
#3
I think that that SVD file is not according spec.

"name = String that identifies the cluster. Register names are required to be unique within the scope of a peripheral. Specify [%s] for generating an array in the device header file."

But that SVD file makes every instance the same name.

e.g.

<cluster>
<dim>8</dim>
<dimIncrement>16</dimIncrement>
<name>PWM_CMP</name>
<description>PWM Comparison 0 Value Register</description>
<addressOffset>0x130</addressOffset>


I think that it should be something like

<cluster>
<dim>8</dim>
<dimIncrement>16</dimIncrement>
<name>PWM_CMP_[%s]</name>
<description>PWM Comparison Value Register</description>
<addressOffset>0x130</addressOffset>

See also
https://siliconlabs.github.io/Gecko_SDK_...l__gr.html
Reply
#4
The .svd file is from Microchip/Atmel for their SAM S70 line.  I'm reporting it to them for the mistake.  Thanks.
Reply
#5
Re-reading the link to the .svd <cluster> definition, I think [%s] is optional.  The register name TC_CCR in TC0 appears once in TC0 which would meet one unique register name per peripheral requirement for a <cluster> tag.  There is only one TC_CCR in TC0.

I added [%s] to the <name> tag to test if TC_CCR and other nondisplayed register are shown with [%s] included.  

<registers>
            <cluster>
               <dim>3</dim>
               <dimIncrement>64</dimIncrement>
               <name>TC_CHANNEL[%s]</name>
               <description>Channel Control Register (channel = 0)</description>
               <addressOffset>0x0</addressOffset>
               <register>
                  <name>TC_CCR</name>
                  <description>Channel Control Register (channel = 0)</description>

TC_CCR and other registers are still not displayed when [%s] is included.

I checked Atmel Studio.  Atmel Studio seems to show the registers.


Attached Files Thumbnail(s)
   
Reply
#6
But what is the function of that DIM statement? and the dimIncrement?

Normally the Dim will give you an array of that instance.
Reply
#7
Omitting [%s] in an .svd file is wrong - you are correct. I raised this with Arm and Microchip. Microchip responded "It seems there is a bug regarding the issue which was already raised internally. It may be resolved in future updates."  It appears .svd files for all Microchip Cortex-M7 parts have the bug.

https://community.arm.com/tools/f/discus...4e3419fe2e
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)