r45_m7_sample_bringup

M7 Bringup Steps

Yocto Configuration

  • Add m7-sample path to file m7-sample.bb as shown below:
    Alt text
  • Add the required cross-compilation toolchain to file cortex-m-toochain.bb
    Alt text
  • m7-sample will be compiled into the image under name m7-boot,this is shown in the figure below:
    Alt text
  • next you should add the DISTRO_FEATURE:append = "m7-boot" to build\conf\local.conf as shown below:
    Alt text
  • and then you can use commandbitbake m7-sample to build the m7-sample.bb for generate the sdcard file.
    • Notice: if you want to build your own new code add in m7-sample project under build/tmp/work/cortexa53-crypto-fsl-linux/m7-sample/1.0-r0/git only,
      you can use the command bitbake m7-sample -c do_compile -f to build it.

Pre-analyze fip.s32-sdcard.m7

  • Before analyzing the mirror, it is necessary to understand the structure of the IVT, as shown below:
    Alt text

  • Application boot as shown below:
    Alt text

Example

  • fip.s32-sdcard.m7 information as shown below:
    Alt text

  • IVT table shows that the entry address of the ivt header is 0x1000, and the Applicatioin boot entry pointer address is 0x1200( store the application boot ram address)
    Alt text

  • Application boot image structure(BOOT_SEQ=0) as shown below:
    Alt text

  • From the Application boot image structure and you can find the RAM_start_pointer, RAM_entry pointer and Code_len;
    Alt text

  • M7.bin actual size is 0xdbe0 as shown below:
    Alt text

  • M7.bin start address as shown below:
    Alt text

  • M7.bin end address(start address + actual size) as shown below:
    Alt text

  • fip.bin as shown below:
    Alt text

  • 0x11240 is the fip.bin start address
    Alt text

  • fip.bin size is 0xf0690
    Alt text