arjun.a
rename files
6c7b14a
Ticket Name: Linux/TDA2: How to run demo program (apps.out) automatically after boot up?
Query Text:
Part Number: TDA2 Tool/software: Linux Dear Support, I'm running Processor SDK Vision Linux on TDA2x. The following are the steps to run demo program, 1. login as root 2. manually input below commands a. cd /opt/vision_sdk b. source ./vision_sdk_load.sh c. ./apps.out Is there any way to run the program automatically after boot up? If yes, could you provide a verified example? I'm seeing the following similar post (for AM437x) but I'm not sure if it is applicable for TDA2x.
Responses:
Hi, Which VSDK version are you using? Regards, Anuj
Hi, Anuj I'm using Processor SDK Vision Linux v3.4. The steps to run demo program is the same since v3.1.
Hi, Attached a couple of files that need to be copied to the root-fs to autolaunch the VSDK app on startup (remove the .txt from the filenames from both files when adding to the file-system). Please note the logs don’t show up on UART and the VSDK app needs to be modified to select a chain by default and user input needs to be disabled (else the menu will keep printing in a loop and increase CPU load). The vsdk.service file needs to be copied to <path to target rootfs>/etc/systemd/system/multi-user.target.wants/ and the autorun.sh needs to be copied to <path to target rootfs>/opt/vision_sdk/. Ensure both files have executable permissions. The logs are redirected to /tmp/vsdk.log. Regards Shravan vsdk.service.txt [Unit]
Description=Launching Vision SDK App
After=rc.pvr
[Service]
ExecStart=/bin/sh /opt/vision_sdk/autorun.sh
Restart=always
Type=simple
[Install]
WantedBy=multi-user-target
autorun.sh.txt echo "Inside the script" > /tmp/vsdk.log
cd /opt/vision_sdk
./vision_sdk_load.sh >> /tmp/vsdk.log
./apps.out >> /tmp/vsdk.log