Nvidia Jetson Orin 开发板配置开发环境

参考文档:(官方)https://developer.nvidia.com/embedded/learn/get-started-jetson-agx-orin-devkit

  1. Check your L4T version first to see if you have a unit flashed with older version of the BSP.
cat /etc/nv_tegra_release

You may get something like this, # R34 (release), REVISION: 1.0, GCID: 30102743, BOARD: t186ref, EABI: aarch64, DATE: Wed Apr 6 19:11:41 UTC 2022, and this shows that you have L4T for JetPack 5.0 Developer Preview.

  • 我的版本号是R35.1,和官网给出的不一样
  1. If you have an earlier version of L4T, issue the following command to manually put the apt repository entries using commands below.
  • 打开/etc/apt/sources.list.d/nvidia-l4t-apt-source.list发现版本是对的,就是R35.1,R35.1就不需要执行官网的内容。也就是说,deb https://repo.download.nvidia.com/jetson/common r35.1 main和deb https://repo.download.nvidia.com/jetson/t234 r35.1 main,的版本号要和步骤一中的版本号一致,如果一致就不需要了。
sudo bash -c 'echo "deb https://repo.download.nvidia.com/jetson/common r34.1 main" >> /etc/apt/sources.list.d/nvidia-l4t-apt-source.list'
sudo bash -c 'echo "deb https://repo.download.nvidia.com/jetson/t234 r34.1 main" >> /etc/apt/sources.list.d/nvidia-l4t-apt-source.list' 

If you see R34 (release), REVISION: 1.0 or newer, then your apt sources lists are already up to date and you can proceed

  1. Issue the following commands to install JetPack components.
sudo apt update 
sudo apt dist-upgrade 
sudo reboot 
sudo apt install nvidia-jetpack
  • 如果指定第一个遇到下面的情况,需要执行以下内容:
swift@ubuntu:~/Desktop$ sudo apt update
[sudo] password for swift: 
Reading package lists... Done
E: Could not get lock /var/lib/apt/lists/lock. It is held by process 10336 (apt-get)
N: Be aware that removing the lock file is not a solution and may break your system.
E: Unable to lock directory /var/lib/apt/lists/
  • 解决方案:sudo rm /var/lib/apt/lists/* -vf
  • 开始安装,一定要注意重启,并且由于没有更换镜像,安装非常慢。我可能花费了6个多小时,完成73%的下载任务。如果网速比较好的话,一个小时就行(2M的网络),建议不要用电脑共享网络(以2M的网速为例,可能实际在50kb->600kb之间。),网速不稳定,wifi也不一定稳定,但是下载这个绰绰有余。最好用网线。
  1. 安装好以后执行。

(1)CUDA:执行以下指令

nvcc -V

如果出现以下信息则表示正确。

nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2022 NVIDIA Corporation
Built on Wed_May__4_00:02:26_PDT_2022
Cuda compilation tools, release 11.4, V11.4.239
Build cuda_11.4.r11.4/compiler.31294910_0
  • 如果没有出现结果,可以参考这篇文章:http://www.cppblog.com/jack-wang/archive/2022/07/27/229377.aspx
vim .bashrc
export PATH=/usr/local/cuda/bin:$PATH
source .bashrc
  • nvcc -V有显示了,可以查看到CUDA的版本信息了

(2)cuDNN:执行以下指令

dpkg -l libcudnn8

如果出现以下信息则表示正确。

Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name           Version             Architecture Description
+++-==============-===================-============-===========================>
ii  libcudnn8      8.4.1.50-1+cuda11.4 arm64        cuDNN runtime libraries

(3)TensorRT:

dpkg -l tensorrt

如果出现以下信息则表示正确。

| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name           Version            Architecture Description
+++-==============-==================-============-============================>
ii  tensorrt       8.4.1.5-1+cuda11.4 arm64        Meta package for TensorRT

(4)OpenCV:

dpkg -l libopencv

如果出现以下信息则表示正确。

Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name           Version             Architecture Description
+++-==============-===================-============-===========================>
ii  libopencv      4.5.4-8-g3e4c170df4 arm64        Open Computer Vision Library

4、安装 jtop 系统监控工具
这是 Jetson 系列非常著名的监控工具,请执行以下指令进行安装:

sudo apt install python3-pip
sudo -H pip3 install -U pip
sudo -H pip install jetson-stats==4.0.0rc1

然后执行下面启动指令就能开启这个监控工具:

jtop

如果启动出现错误的话,请重启一下 Jetson Orin 让这个服务完整启动。

sudo reboot

image.png

5. 中文输入法踩坑

如果之后安装中文输入发,一定要安装arm架构的,而且注意,镜像源不能乱选。
一个安装中文输入法的教程。(百度和搜狗都装不了)
https://blog.csdn.net/weixin_39589455/article/details/122328395

sudo apt-get install fcitx fcitx-googlepinyin -y

Nvidia Jetson Orin 开发板配置开发环境_第1张图片Nvidia Jetson Orin 开发板配置开发环境_第2张图片

  • 设置fcitx,然后重启
sudo reboot
  • 选择输入配置,选择Google pinyin

image.png
Nvidia Jetson Orin 开发板配置开发环境_第3张图片

  • 然后就可以使用Google拼音了,虽然不是很好用,但是总比没有好。

你可能感兴趣的:(开发板,ubuntu,计算机视觉,机器学习,目标检测,人工智能)