Forum Discussion
custom ip core
Which .vhd?
The project which i have attached is having single register with avalone interface.
hi Anand,
the txt file I attached "myRossler.vhd" provide as output 3 signalz x,y and z of 32 bit,
I just want you please to show me how to use your example to make these signals x,y,z
visible in eclipse.
because in the project you attached "myRossler.v" used reg32.v to output Q_export.
It is ineed visible in eclipse by the name MYROSSLER_0_BASE but doesnot give any of the 3 signals x, y or z.
can you please just tell me how to do we with "myRossler.vhd"
- AnandRaj_S_Intel7 years ago
Regular Contributor
WE ARE NOT HERE FOR CREATING PROJECT
It is ineed visible in eclipse by the name MYROSSLER_0_BASE but does not give any of the 3 signals x, y or z.
>>It's Qsys IP instance name. You have to modify myRossler.v & reg32.v as per your requirement.
It is ineed visible in eclipse by the name MYROSSLER_0_BASE but doesnot give any of the 3 signals x, y or z.
>> You will not see any signals in eclipse, You can communicate using base address check system.h for base address.
Refer below link and try to understand how PIO communicated using base address.
https://www.intel.com/content/dam/www/programmable/us/en/pdfs/literature/tt/tt_my_first_nios_sw.pdf
Regards
Anand
- rkaib7 years ago
Occasional Contributor
not at all Anand,
I am not looking for letting you create any project for me,
All I need is to export 3 signals into eclipse,
so can you please show me how to put these signals in the reg_32 you provided,
or at least show me how to modify it so it can export those needed signals
thank you
- AnandRaj_S_Intel7 years ago
Regular Contributor
Read the pdf line by line attached in my previous post.
Try it by user self.
I have shown it for one signal you should do it for 3 signal.
- rkaib7 years ago
Occasional Contributor
Mr Anand,
Now I can see that you haven'y got my meaning yet
and I understand your frustration with me
I am not asking how to export 1 signal,
this I can do it now, from the project and all the documents you post it, I can apply it for more than 1 signals
If I asked something like that, it would silly of me.
My question though is this: I have a function that I called myRossler,
this function perfoms some intermediary calculations and outputs three variables x,y,z
All I am asking if possible, how do I modify reg32_avalon_interface you provided (which works fine)
so I can export them using reg32.
I hope I have made myself clear this time.
sorry for the inconvenience I may have caused you anyways, Annad
- AnandRaj_S_Intel7 years ago
Regular Contributor
Hi,
First let us understand how to communicate to custom component using Nios ii.
You need to have a custom component with avalone interface with some logic to handle the request from Nioss II Memory mapped master.So that custom component signals or registers can be accessed using eclipse/software.
Basically Nios II<->Onchip-ram<-> custom component(myRossler).
I can't see any logic in your myRossler for communicating with Nios II, so that you can access,control or modify the register /signals using software or eclipse project.
Please check attached an example and try to modify your design, If still your facing problem you should undergo training.
https://www.intel.com/content/www/us/en/programmable/support/training/catalog.html
Regards
Anand
- rkaib7 years ago
Occasional Contributor
Hi Anand,
Thank you for your last post,
In which you write in reg32_avalon_interface (IOWR) then you can read from it (IORD) (in eclipse)
It is working fine,
I would ask you Anand to just bear with me a little bit more because I am almost there, so I can
move to something else and not bother you anymore in this topic.
I modified your reg32_avalon_interface.vhd such as:
I have removed the writing input part (write and writedata) because I need just to read the data that the function outputs ( x, y,z) then put them in Q_export.
so I modified your reg32_avalon_interface.vhd file by including my function called myRossler in a new process, It outputs x,y,z. then I have put these outputs in Q_export1,2 and 3.
The last part I am still stuck in is how to read these export data in eclipse.
so would you please just have a final look on my modifications and tell me how to read these data in eclipse.
best regards
- AnandRaj_S_Intel7 years ago
Regular Contributor
Hi,
so I modified your reg32_avalon_interface.vhd file by including my function called myRossler in a new process, It outputs x,y,z. then I have put these outputs in Q_export1,2 and 3
- Also store x,y&z data in r_Mem memory.
- r_Mem (offset) you can access the data using base address plus offset.
Example:
r_Mem (0)<=x;
r_Mem (1)<=y;
r_Mem (3)<=z;
readdata<= r_Mem(slave_address);
IORD_32DIRECT(REG32_AVALON_INTERFACE_0_BASE,0); // you can access x data
IORD_32DIRECT(REG32_AVALON_INTERFACE_0_BASE+1,0);//You can access y data and so on
Regards
Anand
- rkaib7 years ago
Occasional Contributor
thank you for the example.
can you please have a look on what I did in reg32_avalon_interface.vhd. escecially on the read process
quick questions for you Anand:
1.does slave_address variable increment automatically or do I have to do it?
2.how to use Q1_export 1,2 and 3?
3.do I still need to use chipselect variable (because there is no write part)?
4.how data are stored in memory ie (REG32_AVALON_INTERFACE_0_BASE+1,...)?
the data I am getting in eclipse is random (different from the real x, y and z).
Anand I have read your last document carrefully as you suggested
all I need is some assistance from you, I need just to retreive x,y and z correctly
afterwards we close this thread if you see that it has taken too much
thank you, looking forward to hearing from you.