Add a new platform to U-Boot bootloader
Platform code overview
You can access Digi's U-Boot source code in Github.
The BSP is inside folder board/digi/ where there are three subfolders:
- ccimx6ul: contains common code for the ConnectCore 6UL System-On-Chip (DDR3 initialization, flash, PMIC, Ethernet, and so on).
- ccimx6ulstarter: contains code for the ConnectCore 6UL SBC Express carrier board (Ethernet PHY, power regulators, and so on).
- ccimx6ulsbc: contains code for the ConnectCore 6UL SBC Pro carrier board (Ethernet PHY, power regulators, and so on).
Normally you only need to modify the code inside either ccimx6ulsbc or ccimx6ulstarter, depending on which is closer to your hardware design, to adapt it to your carrier board-specific hardware. You may want to adapt, for example:
- Ethernet PHY, if a different PHY is used on your board.
- PMIC voltages, if different LDOs are used to power interfaces that must be enabled during the boot process.
- GPIOs, IOMUX of pads, per your board's requirements.
Platform include files
Platform include files in include/configs/ are:
- ccimx6ulsbc.h, ccimx6ulstarter.h: defines variables that determine things like the board name, the UART to use as console, the Ethernet PHY address, or the default environment.
- ccimx6ul_common.h: contains common configuration for the ConnectCore 6UL System-On-Chip, like the location of U-Boot and its environment, or the supported interfaces and commands.
- digi_common.h: contains common configuration for Digi embedded products.
You can configure most settings for your carrier board on either the ccimx6ulsbc.h or ccimx6ulstarter.h header files.
Add a new platform
Once you understand the structure of U-Boot platform code, you can duplicate one of the Digi reference platforms so it can be customized. We will call this new platform "custom".
- Fork the U-Boot repository from the Digi Embedded github account into your own account.
- Duplicate the reference platform of your choice. You can use the following commit as reference.
- Customize your platform.
- Either modify the DEY u-boot recipe to point to your forked branch or extract the patch from the repository and add it to your own custom Yocto layer. See Add new machine in custom Digi Embedded Yocto layer for more information.
PDF
