I just built and compiled the Nios II Ethernet Standard Design Example with no problems, and successfully programmed it on my Cyclone III Nios II NEEK development kit.I did a quick SW check by running the "Hello World" sample software with no problem. Now, getting into the more serious stuff with an attempt to compile and run the Web Server sample code. No luck! Got the following error: web_server.c:346: error: 'led_pio_base' undeclared (first use in this function)
Can someone tell me where 'LED_PIO_BASE' should be declared, and perhaps WHY it is not declared? Here is the link to the example design on Altera's Website http://www.altera.com/support/examples/nios2/exm-net-std-de.html
It's because you have to declare in your sopc a component name LED_PIO that must be of the type GPIO OUTPUT. If you dont want this you can remove all the references to LED_PIO in the sourc codes of the webserver
Ah ha! The error I was getting was:web_server.c:346: error: 'led_pio_base' undeclared (first use in this function)
The example Qsys design implements two Qsys submodules, one of which contains the LED_PIO component. I checked to see if it was defined in the system.h file as you suggested, and found that it had the name "PERIPHERAL_SUBSYSTEM_LED_PIO_BASE". I changed the web_server.c file to use this name instead of "LED_PIO_BASE" and it compiled and ran correctly. Thanks for your help and quick reply to my plea for help. now, how do we get this information to altera so they can make the correction to the example design?
Were you using the copy of web server in the design file? I just downloaded the NEEK version and the software looks fine to me on line 346 (using a hierarchical name).
i am getting the following error while running web server demo program in nios ii sbt for eclipse. i looked at the qsys the name of the pio is led_pio..
web_server.c:346: error: 'led_pio_base' undeclared (first use in this function)
can someone tell me where 'led_pio_base' should be declared, and perhaps why it is not declared?