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

How to boot uClinux automatically

Altera_Forum
Honored Contributor II
1,937 Views

Hi, 

 

Please explain to me how to boot uClinux kernel and filesystem and Nios2 configuration, when power on the Altera Nios2 cyclone development board. I need to download the FPGA configuration to flash, how can I do it. Do I need some kind of bootloader for the uClinux? 

 

Regards CoolMan
0 Kudos
9 Replies
Altera_Forum
Honored Contributor II
442 Views

I would do the following: 

 

(1) Ensure that your hardware design's reset location is set to the beginning of flash 

(2) Upload the hardware design into flash 

(3) Build a kernel to match the hardware design 

(4) Upload the kernel to flash 

 

If you have an Altera board, you could use the "standard" example quartus project as a starting point. Build a kernel using the default configuration minus the IDE controller and upload both the quartus project and kernel to flash. The next time you restart the board, Linux should start up.
0 Kudos
Altera_Forum
Honored Contributor II
442 Views

Ken, 

 

I followed your instructions but failed. 

 

Coolman, 

 

Do you make it? 

 

It seems there is something wrong with the .sof file.
0 Kudos
Altera_Forum
Honored Contributor II
442 Views

Hi, 

 

I tried to download the kernel-project and the hardware design with flashprogrammer, but it failed. Then I downloaded the hardware design file (.pof) with Quartus programmer and ByteblasterII to EPSC4-device and the kernel project with flashprogrammer to flash, it worked succesfully! 

 

Now I don't have to download .sof-file each time when powering on the board. 

 

But tell me, how I can get the rid of starting the uclinux with terminal console. I want that uclinux starts running immadiately when I turns the power on. 

 

-CoolMan
0 Kudos
Altera_Forum
Honored Contributor II
442 Views

Are you using a JTAG UART ?

0 Kudos
Altera_Forum
Honored Contributor II
442 Views

 

--- Quote Start ---  

originally posted by coolman@Feb 14 2005, 01:46 AM 

hi, 

 

i tried to download the kernel-project and the hardware design with flashprogrammer, but it failed. then i downloaded the hardware design file (.pof) with quartus programmer and byteblasterii to epsc4-device and the kernel project with flashprogrammer to flash, it worked succesfully! 

 

now i don't have to download .sof-file each time when powering on the board. 

 

but tell me, how i can get the rid of starting the uclinux with terminal console. i want that uclinux starts running immadiately when i turns the power on. 

 

-coolman 

--- Quote End ---  

 

CoolMan, 

 

Could you tell me which hardware configuration you are using now (.pof)? You build your kernel and filesystem based on that file? 

 

Why not use .sof file? 

 

Thanks, 

Neo
0 Kudos
Altera_Forum
Honored Contributor II
442 Views

Hi Neo 

 

I'm using a standard Nios2 configuration for cyclone device. Yes, I built my kernel and filesystem based on that. First I downloaded *.pof - file to EPCS4 with ByteBlaster and then the kernel and filesystem to flash with Flashprogrammer. 

 

 

EPSC4 device needs a *.pof - file when programming with ByteBlasterII. 

 

-CoolMan
0 Kudos
Altera_Forum
Honored Contributor II
442 Views

Hi again, 

 

there is own header for EPCS4 in my development board, I used that instead of JTAG UART - header when downloading the configuration. 

 

-CoolMan
0 Kudos
Altera_Forum
Honored Contributor II
442 Views

Sorry, of course I means EPSC4 - device. 

 

-CoolMan http://forum.niosforum.com/work2/style_emoticons/<#EMO_DIR#>/rolleyes.gif
0 Kudos
Altera_Forum
Honored Contributor II
442 Views

It sounds as if you have your device being configured corectly (automatically). 

 

I&#39;m assuming your code is programed into your external (not on chip) flash, and compiled corectly. 

 

The CPU needs to be set up to boot from a particular memory location. If you are usually loading code into RAM, and it runs, then the CPU is probably not configured corectly. Recompile (rebuild) your CPU with its reset location where your external ROM (flash) is. Reprogram your configuration device, and then it should boot from the flash.
0 Kudos
Reply