Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
20 years ago

uClinux without Flash (again)

I decided to give uClinux a try on my custom board, but I only have an SD card slot, no CFI. When reading the install guide for uClinux, and when trying it, it won't let me build a kernel project without a CFI device present? Is there any way to get around this? It seems odd that I can't build the kernel and run from DRAM, and then write to the SD Card if I wish to boot...

Thx!

58 Replies

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    "all of the thread is talking about how to build the kernel under linux"

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    > I'd like to build out vmlinux.bin in order to let u-boot to boot or flash-programmer.

    > How to do it ?

    For u-boot:

    1. Optionally compress the linux binary.

    2. Create the u-boot image file from the linux binary (or compressed binary).

    3. Load the image file into ram.

    4. Execute the u-boot "bootm" command.

    Regards,

    --Scott
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    1.

    -----------------------------------------------------

    In redhat, when I

    make ARCH=....

    it just built out vmlinux, which is used for "nios2-download -g vmlinux" to debug in SDRAM. I'd like to get vmlinux.bin, which is used for nios2-flash-program.

    is it also nios2-elf-objcopy??

    2.

    -----------------------------------------------------

    there is a exe file in <plugs>/<microtronix>/application/bin/elf2flt.exe

    but how to get elf2flt in redhat?

    I cannot surf marc&#39;s page to build toolchain.
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Regarding Q1, I&#39;m not sure, I tried doing the same at one point, but I don&#39;t think I ever got it...

    Regarding elf2flt, check the linux distribution CD where you got all the linux binaries from. If it&#39;s not there, I&#39;m afraid you will have to build the toolchain somehow... or at least get those binaries. You can probably email Marc himself and ask for binaries.
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    1. There is no elf2flt in the linux distribution CD. The source is in the examples/software/linux/utils/elf2flt. But you need libbfd to build it. It should be better to do the buildroot following the marc&#39;s page.

    2. "nios2-elf-objcopy -O binary vmlinux vmlinux.bin" will create the raw binary file.
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    --- Quote Start ---

    originally posted by hippo@Dec 14 2005, 08:06 PM

    1. there is no elf2flt in the linux distribution cd. the source is in the examples/software/linux/utils/elf2flt. but you need libbfd to build it. it should be better to do the buildroot following the marc&#39;s page.

    2. "nios2-elf-objcopy -o binary vmlinux vmlinux.bin" will create the raw binary file.

    <div align='right'><{post_snapback}> (index.php?act=findpost&pid=11562)

    --- quote end ---

    --- Quote End ---

    I agree with hippo - the toolchain is ultimately the best way to go... I tried working with the windows one, and it&#39;s just so much slower and you can&#39;t automate it like with linux - so I would definitely advise trying to build it.
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    --- Quote Start ---

    originally posted by mountain8848@Dec 15 2005, 03:13 AM

    but i cannot surf marc&#39;s website here, china.

    <div align='right'><{post_snapback}> (index.php?act=findpost&pid=11578)

    --- quote end ---

    --- Quote End ---

    I&#39;m looking for a Proxy Server outside China,so we can visit the site