Hello, everyone, and welcome to the training on mmWave SDK. 大家好,欢迎参加毫米波SDK培训 The training is intended for the software system and test engineers who are working with TI Single Chip mmWave RADAR devices. 本培训面向使用TI单芯片毫米波雷达器件的软件系统和测试工程师 The goal of this training is to help you understand the software offerings for these mmWave sensors, such as AWR1443, AWR1642, IWR1443, and IWR1642. 本培训的目的是帮助您了解AWR1443、AWR1642、IWR1642等毫米波传感器的软件产品 The common software package for all these devices is called mmWave SDK. 所有这些器件的通用软件包称为毫米波SDK This training provides overview of the mmWave SDK building blocks and the core components. 本培训概要性介绍了毫米波SDK构建块和核心组件 It explains the interaction between different SDK components and also describes the typical control and data flow in these mmWave devices. 培训中介绍了不同SDK组件之间的相互作用,还说明了这些毫米波器件中的典型控制和数据流 Before going into the details of the SDK, let’s first understand the different platforms for these mmWave sensors. 在详细介绍SDK之前,我们首先了解一下适用于这些毫米波传感器的不同平台 Both the xWR14xx and the xWR16xx are platforms for the single chip autonomous mmWave sensors. xWR14xx和xWR16xx都是适用于单芯片自主毫米波传感器的平台 The first platform, xWR14xx, which includes AWR1443 and IWR1443, has four receive channels and three transmit channels and comes along with a user programmable R4F microcontroller and a hardware accelerator for the signal processing. 第一个平台是xWR14xx,它包括AWR1443和IWR1443,具有四个接收通道和三个发射通道,并且附带用户可编程的R4F微控制器和硬件加速器用于进行信号处理 Whereas the second platform, which includes AWR1642 and IWR1642, has four receive channels, two transmit channels, and comes along with the same microcontroller but has an additional C674 DSP instead of the hardware accelerator. 而第二个平台包括AWR1642和IWR1642,具有四个接收通带和两个发射通道,并且附带相同的微控制器,但具有一个附加的C674 DSP而不是硬件加速平台 The data from these devices can be sent to an external processor or controller using the various external interface available. 来自这些器件的数据可以使用多种不同的可用外部接口发送到外部处理器或控制器 Please note that both these devices need an external serial flash where the application code for the microcontroller and the DSP can be used stored. 请注意,这两个器件都需要一个外部串行闪存,,其中存储了微控制器和DSP可以使用的应用程序代码 So in order to enable the application and the software development on these devices, TI provides platform software, which includes TI real-time operating system for the R4F and the DSP; device drivers for different peripherals; the APIs to program the mmWave device and the libraries for the signal processing; different demo applications to demonstrate the final use case; and certain tools. 因此,为了在这些器件上启用应用程序和软件开发,TI提供了平台软件,其中包括用于R4F和DSP的TI实时操作系统,适用于不同外设的器件驱动程序,用于对毫米波器件进行编程的API和用于进行信号处理的库,用于演示最终用例的不同演示应用程序以及某些工具 The platform software for these devices are called mmWave software development kit or mmWave SDK. 这些器件的平台软件称为毫米波软件开发套件,或称毫米波SDK This is the high level block diagram of TI mmWave SDK. 这是TI的毫米波SDK的高级方框图 On the color coding, the blue blocks indicates the production quality components provided by TI. 对于彩色编码,蓝色块表示TI提供的生产质量组件 Components in the yellow blocks are provided as a reference or example and is expected by the users to develop them according to the system use cases. 黄色块中的组件以参考或示例的形式提供,用户需要这些组件以便根据系统用例开发它们 Now let’s look at the different components in the TI mmWave SDK. 现在让我们看一下TI毫米波SDK中的不同组件 At the bottom of this block diagram is the bootloader, which resides in the Master SS of the R4F MCU and is responsible for the booting of the entire device. 在此方框图的底部是引导加载程序,它驻留在R4F MCU的主SS内,负责启动整个器件 It also loads the application code from the serial flash into the different cores and executes them. 它还将应用程序代码从串行闪存加载到不同内核并执行这些代码 The Radar SS Firmware or the mmWave Front End controls the RF and the analog hardware blocks and is responsible for the entire mmWave Radar operations. 雷达SS固件或毫米波前端控制射频和模拟硬件块,并负责整个毫米波雷达的操作 The mmWaveLink is the driver for the Radar SS Firmware and provides low level APIs to control each of the hardware blocks in the front end. mmWaveLink是雷达SS固件的驱动程序,并提供用于控制前端中每个硬件块的低级API The mmWave API is an abstraction over the mmWaveLink and provides simple APIs to the application to configure the front end. 毫米波API是对mmWaveLink的抽象,并为应用程序提供用于配置前端的简单API The mmWave API also handles the synchronization and the interprocess communication between the R4F MCU and the DSP subsystem. 毫米波API还处理R4F MCU和DSP子系统之间的同步和进程间通信 The SDK also includes the TI real-time operating system, TI-RTOS, and the RTOS-based drivers for both the master subsystem and the DSP subsystem. SDK还包括TI实时操作系统TI-RTOS和适用于主子系统和DSP子系之间的同步和进程间通信 All the drivers comes along with the OSAL, which means that the drivers can be ported into a different RTOS, as here. 所有驱动程序都附带OSAL,这意味着可以将这些驱动程序移植到不同的RTOS中,如此处所示 The mmWave library contains standard routines and the algorithms for signal processing, such as the FFT and the CFAR algorithm. 毫米波库包含用于信号处理的标准例程和算法,例如FFT和CFAR算法 There are some simple applications which are packaged in the SDK, which demonstrates the usage of these components to create a simple proximity [INAUDIBLE] applications. SDK中还封装了一些简单应用程序,演示了如何使用这些组件来创建简单接近[听不清]应用程序 The mmWave Demo Visualizer is a GUI, which runs on a PC and p the object data, such as the range, velocity, and the relative position of the optics. 毫米波演示可视化工具是一个GUI,他在PC上运行并处理物体数据,如光学器件的距离、速度和相对位置 This is the directory structure for TI mmWave SDK. 这是TI毫米波SDK的目录结构 They Once you install the SDK, this is how you will see the directory structure in your PC. 这就是在安装了SDK后,您的PC中将会显示的目录结构 The other route, there are four folders-- the packages, docks, firmware, and tools. 也就说,有四个文件夹:packages、docs、frimware和tools The packages contain the scripts files to building mmWave SDK. packages包含用于构建毫米波SDK的脚本文件 The TI folder contains all the source files for the components that were discussed in the last slide. TI文件夹包含上一个幻灯片中讨论的组件的所有源文件 So it includes the source files for the demo, which is the out-of-box demo and the capture demo. 所以它包括演示源文件,该演示是开包即用演示和捕获演示 The drivers folder contains the source file for the drivers, including the associated PinMux and the other peripheral drivers. drivers文件夹包含驱动程序的源文件,包括关联的PinMux和其他外设驱动程序 The driver comes along with the osal so it can be put into a different RTOS. 驱动程序附带OSAL,因此可以将其放入到不同RTOS中 All the drivers comes along with the corresponding doxygen documents, which explains how to use the driver at the unit level, and also comes along with the unit test for these driver APIs. 所有驱动程序都附带相对应的Doxygen文档,这写文档说明了如何在单元级别使用驱动程序,另外还附带适用于这些驱动程序API的单元测试功能 The control folder contrains the APIs to control the mmWave Front End, so it has the mmWaveLink, which is the low level APIs, and then mmWave will provide the high level APIs. control文件夹包含用于控制毫米波前端的API,因此具有mmWaveLink,它是低级API,毫米波将提供高级API The algorithm folder contains mmWaveLib, which is the signal processing library. algorithm文件夹包含mmWaveLib,它是信号处理库 The platform contains the platform specific files, such as the linker command file for these platforms. platform包含特定于平台的文件,例如适用于这些平台的连接器命令文件 The utils folder contains all the utility applications, such as the ccsdebug application, the command line interface to send data over the [INAUDIBLE] interface, the system profiler, which is the cycleprofiler, and the testlogger. utils文件夹包含所有使用程序,例如ccsdebug应用程序、用于通过[听不清]接口发送数据的命令行接口、系统描述器cycleprofiler和testlogger Remember the source files. 请记住源文件 The mmWave SDK contains the docs folder, which contains the release notes and the user guides. 毫米波SDK包含docs文件夹,其中包含版本说明和用户指南 These are the starting point for any new user. 对于任何新用户来说,可以将这些内容作为入门起点 There release notes contains the information about the release-- what are the different components, what are the dependencies on the different tools? 这些版本说明包含有关版本的信息:有哪些不同组件、对不同工具的依赖性如何 Along with that, it also captures a lot of the new changes into this particular release. 除此之外,还将许多新更改捕获到了这一特定版本中 The user guide contains the information on how to run the mmWave SDK demo, so the out-of-box and the capture demo, how to set up the mmWave SDK, and how to build the mmWave SDK. user guide包含有关如何运行毫米波SDK演示,即开包即用演示和捕获演示、如何设置毫米波SDK以及如何构建毫米波SDK的信息 And finally, there is a firmware folder, which contains the firmware for the Radar subsystem and data tools folder. 最后,有一个firmware文件夹,其中包含雷达子系统的固件和数据工具文件夹 For more information on the SDK contents, you will refer to the release notes and the user guides. 有关SDK内容的更多信息,请参阅版本说明和用户指南 Now let’s have a brief look into each of these building blocks. 现在简要介绍一下每个构建块 mmWave SDK drivers offer portable and feature-rich access to peripherals through easy-to-use APIs. 使用毫米波SDK驱动程序,可以通过易于使用的API Here is an example of one of these drivers, and all the drivers follow the same structure and conventions. 下面是其中一个驱动程序的示例,所有驱动程序都遵循相同的结构和约定 For example, the device and the CPU configuration allows each driver to be portable on a different CPU. 例如,器件和CPU配置允许在不同的CPU上移植每个驱动程序 In this case, drivers are common across the MSS and the DSP subsystem. 在这种情况下,驱动程序在MSS和DSP之间是通用的 Each level uses the OSAL to provide a threat-safe and control access to the hardware IP. 每个级别都使用OSAL提供对硬件IP的威胁安全和控制权限访问 The TI-RTOS provides all the OS-related functionalities to these drivers. TI-RTOS为这些驱动程序提供所有与操作系统有关的功能 All the drivers in the SDK comes along with their doxygen document and the test application, which demonstrates the uses of these APIs. SDK中的所有驱动程序均附带其doxygen文档和测试应用程序,演示这些API的用法 Now let’s look into the mmWave component. 现在让我们看一下毫米波组件 mmWaveLink is the driver for the Radar subsystem or the mmWave Front End. mmWaveLink是雷达子系统或毫米波前端的驱动程序 As you know, the Radar subsystem controls the RF and the [INAUDIBLE], and is responsible for the entire mmWave Radar operations. 如您所知,雷达子系统控制射频和[听不清],并且负责整个毫米波雷达的操作 On its internal block, any operation can be controlled using the messages coming over the mailbox. 在其内部块上,可以使用通过邮箱传来的消息控制任何操作 mmWaveLink framework provides the infrastructure which generates these messages and also handles the communication over the mailbox. mmWaveLink框架提供基础架构,他可生成这些消息,还可处理通过邮箱进行的通信 mmWaveLink provides the low level APIs to control the Radar subsystem and the FMCW chirp configuration. mmWaveLink提供用于控制雷达子系统和FMCW线性调频脉冲配置的低级API Here is a snapshot of some of the APIs. 下面是一些API的快照 The Device Manager APIs can be used to initialize a driver and do the handshake with the mmWave Front End. 设备管理器API可用于初始化某个驱动程序并执行与毫米波前端握手 The Sensor Control APIs allows you to configure different blocks in the mmWave Front End, such as you can configure how many receive and how many transmit channels needs to be enabled. 传感器控制API可用于配置毫米波前端中的不同块,例如,您可以配置需要启用多少个接收通道和多少个反射通道。 Similarly, you can configure the ADC format, the chirp configuration, and you can use the APIs to start and stop the transmission of the frames. 同样,您可以配置ADC格式,线性调频脉冲配置,并且可以使用这些API来启动和停止帧传输 mmWave component provides high level APIs, which abstracts the low level mmWaveLink APIs and provides simple interface to the application. 毫米波组件提供高级API,这些API使低级mmWaveLink API抽象化并为应用程序提供简单接口 The model runs on both the MSS and the DSP and allows the flexibility to configure the Radar SS Firmware or the mmWave Front End from each of these cores. 模型在MSS和DSP上运行,并可以从这两个内核中的每个内核上灵活地配置雷达SS固件或毫米波前端 It also handles the communication between the MSS and the DSP to provide the synchronization. 它还处理MSS和DSP之间的通信,从而实现同步 In this example, the configuration of the front end is done from the MSS application, but the mmWave API passes the configuration the DSP so that the DSS can configure the EDMAs and the signal processing chains accordingly. 在本示例中,前端的配置是从MSS应用程序中完成的,但毫米波API会将该配置传递给DSP,以便DSS可以相应地配置EDMA和信号处理链 mmWaveLib, which runs on the DSP subsystem, provides key routines for the FMCW signal processing, which includes various FFT routines they’ve been doing on the input data. mmWaveLib在DSP子系统上运行,它为FMCW信号处理提供关键例程,其中包括已对输入数据执行的各种FFT例程 The basic detection algorithms, such as the CFAR-CA, the different angle estimation FFT, and the other helper routines, such as the scaling, shifting, and accumulation. 基本检测算法,例如CFAR-CA,不同的角度估算FFT以及其他帮助器例程,例如缩放、平移和累积 All these routines are optimized for the C674x architecture to give a better system performance. 所有这些例程都已针对C674x架构进行优化,以实现更好的系统性能 This is a typical flow in the mmWave SDK. 这是毫米波SDK中的一个典型流 As the bootloader brings out the MSS and the DSS out of reset, the application on the master subsystem uses the mmWave API and the mmWave Web Link driver to communicate with the mmWave Front End. 随着引导加载程序使MSS和DSS结束复位,主子系统上的应用程序将使用毫米波API和毫米波Web链接驱动程序与毫米波前端通信 The application does all the configuration of the mmWave Front End and triggers the frame. 应用程序执行毫米波前端的所有配置并出发帧 Once the frame is triggered, the ADC data from the front end is moved to the ADC Buffer. 触发帧后,会将来自前端的ADC数据移动到ADC缓冲器 ADC Buffer is a Ping-Pong Buffer, which means that while the data is getting moved from the mmWave Front End to the Pong Buffer, the data from the Ping Buffer is moved to the DSP memory. ADC缓冲器是一种乒乓缓冲器,这意味着在将数据从毫米波前端移动到乒乓缓冲器时,会将乒乓缓冲器中的数据移动到DSP存储器中 And the DSP uses the mmWave library to do The range FFT on the Ping Buffer. 而DSP使用毫米波库在乒缓冲器上执行距离FFT Once the Range FFT is complete, it uses the EDMA driver to move the data to the L3 Memory. 距离FFT完成后,它将使用EDMA驱动程序将数据移动到L3存储器 The sequence is repeated for all the chirps in a fame, and the Range FFT is calculated for all the chirps. 将会对某一帧中的所有线性调频脉冲重复该序列,并为所有线性调频脉冲计算距离FFT During inter-frame time, DSP moves the data from the L3 Memory back to the DSP memory and does the Doppler FFT. 在帧间时间段内,DSP会将数据从L3存储器移回DSP存储器并执行多普勒FFT The result of the Doppler FFT is, again, moved to the L3 Memory. 同样,多普勒FFT的结果是将数据移动到L3存储器 After Doppler FFT, DSP runs the basic CFAR algorithm for the object detection and uses the angle estimation routine to find the relative position of the objects. 执行多普勒FFT后,DSP运行基本CFAR算法进行物体检测,并使用角度估算例程计算物体的相对位置 Now, data is then sent back to the master subsystem. 现在,数据发送回了主子系统 MSS can send this information to an external controller using the different peripheral drivers, or it can also pass this data to an external processor to do the object tracking and the classification. MSS可以使用不同的外设驱动程序将此信息发送到外部控制器,也可以将此数据传递到外部处理器以进行物体跟踪和分类 Now, let’s look into the detailed control flow. 现在让我们看一下详细的控制流 The MSS application uses the SOC_init to initialize the device and powers up the mmWave Front End. MSS应用程序使用SOC_init初始化器件并为毫米波前端加电 It then uses the MMWave_init APIs to do the basic initialization of the mailbox and the other key drivers. 之后,它使用MMwave_init API执行邮箱和其他关键驱动程序的基本初始化 After that, it waits for the front end bootup completion. 之后,它等待前端启动完成 DSP application, on the other hand, uses the MMWave_execute API, which sets up the IPC to receive the data from the MSS. 另一方面,DSP应用程序使用MMWave_execute API,并将IPC设置为从MSS接收数据 After this, both the MSS and the DSP does synchronization to check the health of each other. 之后,MSS和DSP进行同步以相互检查运行状态 DSS also initializes the EDMA and the ADC buffer for the data processing. DSS还会初始化EDMA和ADC缓冲器以进行数据处理 Once the initialization is complete and the MSS and the DSS is synchronized, MSS application use the MMWave_config API to parse the configuration from the application to the mmWave Front End. 初始化完成后并且MSS和DSS同步后,MSS应用程序使用MMWave_config API将配置从应用程序解析到毫米波前端 mmWave API uses the mmWaveLink API, which constructs the mailbox message and sends it to the mmWave Front End. 毫米波API使用mmWaveLink API,构建邮箱消息并将其发送到毫米波前端 mmWave Front End, once it receives a message, checks the integrity of the message and sends an acknowledgement back to the mmWaveLink. 毫米波前端收到消息后,它将检查消息的完整性并将确认发回mmWaveLink In this way, all the messages are sent to the front end. 通过这种方式,将所有消息发送到前端 When the mmWave API has sent all the configuration to the front end, it also passes the configuration to that DSP. 毫米波API将所有配置发送到前端后,它还会将配置传递给该DSP The DSP, once it receives this configuration, sets up the EDMA and the ADC Buffer accordingly. DSP收到此配置后,它就会相应地设置EDMA和ADC缓冲器 Once all the configuration is done, the MSS application uses the MMWave_start API, which sends a message to the DSP. 所有配置都完成后,MSS应用程序将使用MMWave_start_API,向DSP发送一条消息 Once the DSP receives the start message, it enables the data processing and waits for the ADC data. DSP接收到该启动消息后,它将启用数据处理并等待ADC数据 After that, the mmWave API uses the mmWaveLink API to send a start message to the mmWave Front End. 之后,毫米波API将使用mmWaveLink API向毫米波前端发送一条启动消息 Once the mmWave Front End receives this start message, it starts transmission of the frame. 毫米波前端收到该启动消息后,它将开始帧的传输 Now let’s look into the data flow. 现在让我们看一下数据流 Once a frame is triggered, the mmWave Front End moves the ADC samples into the Ping-Pong ADC buffer. 触发了某个帧后,毫米波前端会将ADC样本移动到乒乓ADC缓冲器中 Once one of these buffers is full, it generates an interrupt to the DSP, and the EDMA moves the data from one of these buffers into the DSP memory. 一旦这些缓冲器中有一个变满后,它会生成DSP中断,EDMA会将数据从其中一个缓冲器移动到DSP存储器中 DSP then uses the mmWaveLib to do the Range FFT on this buffer and moves the result to the L3 Memory. 之后,DSP使用mmWaveLib对该缓冲器执行距离FFT,并将结果移动到L3存储器 The sequence is then repeated for all the chirps in a frame, and the Range FFT is stored into the L3 Memory. 然后对帧中的所有线性调频脉冲重复该序列,并将距离FFT存储到L3存储器中 During the inter-frame time, the DSP configures the EDMA to move the data from the L3 Memory back to the DSP Memory and does the Doppler FFT. 在帧时间段内,DSP会将EDMA配置为将数据从L3存储器移回到DSP存储器并执行多普勒FFT When the Doppler FFT is done, DSP, again, configures the EDMA to move the data back to the L3 Memory. 同样,多普勒FFT完成后,DSP会将EDMA配置为将数据移回到L3存储器 After that, the DSP does the object detection and the angle estimation and moves the object list to one of the object buffer in the ping-pong manner. 之后,DSP进行物体检测和角度估算,并以乒乓方式将物体列表移动到其中一个物体缓冲器中 MSS then picks up this Object List from one of these buffer and sends it to the external controller. 之后,MSS从其中一个缓冲器中拾取此物体列表并将其发送到外部控制器 With this, we have come to the end of this training session. 这样,我们便完成了此次课程的培训 For more information, do refer to the mmWave SDK user guide and the demo applications. 有关更多信息,请参阅毫米波SDK用户指南和演示应用程序 I hope that the training was helpful, and I sincerely thank you for your valuable time. Thank you very much. 希望这次培训对您有所帮助,真诚感谢您抽出宝贵时间参与培训