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++

kernel not booting

Altera_Forum
Honored Contributor II
1,012 Views

Hello eCos community, 

 

I have been working with a design for some time that is hosted on a NiosII development board (Stratix edition). I have had problems with eCos booting and really need to get to the bottom of it. My setup is: 

 

Quartus 5.0, NiosII 5.0, eCos 5.0 

Hardware design based around the standard design for the Stratix 1s40, (I needed the CF support) modified for use with the 1s10. 

Nios II/s core 

SRAM, SDRAM, FLASH, on-chip ram, CF interface, LCD (not sharing pins with CF) 

executing from SD Ram 

 

I built an eCos config based on the Nios template with the inclusion of support for CF. Eventually I got it to run on one dev board, but it never ran on another board that appears to be the same (both boards are NiosII dev (Statix edition) boards, one stamped NiosII 1.0, and the other NiosII 1.1. 

 

On the board that works, sometime I have to load the software several times from the NiosII IDE before it runs properly. Quite often after loading the software (for run from RAM) a previously loaded flash image will start to run before being interrupted by the software I have uploaded. Other times the image is uploaded properly but with the message "Leaving target processor puased" and there is no more communication to the console although the software runs. 

 

On the board that does not work, the thread of execution does not seem to get to any code start point. If the debugger is run, it is a mess and fails to suspend execution, producing an error. 

 

What might cause this behaviour? 

1) configuration controller not functioning correctly: seems to work for all my other designs that run from Ram and are not eCos based. I uploaded an older and newer design into the configuration controller just to make sure - no difference. 

 

2) something in the eCos config design: Have tried to run from ROMRAM and ROM, with appropriate changes to the Nios core design. 

 

3) some problem in the operation of the linker or somewhere that causes the system to attempt to boot from the wrong place in memory. 

 

4) some problem with the ROM monitor and eCos. 

 

There is a lot of text here, anyone getting to this line after reading it all is truely dedicated to Nios/eCos ! 

 

Any ideas much appreciated.....
0 Kudos
2 Replies
Altera_Forum
Honored Contributor II
267 Views

I wonder if you have the same underlying cause as I do as some of your symptoms seem similar to mine.  

 

See Recent Post: ecos kernel suddenly stops booting 

 

Stefan
0 Kudos
Altera_Forum
Honored Contributor II
267 Views

I have been further developing my eCos based compact flash card application on the stratix dev board and thought I had achieved stable code both for debugging (run from Ram) and run from flash operation. 

 

Along the way I found that CF cards can behave in different ways, for example when debugging (optimisation -O0) only one of my CF cards will mount (the el-cheapo Samsung one). When running from flash with -O3, all my cards will mount. Might be a timming issue, as I guess the -O0 code executes slower. Also, as Stefan Levie has pointed out in this forum, do not attempt to access hardware directly, use the HAL IO macros such as IOWR and IORD. 

 

However, I still get strange behaviour from one stratix dev board that on occassion will not boot eCos while another board will. One time I found when eCos would not boot on the bad board, after waiting a while and loading the same code again, and it ran just fine. I think I may have a intermittently bad board - time to order another one. 

 

Peter
0 Kudos
Reply