You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is definitely a bug, but there's actually a few things going on here.
SystemRDL defines this strange register packing mode called "msb0 mode" which means that the upper bit of a register is the least-significant bit instad of most-significant. You can switch to this mode explicitly by using the msb0 property, or infer it by using [low:high] bit ordering.
Assuming that using msb0 mode was not your intention, try flipping your fields to define bit-order using the lsb0 notation of [high:low]. That is more conventional for field definitions and I assume is what you intended.
reg {
name = "Version";
field {} VERSION_REVISION[7:0];
field {} VERSION_BUILD[15:8];
field {} VERSION_MINOR[23:16];
field {} VERSION_MAJOR[31:24];
} version;
All that said, this is definitely a bug in the HTML generator - it ought to be able to support the alternate msb0 bit-mode correctly.
amykyta3
changed the title
Register decoding does not work correctly
Register decoding does not work correctly when fields are represented in msb0 mode
Mar 13, 2024
When entering a value in the "Encoded Register Value", the decoding doesn't work correctly. For this RDL source:
Example result:
I'm also not sure what behavior is expected when entering a field value. The field text field always goes red it seems.
I'm using peakrdl-html v2.10.1 and Firefox. Also fails in Edge.
The text was updated successfully, but these errors were encountered: