axf file to SD Card

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 
2,126件の閲覧回数
contra
Contributor III

Hi, I am creating a bare metal application for i.mx28 EVK using ARM-DS5. My project outputs a .axf file. How can I get this onto SD card so that I can boot it?

I don't need to use Linux or Windows CE as my application is very simple and requires boot speed.

ラベル(1)
0 件の賞賛
返信
1 解決策
1,680件の閲覧回数
PeterChan
NXP Employee
NXP Employee

If the AXF contains records in ELF format, you can use the tool "elftosb" to convert the ELF file into i.MX28 binary format .SB.

Usage

usage: elftosb [-?|--help] [-v|--version] [-f|--chip-family <family>]

              [-c|--command <file>] [-o|--output <file>]

              [-P|--product <version>] [-C|--component <version>]

              [-k|--key <file>] [-z|--zero-key] [-D|--define <const>]

              [-O|--option <option>] [-d|--debug] [-q|--quiet] [-V|--verbose]

              [-p|--search-path <path>] files...

Options:

  -?/--help                    Show this help

  -v/--version                Display tool version

  -f/--chip-family <family>    Select the chip family (default is 37xx)

  -c/--command <file>          Use this command file

  -o/--output <file>          Write output to this file

  -p/--search-path <path>      Add a search path used to find input files

  -P/--product <version        Set product version

  -C/--component <version>    Set component version

  -k/--key <file>              Add OTP key, enable encryption

  -z/--zero-key                Add default key of all zeroes

  -D/--define <const>=<int>    Define or override a constant value

  -O/--option <name>=<value>  Set or override a processing option

  -d/--debug                  Enable debug output

  -q/--quiet                  Output only warnings and errors

  -V/--verbose                Print extra detailed log information

After installing the i.MX28 LTIB, the "elftosb" can be found at the path "/opt/freescale/ltib/usr/bin". Please let me know if you need to run in Windows.

Example

Usually, we provide a command file to specify how to load and run the input ELF. The command file can be as simple as

File: uboot.bd

______________________________________________________________________

// STMP378x ROM command script to load and run U-Boot

sources {

    u_boot="/ltib/rootfs/boot/u-boot.elf";

}

section (0) {

    //----------------------------------------------------------

    //  Load and call u_boot - ELF ARM image

    //----------------------------------------------------------

        load u_boot;

        call u_boot;

}

_______________________________________________________________________


and the command line to execute elftosb is

elftosb -z -f imx28 -c ./uboot.bd -o imx28_uboot.sb

元の投稿で解決策を見る

0 件の賞賛
返信
2 返答(返信)
1,680件の閲覧回数
YixingKong
Senior Contributor IV

David, please clickCorrect Answer/Helpful Answer if your issue had been resolved.

Thanks,

Yixing

0 件の賞賛
返信
1,681件の閲覧回数
PeterChan
NXP Employee
NXP Employee

If the AXF contains records in ELF format, you can use the tool "elftosb" to convert the ELF file into i.MX28 binary format .SB.

Usage

usage: elftosb [-?|--help] [-v|--version] [-f|--chip-family <family>]

              [-c|--command <file>] [-o|--output <file>]

              [-P|--product <version>] [-C|--component <version>]

              [-k|--key <file>] [-z|--zero-key] [-D|--define <const>]

              [-O|--option <option>] [-d|--debug] [-q|--quiet] [-V|--verbose]

              [-p|--search-path <path>] files...

Options:

  -?/--help                    Show this help

  -v/--version                Display tool version

  -f/--chip-family <family>    Select the chip family (default is 37xx)

  -c/--command <file>          Use this command file

  -o/--output <file>          Write output to this file

  -p/--search-path <path>      Add a search path used to find input files

  -P/--product <version        Set product version

  -C/--component <version>    Set component version

  -k/--key <file>              Add OTP key, enable encryption

  -z/--zero-key                Add default key of all zeroes

  -D/--define <const>=<int>    Define or override a constant value

  -O/--option <name>=<value>  Set or override a processing option

  -d/--debug                  Enable debug output

  -q/--quiet                  Output only warnings and errors

  -V/--verbose                Print extra detailed log information

After installing the i.MX28 LTIB, the "elftosb" can be found at the path "/opt/freescale/ltib/usr/bin". Please let me know if you need to run in Windows.

Example

Usually, we provide a command file to specify how to load and run the input ELF. The command file can be as simple as

File: uboot.bd

______________________________________________________________________

// STMP378x ROM command script to load and run U-Boot

sources {

    u_boot="/ltib/rootfs/boot/u-boot.elf";

}

section (0) {

    //----------------------------------------------------------

    //  Load and call u_boot - ELF ARM image

    //----------------------------------------------------------

        load u_boot;

        call u_boot;

}

_______________________________________________________________________


and the command line to execute elftosb is

elftosb -z -f imx28 -c ./uboot.bd -o imx28_uboot.sb

0 件の賞賛
返信