Forum Discussion
Altera_Forum
Honored Contributor
20 years agoException Address Problem
I am new to using NIOS II and have run through a number of examples and tutorials successfully. I have been able to succesfully run the "Hello World" program on the "standard" example for the N...
Altera_Forum
Honored Contributor
20 years ago --- Quote Start --- originally posted by david_cai@Apr 17 2006, 07:25 AM hi conners,
<div class='quotetop'>quote
--- quote end ---
--- quote start ---
if i then go to system library in properties of the syslib folder that has been created i see that the program memory, read only data memory and read/write data memory heap memory and stack memory are all set to sdram. this conflicts with the settings i made in builder. is this correct? --- Quote End --- It is correct. The compiler generate many sector of Nios, see the following: 0 .entry 00000000 00800c20 00800c20 00000094 2**5 CONTENTS, ALLOC, LOAD, READONLY, CODE 1 .exceptions 000001a8 01000020 01000020 00000094 2**2 CONTENTS, ALLOC, LOAD, READONLY, CODE 2 .text 0001a8a4 010001c8 010001c8 0000023c 2**2 CONTENTS, ALLOC, LOAD, READONLY, CODE 3 .rodata 0001d380 0101aa6c 0101aa6c 0001aae0 2**2 CONTENTS, ALLOC, LOAD, READONLY, DATA 4 .rwdata 00001f5c 01037dec 01037dec 00037e60 2**2 CONTENTS, ALLOC, LOAD, DATA, SMALL_DATA 5 .bss 000004d0 01039d48 01039d48 00039dbc 2**2 ALLOC, SMALL_DATA 6 .sdram_0 00000000 0103a218 0103a218 00039dbc 2**0 CONTENTS 7 .onchip_memory 00000000 00800c40 00800c40 00039dbc 2**0 CONTENTS You can only set your .exceptions address in SOPC Builder, and can't modify it in NiosII IDE. <div class='quotetop'>QUOTE </div> --- Quote Start --- however i do not see "Hello World" printed to the console window.[/b] --- Quote End --- About this issue, I think you can search in this forum, there are many posts discussing it. FYI. David <div align='right'><{post_snapback}> (index.php?act=findpost&pid=14425)</div> [/b] --- Quote End --- David, Thank you for your reply. I have checked my objdump file and can see where the exceptions should reside. From what i can see this file looks ok and the exception address falls within valid address space. I have re-run my program but removed the printf and replaced it with some code that increments a variable. When I run this program in debug mode I cannot get the code to break in main at all when my exception address is set to be located in ext_ram in SOPC Builder. Identical code will break if i set the exception address to be located in SDRAM. This is the only difference between the two builds. This leads me to believe that it is not a printf problem and is completely down to the exception address being located away from SDRAM. Any more tips and advice that you can give would be greatly appreciated. I dont think it should be this difficult!!! Thanks again Conners