Cannot load basic OpenEmbedded-Core on Freescale i.MX28

I am trying to create and download OpenEmbedded-Core in the evaluation kit for Freescale ARM i.MX28 using the Freescale ARM level for OpenEmbedded-Core . Unfortunately, I cannot find the basic Getting Started guide (although there is a Yocto Getting Started Guide ). Unfortunately, I was unable to “get started” to successfully boot into the base command line on the debug serial port.

Here is what I managed to bring together, and how much I managed to do it.

Extraction sources

mkdir -p oe-core/freescale-arm cd oe-core/freescale-arm git clone git://git.openembedded.org/openembedded-core oe-core git clone git://github.com/Freescale/meta-fsl-arm.git cd oe-core git clone git://git.openembedded.org/meta-openembedded git clone git://git.openembedded.org/bitbake bitbake 

Environment setup

 . ./oe-init-build-env 

This puts us in a new build subdirectory and sets certain environment variables.

Change configuration

Edit the conf/bblayers.conf and local.conf :

conf/bblayers.conf must have meta-fls-arm and meta-oe BBLAYERS for BBLAYERS . For example:.

 BBLAYERS ?= " \ /home/craigm/oe-core/freescale-arm/oe-core/meta \ /home/craigm/oe-core/freescale-arm/oe-core/meta-openembedded/meta-oe \ ${TOPDIR}/../../meta-fsl-arm \ " 

In conf/local.conf I installed:

 BB_NUMBER_THREADS = "4" PARALLEL_MAKE = "-j 4" MACHINE = "imx28evk" 

Build

 bitbake core-image-minimal 

I started this build in one night and it completed successfully for me. The output files were in ~/oe-core/freescale-arm/oe-core/build/tmp-eglibc/deploy/images .

There are two download options that I would like to try, as described below. Downloading from an SD card is simpler, but it takes quite a while (~ 30 minutes) to write the image to the SD card. Downloading from TFTP + NFS is faster, but requires more configuration.

Download from SD card

Recording an image on an SD card:

 sudo dd if=tmp-eglibc/deploy/images/core-image-minimal-imx28evk.sdcard of=/dev/sdc 

It took about 30 minutes (3.5 GB file). Then I put it in the SD card slot of the SD card and turned on the power. He got to the kernel boot and then stopped:

 U-Boot 2012.04.01-00059-g4e6e824 (Aug 23 2012 - 18:08:54) Freescale i.MX28 family at 454 MHz BOOT: SSP SD/MMC #0, 3V3 DRAM: 128 MiB MMC: MXS MMC: 0 *** Warning - bad CRC, using default environment In: serial Out: serial Err: serial Net: FEC0, FEC1 Hit any key to stop autoboot: 0 reading boot.scr ** Unable to read "boot.scr" from mmc 0:2 ** reading uImage 2598200 bytes read Booting from mmc ... ## Booting kernel from Legacy Image at 42000000 ... Image Name: Linux-2.6.35.3-11.09.01+yocto-20 Created: 2012-08-23 7:53:40 UTC Image Type: ARM Linux Kernel Image (uncompressed) Data Size: 2598136 Bytes = 2.5 MiB Load Address: 40008000 Entry Point: 40008000 Verifying Checksum ... OK Loading Kernel Image ... OK OK Starting kernel ... Uncompressing Linux... done, booting the kernel. 

Boot from TFTP + NFS

At first I tried to write U-Boot to an SD card:

 sudo dd if=tmp-eglibc/deploy/images/u-boot-imx28evk.mxsboot-sdcard of=/dev/sdc 

Then I put it in the SD card slot of the SD card and turned on the power. But all I got in the debug serial port was:

 0x8020a01d 

So, I decided to use the U-Boot Freescale distribution for i.MX28 (from my LTIB distribution) on the SD card. I set the appropriate U-Boot options to boot NFS with DHCP options.

 setenv bootargs console=ttyAMA0,115200n8 setenv bootargs_nfs setenv bootargs ${bootargs} root=/dev/nfs ip=dhcp nfsroot=,v3,tcp fec_mac=${ethaddr} saveenv 

