Closed iDoka closed 7 years ago
It seems to me like you're using a property that isn't defined in the specific class (Field). rgen comes bundled with ipyxact (in the dependencies directory). I noticed you opened a case against that project to related to adding new properties and that you've made modifications to it. You'll need to point to your repository version either by changing what gets populated in dependencies (via Git) or by changing your PYTHONPATH to contain your local ipyxact repository.
I'm already changed ipyxact
project for supporting chain register -> field -> resets -> reset -> value
; see https://github.com/olofk/ipyxact/issues/7 (I hope it works)
In parse_tree
function proceed dynamically create object (based on YAML-template)
BTW, I can find field
-word only in ipyxact/ipxact_yaml.py
file.
My suggestion that I add in YAML required field in right way, but in my wrong way calling the object ${field.resets.reset.value}
(I'm almost don't know python).
Which one right way to call object field -> resets -> reset -> value
(described my own in YAML) into mako template uvm_reg.mako
?
What you wrote should have worked, that's why I'm saying that you're probably pointing to the old version of ipyxact.
The root of problem was in not all fileds has default reset value, I just added exception handler in uvm_reg.mako
. It solved my task.
Mentioned changes contain into my fork https://github.com/iDoka/ipxact-cli-tools
I just now solved how to support default reset values in yaml-template: https://github.com/olofk/ipyxact/issues/7
Because I'm not python-guru (HW Designer) I have troubles to adding default reset values in
uvm_reg.mako
: The variable${field.resets.reset.value}
inside cyclefor field in reg.field:
don't workHow to I can use value of this chain in mako-template:
register -> field -> resets -> reset -> value
?