Forum Discussion
Altera_Forum
Honored Contributor
16 years agoHi Jake,
thanks for your answer! --- Quote Start --- 2 - The macro found in system.h "<COMPONENT_NAME>_SPAN" (in your case MY_INTERFACE_SPAN) is merely a macro that can be used to determine how much address space is occupied by the component on the avalon bus. It is rarely used. --- Quote End --- This seems to be an important information for me. In the c-Code I heired through this project, old project, I found something like this: alt_u32* p1 = (alt_u32*) MY_INTERFACE_BASE; alt_u32* p2 = ((alt_u32*) MY_INTERFACE_BASE) + 1; I had no idea, where these pointers are pointing to, because the data bus of my external component is only 8 bits wide. But the MY_INTERFACE_SPAN macro is 8. In the end, I still don't know, hoe SOPC (or whatever tool) knows, how to define this SPAN macro because as i said in my external component the writedata bus is 8 bits, the readdata bus is 8 bits, and it does exist an additional address bus of the width 4 bits. Its very hard for me to understand what is going on here, but your explanations already helped a lot. It is very hard for me to implement my interfaces to user logic components into the SOPC custom component because all these components are AHDL modules and I think I read somewhere, that SOPC only supports VHDL or verilog. Maik