Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Control bit-width of address bus in addrmap #84

Open
tenaliram opened this issue Aug 16, 2020 · 2 comments
Open

Control bit-width of address bus in addrmap #84

tenaliram opened this issue Aug 16, 2020 · 2 comments

Comments

@tenaliram
Copy link

I have 4 registers in my addrmap, but want to reserve 16 addresses. When I generate the address map verilog file, the h2d_pio_dec_address is only 2 bits (since I have only instantiated 4 registers). How can I force the h2d_pio_dec_address to use 4 bits?

@ebertland
Copy link
Contributor

You can create a read-only register at the bottom of your range with constant value of 0 and reset value of 0. This will synthesize away, but you will have the address width that you want in the RTL. I can post an example if this is not clear.

@tenaliram
Copy link
Author

Yes, please post an example of constant value=0 and reset value=0.

I created a register with (SW=r), but that is still creating ports on HW side. So, I had to create a "HW=w, SW=r" register.

One issue with creating a dummy register is that it will appear in the register documentation, if we use the RDL file to create the register documentation. I have multiple address maps which need this dummy register. If there is no other way to specify the address space for an address map, then I will have to use this method, but would like to know if there is an alternate method.

Thanks for the help and quick response.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants