-
I am new to SystemRDL and I am struggling with what I think should be a very simple thing. I want to create two registers, each with only 1 bit. Register 1 is a status register that tells me the present value of a wire that originates from outside of the block. Register 2 is a control register that set and holds the value of a different wire. That wire would be used outside of the block. Defining the registers was straight-forward, but I am struggling with how to attach the input and output wires to the registers, especially the output. Here is what I have:
How do I assign the block level signal to the register field level signal to set value that is read? Thanks in advance for any help. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Hi and thanks for taking an interest in SystemRDL! You're actually quite close already. As you learn more about the language, you'll see that SystemRDL does a lot of things through inference. The
The SystemRDL spec has a really good table in section 9 that shows some combinations and what they end up inferring: From there, you can use the numerous other properties to further augment the implied behavior. The extra |
Beta Was this translation helpful? Give feedback.
-
Thank you for the help. I had incorrectly assumed that signals were an essential part of the description; I didn't realize that things were inferred as part of language, so your response put me back on the right track. |
Beta Was this translation helpful? Give feedback.
Hi and thanks for taking an interest in SystemRDL!
You're actually quite close already. As you learn more about the language, you'll see that SystemRDL does a lot of things through inference. The
hw
property implicitly controls what the "hardware-facing" interface looks like. Settinghw = r
implicitly infers an output signal from the block, since the hardware-side "reads" the value of the register. Similarly,hw = w
infers an input signal that the outside logic "writes" to the register.So for your example, all you need is the following: