Qualcomm CSRmesh v2.1 Application 移植指南简介(六)

2.4.4 Mesh model handlers(网格模型处理程序)

    To make the applications more modular and to make the effort of inclusion of models much simpler the handling of models is done in the model handlers. The model handlers would initialize the models of the CSRmesh library as well as handle the events received from the models. The model handlers also share the data structure with the main application so that the data can be accessed by both.
    This section describes the application modifications required to include a model into the CSRmesh application code. First a new model supported flag needs to be defined in the user_config.h for inclusion of the model as shown in
Table 2-12.
    为了使应用程序更加模块化,并使模型包含的工作更简单,模型处理程序完成模型的处理。 模型处理程序将初始化CSRmesh库的模型以及处理从模型接收到的事件。 模型处理程序还与主应用程序共享数据结构,以便两者都可以访问数据。

     本节介绍将模型包含到CSRmesh应用程序代码中所需的应用程序修改。 首先需要在user_config.h中定义一个支持新模型的标志,以包含模型,如表2-12所示。



    There are certain instances where the events from the mesh models would need to be indicated to the application. This can be done by calling a predefined function as done in some models or by passing the mesh model events received along with the relevant data received from the model events. An example of calling a common function and passing the model events is shown in.

    在某些情况下,需要指示来自网格模型的事件到应用程序。 这可以通过在某些模型中调用预定义的函数来完成通过传递接收到的网格模型事件以及从模型接收到的相关数据事件。 显示调用通用函数和传递模型事件的示例。



评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值