Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save Hypnotriod/02cbbb23e8f0f6e0e7004cd8607eb7f0 to your computer and use it in GitHub Desktop.

Select an option

Save Hypnotriod/02cbbb23e8f0f6e0e7004cd8607eb7f0 to your computer and use it in GitHub Desktop.
Jetpack 4.6.6 installation on the Waveshare JETSON-NANO-DEV-KIT with 16GB eMMC

Jetpack 4.6.6 installation on the Waveshare JETSON-NANO-DEV-KIT with 16GB eMMC

Based on www.waveshare.com/wiki/JETSON-NANO-DEV-KIT

Prepare the Jetpack 4.6.6 on Ubuntu PC

mkdir jetpack.4.6.6
cd jetpack.4.6.6
export WORKSPACE_DIR=$PWD
wget https://developer.nvidia.com/embedded/l4t/r32_release_v7.6/t210/jetson-210_linux_r32.7.6_aarch64.tbz2
wget https://developer.nvidia.com/embedded/l4t/r32_release_v7.6/t210/tegra_linux_sample-root-filesystem_r32.7.6_aarch64.tbz2
wget https://developer.nvidia.com/downloads/embedded/L4T/r32_Release_v7.5/overlay_32.7.5_PCN211181.tbz2
sudo tar -xjf jetson-210_linux_r32.7.6_aarch64.tbz2
cd ${WORKSPACE_DIR}/Linux_for_Tegra/rootfs/
sudo tar -xjf ../../tegra_linux_sample-root-filesystem_r32.7.6_aarch64.tbz2
cd ${WORKSPACE_DIR}/Linux_for_Tegra/
sudo ./apply_binaries.sh
cd ${WORKSPACE_DIR}
sudo tar -xjf overlay_32.7.5_PCN211181.tbz2
  • Patch the device tree to enable the SD Card slot
cd ${WORKSPACE_DIR}/Linux_for_Tegra/kernel/dtb
sudo dtc -I dtb -O dts -o tegra210-p3448-0002-p3449-0000-b00.dts tegra210-p3448-0002-p3449-0000-b00.dtb
sudo nano tegra210-p3448-0002-p3449-0000-b00.dts
  • Search for the sdhci@700b0400 section with: Ctrl+W -> type sdhci@700b0400 { -> Enter
  • Replace status = "disabled"; with status = "okay";
  • Replace uhs-mask = <0x00>; with uhs-mask = <0xc>;
  • Add next lines above the uhs-mask = <0xc>;:
cd-gpios = <0x5b 0xc2 0x0>;
sd-uhs-sdr104;
sd-uhs-sdr50;
sd-uhs-sdr25;
sd-uhs-sdr12;
no-mmc;
  • Compile the device tree overlay:
sudo dtc -I dts -O dtb -o tegra210-p3448-0002-p3449-0000-b00.dtb tegra210-p3448-0002-p3449-0000-b00.dts
  • Add jumper between the FC REC and GND pins on the Jetson's carrier board to enter the Recovery Mode and connect the device to the Linux PC via microUSB.
  • Flash the target:
cd ${WORKSPACE_DIR}/Linux_for_Tegra/
sudo ./flash.sh jetson-nano-emmc mmcblk0p1

On the Jetson Nano:

  • Boot the Jetson Nano with display and keyboard attached to proceed with the initial configurations.
  • Beware of any Nvidia system updates, as they may override the Device Tree SD Card patches.
  • To move the root file system from the eMMC to the SD Card do:
# Unmount the SD Card if mounted
sudo umount /media/ <TAB> <TAB>
sudo mkfs.ext4 /dev/mmcblk1
sudo mount /dev/mmcblk1 /mnt
sudo cp -ax / /mnt
sudo rm -rf /mnt/boot
sudo umount /mnt/
  • Replace the content of the U-Boot /boot/extlinux/extlinux.conf file with the following, to add the sdcard boot option:
TIMEOUT 30
DEFAULT sdcard

MENU TITLE L4T boot options

LABEL emmc
      MENU LABEL primary kernel (emmc)
      LINUX /boot/Image
      INITRD /boot/initrd
      APPEND ${cbootargs} quiet root=/dev/mmcblk0p1 rw rootwait rootfstype=ext4 console=ttyS0,115200n8 console=tty0 fbcon=map:0 net.ifnames=0 sdhci_tegra.en_boot_part_access=1

LABEL sdcard
      MENU LABEL primary kernel (sdcard)
      LINUX /boot/Image
      INITRD /boot/initrd
      APPEND ${cbootargs} quiet root=/dev/mmcblk1 rw rootwait rootfstype=ext4 console=ttyS0,115200n8 console=tty0 fbcon=map:0 net.ifnames=0 sdhci_tegra.en_boot_part_access=1
  • reboot
  • The emmc or sdcard options can be chosen in the U-Boot prompt by typing 1 or 2 and hit Enter. You will need to connect the TTL UART Converter to the UART TXD, UART RXD and GND pins of the carried board to access the Linux primary console.

Python3 configuration

cd ~ && sudo sh -c "echo 'alias python=python3' >> .bashrc"
source ~/.bashrc
pip3 install --upgrade setuptools
pip3 install --upgrade pip

Install Nvidia Jetpack on the Jetson Nano SD Card

sudo apt update
sudo apt install nvidia-jetpack

Jetson Inference L4T-R32.7.1

sudo apt-get update
sudo apt-get install git cmake libpython3-dev python3-numpy
git clone --recursive -b L4T-R32.7.1 https://github.com/dusty-nv/jetson-inference
cd jetson-inference
mkdir build
cd build
cmake ../
make -j$(nproc)
sudo make install
sudo ldconfig
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment