Table of Contents
Overview
The following project it's based from Jetpack 4.4.1 OS. There are three layers of Sofware development: Linux for Tegra Kernel, CTI Kernel, and Drivers. This is on top of the Elroy carrier board support package (BSP) by ConnectTech, that gets installed on the Linux for Tegra workspace. Each of the layers correspond to a Git Submodule as a way to implement this project parametrized, and letting to keep the Commits separated.
The following diagram shows how the project it's organized.
Platform project
NVIDIA's Jetson OS for the TX2. On top of it the ConnectTech BSP for the Elroy revF+ carrier.
CTI BSP
The CTI BSP allows the portability to the Elroy carrier for TX2 Linux4Tegra Family, i.e, device trees for the custom hardware, configuration files, environment variables and scripts for the build. The installation it's made with the CTI-L4T/install.sh script.
Reference Kernel
The Kernel source from Jetpack + CTI it's the reference Kernel. In order to introduce Drivers, get them parsed onto the reference Kernel with the KERNEL OVERLAYS, and DTB_LIST variables. This variables lets the Driver Makefiles for source and dtb to be added accordingly, giving the dynamism of modularize, manage the sources, make updates, by implementing it on the reference Kernel Makefiles:
├── kernel
├── kernel-4.9
└── Makefile
├── kernel
└── kernel-4.9
└── arch
└── arm64
├── boot
└── dts
└── Makefile
Driver MT9M021
The Driver for the MT9M021 cameras consists on the following structure, that adds the DTB and Kernel sources, along with its Makefiles that lead its portability to a Kernel source.
.
├── hardware
│ └── nvidia-spiri
│ └── platform
│ └── t18x
│ ├── common
│ │ └── kernel-dts
│ │ └── t18x-common-platforms
│ │ ├── tegra186-tx2-spiri-camera-base.dtsi
│ │ └── tegra186-tx2-spiri-camera.dtsi
│ └── quill
│ └── kernel-dts
│ ├── Makefile
│ ├── tegra186-tx2-spiri-base.dts
│ ├── tegra186-tx2-spiri-mPCIe.dts
│ ├── tegra186-tx2-spiri-revF+.dts
│ └── tegra186-tx2-spiri-USB3.dts
├── kernel
│ ├── kernel-4.9
│ │ └── arch
│ │ └── arm64
│ │ └── configs
│ │ └── tegra_defconfig
│ └── nvidia-spiri
│ ├── drivers
│ │ └── media
│ │ ├── i2c
│ │ │ ├── Kconfig
│ │ │ ├── Makefile
│ │ │ ├── mt9m021.c
│ │ │ └── mt9m021_mode_tbls.h
│ └── include
│ └── media
│ └── mt9m021.h
└── README.md
In order to add the Driver to the Kernel, the following reference Kernel files are patched for adding custom controls that the camera implements.
- kernel/nvidia/drivers/media/platform/tegra/camera/camera_common.c
- kernel/nvidia/drivers/media/platform/tegra/camera/tegracam_ctrls.c
- kernel/nvidia/include/media/camera_common.h
- kernel/nvidia/include/media/tegra-v4l2-camera.h
Driver EG25-G
The Driver for the EG25-G Quectel module consists has the following structure on the Kernel space side, for interfacing it and adding its Network packets transmisions on Kernel.
.
├── kernel
└── kernel-4.9-spiri
└── drivers
└── net
└── usb
├── GobiUSBNet.c
├── Kconfig
├── Makefile
├── QMI.c
├── QMIDevice.c
├── QMIDevice.h
├── QMI.h
└── Structs.h
In order to add the Driver to the Kernel, the following reference Kernel files are patched:
- drivers/usb/serial/option.c
- drivers/usb/serial/usb_wwan.c
- drivers/net/usb/qmi_wwan.c