Main Content

XCP UDP数据采集

从配置的服务器连接中获取选定的测量

  • 图书馆:
  • 车辆网络工具箱 / XCP通信 / UDP

    万博1manbetxSimulink实时 / XCP / UDP

  • XCP UDP数据采集块

Description

XCP UDP数据采集block acquires data from the configured server connection based on the measurements that you select. The block uses the XCP UDP transport layer to obtain raw data for the selected measurements at the specified simulation time step. Configure your XCP connection and use theXCP UDP数据采集块选择您的事件和配置服务器连接的测量。该块将所选测量结果显示为输出端口。

这XCP communication blocks support the use of Simulink®accelerator mode and rapid accelerator mode. You can speed up the execution of Simulink models by using these modes. For more information on these simulation modes, see设计您的模型以有效加速(万博1manbetxSimulink)

参数

expand all

Select the name of XCP configuration that you want to use. This list displays all available names specified in theXCP UDP配置模型中的块。选择配置显示此配置的A2L文件中可用的事件和测量结果。您只能使用一个事件获得一个事件的测量XCP UDP数据采集堵塞。为每个事件使用一个块,其测量值要获得。

从可用事件列表中选择事件。这XCP UDP配置块使用指定的A2L文件填充事件列表。

此列表将显示所有可用于选定事件的测量结果。选择要使用的测量值,然后单击“添加”按钮,将其添加到选定的测量中。持有Ctrlkey on your keyboard to select multiple measurements.

In theBlock Parametersdialog box, type the name of the measurement you want to use in the搜索box. The所有测量列表显示所有匹配名称的列表。单击X以清除您的搜索。

This list displays selected measurements. To remove a measurement from this list, select the measurement and click the remove button,

In theBlock Parameters对话框,使用切换按钮重新排序所选的测量。

此参数可以支持ASAP2标准中定义的XCP数据万博1manbetx类型和尺寸。块输出设置参数选择端口输出是compu方法转换值还是原始值。选项提供:

  • Physical values (apply Compu method conversion)实现ECU测量值的原始转换。对于此选项,将块端口设置设置为'double'or'string',基于基础综合方法转换。例如,compu方法IDENTICAL,,,,LINEAR,,,,RAT_FUNC,,,,TAB_INTP,,,,andTAB_NOINTP端口设置为'double'同时compu方法TAB_VERB端口设置为'string'。这maximum string length supported for Compu method conversion is 1024 as specified in theASAM XIL规范

    不支持形式的compu方法转换。万博1manbetx万博1manbetxSimulink向这种转换发出警告,并将相同的转换应用于基础测量。同样,仅支持simulink仅支持标量字符串,仅支持标量测量信号。万博1manbetx万博1manbetx

    Selecting this option shows the physical units (if any) in front of the measurement name on the block mask. This physical unit is acquired from the A2L description of the measurement and Compu method. If the physical unit is not specified, only the measurement name is displayed.

  • 原始值(无综合方法转换)sets the port data type according to the type definition in the A2L file and supports up to three-dimensional XCP measurements in Simulink.

  • 原始值作为double(无综合方法转换)sets the port data type asdouble,,,,converting all internal measurement values. This selection supports up to three-dimensional XCP measurements in Simulink.

这se ASAP2 data types are supported by corresponding Simulink port data types:

  • SBYTE

  • UWORD

  • SWORD

  • 乌隆

  • SLONG

  • A_UINT64

  • A_INT64

  • float32_ieee

  • float64_ieee

这dimension support in the block accommodates the different treatment of matrices by MATLAB®and the ECU. The MATLAB default operation treats matrices as row-major matrices. An XCP measurement can have a布局作为COLUMN_DIRorROW_DIR。如果矩阵测量是COLUMN_DIR,,,,the blocks rearrange the measurement in memory and ensure that the matrix (row X, col Y) in MATLAB refers to the same entry as (row X, col Y) on the ECU. The rearrangement causes matrix entries that are contiguous on the ECU to be noncontiguous in MATLAB and Simulink.

对于服务器设备驱动程序,将优先值从0到255指定为整数,以确定数据包的传输。在传输到客户端之前,该服务器可以累积XCP数据包,以获取较低优先级DAQ列表。255值的优先级最高。这set_daq_list_mode命令传达DAQ列表优先级从客户端到服务器的价值。此通信方法与来自A2L文件的事件通道优先属性的规范不同。

在模拟过程中指定块的采样时间,即模拟时间。此值定义了XCP UDP数据采集块在模拟过程中运行。如果该块在触发的子系统内部或继承样本时间,则可以指定–1作为样本时间。您还可以在示例时间内指定MATLAB变量。默认值为0.01仿真秒。有关模拟示例正时的信息,请参阅硬件接口模型中的时间安排

When the Timestamp is enabled, the block reads the timestamp from incoming DTO packets and outputs the timestamp to Simulink. The启用时间戳check box appears in the block parameters dialog box when the parameter is supported in the A2L file.

扩展功能

版本历史记录

在R2019a中引入