I connected to the DD-WRT router with the following DNSmasq settings:

 dhcp-boot=,,192.168.250.106 dhcp-option=17,"192.168.250.106:/home/craigm/rootfs" 

On my main PC, I set up a TFTP server to serve the uImage file from ~/oe-core/freescale-arm/oe-core/build/tmp-eglibc/deploy/images/ .

I also installed the NFS root server to serve the root file system. I edited /etc/exports to serve /home/craigm/rootfs . I extracted the root file system:

 bitbake meta-ide-support rm -Rf ~/rootfs runqemu-extract-sdk tmp-eglibc/deploy/images/core-image-minimal-imx28evk.tar.bz2 ~/rootfs 

Then I put the U-Boot SD card into the SD card slot of the SD card and turned on the power. He got to this, then stopped:

 ... TCP cubic registered NET: Registered protocol family 17 can: controller area network core (rev 20090105 abi 8) NET: Registered protocol family 29 can: raw protocol (rev 20090105) mxs-rtc mxs-rtc.0: setting system clock to 1970-01-01 00:03:33 UTC (213) eth0: Freescale FEC PHY driver [Generic PHY] (mii_bus:phy_addr=0:00, irq=-1) eth1: Freescale FEC PHY driver [Generic PHY] (mii_bus:phy_addr=0:01, irq=-1) Sending DHCP requests . PHY: 0:00 - Link is Up - 100/Full ., OK IP-Config: Got DHCP answer from 192.168.250.106, my address is 192.168.250.142 IP-Config: Complete: device=eth0, addr=192.168.250.142, mask=255.255.255.0, gw=192.168.250.1, host=192.168.250.142, domain=, nis-domain=(none), bootserver=192.168.250.106, rootserver=192.168.250.106, rootpath=/home/craigm/rootfs Looking up port of RPC 100003/3 on 192.168.250.106 Looking up port of RPC 100005/3 on 192.168.250.106 VFS: Mounted root (nfs filesystem) on device 0:15. Freeing init memory: 160K 

I am not sure if it works without a serial console or some other problem. I can ping on 192.168.250.142 , but I cannot use Telnet or SSH.

Questions

  • Is there any tutorial to get started with OpenEmbedded-Core on Freescale i.MX28?
  • Is the Freescale ARM layer really designed to be used with OpenEmbedded-Core, Yocto or what? I really don’t understand how these projects are related.
  • Has anyone else managed to upload a minimal OpenEmbedded-Core image to Freescale i.MX28? If so, how was your procedure different from mine?
  • At this point, I'm not sure if the problem is just a dysfunctional serial console or some other problem. It is difficult to diagnose these problems that do not even allow you to start the base system. Any pointers on how to diagnose at this point?
  • Why was U-Boot broken, so it can't even boot?
+7
source share
1 answer

From the boot message, it looks like U-boot is working fine. U-boot is not broken.

Next boot message

 2598200 bytes read Booting from mmc ... ## Booting kernel from Legacy Image at 42000000 ... Image Name: Linux-2.6.35.3-11.09.01+yocto-20 Created: 2012-08-23 7:53:40 UTC Image Type: ARM Linux Kernel Image (uncompressed) Data Size: 2598136 Bytes = 2.5 MiB Load Address: 40008000 Entry Point: 40008000 Verifying Checksum ... OK Loading Kernel Image ... OK OK Starting kernel ... Uncompressing Linux... done, booting the kernel. 

In the above log, u-boot did its job. "Kernel loading" is where the loader gave control to the kernel.

I think the problem may be in the kernel image or in memory.

To fix a memory problem, try checking the manual and trying to read and write to RAM using the card reference manual.

From the boot log, RAM looks like there is no problem. It has been initialized.

 DRAM: 128 MiB 

Check if the following message causes the following message. * Warning - bad CRC using default environment

Make sure that all devices have been initialized and that nothing is missing after a warning.

+2
source

All Articles