-
Notifications
You must be signed in to change notification settings - Fork 11
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
Translate ATDF series and architecture into SVD fields. #32
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi, thanks for the PR. This looks like a good idea. I'll run a regression test against our devices to make sure it doesn't affect them. I would be surprised if it does, though.
749b651
to
a978fa4
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi,
re-ran with your latest changeset. Now I'm generating an SVD file successfully but svdtools
isn't a fan of the new version. I'm hitting this error:
Traceback (most recent call last):
...
File ".../svdtools/cli.py", line 16, in patch
svdtools.patch.main(yaml_file)
File ".../svdtools/patch.py", line 1639, in main
process_device(svd, root)
File ".../svdtools/patch.py", line 1619, in process_device
sort_recursive(svd.getroot())
File ".../svdtools/patch.py", line 374, in sort_recursive
sort_recursive(child)
File ".../svdtools/patch.py", line 370, in sort_recursive
sort_element(tag)
File ".../svdtools/patch.py", line 362, in sort_element
raise UnknownTagError((tag.tag, child.tag))
svdtools.patch.UnknownTagError: ('cpu', 'access')
and the diff between old and new is this:
--- svd-original/atmega32u4.svd 2022-09-28 19:56:16.307095959 +0200
+++ svd/atmega32u4.svd 2022-10-08 22:54:17.229940071 +0200
@@ -14,7 +14,10 @@
<endian>little</endian>
<mpuPresent>false</mpuPresent>
<fpuPresent>false</fpuPresent>
- <nvicPrioBits>4</nvicPrioBits>
+ <access>read-write</access>
+ <resetValue>0</resetValue>
+ <resetMask>0xff</resetMask>
+ <nvicPrioBits>0</nvicPrioBits>
<vendorSystickConfig>false</vendorSystickConfig>
</cpu>
<peripherals>
Maybe we can just drop the access
, resetValue
, and resetMask
from the <cpu/>
tag again?
Just had a stroke, they weren't there before, not sure why I added them there 🤔 |
a978fa4
to
8ff0f83
Compare
Just removed them on recent commits, thanks for noticing it out! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alright, change looks good now and no regressions in my tests. Only change I'm seeing is the expected
--- src/devices-original/attiny88/mod.rs 2022-09-28 19:55:49.690093934 +0200
+++ src/devices/attiny88/mod.rs 2022-10-11 20:04:40.240616110 +0200
@@ -3,7 +3,7 @@
use core::marker::PhantomData;
use core::ops::Deref;
#[doc = r"Number available in the NVIC for configuring priority"]
-pub const NVIC_PRIO_BITS: u8 = 4;
+pub const NVIC_PRIO_BITS: u8 = 0;
#[doc(hidden)]
pub mod interrupt;
pub use self::interrupt::Interrupt;
but that's totally fine. Thanks again for the contribution!
No description provided.