Nios® V/II Embedded Design Suite (EDS)
Support for Embedded Development Tools, Processors (SoCs and Nios® V/II processor), Embedded Development Suites (EDSs), Boot and Configuration, Operating Systems, C and C++
12589 Discussions

Includes.h no such file or directory

Altera_Forum
Honored Contributor II
3,066 Views

I am using NIOS II 10, and i am using in my code includes.h. 

 

The problem is that while compiling the nios couldnt discover or find the path of the includes.h... 

 

so i tried to add manually to the project but i recognized that i need dozens of file to add.. 

 

includes.h: no such file or directory 

 

the related code that i have the syntax error in 

 

os_stk task1_stk[task_stacksize]; 

 

alt_u32 canirq0 = canif_0_irq; 

 

so i think the includes.h will solve the problem... 

 

Is there a way to add this header files from directory or smth...i think this will solve my problem
0 Kudos
8 Replies
Altera_Forum
Honored Contributor II
1,634 Views

Compiler include paths are added to the project properties: 

 

Here's how: Right-click the project, choose 'C/C++ Build', Tool Settings tab, the General node on the NIOS II Compiler branch. You can add compiler flags and set optimization levels here as well. 

 

Bill A
0 Kudos
Altera_Forum
Honored Contributor II
1,634 Views

it worked with me but after adding four paths.... i got 36 errors from ucos_ii.h  

 

like: 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_task_suspend_en: include code for ostasksuspend() and ostaskresume()" 

 

then another error: 

 

error: `alt_irq_not_connected' undeclared here (not in a function) 

 

So i dont know if i miss paths or smth wrong.
0 Kudos
Altera_Forum
Honored Contributor II
1,634 Views

In the attchement, you will find the added and the discovered paths. 

 

Do you i think i need to add more or?
0 Kudos
Altera_Forum
Honored Contributor II
1,634 Views

You have to modify os_cfg.h for your application. It found the# includes. Now it's not happy about the configured contents. 

 

Bill A
0 Kudos
Altera_Forum
Honored Contributor II
1,634 Views

the project that i am working on is already existed and tested. i just want to open, build, and then run it on my pc to see the output. 

 

another big problem that I am not familiar with C and i dont know how to configure this file.... 

 

So do you have any advices?
0 Kudos
Altera_Forum
Honored Contributor II
1,634 Views

 

--- Quote Start ---  

the project that i am working on is already existed and tested. i just want to open, build, and then run it on my pc to see the output. 

--- Quote End ---  

 

 

Then that project should have it's own local uC/OS-II files and an OS_CFG.h already configured. If as you say you have a project already done then it should still build now unless the files that are# included are not the same. Search for other OS_CFG.h files. 

 

Bill A
0 Kudos
Altera_Forum
Honored Contributor II
1,634 Views

i asked the one who created the project and he sent me the ucos_ii.h and os_cfg.h and i found that they are the same like mine. He told me that he didnt include any path for his project. BUT for me i had to add the files manually to remove the errors. 

 

SO it is really weird that we have the same files and everything and i have thses 

 

 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_arg_chk_en: enable (1) or disable (0) argument checking" blank_project_mah line 1783 1286796718005 919 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_cpu_hooks_en: uc/os-ii hooks are found in the processor port files when 1" blank_project_mah line 1788 1286796718005 920 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_debug_en: allows you to include variables for debugging or not" blank_project_mah line 1798 1286796718005 921 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_flag_en: enable (1) or disable (0) code generation for event flags" blank_project_mah line 1438 1286796718005 896 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_lowest_prio: defines the lowest priority that can be assigned" blank_project_mah line 1803 1286796718005 922 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_max_events: max. number of event control blocks in your application" blank_project_mah line 1808 1286796718005 923 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_max_tasks: max. number of tasks in your application" blank_project_mah line 1642 1286796718005 902 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_mbox_en: enable (1) or disable (0) code generation for mailboxes" blank_project_mah line 1480 1286796718005 897 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_mem_en: enable (1) or disable (0) code generation for memory manager" blank_project_mah line 1514 1286796718005 898 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_mutex_en: enable (1) or disable (0) code generation for mutex" blank_project_mah line 1540 1286796718005 899 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_q_en: enable (1) or disable (0) code generation for queues" blank_project_mah line 1562 1286796718005 900 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_sched_lock_en: include code for osschedlock() and osschedunlock()" blank_project_mah line 1817 1286796718005 924 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_sem_en: enable (1) or disable (0) code generation for semaphores" blank_project_mah line 1612 1286796718005 901 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_task_change_prio_en: include code for ostaskchangeprio()" blank_project_mah line 1675 1286796718005 907 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_task_create_en: include code for ostaskcreate()" blank_project_mah line 1679 1286796718005 908 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_task_create_ext_en: include code for ostaskcreateext()" blank_project_mah line 1683 1286796718005 909 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_task_del_en: include code for ostaskdel()" blank_project_mah line 1687 1286796718005 910 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_task_idle_stk_size: idle task stack size" blank_project_mah line 1659 1286796718005 903 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_task_name_size: determine the size of task names" blank_project_mah line 1691 1286796718005 911 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_task_profile_en: include data structure for run-time task profiling" blank_project_mah line 1827 1286796718005 925 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_task_query_en: include code for ostaskquery()" blank_project_mah line 1699 1286796718005 913 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_task_stat_en: enable (1) or disable(0) the statistics task" blank_project_mah line 1663 1286796718005 904 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_task_stat_stk_chk_en: check task stacks from statistics task" blank_project_mah line 1671 1286796718005 906 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_task_stat_stk_size: statistics task stack size" blank_project_mah line 1667 1286796718005 905 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_task_suspend_en: include code for ostasksuspend() and ostaskresume()" blank_project_mah line 1695 1286796718005 912 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_task_sw_hook_en: allows you to include the code for ostaskswhook() or not" blank_project_mah line 1832 1286796718005 926 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_tick_step_en: allows to 'step' one tick at a time with uc/os-view" blank_project_mah line 1837 1286796718005 927 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_ticks_per_sec: sets the number of ticks in one second" blank_project_mah line 1709 1286796718005 914 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_time_dly_hmsm_en: include code for ostimedlyhmsm()" blank_project_mah line 1713 1286796718005 915 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_time_dly_resume_en: include code for ostimedlyresume()" blank_project_mah line 1717 1286796718005 916 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_time_get_set_en: include code for ostimeget() and ostimeset()" blank_project_mah line 1721 1286796718005 917 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_time_tick_hook_en: allows you to include the code for ostimetickhook() or not" blank_project_mah line 1842 1286796718005 928 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h# error "os_cfg.h, missing os_tmr_en: when (1) enables code generation for timer management" blank_project_mah line 1731 1286796718005 918 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h error: `os_lowest_prio' undeclared here (not in a function) blank_project_mah line 736 1286796718005 893 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h error: `os_max_tasks' undeclared here (not in a function) blank_project_mah line 756 1286796718005 895 

c:/altera/10.0sp1/nios2eds/components/micrium_uc_osii/ucosii/inc/ucos_ii.h error: `os_task_idle_stk_size' undeclared here (not in a function) blank_project_mah line 748 1286796718005 894 

 

so maybe there is smth in the options of the project...i dont really know... 

 

Does anyone know what to do or try??
0 Kudos
Altera_Forum
Honored Contributor II
1,634 Views

I had the similar problem. I forgot to select RTOS. To do this  

 

Right click project -> System Library Properties  

 

Here you can select an RTOS from dropdown.
0 Kudos
Reply