Origen-SDK / o2

MIT License
4 stars 0 forks source link

Support enumeratedValues in registers #31

Open chrisnappi opened 4 years ago

chrisnappi commented 4 years ago

IPXact supports bitfield enumerated values: https://accellera.org/images/xmlschema/spirit/1685-2009/memoryMap.xsd search for:

We should support this, so that we can do things like: dut.reg(:clock_ctrl).bits(:clock_select).write(:osc_24mhz)
ginty commented 4 years ago

Yes this will definitely be done, the data structure for it is already there - https://github.com/Origen-SDK/o2/blob/master/rust/origen/src/core/model/registers.rs#L124

Just need to come up with the appropriate API.