Altera_Forum
Honored Contributor
13 years agoQuestion about #include in NIOS II?
I have built the following file:
#include <stdio.h># include "system.h"# include "altera_avalon_pio_regs.h"# include "altera_up_avalon_rs232.h"
int main()
{
printf("Hello from Nios II!\n");
int count = 0;
int delay;
while(1)
{
IOWR_ALTERA_AVALON_PIO_DATA(PIO_LED_BASE, count & 0x01);
delay = 0;
alt_up_rs232_write_data('hi');
while(delay<2000000)
{
delay ++;
}
count ++;
}
return 0;
} ---My system recognizes the first 3 includes but has a problem recognizing # include "altera_up_avalon_rs232.h" It says this file doesnt exist. Why is this? # include "altera_avalon_pio_regs.h" is located at: C:\altera\11.1sp1\ip\altera\sopc_builder_ip\altera_avalon_pio and # include "altera_up_avalon_rs232.h" is located at: C:\altera\11.1sp1\ip\University_Program\Communications\altera_up_avalon_rs232