DE2-115: User Manual
DE2-115: User Manual
DE2-115: User Manual
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
Nios II Processor<br />
Software Device Drivers<br />
HAL API<br />
MicroC/OS-II<br />
NicheStack TCP/IP Software Component<br />
Application Specific System Initialization<br />
Web Server Application<br />
Figure 6-33 Nios II Program Software Architecture<br />
Finally, the detail descriptions for Software flow chart of the Web Server program are listed in<br />
below:<br />
Firstly, the Web Server program initiates the MAC and net device then calls the get_mac_addr()<br />
function to set the MAC addresses for the PHY. Secondly, it initiates the auto-negotiation process to<br />
check the link between PHY and gateway device. If the link exists, the PHY and gateway devices<br />
will broadcast their transmission parameters, speed, and duplex mode. After the auto-negotiation<br />
process has finished, it will establish the link. Thirdly, the Web Server program will prepare the<br />
transmitting and receiving path for the link. If the path is created successfully, it will call the<br />
get_ip_addr() function to set up the IP address for the network interface. After the IP address is<br />
successfully distributed, the NicheStack TCP/IP Stack will start to run for Web Server application.<br />
Figure 6-34 describes this demo setup and connections on <strong>DE2</strong>-<strong>115</strong>. The Nios II processor is<br />
running NicheStack on the MicroC/OS-II RTOS.<br />
Note: your gateway should support DHCP because it uses DHCP protocol to request a valid<br />
IP from the Gateway, or else you would need to reconfigure the system library to use static IP<br />
assignment. Furthermore, the web server demonstration uses the RGMII or MII interface to<br />
access the TCP/IP. You can switch the MAC Interface via JP1 and JP2 for Ethernet 0 and<br />
112