How do we run vision_apps demos using tisdk tiny-fs?
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Run vision_apps demo (Single Cam Demo) using tiny fs in SD - Boot Mode.
The following steps are tested for SDK 8.4 on TDA4VM.
Step 1: Format the SD card and create the Boot and rootfs partition
You can use the utility script psdk_rtos/scripts/mk-linux-card.sh to make the partitions
Use the command "df -h" to identify the device used by SD card
Unmount the SD card before running the script
Example, if your SD card is on device /dev/sdb having two partitions, do below to unmount them
umount /dev/sdb1
umount /dev/sdb2
Run the script as below to partition it, answer "y" to all questions asked when running the script
cd ${PSDKR_PATH}
sudo psdk_rtos/scripts/mk-linux-card.sh /dev/sdb
After formatting, remove and insert the SD card for the freshly formatted partitions to get auto mounted on the host PC
Step 2: Copy the below script "install_to_sd_card_tiny.sh" to the path ${PSDKR_PATH}/psdk_rtos/scripts
Copy below files (linux tinyfs and linux boot files) from PSDK Linux folder to base folder of PSDK RTOS
cp ${PSDKL_PATH}/board-support/prebuilt-images/boot-j7-evm.tar.gz ${PSDKR_PATH}/
cp ${PSDKL_PATH}/filesystem/tisdk-tiny-image-j7-evm.tar.xz ${PSDKR_PATH}/
Step 3: Copy/untar filesystem and boot files to SD card by executing the script as shown below,
cd ${PSDKR_PATH}
psdk_rtos/scripts/install_to_sd_card_tiny.sh
Step 4: Copy the test data to the SD card using below commands
cd /media/$USER/rootfs/
mkdir -p opt/vision_apps
cd opt/vision_apps
tar --strip-components=1 -xf ${path/to/file}/psdk_rtos_ti_data_set_xx_xx_xx.tar.gz
sync
Step 5: Copy the dependencies/drivers required
Run ./setup.sh in $PSDK_LINUX_PATH/ to create the targetNFS folder
cp -r $PSDK_LINUX_PATH/targetNFS/boot/* /media/$USER/rootfs/boot
cp -r $PSDK_LINUX_PATH/targetNFS/lib/* /media/$USER/rootfs/lib
cp -r $PSDK_LINUX_PATH/targetNFS/usr/lib/* /media/$USER/rootfs/usr/lib/
cp -r $PSDK_LINUX_PATH/targetNFS/etc/* /media/$USER/rootfs/etc/
Step 6: Copy the vision_apps binary into the SD card using below script.
cd ${PSDK_RTOS_PATH}/vision_apps
make linux_fs_install_sd
Step 7: Insert the SD Card into EVM and boot.
Step 8: Run the below commands on terminal after login
export PATH=/usr/bin:/sbin:/bin
export LD_LIBRARY_PATH=/lib:/usr/lib:$LD_LIBRARY_PATH
mount -t proc proc /proc
mount -n -t sysfs none /sys
mount -n -t tmpfs none /run
insmod /lib/modules/5.10.120-g95b90aa828/kernel/drivers/rpmsg/virtio_rpmsg_bus.ko
insmod /lib/modules/5.10.120-g95b90aa828/kernel/drivers/remoteproc/ti_k3_r5_remoteproc.ko
insmod /lib/modules/5.10.120-g95b90aa828/kernel/drivers/remoteproc/ti_k3_dsp_remoteproc.ko
insmod /lib/modules/5.10.120-g95b90aa828/extra/pvrsrvkm.ko
insmod /lib/modules/5.10.120-g95b90aa828/kernel/drivers/rpmsg/rpmsg_char.ko
insmod /lib/modules/5.10.120-g95b90aa828/kernel/drivers/rpmsg-kdrv/rpmsg_kdrv_switch.ko
Step 9: On the EVM, do below steps to init the environment for the demos
cd /opt/vision_apps
source ./vision_apps_init.sh
Now run the below script to run the single cam demo
./run_app_single_cam.sh
Regards,
Nikhil