ZedBoard
2021-11-19
Get the requirements:
./petalinux-v2021.1-final-installer.run --dir 2021.1 --platform arm
. 2021.1/settings.sh
petalinux-util --webtalk off
petalinux-create -t project -s avnet-digilent-zedboard-v2021.1-final.bsp
Uncomment the #OE_TERMINAL = "tmux"
line in project-spec/meta-user/conf/petalinuxbsp.conf
petalinux-config --get-hw-description ${XSA_DIR}/system.xsa
# Imports the custom hardware configuration
#
# Image Packaging Configuration --->
# Root filesystem type (EXT4 (SD/eMMC/SATA/USB)) --->
# (X) EXT4 (SD/eMMC/SATA/USB)
# [ ] Copy final images to tftpboot
petalinux-config -c kernel
# Device Drivers
# <*> Industrial I/O support --->
# Inertial measurement units --->
# <M> InvenSense ICM-426xx I2C driver
# <M> InvenSense ICM-426xx SPI driver
# <*> I3C support --->
# <M> Cadence I3C master driver
# [*] SPI support --->
# <M> User mode SPI device driver support
petalinux-config -c rootfs
# https://github.com/Xilinx/meta-petalinux/tree/master/recipes-core/packagegroups
# Add self-hosted for gcc, make, and vim
#
# Petalinux Package Groups
# packagegroup-petalinux
# packagegroup-petalinux
# packagegroup-petalinux-dev
# packagegroup-petalinux-networking-stack
# packagegroup-petalinux-networking-stack
# packagegroup-petalinux-networking-stack-dev
# packagegroup-petalinux-opencv
# packagegroup-petalinux-opencv
# packagegroup-petalinux-opencv-dev
# packagegroup-petalinux-python-modules
# packagegroup-petalinux-python-modules
# packagegroup-petalinux-python-modules-dev
# packagegroup-petalinux-self-hosted
# packagegroup-petalinux-self-hosted
# packagegroup-petalinux-self-hosted-dev
# packagegroup-petalinux-utils
# packagegroup-petalinux-utils
# packagegroup-petalinux-utils-dev
# Image Features
# [*] package-management
petalinux-build
# Build petalinux-image-minimal
petalinux-package --boot --fsbl --fpga --u-boot
# Generates BOOT.BIN containing:
# 1. FSBL (images/linux/zynq_fsbl.elf)
# 2. FPGA bitstream (images/linux/system.bit)
# 3. U-Boot (images/linux/u-boot.elf)
# 4. DTB (images/linux/system.dtb)
Split SD card into two partitions:
a
) vfat (+1G
)More info at the wiki page How to format SD card for SD boot
sudo fdisk /dev/sdb
sudo mkfs.vfat -F 32 -n BOOT /dev/sdb1
sudo mkfs.ext4 -L rootfs /dev/sdb2
# Mount boot partition (/dev/sdb1 on /media/connure/BOOT)
# Copy over BOOT.BIN, boot.scr, and image.ub
sudo dd if=rootfs.ext4 of=/dev/sdb2 bs=1M status=progress
# Or, mount rootfs partition (/dev/sdb2 on /media/connure/rootfs) and
sudo tar -zxvpf rootfs.tar.gz -C /media/connure/rootfs
sync
Make sure jumpers are set correctly on ZedBoard
Look at the Hardware User's Guide
Simple checklist:
Compare Vadj Select (J18
) jumper on ZedBoard to that of the firmware design's
Seems to default to 2.5 V on default BSP and when generating a custom XSA
Though, Digilent's Zedboard-Master.xdc sets it to 1.8 V
grep
for VCCO_34
and VCCO_35
corresponding to FPGA Bank 34 and FPGA Bank 35
JP6
shorted for SD Card boot on CES silicon
JP11
--JP7
controlling the Boot Mode (defaults to 01100
)
python3 -m serial.tools.list_ports
# List all serial ports
python3 -m serial.tools.miniterm --eol LF --raw COM3 115200
# Connect over serial to the UART port on ZedBoard
Already installed by one of the Petalinux Package Groups
from the rootfs
config step
Provided by the github.com/lathiat/nss-mdns package in the sswreleases repository
# /media/connure/rootfs/etc/avahi/avahi-daemon.conf
[server]
host-name=zedboard
domain-name=local
allow-interfaces=eth0
[publish]
publish-addresses=yes
publish-hinfo=yes
publish-workstation=yes
publish-domain=yes
publish-aaaa-on-ipv4=yes
publish-a-on-ipv6=no
# /media/connure/rootfs/home/petalinux/.ssh/authorized_keys
cat id_ed25519.pub >> authorized_keys
# Permanent pub-key auth
ssh petalinux@zedboard.local
# SSH into device
More info in the Xilinx Linux kernel DeviceTree doc's configfs-overlays.txt
sudo su
mkdir /sys/kernel/config/device-tree/overlays/icm42605
cat /sys/kernel/config/device-tree/overlays/icm42605/status
cat icm42605.dtbo > /sys/kernel/config/device-tree/overlays/icm42605/dtbo
cat /sys/kernel/config/device-tree/overlays/icm42605/status