Forum Discussion
Altera_Forum
Honored Contributor
20 years agohow to modify alt_sys_init()?
hello,everybody,when bulid a project,alt_sys_init() initializes every single device in your system--even ones which your application may not use,how can i to modify alt_sys_init() so as to initializes the only device which my project own,the altera dev_kit documents says a "readme.html" file give a example,but i can not find it,can every find it or know how to do it ,thank you,my email:[email protected]
3 Replies
- Altera_Forum
Honored Contributor
hi cosmosd,
check the "hello_alt_main" example that comes with the nios2 ide. --wolf - Altera_Forum
Honored Contributor
yes , i have found the readme.txt that gives a example,thank you!wolf,
but i have another question,how can i generate .elf in the nios 2 IDE,i want to downlode a program into the flash that can run at the reset time,i use the flash programmer ,but it must the *.elf file,but i do not know how to generate *.elf in the nios 2 IDE, i have a think that if can run run in the nios2 SDK shell,but in the shell,use" nr ××.c ",the error message is no makefile,have every one tell me how to generate .elf file in the nios 2 IDE and how to compile C.file in the nios2 SDK shell successfully. thank you! - Altera_Forum
Honored Contributor
usually, Nios II IDE generates elf files by default.
In your project properties dialog check if the Binary Parser under C/C++ Build is set to GNU Elf Parser. You will find the .elf file in the debug directory of your project. The autogenerated makefile generated.x is located in the syslib directory in debug\system_description\. Because I am not using the sdk at all, I can't help you with that question, sorry. --wolf