Nios® II Embedded Design Suite (EDS)
Support for Embedded Development Tools, Processors (SoCs and Nios® II processor), Embedded Development Suites (EDSs), Boot and Configuration, Operating Systems, C and C++
Announcements
Intel Support hours are Monday-Fridays, 8am-5pm PST, except Holidays. Thanks to our community members who provide support during our down time or before we get to your questions. We appreciate you!

Need Forum Guidance? Click here
Search our FPGA Knowledge Articles here.
12455 Discussions

NIOS II Gen2 linker script problem?

Altera_Forum
Honored Contributor II
1,086 Views

I tried to make a NIOS II Gen2 with a single on-chip ram 

 

My flow is 

qsys-edit 

qsys-generate nios2g2.qsys --synthesis=verilog --simulation=verilog --output-directory=nios2g2 

nios2-bsp HAL hal_bsp nios2g2.sopcinfo 

nios2-app-generate-makefile --bsp-dir ./hal_bsp --src-files nios2_test.c 

make 

 

 

but I get the following message at the last make: 

 

/altera/quartus/v14.0_web/nios2eds/bin/gnu/H-x86_64-pc-linux-gnu/bin/../lib/gcc/nios2-elf/4.7.3/../../../../../H-x86_64-pc-linux-gnu/nios2-elf/bin/ld: address 0x85d8 of nios2_test.elf section `.bss' is not within region `ram' 

 

 

I first tried to put code into rom and data in ram, but ran into a similar problem, and went with a single ram since I would assume it was simpler. 

 

The ram should be big enough: 

 

grep memorySize nios2g2.qsys 

<parameter name="memorySize" value="32768" /> 

 

Any idea's?
0 Kudos
2 Replies
Altera_Forum
Honored Contributor II
144 Views

32k will only be big enough for the 'small' template examples.

Altera_Forum
Honored Contributor II
144 Views

Thanks! That was indeed the problem. The program I used was tiny, but I only used default values for the bsp generation so I did not get any of the small libc stuff etc. I increased the size and it's working now.

Reply