Forum Discussion
Altera_Forum
Honored Contributor
16 years agoHi again everyone,
I have found a solution to my problem. It was essentially a brute force approach. I'm going from memory, so I may accidentally leave out some details during my explanation... I added a second OpenCores MAC Controller to my SOPC project. I named it 'eth_web'. I auto-assigned base addresses and IRQs, then generated my SOPC system. I modified my top level VHDL to include the changes to my SOPC system. Then I compiled in Quartus II. I then copied my PTF to my uClinux development system. I first made a copy of open_eth.c and named the copy open_eth_2.c. In open_eth_2.c I renamed a few of the functions (the names escape me at the moment) from 'whatever()' to 'whatever_2()'. I also modified the MAC address assignments and the hard-coded 'na_igor_mac' values to 'na_eth_web'. Space.c will need to be modified to include the second OpenCores MAC instance as well as the new _2 function calls. I think for the _2 call in Space.c, I passed a parameter value of '1' instead of '0' like the rest of the calls did. I believe I also had to modify one of the Makefiles to include the open_eth_2.o file or something like that. I did a 'make clean', 'make vendor_hwselect...', 'make romfs', and finally 'make'. After copying my zImage file back to my Windows PC, I loaded my SOF and uploaded my zImage to my board. All said and done, I had two OpenCore MAC controllers available in uClinux. Eth0 and Eth1. I did a simple 'ifconfig eth1 192.168.0.1 netmask 255.255.255.0' to associate the MAC controller with an IP and away I go. This may not be the most efficient or best way to solve the problem, but it definitely worked and may be a starting point for further investigation in the future. Hope this helps anyone that may be interested! -Jason