The best solution for
starting your AI applications.
Provided by Renesas Electronics Corporation
This project is maintained by renesas-rz
Hosted on GitHub Pages — Theme by orderedlist
Learn more about the RZ/V series.
Equipment | Details |
---|---|
RZ/V2L Evaluation Board | Evaluation board itself. |
MIPI Camera Module | Google Coral Camera.Note that the CMOS sensor (OV5645) in the camera is no longer available, and should not be used for mass production. |
MicroUSB to Serial Cable | For serial communication between PC and the board. |
Equipment | Details |
---|---|
HDMI Monitor | Used to display the graphics. |
Micro HDMI Cable | Used to connect the HDMI Monitor and the board. |
AC adapter | Power supply to the board. |
USB Cable Type-C | Connect AC adapter and the board. |
microSD card | Must have over 4GB capacity of blank space. Operating Environment: Transcend USH-I microSD 300S 16GB |
Linux PC | Used for Setup microSD card and RZ/V2L AI SDK Setup. Operating Environment: Ubuntu 20.04 |
SD card reader | Used for setting up microSD card. |
Windows PC | Optional. Used as the serial communication console for eMMC Bootloader. Operating Environment : Windows 10 |
USB Hub | Used to connect USB Keyboard and USB Mouse. |
USB Keyboard | Used to type strings on the terminal of board. |
USB Mouse | Used to operate the mouse on the screen of board. |
Please install following software on Ubuntu PC.
AI SDK provides following packages.
Name | Package | Details |
---|---|---|
RZ/V2L AI SDK | RTK0EF0160F*SJ.zip | Package used for AI development. |
RZ/V2L AI SDK Source Code | RTK0EF0160F*SJ_linux-src.zip | Package used for Linux development. Please refer to How to Build AI SDK for more details on this package. |
For this Getting Started, please download "RZ/V2L AI SDK" from the link below.
Download Link
Once downloaded, please check the Release Note included in the package.
This step explains how to extract the RZ/V2L AI SDK zip file.
mkdir -p ai_sdk_work
export WORK=<path to the working directory>/ai_sdk_work
cd ${WORK}
unzip <Path to the file>/RTK0EF0160F*.zip -d ${WORK}
ls ${WORK}/
ai_sdk_setup board_setup documents references r11an0752ej*.pdf
This step explains how to setup the RZ/V2L AI SDK environment.
cd ${WORK}/ai_sdk_setup
docker build -t rzv2l_ai_sdk_image --build-arg SDK="/opt/poky/3.1.21" --build-arg PRODUCT="V2L" .
mkdir ${WORK}/ai_sdk_setup/data
rzv2l_ai_sdk_container
is a name of docker container, which can be changed by user.
docker run -it --name rzv2l_ai_sdk_container -v $(pwd)/data:/drp-ai_tvm/data rzv2l_ai_sdk_image
$(pwd)/data
is mounted to /drp-ai_tvm/data
on the Docker container by the above command option.libtvm_runtime.so
, which is the necessary file for the board, to host machine.cp /drp-ai_tvm/obj/build_runtime/V2L/libtvm_runtime.so /drp-ai_tvm/data
exit
rzv2l_ai_sdk_container
again, run the following command.docker start -i rzv2l_ai_sdk_container
You have finished the RZ/V2L AI SDK environment setup.
You are ready to build the AI applications!
This step explains how to build AI application.
AI Applications are provided in the GitHub repository.
To access the application, please see AI Applications.
Application directory has the following structure.
Directory | Details |
---|---|
exe |
Execution environment required when running application on the board. |
src |
Application Source Code. |
Other directory | Optional: Extra files that may be required other than above. |
Makefile |
Optional: Configuration to build the application. It may be included in the src directory. |
README.md |
Optional: Documentation of the application. |
In AI Applications, there are two types of applications.
README.md
document provided in application directory and follow the instruction in the chapter called "Application: Build Stage" (or similar) to build the application.git clone
command shown in the README.md
will download the latest source code and related files. -b v2.10
when you running the git clone
command as shown below.
git clone -b v2.10 https://github.com/renesas-rz/rzv_ai_sdk.git
docker start -i rzv2l_ai_sdk_container
source /opt/poky/3.1.21/environment-setup-aarch64-poky-linux
cd /drp-ai_tvm/data
git clone https://github.com/Ignitarium-Renesas/RZV2L_AiLibrary
-b v2.10
when you running the git clone
command as shown below.
git clone -b v2.10 https://github.com/Ignitarium-Renesas/RZV2L_AiLibrary
cd RZV2L_AiLibrary/01_Head_count/Head_count_cam
make
command.
make
RZV2L_AiLibrary/01_Head_count/
Head_count_cam/exe
.
This section explains how to deploy the AI Application to the RZ/V2L Evaluation Board Kit.
To boot the board, bootloader and other Linux necessary files are required.
There are two types of bootloader available on RZ/V2L AI SDK.
Other necessary files, i.e. Linux kernel and root filesystem, are stored on microSD card.
You can use Linux PC to format the microSD card and expand the kernel and the root filesystem using SD card reader.
Type/Number | Size | Type of Filesystem | Contents |
---|---|---|---|
Primary #1 | 500MB (minimum 128MB) | Ext4 | Linux kernel Device tree |
Primary #2 | All remaining | Ext4 | Root filesystem |
Type/Number | Size | Type of Filesystem | Contents |
---|---|---|---|
Primary #1 | 500MB (minimum 128MB) | FAT32 | Linux kernel Device tree |
Primary #2 | All remaining | Ext4 | Root filesystem |
${WORK}/board_setup/eSD.zip
.cd ${WORK}/board_setup
unzip eSD.zip
${WORK}/board_setup/eSD
directory.
File | Description | microSD card partition |
---|---|---|
Image-smarc-rzv2l.bin | Linux kernel image (The boot program) |
Partition 1 |
Image-r9a07g054l2-smarc.dtb | Linux device tree file (The configuration file for booting) |
Partition 1 |
core-image-weston-smarc-rzv2l.tar.bz2 | Linux Root filesystem | Partition 2 |
/dev/sdb
" as microSD card device name.
df
command.df -h
Filesystem Size Used Avail Use % Mounted on
… … … … … …
/dev/sdb1 … … … … …
/dev/sdb2 … … … … …
/dev/sdb
may differ depending on your environment.sudo mkdir -p /mnt/sd
sudo mount /dev/sdb1 /mnt/sd
sudo cp $WORK/board_setup/eSD/Image-smarc-rzv2l.bin /mnt/sd
sudo cp $WORK/board_setup/eSD/Image-r9a07g054l2-smarc.dtb /mnt/sd
sync
sudo umount /mnt/sd
/dev/sdb
to your microSD card device name.sudo mount /dev/sdb2 /mnt/sd
sudo tar xfj $WORK/board_setup/eSD/core-image-weston-smarc-rzv2l.tar.bz2 -C /mnt/sd
sudo cp $WORK/ai_sdk_setup/data/libtvm_runtime.so /mnt/sd/usr/lib64
sync
sudo umount /mnt/sd
/dev/sdb
to your microSD card device name.${WORK}/board_setup/eMMC
directory.
File | Description | microSD card partition |
---|---|---|
Image-smarc-rzv2l.bin | Linux kernel image (The boot program) |
Partition 1 |
Image-r9a07g054l2-smarc.dtb | Linux device tree file (The configuration file for booting) |
Partition 1 |
core-image-weston-smarc-rzv2l.tar.bz2 | Linux Root filesystem | Partition 2 |
${WORK}/board_setup/eMMC.zip
.cd ${WORK}/board_setup
unzip eMMC.zip
df
command.df -h
Filesystem Size Used Avail Use % Mounted on
… … … … … …
/dev/sdb1 … … … … …
/dev/sdb2 … … … … …
/dev/sdb
, may differ depending on your environment.
sudo mkdir -p /mnt/sd
sudo mount /dev/sdb1 /mnt/sd
sudo cp $WORK/board_setup/eMMC/Image-smarc-rzv2l.bin /mnt/sd
sudo cp $WORK/board_setup/eMMC/Image-r9a07g054l2-smarc.dtb /mnt/sd
sync
sudo umount /mnt/sd
/dev/sdb
, to your microSD card device name.
sudo mount /dev/sdb2 /mnt/sd
sudo tar xfj $WORK/board_setup/eMMC/core-image-weston-smarc-rzv2l.tar.bz2 -C /mnt/sd
sudo cp $WORK/ai_sdk_setup/data/libtvm_runtime.so /mnt/sd/usr/lib64
sync
sudo umount /mnt/sd
/dev/sdb
, to your microSD card device name.
sudo eject /dev/sdb
/dev/sdb
to your microSD card device name.${WORK}/board_setup/eSD/bootloader
to boot up the board.bl2_bp_esd-smarc-rzv2l_pmic.bin
bl2_bp-smarc-rzv2l_pmic.srec
fip-smarc-rzv2l_pmic.srec
cd ${WORK}/board_setup/eSD/bootloader
sudo dd if=bl2_bp_esd-smarc-rzv2l_pmic.bin of=/dev/sdb seek=1 count=1
sudo dd if=bl2-smarc-rzv2l_pmic.bin of=/dev/sdb seek=8
sudo dd if=fip-smarc-rzv2l_pmic.bin of=/dev/sdb seek=128
sync
/dev/sdb
, to your microSD card device name.sudo eject /dev/sdb
/dev/sdb
to your microSD card device name.This section explains how to copy the application binary created in Step 6 to the board.
Users are expected to have finished the instructions in Setup RZ/V2L Evaluation Board Kit in Step 7-1.
sudo mount /dev/sdb2 /mnt/sd
/dev/sdb
to your microSD card device name.sudo mkdir /mnt/sd/home/root/tvm
tvm
can be determined by user.Option 1. <Application 1>
Check theREADME.md
document provided in application directory and follow the instruction in the chapter called "Application: Deploy Stage" (or similar) to deploy the application.
sudo cp $WORK/ai_sdk_setup/data/<Path to target file>/<filename> /mnt/sd/home/root/tvm
Option 2. <Application 2>
Run the following command to copy the whole repository to the root filesystem.sudo cp $WORK/ai_sdk_setup/data/<Path to repository>/RZV2L_AiLibrary /mnt/sd/home/root/tvm -r
sync
sudo umount /mnt/sd
sudo eject /dev/sdb
/dev/sdb
to your microSD card device name.This section explains how to boot the RZ/V2L Evaluation Board Kit.
Follow the instruction below to boot the board.
Document of applications on GitHub has the instructions to run the application.
You have experienced the AI Application development procedures.
Next step is to change the application to create your own AI Application.
You can use the applications listed in AI Applications to expand your ideas!
If you would like to customize Yocto Linux or develop your own board, please change and build the AI SDK Source Code based on your environment.
For how to build the AI SDK Source Code, please refer to How to Build AI SDK.