Binome, if you need to access a component (like an internal memory instance) from both hardware and software it's recommended that you use Qsys for that. You can use the "On-Chip Memory" component and connect it to your NiosII data master interface, this way the processor can read/write this memory through software.
In order to access this memory using your hardware component you can adapt your component to use the Avalon Memory-Mapped interface protocol. You can found information about it in the Avalon Interface Specification:
http://www.altera.com/literature/manual/mnl_avalon_spec.pdf Your hardware component can be imported into Qsys by creating a custom component. You can find information about it here:
http://www.altera.com/literature/hb/qts/qsys_components.pdf Also, there are free online video trainings on the Altera website, please check the Introduction to Qsys and Custom IP Development Using Avalon and AXI Interfaces