0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

Jetson Nano JetPack 4.6.1 (L4T 32.7.1) のカーネルビルド

Last updated at Posted at 2022-03-19

はじめに

JetsonHacksのbuildKernelAndModulesツールはJetPack4.6(L4T 32.6.1)までしか対応していないため、スクリプトを一部修正してJetPack4.6.1でカーネルビルドを行ってみました。

1. buildKernelAndModulesツールのダウンロード

$ git clone https://github.com/JetsonHacksNano/buildKernelAndModules

2. スクリプトの修正

$ cd buildKernelAndModules/

scriptsディレクトリのgetKernelSources.shとjetson_variablesを修正します。

scripts/getKernelSources.sh
# Table of the URLs to Kernel Sources for Jetson Nano, Nano 2GB and TX1
# L4T Driver Package [BSP] Sources - Code 210
declare -A source_url_list_210=( 
  ["32.7.1"]="https://developer.nvidia.com/embedded/l4t/r32_release_v7.1/sources/t210/public_sources.tbz2"     ←追加
  ["32.6.1"]="https://developer.nvidia.com/embedded/l4t/r32_release_v6.1/sources/t210/public_sources.tbz2"
  ["32.5.2"]="https://developer.nvidia.com/embedded/l4t/r32_release_v5.2/sources/t210/public_sources.tbz2"
  ["32.5.1"]="https://developer.nvidia.com/embedded/l4t/r32_release_v5.1/r32_release_v5.1/sources/t210/public_sources.tbz2"
scripts/getKernelSources.sh
   "t210ref" ) 
     SOURCE_URL=${source_url_list_186[$JETSON_L4T]}
   ↓(修正)
     SOURCE_URL=${source_url_list_210[$JETSON_L4T]}
scripts/jetson_variables
    case $JETSON_L4T in
        "32.7.1") JETSON_JETPACK="4.6.1" ;;     ←追加
        "32.6.1") JETSON_JETPACK="4.6" ;;
        "32.5.1") JETSON_JETPACK="4.5.1" ;;
        "32.5.0" | "32.5") JETSON_JETPACK="4.5" ;;

3. カーネルソースのダウンロード

$ cd buildKernelAndModules/
$ ./getKernelSources.sh

4. カーネルコンフィグの編集

editConfig.shコマンドを使用してCUIでカーネルコンフィグを編集します。

$ ./editConfig.sh

Framebuffer Driver (fbtft_driver) を有効化する場合

場所は
Linux Kernel Configuration
 └─> Device Drivers
  └─> Staging drivers
   └─> Support for small TFT LCD display modules

1.jpg

2.jpg

MIDIを有効化する場合

場所は
Linux Kernel Configuration
 └─> Device Drivers
  └─> Sound card support
   └─> Advanced Linux Sound Architecture
    └─> Generic sound devices
    └─> USB sound devices

Device_Drivers.jpg

sound.jpg

advanced.jpg

general.jpg

USB_sound_devices.jpg

5. カーネルビルド

$ ./makeKernel.sh 

掛かった時間

real	30m37.182s
user	76m53.952s
sys	7m37.456s

6. モジュールのビルド

$ ./makeModules.sh

掛かった時間

real	44m15.801s
user	113m15.636s
sys	12m10.092s

7. イメージのコピー

$ ./copyImage.sh

8. 再起動

$ sudo reboot

(参考)

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?