超碰激情 I 成人福利网站 I 淫国产 I 曰批视频免费30分钟成人 I 刘亦菲裸体视频一区二区三区 I 午夜久 I 尤物综合 I 亚洲一区av在线观看 I 欧美亚洲国产精品久久高清 I 欧美老熟妇乱子伦视频 I 无码中出人妻中文字幕av I 久久美女福利视频 I 精品无人区乱码1区2区3区在线 I 性饥渴的农村熟妇 I 色综合综合色 I 少妇人妻88久久中文字幕 I 久久夜色精品国产噜噜av I 老熟妇仑乱视频一区二区 I 男女做爰猛烈叫床视频动态图 I 日本大片一区二区 I 人成午夜免费视频在线观看 I 激情婷婷av I 男女下面一进一出免费视频网站 I 久久影视一区 I 午夜污网站 I 先锋人妻无码av电影 I 久久久久久久岛国免费网站 I 又粗又大又黄又硬又爽免费看 I 人妻无码免费一区二区三区 I www.色成人100 I 欧美高清网站 I 精品国产第一页 I 国产suv一区二区三区88区 I 橹图极品美女无圣光 I 午夜宅男欧美

產品分類

當前位置: 首頁 > 工業電氣產品 > 端子與連接器 > 線路板連接器 > FFC連接器

類型分類:
科普知識
數據分類:
FFC連接器

適用于TI mmWave sensor平臺的配置隨啟動加載的方式

發布日期:2022-04-28 點擊率:179

Other Parts Discussed in Post: AWR6843, AWR1843, AWR1642, AWR1443, IWR6843ISK, IWR6843

作者:He, Wesley 

TI mmWave sensor是高集成度的毫米波雷達傳感器SOC,在開發過程中,SDK及TI DEMO均使用靈活的UART接口發送CLI命令進行射頻參數配置及相關算法參數的配置。對于量產及或者有固化參數的產品而言,將參數固化在代碼中會是一項明確的需求。本文介紹一種可以快速將CFG文件參數固化到應用代碼中的實現方式,同時支持原有串口的CLI配置,無需修改SDK驅動層代碼,可方便快捷的完成參數的固化。

本文的測試環境如下:

  • 此方法適用器件型號:I/AWR1443, I/AWR1642, I/AWR1843, I/AWR6843

  • 本文測試軟件版本:mmWave SDK 3.5.0.4

  • 本文測試硬件平臺:IWR6843ISK EVM

1. 運行SDK  mmWave sensor demo的流程及對外接口說明

在現有的TI mmWave SDK及TOOLBOX相關的示例代碼中,均使用兩個串口進行參數的配置及數據的獲取,EVM板載的TM4C MCU是一個板載XDS110仿真器,仿真器自帶兩路串口,可以直接完成SDK DEMO中的參數配置及數據輸出。在客制化產品中,可以使用外部的2個USB

配置命令口:Application/User Uart: Configuration port 115200bps: UART_RX/TX port

數據口:Auxilliary Data Port: Data port 921600bps: MSS_LOGGER-> USB-UART cable -> PC

mmWave sensor的啟動配置流程

2.  修改CLI參數以調整mmWave sensor 的配置參數

以SDK內的Out of Box demo為例,將BIN文件(比如:.mmwave_sdk_

對于Toolbox內的demo,則需要同時參考SDK user’s Guide 及toolbox內的demo guide,其配置文件有SDK通用的部分,也有屬于此demo獨有的配置命令,包含SDK參數、目標檢測層的參數、追蹤器層的參數,示例如下(.mmwave_industrial_toolbox_4_9_0labspeople_counting68xx_3D_people_countingchirp_configsAOP_6m_default.cfg):

% SDK Parameters

% See the SDK user's guide for more information

% "C: immwave_sdk_[VER]docsmmwave_sdk_user_guide.pdf"

sensorStop

flushCfg

dfeDataOutputMode 1

channelCfg 15 7 0

adcCfg 2 1

adcbufCfg -1 0 1 1 1

lowPower 0 0

% Detection Layer Parameters

% See the Detection Layer Tuning Guide for more information

% "C: immwave_industrial_toolbox_[VER]labspeople_countingdocs3D_people_counting_detection_layer_tuning_guide.pdf"

profileCfg 0 60.75 30.00 25.00 59.10 394758 0 54.71 1   96 2950.00 2 1 36

chirpCfg 0 0 0 0 0 0 0 1

chirpCfg 1 1 0 0 0 0 0 2

chirpCfg 2 2 0 0 0 0 0 4

frameCfg 0 2  96  0 55.00 1 0

dynamicRACfarCfg -1 4 4 2 2 8 12 4 8 5.00 8.00 0.40 1 1

staticRACfarCfg -1 6 2 2 2 8 8 6 4 8.00 15.00 0.30 0 0

dynamicRangeAngleCfg -1 0.75 0.0010 1 0

dynamic2DAngleCfg -1 1.5 0.0300 1 0 1 0.30 0.85 8.00

staticRangeAngleCfg -1 0 8 8

antGeometry0 -1 -1 0 0 -3 -3 -2 -2 -1 -1 0 0

antGeometry1 -1 0 -1 0 -3 -2 -3 -2 -3 -2 -3 -2

antPhaseRot 1 -1 1 -1 1 -1 1 -1 1 -1 1 -1

fovCfg -1 70.0 20.0

compRangeBiasAndRxChanPhase 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0

% Tracker Layer Parameters

% See the Tracking Layer Tuning Guide for more information

% "C: immwave_industrial_toolbox_[VER]labspeople_countingdocs3D_people_counting_tracker_layer_tuning_guide.pdf"

staticBoundaryBox -3 3 0.5 7.5 0 3

boundaryBox -4 4 0 8 0 3

sensorPosition 2 0 15

gatingParam 3 2 2 2 4

stateParam 3 3 12 500 5 6000

allocationParam 20 100 0.1 20 0.5 20

maxAcceleration 0.1 0.1 0.1

trackingCfg 1 2 800 30 46 96 55

presenceBoundaryBox -3 3 0.5 7.5 0 3

sensorStart

 

3. 固化CLI參數以實現芯片上電后自動加載配置

固化配置參數有幾種操作方式,如SDK文檔描述(file:///C:/ti/mmwave_sdk_03_05_00_04/packages/ti/demo/xwr68xx/mmw/docs/doxygen/html/index.html#bypassCLI),用戶可以將CFG文件中每一條都使用對應的函數調用替換。這種方式比較底層,代碼的改動量較大,但是可以節省一部分代碼空間。實現方法可參考Toolbox中提供的一個hard-coded chirp configurations的參考示例代碼,位于:.mmwave_industrial_toolbox_4_9_0labsout_of_box_demo68xx_mmwave_sdk_hcc

本文所介紹的CLI參數固化方式將保留原有的CLI串口調試的接口,同時將現有的CFG參數以CLI的格式配置進去,可視化程度高,實現更為簡單,實現方式如下。

  • 在c 增加頭文件

#include

  • 在c中增加外部結構體的定義。

extern CLI_MCB     gCLI;

  • 在c中,增加如下外部函數定義。

extern void MmwDemo_Bypass_CLI (void);

  • 在c的"void MmwDemo_initTask(UArg arg0, UArg arg1)"函數中,在CLI_OPEN之后,調用” MmwDemo_Bypass_CLI”函數。

MmwDemo_Bypass_CLI();

  • 在C中增加如下配置命令及代碼。

#define CLI_BYPASS 1

#define MAX_RADAR_CMD               30

uint8_t* radarCmdString[MAX_RADAR_CMD] =

{

                {"sensorStop "},

                {"flushCfg "},

                {"dfeDataOutputMode 1 "},

                {"channelCfg 15 5 0 "},

                {"adcCfg 2 1 "},

                {"adcbufCfg -1 0 1 1 1 "},

                {"lowPower 0 0 "},

                {"profileCfg 0 60 7 3 24 0 0 166 1 256 12500 0 0 158 "},

                {"chirpCfg 0 0 0 0 0 0 0 1 "},

                {"chirpCfg 1 1 0 0 0 0 0 4 "},

                {"frameCfg 0 1 32 0 100 1 0 "},

                {"guiMonitor -1 1 1 1 0 0 1 "},

                {"cfarCfg -1 0 2 8 4 3 0 15.0 0 "},

                {"cfarCfg -1 1 0 4 2 3 1 15.0 0 "},

                {"multiObjBeamForming -1 1 0.5 "},

                {"calibDcRangeSig -1 0 -5 8 256 "},

                {"clutterRemoval -1 0 "},

                {"compRangeBiasAndRxChanPhase 0.0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 "},

                {"measureRangeBiasAndRxChanPhase 0 1. 0.2 "},

                {"aoaFovCfg -1 -90 90 -90 90 "},

                {"cfarFovCfg -1 0 0.25 9.0 "},

                {"cfarFovCfg -1 1 -20.16 20.16 "},

                {"extendedMaxVelocity -1 0 "},

                {"CQRxSatMonitor 0 3 4 63 0 "},

                {"CQSigImgMonitor 0 127 4 "},

                {"analogMonitor 0 0 "},

                {"lvdsStreamCfg -1 0 0 0 "},

                {"bpmCfg -1 0 0 0 "},

                {"calibData 0 0 0 "},

                {"sensorStart "}

};

 

static int32_t CLI_ByPassApi(CLI_Cfg* ptrCLICfg)

{

                //uint8_t cmdString[128];

                char* tokenizedArgs[CLI_MAX_ARGS];

                char* ptrCLICommand;

                char delimitter[] = " ";

                uint32_t argIndex;

                CLI_CmdTableEntry* ptrCLICommandEntry;

                int32_t cliStatus;

                uint32_t index, idx;

                uint16_t numCLICommands = 0U;

 

               

                if (ptrCLICfg == NULL)

                return -1;

 

               

                for (index = 0; index < CLI_MAX_CMD; index++)

                {

                               

                                if (ptrCLICfg->tableEntry[index].cmd == NULL)

                                {

                                               

                                                break;

                                }

                                else

                                {

                                               

                                                numCLICommands = numCLICommands + 1;

                                }

                }

 

               

                for (idx = 0; idx < MAX_RADAR_CMD; idx++)

                {

                               

                                memset ((void *)&tokenizedArgs, 0, sizeof(tokenizedArgs));

                                argIndex = 0;

                                ptrCLICommand = (char*)radarCmdString[idx];

 

                               

                                cliStatus = -1;

 

                               

                                while (1)

                                {

                                               

                                                tokenizedArgs[argIndex] = strtok(ptrCLICommand, delimitter);

                                                if (tokenizedArgs[argIndex] == NULL)

                                                                break;

 

                                               

                                                argIndex++;

                                                if (argIndex >= CLI_MAX_ARGS)

                                                                break;

 

                                               

                                                ptrCLICommand = NULL;

                                }

 

                               

                                if (argIndex == 0)

                                                continue;

 

                               

                                for (index = 0; index < numCLICommands; index++)

                                {

                                                ptrCLICommandEntry = &ptrCLICfg->tableEntry[index];

 

                                               

                                                if (strcmp(ptrCLICommandEntry->cmd, tokenizedArgs[0]) == 0)

                                                {

                                                               

                                                                cliStatus = ptrCLICommandEntry->cmdHandlerFxn (argIndex, tokenizedArgs);

                                                                if (cliStatus == 0)

                                                                {

                                                                                CLI_write ("Done ");

                                                                }

                                                                else

                                                                {

                                                                                CLI_write ("Error %d ", cliStatus);

                                                                }

                                                                break;

                                                }

                                }

 

                               

                                if (index == numCLICommands)

                                {

                                               

                                                if (ptrCLICfg->enableMMWaveExtension == 1U)

                                                {

                                                               

                                                                cliStatus = CLI_MMWaveExtensionHandler (argIndex, tokenizedArgs);

                                                }

 

                                               

                                                if (cliStatus == -1)

                                                {

                                                               

                                                                CLI_write ("'%s' is not recognized as a CLI command ", tokenizedArgs[0]);

                                                }

                                }

                }

 

                return 0;

}

void MmwDemo_Bypass_CLI (void)

{

                if (CLI_ByPassApi(&gCLI.cfg) != 0)

                {

                                System_printf ("Error: Unable to CLI_ByPassApi ");

                                return;

                }

                return;

}

 

 

4.  運行測試例程

將上述代碼集成進測試程序后,mmWave sensor成功配置。將此BIN文件燒寫到EVM板卡中,可以實現上電自動配置參數及運行的功能,代碼上電自動運行功能添加成功。

CCS debug運行模式下,CCS控制臺打印信息如下:

[Cortex_R4_0] **********************************************

Debug: Launching the MMW Demo on MSS

**********************************************

Debug: Launched the Initialization Task

Debug: mmWave Control Initialization was successful

Debug: mmWave Control Synchronization was successful

[C674X_0] Debug: DPM Module Sync is done

[Cortex_R4_0] Debug: CLI is operational

Debug: Sending rlRfSetLdoBypassConfig with 0 0 0

============ Heap Memory Stats ============

                             Size         Used         Free      DPCUsed

   System Heap(TCMB)        32768        28016         4752         2048

                  L3       786432       262144       524288

      localRam(TCMB)         4096          512         3584

============ Heap Memory Stats ============

                             Size         Used         Free      DPCUsed

     System Heap(L2)        32768        16112        16656            0

                  L3       786432        16384       770048

        localRam(L2)        50176        15272        34904

        localRam(L1)        16384         5728        10656

Starting Sensor (issuing MMWave_start)

直接燒寫BIN文件到EVM板卡,串口打印信息如下:

******************************************

xWR68xx MMW Demo 03.05.00.04

******************************************

mmwDemo:/>Ignored: Sensor is already stopped

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Done

Debug: Init Calibration Status = 0x1ffe

Done

mmwDemo:/>

5. 附加說明

在部分的demo(比如3D people counting demo)中,會出現堆棧溢出導致上電后,initTask中,bypasscli配置失敗的情況,此時只需要需要適當增加此task的stacksize為4*1024,即可完成參數的配置。

   

    Task_Params_init(&taskParams);

    taskParams.stackSize = 4*1024;

    gMmwMssMCB.taskHandles.initTask = Task_create(MmwDemo_initTask, &taskParams, NULL);

6. 參考資料

  • IWR6843、IWR6443 單芯片 60GHz 至 64GHz 毫米波傳感器 數據表 (Rev. D)

  • mmWave SDK: mmWave Software Development Kit http://www.ti.com/tool/mmwave-sdk

  • mmWave SDK User’s Guide: C: immwave_sdk_03_05_00_04docsmmwave_sdk_user_guide.pdf

  • mmWave SDK Out of Box Demo - XWR68XX: C:/ti/mmwave_sdk_03_05_00_04/packages/ti/demo/xwr68xx/mmw/docs/doxygen/html/index.html

  • mmWave SDK Out of Box Demo - 68xx Hard-Coded Config Version User's Guide: C:/ti/mmwave_industrial_toolbox_4_9_0/labs/out_of_box_demo/68xx_mmwave_sdk_hcc/docs/mmWave_sdk_68xx_hcc_user_guide.html

下一篇: PLC、DCS、FCS三大控

上一篇: 小體積電源在光模塊里

推薦產品

更多