Forum Discussion
Altera_Forum
Honored Contributor
18 years ago[LIST]
HAL is just a set of code that has drivers, file system, interrupt handler functions. It can be used in an OS but it does not need it to run. I am not sure if you can re-write the interrupt handler, if the NIOS II interrupt handler is too slow. Some else may know that answer. [/LIST] [LIST] You may have to change you methodology with the NIOS II CPU. The "system.h" holds all the memory mapping for the system (on the FPGA). This file is generated when you first build the project or with the ptf file changes. If you want to read/write to any device or port you can use IOWR/IORD macros in "io.h" header. [/LIST] [LIST] Your lack of knowledge on how the tool works is building your frustration. The debugging module from the NIOS II is setup in SOPC Builder if you want that removed you have to do it there. Also if you goto the project properties (right click on the folder) you can set the optimization for the project in the "C/C++ Build" Menu that should reduce you could size. In addition, The "System Library" menu, there are other settings you can use to reduce your code size. Such as, "Small C Library" or "Reduce device drivers". All of this is in the NIOS II Software Development Handbook. I suggest taking an hour to skim through it. [/LIST] [LIST] C is the most portable language in the world. Your code will compile for NIOS II, it just may not the way you want it to. Evey CPU is different so you may have to modified especially if your accessing memory at a specific location or an off chip devices. You can't assume if it works on an 8051 or ARM it's going to work on NIOS II the way you intended it to. [/LIST]