Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add SVD files for ATMega chips #238

Closed
wants to merge 5 commits into from

Conversation

maxgerhardt
Copy link

@maxgerhardt maxgerhardt commented Feb 10, 2021

Output of the https://github.com/Rahix/avr-device tool (all *.svd.patched files renamd to *.svd).

Created as descripted in community post.

The SVD files are not yet referenced in the board JSON files because the parser in VSCode throws an error and in CLion it can parse the file but cannot read out the registers (possible avr-gdb issue). Other issues will be opened for this.

For testing, you can e.g. modify the uno.json file with

  "debug": {
    "simavr_target": "atmega328p",
    "avr-stub": {
      "speed": 115200
    },
    "svd_path": "atmega328p.svd"
  },

and then receive the same parsing error as in the linked topic -- CLion gets much further as said, but can't read out the I/O registers..

Output of the https://github.com/Rahix/avr-device tool (all `*.svd.patched` files renamd to `*.svd`). 

Created as descripted in [community post](https://community.platformio.org/t/avr-simulator-as-aid-tool-for-debugging-code/13444/44?u=maxgerhardt)

The SVD files are not yet referenced in the board JSON files because the parser in VSCode throws an error and in CLion it can parse the file but cannot read out the registers (possible `avr-gdb` issue). Other issues will be opened for this.
@Gasman2014
Copy link

FWIW The Atmel SVD files generated by https://github.com/Rahix/avr-device do not parse correctly using the SVDConv tool (described here https://www.keil.com/pack/doc/CMSIS/SVD/html/index.html). As an example, I have prepared a test attiny85 svd file and stripped out all but one peripheral definitions such that it eventually produced no errors (but several warnings) when checked with SVDConv. The svd also need to feature an xml typedef header and a section for each peripheral. My minimal svd file IS loaded correctly by platformio.

@Rahix
Copy link

Rahix commented Jun 10, 2021

ACK, we've already identified at least one spec violation (Rahix/atdf2svd#25). Just as a bit of background: With https://github.com/Rahix/avr-device the intent was obviously just to get the Rust generation working so not much attention was paid to full SVD spec adherance - we just implemented the minimum subset required for this usecase. That said, I'm happy to improve https://github.com/Rahix/atdf2svd so it is useful here as well.

@Gasman2014, If you're able to run SVDConv, maybe you can open some issues on atdf2svd about further problems with the current output?

@maxgerhardt
Copy link
Author

Retracted.

@maxgerhardt maxgerhardt closed this Nov 1, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants