Linux + BIOS mode
一、用例生成
生成用例文件涉及: 1.编写配置文件 2.生成文件
用例名称可以在配置文件中提到。它在生成的文件、结构和函数名中用作前缀。
Example:
UseCase: chains_vipSingleCam_Display
连接语法:
Connection : ID | ID -> Connection | ID ( [CPU] ) | ID ( [CPU] ) -> Connection
示例
UseCase: chains vipSingleCameraEdgeDetection
Capture -> Alg EdgeDetect (EVE1) -> Display
vsdk位置:build/ti/rtos/scripts
configure/tools/vision_sdk_usecase_gen/bin
要生成用例文件,请键入:
./vsdk_linux.out - file configFile 这将在执行命令的文件夹中生成文件 ??
?要在“ output ”文件夹中生成usecase文件,请键入: ./vsdk_linux.out -file configFile -path ./output
要与文件一起生成图像,请键入:
./vsdk_linux.out -file -img configFile
支持的其他选项包括: -help显示有关受支持的cmd行选项,链接和CPU的帮助
-v详细
? -help Show help and supported basename and processors
? -file Create .c and .h file
? -img Create in .jpg image (or out.jpg)
? -log Creates a .txt log file with debugging info
? -debug Prints file name(in source code) and line no. in error
statement
? -path takes the next argument as output path
? -v Verbose
二、添加新用例,构建
1./build/ti/Rules.make
2./bsw/platform/ti/configs/cfg.mk
3./bsw/platform/ti/configs/yourconfigdoc/cfg.mk && uc_cfg.mk
4.把自己生成的usecase 拷贝到 /app/src/hlos/adas/src/usecases里
如自己生成的是my_usecase
a.把别的用例里MAKEFILE.MK拷贝到my_usecase
b.创建个cfg.mk
c.edit cfg.mk:
添加需要的alg plagins(在app/src/rtos/alg_plagins等文件夹)eg:ALG_dmaSwMs=yes
需要的cpu,eg:NEED_PROC_A_0=yes(<CPU> can be IPU1_0, IPU1_1, IPU2, DSP1, DSP2, EVE1,
EVE2, EVE3, EVE4, A15_0)
5./bsw/platform/ti/configs/cfg.mk 里
添加自己的usecase变量
Ex, LINUX_TDA2XX_UC_LIST = \
UC_avbrx_dec_display \
…
UC_my_usecase(将自己创建的变量在后面追加写上)
6./bsw/platform/ti/configs/yourconfigdoc/uc_cfg.mk里,添加自己新增的usecase:
UC_my_usecase=yes
7./build/ti$ make showconfig
#Use-cases included in build &&
#Alg plugins included in build 下会有自己配置的需要的alg和usecase
8./app/commom/chains_main.c
添加menu-item string:
char gChains_testMenu[] = {
#ifdef UC_my_usecase
"\r\n u: My usecase"
#endif
"\r\n"
"\r\n x: Exit "
"\r\n "
"\r\n Enter Choice: "
"\r\n "
}; //当程序在开发版上运行时可以选择调用菜单然后调用自定义的用例进行运行
void gChains_test() //这个函数不知如何命名
Void Chains_menuMiscTestRun() /*根据上方菜单的显示,然后根据用户输入情况选择调用的具体用例
{
switch(ch)
{
#ifdef UC_my_usecase
Case ‘u’:
MY_usecase_run(&gChains_usecaseCfg);
break;
#endif
}