NVIDIA Tegra Jetson TX2

Board description

NVIDIA Jetson TX2 hardware with computer vision, GPU and multimedia support.

image

URL: https://www.nvidia.com/en-us/autonomous-machines/embedded-systems-dev-kits-modules/
Wiki: https://elinux.org/Jetson_TX2

Test results

The Yocto Project releases in the table below have been tested by the Mender community. Please update it if you have tested this integration on other Yocto Project releases:

Yocto Project Build Runtime
sumo (2.5) :test_works: :test_works:
thud (2.6) :test_works: :test_works:
warrior (2.7) :test_works: :test_works:
zeus (3.0) :test_works: :test_works:

Build Means that the Yocto Project build using this Mender integration completes without errors and outputs images.
Runtime Means that Mender has been verified to work on the board. For U-Boot-based boards, the integration checklist has been verified.

Getting started

Prerequisites

  • A supported Linux distribution and dependencies installed on your workstation/laptop as described in the Yocto Mega Manual
    • NOTE. Instructions depend on which Yocto version you intend to use.
  • Google repo tool installed and in your PATH .

Setup Yocto environment

Set the Yocto Project branch you are building for:

# set to your branch, make sure it is supported (see table above)
export BRANCH="zeus" 

Create a directory for your mender-tegra setup to live in and clone the
meta information.

mkdir mender-tegra && cd mender-tegra

Initialize repo manifest:

repo init -u https://github.com/mendersoftware/meta-mender-community \
           -m meta-mender-tegra/scripts/manifest-tegra.xml \
           -b ${BRANCH}

Fetch layers in manifest:

repo sync

Setup build environment

Initialize the build environment:

source setup-environment tegra

Building the image

You can now proceed with building an image:

MACHINE=jetson-tx2 bitbake core-image-base

Replace core-image-base with your desired image target here and in the sections below.

Using the build output

After a successful build, the images and build artifacts are placed in tmp/deploy/images/jetson-tx2.

The disk image package for Jetson has a name like core-image-base-jetson-tx2.tegraflash.zip. This file can be used along with recovery mode on the Jetson TX2 to initially provision the device. To enter recovery mode:

  • Power cycle
  • Hold down the RST button and REC button.
  • Release the RST button while continuing to hold the REC button.
  • Wait two seconds, then release the REC BUTTON.

Copy the deploy.sh script from the meta-mender/tegra/scripts/deploy.sh to the base directory (the one below build) and run.

On the other hand, if you already have Mender running on your device and want to deploy a rootfs update using this build, you should use the Mender Artifact files, which have .mender suffix. You can either deploy this Artifact in managed mode with the Mender server (upload it under Releases in the server UI) or by using the Mender client only in Standalone deployments. See additional notes below about standalone updates on warrior and later branches.

References

  • meta-tegra: The base BSP layer with support for NVIDIA tegra. See completed pull request here for modifications to support Mender.
  • meta-mender-tegra layer in meta-mender-community: Customization for mender on tegra, including u-boot and partitioning. See completed pull request here for initial modifications to support NVIDIA tegra.
  • The official Mender documentation explains how Mender works. This is simply a board-specific complement to the official documentation.

Standalone Updates and Bootloader Components

As of the warrior branch, the mender update framework for tegra now supports redundant boot for bootloader components using NVIDIA tools and images. This means you can now update all bootloader components in your image, including u-boot, c-boot and device trees. See this issue for background.
The redundant boot components are upgraded through a mender reboot state script. This means the upgrades are not performed during manual install. To perform reboot state script updates using manual install, the mender-install-manual script is provided in the rootfs. Run this script with the same arguments you would provide to mender -install. The system will run the reboot state script content after performing the update. Based on the implementation of NVIDIA redundant boot update software, the system will reboot automatically after running

Known issues

  1. NVIDIA tegra platforms other than jetson tx2 should work with many of the change in this repository however they will require additional partitioning changes. Specifically settings in local.conf.append and a specific flash custom layout file similar to flash_l4t_t186.custom.xml which are a modified version of the default PARTITION_FILE used by meta-tegra.
  2. There are important limitations on upgrades when using branches earlier than warrior. The warrior branch adds several changes which clean up variable references related to rootfs size and make it possible to arbitrarily grow the rootfs using variable MENDER_STORAGE_TOTAL_SIZE_MB . Previous rootfs sizes were limited based on u-boot environment storage location. See this conversation on mender hub. The warrior update also supports redundant boot component upgrades as described above. Both of these changes above require changes to the u-boot environment location, which are outlined in the mender hub conversation linked above and also this post on the NVIDIA forum about observations related to mmcblkboot1.
    This means upgrade from sumo or thud to warrior using mender update would require changes to move u-boot environment location and most likely would also require redundant boot support implemented as a post update state script similar to what is done on the warrior branch but also including additional payload and tools from earlier branches to support redundant boot. I have not actually attempted this yet myself. Please feel free to reach out to me if you’d like to discuss this in more detail.

If this post was useful to you, please press like, or leave a thank you note to the contributor who put valuable time into this and made it available to you. It will be much appreciated!

4 Likes

6 posts were split to a new topic: Integration of NVIDIA Tegra Jetson TX2

Did anyone get Mender to work with the Jetson Nano yet, even though it’s based on the tegra210 platform? I’m trying to make this work, but I’ve never used Mender before, and it seems like u-boot-bup-payload is purely tegra186 compatible. There’s also a hard dependency on tegra186-redundant-boot, which isn’t compatible with tegra210 either. To be honest, I don’t really have an idea about what those two recipes even do (selecting the correct partition on boot, sure, but how?) and the only information I can find is the original commit for the bup payload and your issue for the redundant boot recipe.
There is a variable called TEGRA210_REDUNDANT_BOOT, but this seems to only affect the partition table (which should be the smaller issue to fix) while tegra186-redundant-boot seems to do a lot more stuff.

I hope I’m not the only one trying to get Mender to work with the Nano and someone can share his experience. :upside_down_face:

1 Like

15 posts were split to a new topic: Integrating NVIDIA Jetson NANO

4 posts were split to a new topic: Problem flashing NVIDIA Jetson TX2