Ettus E3XX Getting Started Guide ANGRYVIPER Team
Appendices
A Generating Boot Artifacts
In normal use cases, the SD card should be createdable and usable via the simple steps in Section 4. This section
outlines the steps required to regenerate the artifacts used in previous sections for solely informational purposes and
is not expected for users to have to complete these steps.
A.1 BOOT.bin and u-boot.img
The original first and second stage bootloader artifacts that come installed on the E310 SD card are not suitable
for the Petalinux build OpenCPI uses for its software platform as those artifacts are expecting a uImage kernel with
a separate filesystem partition, while the Petalinux build uses a separate ramdisk image file. The BOOT.bin and
u-boot.img files were rebuilt in order to support booting into this style of Linux images from Ettus’s and Xilinx’s
repositories. In summary, the repositories were cloned and checked out to the proper branch, according to the release
for the e310 and the bitbake recipe, and subsequently cross-compiled for ARM using the Xilinx toolchain. The steps
are shown below.
$ git clone https://github.com/EttusResearch/meta-ettus.git
$ cd meta-ettus && git checkout e300-daisy && cd ..
$ git clone https://github.com/Xilinx/u-boot-xlnx.git
$ cd u-boot-xlnx && git checkout 664820b231b129552e963e1a96b45ac7196ccc81 && cd ..
$ cp meta-ettus/e300-bsp/recipes-bsp/u-boot/ettus-e300/* u-boot-xlnx/
$ cd u-boot-xlnx
$ mv ps7_init.{c,h} board/xilinx/zynq/
$ git apply 0001-E300-Uses-UART0-for-console.patch
$ git apply 0002-E300-Disable-QSPI.patch
$ git apply 0003-Read-mac-address-from-i2c-EEPROM.patch
$ git apply 0001-e300-Added-memory-test.patch
$ source {xilinx-install-dir}/Xilinx/SDK/2013.4/settings64.sh
$ make zynq_zc70x_config CROSS_COMPILE=arm-xilinx-linux-gnueabi-
$ make CROSS_COMPILE=arm-xilinx-linux-gnueabi-
A.2 devicetree.dtb
The device tree needed to be modified in order to register the hardware devices with the correct hardware device
driver in the Petalinux kernel. In summary, the device tree provided by Ettus was decompiled to a device tree source
(dts) file using the device tree compiler (dtc), modified the text file by adding the proper "compatible" strings to
the devices, and subsequently compiled back into a device tree blob (dtb). The steps shown below assume dtc is in
your $PATH and the original device tree blob is in the current working directory.
$ dtc -I dtb -O dts -o devicetree.dts uImage-zynq-e31x-3.dtb
$ vim devicetree.dts
$ dtc -I dts -O dtb -o devicetree.dtb devicetree.dts
Note: The full source for the modified devicetree.dts can be found at <BSPproject>/hdl/platforms/e3xx/sd_
card_source/devicetree.dts
A.3 uImage and uramdisk.image.gz
The uImage and uramdisk.image.gz image files come directly from the default 13_4 OpenCPI software platform.
The 13_3 software platform could not be used due to the SD card driver in 13_3 not supporting the E310’s SD card
device.
18