Comments (10)
Correct error message:
❯ svdtools html ./html rk3588.svd
Processing rk3588.svd
thread 'main' panicked at src/html/html_cli.rs:501:41:
called `Result::unwrap()` on an `Err` value: In file rk3588.svd
Caused by:
0: In device `RockChip_RK3588`
1: In peripheral `FSPI`
2: In register `CTRL0`
3: Parsing field `IDLE_CYCLE` at 104982:7
4: `EnumeratedValue error: Value 4 out of range 0..4
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
from svd.
I would propose you to try svdtools
instead. At least until you fix all SVD bugs. There a lot of them.
from svd.
Maybe I misunderstood your message, but how is "Value 4 is outside 0..4" in your post correct? The range of values is 0..3, not 0..4.
from svd.
See line 104982
in SVD. There bitWidth = 2
with EnumeratedValue s from 0 to 15.
from svd.
The range of values is 0..3, not 0..4.
Oh. I see. It just we use open range (a..b) and close range (a..=b) in Rust.
from svd.
Error message is here:
svd/svd-rs/src/enumeratedvalue.rs
Line 43 in 50ee4f7
from svd.
Ah, thanks for clarifying the open/close range thing. I wasn't aware of that.
I was aware of my bitwidth bug as stated in my first post. I was just pointing out that the open range is a bit misleading, not that the parser didn't find a bug on my side. I fixed the range issue before filing this issue. As for the other bugs (_ as name), I haven't fixed those yet due to a lack of names to use.
The real crime is that ARM Development Studio (= the company that owns the svd format), is happy with the bad bit width, so if I hadn't used the other html tool I wouldn't have been any wiser.
from svd.
You could use svdtools patch
after DEF to SVD convert to automatize bug patching.
from svd.
Fixed by #255
from svd.
Thanks!
from svd.
Related Issues (20)
- Serde: custom (de)serializers
- Proposal: struct instead of enum for arrays HOT 6
- should we support dataType?
- custom serializer for WriteConstraint
- deserialize bugs
- remove submodule, add & rework tests
- add expanding default_register_properties
- `svd-parser` doesn't extract `noNamespaceSchemaLocation` correctly
- dimIndexType support for [A-Z]-[A-Z] pattern HOT 2
- check <size> tag
- Unknown access variant 'read-write ' found HOT 7
- [svd_parser]: Tags that contain a XML comment are ignored.
- 0.15 roadmap HOT 1
- Check writeConstraint range
- M302: Size of Register must be 8, 16 or 32 Bits HOT 8
- allow `isDefault` to have optional `value` HOT 10
- do validation when parsing serde yaml/json HOT 3
- svd-parser v0.14.3 fails to compile with svd-rs version v0.14.2 and v0.14.3 HOT 2
- SVD for s32k344 leads to uncompilable output due to many duplicated methods HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from svd.