Hi,
1.does slave_address variable increment automatically or do I have to do it?
>> NO, you're giving the address from the software.
IORD_32DIRECT(REG32_AVALON_INTERFACE_0_BASE,0);
REG32_AVALON_INTERFACE_0_BASE=slave_address
2.how to use Q1_export 1,2 and 3?
>> You can export x,y,& z as per your requirements.
3.do I still need to use chipselect variable (because there is no write part)?
>>Not a mandatory.
4.how data are stored in memory ie (REG32_AVALON_INTERFACE_0_BASE+1,...)?
>>Each component have a unique base address through which we can access its registers.
In your design REG32_AVALON_INTERFACE_0_BASE is the base address of your component.
Inside your custom component, you have memory and its address is the offset.
mem(0)<=data1; --0 is the offset address
mem(1)<=data1;--1 is the offset address
REG32_AVALON_INTERFACE_0_BASE+1 you can access mem(1) content.
data I am getting in eclipse is random (different from the real x, y and z).
>>Give some static values and check
Put your IORD_32DIRECT command in while loop.
I have provided all the required design example and documents for your design. Open a new thread for further support.
Regards
Anand