Rahix / avr-device

Register access crate for AVR microcontrollers
Apache License 2.0
170 stars 66 forks source link

Fix svd2rust regressions #64

Closed Rahix closed 3 years ago

Rahix commented 3 years ago

Latest svd2rust built from git seems to be more strict on the validity of enumerated values (they must fit into the field they are for now). This will break some of the current chip descriptions.

Fix all those cases so we are prepared for when svd2rust releases a new version. A few of the changes will be breaking, which means the next version bump of avr-device after merging this PR must be a major one.

Rahix commented 3 years ago

On a side note, as this kind of issue seems to come up again and again: Maybe atdf2svd should just not emit any broken enumerated values in the first place and drop them with a warning?

Rahix commented 3 years ago

Dropped all changes which are no longer necessary when building with the latest version of atdf2svd.