Forum Discussion
Altera_Forum
Honored Contributor
10 years agoYou need to add the base address of the peripheral. The reason this works for HPS is that the base offset is fixed and defined starting at 0 rather than the beginning of the device's register space.
All of the standard Altera cores will have code generated for them in the BSP. You should use that rather than writing it yourself.