CN102231683B - COM layer communication time limit monitoring method based on AUTOSAR - Google Patents

COM layer communication time limit monitoring method based on AUTOSAR Download PDF

Info

Publication number
CN102231683B
CN102231683B CN 201110159341 CN201110159341A CN102231683B CN 102231683 B CN102231683 B CN 102231683B CN 201110159341 CN201110159341 CN 201110159341 CN 201110159341 A CN201110159341 A CN 201110159341A CN 102231683 B CN102231683 B CN 102231683B
Authority
CN
China
Prior art keywords
communication entity
sending
time limit
direct
time
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
CN 201110159341
Other languages
Chinese (zh)
Other versions
CN102231683A (en
Inventor
李红
顾宗华
王旭阳
张成硕
陈浩杰
吴朝晖
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang University ZJU
Original Assignee
Zhejiang University ZJU
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhejiang University ZJU filed Critical Zhejiang University ZJU
Priority to CN 201110159341 priority Critical patent/CN102231683B/en
Publication of CN102231683A publication Critical patent/CN102231683A/en
Application granted granted Critical
Publication of CN102231683B publication Critical patent/CN102231683B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)
  • Maintenance And Management Of Digital Transmission (AREA)

Abstract

本发明公开了一种基于AUTOSAR的COM层通信时限监测方法,其实施步骤如下:1)建立一个跟随COM层启动的监测警报器,在每一个通信实体初始化时创建时限参数和计时参数;2)监测警报器定时遍历所有通信实体,且每次遍历时更新各个通信实体的计时参数;3)根据时限参数和计时参数判断通信实体的状态,如果通信实体发送时间超时,则通知上层该通信实体发送失败;如果通信实体接收时间超时,则通知下层该通信实体接收失败;如果通信实体发送模式的时间点来临,则将该通信实体向下层传输,并重新设定该通信实体的时限参数。本发明具有占用资源少、维护简单、调试方便、处理速度快、收发效率高的优点。

Figure 201110159341

The invention discloses an AUTOSAR-based COM layer communication time limit monitoring method, the implementation steps of which are as follows: 1) establish a monitoring alarm that starts following the COM layer, and create time limit parameters and timing parameters when each communication entity is initialized; 2) The monitoring alarm traverses all communication entities at regular intervals, and updates the timing parameters of each communication entity during each traversal; 3) judges the state of the communication entity according to the time limit parameter and the timing parameter, and if the communication entity sends the timeout, it notifies the upper layer that the communication entity sends Failure; if the receiving time of the communication entity is overtime, notify the lower layer that the communication entity has failed to receive; if the time point of the communication entity sending mode comes, then transmit the communication entity to the lower layer, and reset the time limit parameter of the communication entity. The invention has the advantages of less resource occupation, simple maintenance, convenient debugging, fast processing speed and high transceiving efficiency.

Figure 201110159341

Description

基于AUTOSAR的COM层通信时限监测方法COM layer communication time limit monitoring method based on AUTOSAR

技术领域 technical field

本发明涉及智能汽车领域,具体涉及一种基于AUTOSAR的通信实体单元时限机制的实现方法。The invention relates to the field of smart cars, in particular to an implementation method of a communication entity unit time limit mechanism based on AUTOSAR.

背景技术 Background technique

AUTOSAR(汽车开放系统架构)是一个开放和标准化的汽车电子软件架构,它是由全球汽车制造商、部件供应商及其他电子、半导体和软件系统公司联合建立。AUTOSAR协议栈用于汽车电子的ECU内部和ECU之间的网络通讯,它是一个类似于OSI七层模型的协议栈,信息由上面的RTE(RunTime Environment)层传入到协议栈,在栈中被打包成帧,然后传入到底层硬件上。如图1所示,Com层通信实体单元主要为以下几种:AUTOSAR (Automotive Open System Architecture) is an open and standardized automotive electronics software architecture, which is jointly established by global automakers, component suppliers and other electronics, semiconductor and software system companies. The AUTOSAR protocol stack is used for network communication between ECUs of automotive electronics and between ECUs. It is a protocol stack similar to the OSI seven-layer model. Information is transmitted to the protocol stack from the RTE (RunTime Environment) layer above. In the stack are packed into frames and passed to the underlying hardware. As shown in Figure 1, the COM layer communication entity units mainly include the following types:

(1)Signal(原子消息),用于Com层和上层交互;(1) Signal (atomic message), used for interaction between the Com layer and the upper layer;

(2)SignalGroup(原子消息组),由一组原子消息构成,用于Com层和上层交互;(2) SignalGroup (atomic message group), which is composed of a group of atomic messages, is used for the interaction between the Com layer and the upper layer;

(3)IPDU(交互层通信数据单元):Signal和SignalGroup在Com层的载体,用于Com层和下层交互。(3) IPDU (interaction layer communication data unit): the carrier of Signal and SignalGroup in the Com layer, used for the interaction between the Com layer and the lower layer.

在AUTOSAR标准中规范里,COM通信栈中的COM层的一个重要的特征就是要求对通信实体单元提供超时监测机制,主要包括截止时间相关的时限监测和发送模式相关的时限监测。时限监测具体涉及以下几种:In the specification of the AUTOSAR standard, an important feature of the COM layer in the COM communication stack is that it is required to provide a timeout monitoring mechanism for the communication entity unit, mainly including time limit monitoring related to the deadline and time limit monitoring related to the sending mode. Time limit monitoring specifically involves the following:

(1)Signal的发送截止时间监测:监测Signal从上层发出发送请求之后,是否在规定的时间间隔内通过Signal所在的IPDU被发送到下层并收到来自下层的发送成功确认,如果在规定的时间内未能成功发送,则启动通知机制通知上层,否则在收到成功确认的时间点取消监测。(1) Signal transmission deadline monitoring: After Signal sends a sending request from the upper layer, whether it is sent to the lower layer through the IPDU where the Signal is located within the specified time interval and receives a successful transmission confirmation from the lower layer, if within the specified time If the transmission fails within a certain period of time, the notification mechanism will be activated to notify the upper layer, otherwise, the monitoring will be canceled at the time when the successful confirmation is received.

(2)Signal的接收截止时间监测:监测Signal所在的IPDU自从在中断中接收到数据之后,是否在规定的时间间隔内被上层提取,如果在规定的时间内未经提取则启动通知机制通知上层,否则在被上层提取的时间点取消这次监测。(2) Signal reception deadline monitoring: monitor whether the IPDU where the Signal is located has been extracted by the upper layer within the specified time interval since it received the data during the interruption, and if it has not been extracted within the specified time, start the notification mechanism to notify the upper layer , otherwise the monitoring will be canceled at the time when it is extracted by the upper layer.

(3)SignalGroup的发送截止时间监测:监测SignalGroup自从上层发送请求发出之后,是否在规定的时间间隔内通过SignalGroup所在的IPDU被发送到下层并收到来自下层的发送成功确认,如果在规定的时间内未能成功发送,则启动通知机制通知上层,否则取消这次监测。(3) SignalGroup sending deadline monitoring: monitor whether the SignalGroup has been sent to the lower layer through the IPDU where the SignalGroup is located within the specified time interval since the sending request of the upper layer and received a successful transmission confirmation from the lower layer, if within the specified time If the transmission fails within a certain period, the notification mechanism will be activated to notify the upper layer, otherwise the monitoring will be cancelled.

(4)SignalGroup的接收截止时间监测:监测SignalGroup所在的IPDU自从在中断中接收到数据之后,是否在规定的时间间隔内被上层提取,如果在规定的时间内未经提取则启动通知机制通知上层,否则在被上层提取的时间点取消这次监测。(4) SignalGroup reception cut-off time monitoring: Monitor whether the IPDU where SignalGroup is located has been extracted by the upper layer within the specified time interval since it receives the data in the interrupt, and if it is not extracted within the specified time, start the notification mechanism to notify the upper layer , otherwise the monitoring will be canceled at the time when it is extracted by the upper layer.

(5)IPDU的周期发送模式的时间监测:如图2示,IPDU经过一个用户配置的周期时限之后,执行向下层发送操作,然后重新开始新的周期时间监测,IPDU发送无限次。其中,周期发送模式就是直接以一个固定的周期执行IPDU的发送操作。(5) Time monitoring of IPDU periodic transmission mode: as shown in Figure 2, after the IPDU passes through a user-configured periodic time limit, the sending operation to the lower layer is performed, and then a new periodic time monitoring is restarted, and the IPDU is sent infinitely. Among them, the periodic sending mode is to directly execute the IPDU sending operation in a fixed period.

(6)IPDU的直接发送模式的时间监测:如图3示,IPDU经过一个用户配置的周期时限之后,执行向下层发送操作,然后重新开始新的周期时间监测,IPDU发送次数为N次。其中,N是用户配置的发送总数目,直接发送模式操作就是执行IPDU的N次以一个固定的间隔发送操作。其中直接发送IPDU的启动是由COM上层驱动的,如上层请求发送一个Signal/SignalGroup。(6) Time monitoring of the direct sending mode of the IPDU: as shown in Figure 3, after the IPDU passes through a user-configured cycle time limit, the sending operation to the lower layer is performed, and then a new cycle time monitoring is restarted, and the number of IPDU sending times is N times. Wherein, N is the total number of transmissions configured by the user, and the direct transmission mode operation is to perform N times of IPDU transmission operations at a fixed interval. Among them, the start of sending IPDU directly is driven by the upper layer of COM, such as the upper layer requests to send a Signal/SignalGroup.

(7)IPDU的混合发送模式的时间监测:如图4示,即执行IPDU的周期发送模式的时间监测,又执行IPDU的直接发送模式的时间监测。(7) Time monitoring of IPDU hybrid transmission mode: as shown in FIG. 4 , time monitoring of IPDU periodic transmission mode is performed, and time monitoring of IPDU direct transmission mode is performed.

在以往的做法中,通常是对上面的每个实体单元的每种时限监测都配置一个监测警报器(Alarm),来实现AUTOSAR标准中要求的时限机制。举例来说:在Com层配置了5个IPDU,每个IPDU分别配置了5个Signal和4个SignalGroup,在极端情况下每个Signal和SIgnalGroup都配置了发送截止时间和接收截止时间监测。这样每个IPDU需要的监测警报器总数目就是(5*2+4*2+1*2)*5=100,这样就需要AUTOSAR OS至少要支持同时能配置100个监测警报器。因此现有技术存在这样的问题:In the past practice, a monitoring alarm (Alarm) is usually configured for each time-limit monitoring of each physical unit above to realize the time-limit mechanism required by the AUTOSAR standard. For example: 5 IPDUs are configured on the Com layer, and each IPDU is configured with 5 Signals and 4 SignalGroups respectively. In extreme cases, each Signal and SIgnalGroup is configured with sending deadline and receiving deadline monitoring. In this way, the total number of monitoring alarms required for each IPDU is (5*2+4*2+1*2)*5=100, so AUTOSAR OS needs to support at least 100 monitoring alarms at the same time. Therefore there is such problem in prior art:

(1)需要用户配置太多监测警报器,引起的直接问题就是占用太多系统的Alarm资源,不易于维护和调试。(1) The user needs to configure too many monitoring alarms, which directly causes the problem of occupying too many alarm resources of the system, making it difficult to maintain and debug.

(2)维护过程中需要遍历太多的监测警报器,花费太多时间,而且有可能导致中断中操作太多,导致关时钟中断时间太长,会影响发送的时间准确性。(2) During the maintenance process, it is necessary to traverse too many monitoring alarms, which takes too much time, and may cause too many operations in the interruption, resulting in too long interruption time of the clock off, which will affect the accuracy of the sending time.

发明内容 Contents of the invention

本发明要解决的技术问题是提供一种占用资源少、维护简单、调试方便、处理速度快、收发效率高的基于AUTOSAR的COM层通信时限监测方法。The technical problem to be solved by the present invention is to provide an AUTOSAR-based COM layer communication time limit monitoring method that occupies less resources, is simple in maintenance, convenient in debugging, fast in processing speed, and high in sending and receiving efficiency.

为了解决上述技术问题,本发明采用的技术方案为:In order to solve the problems of the technologies described above, the technical solution adopted in the present invention is:

一种基于AUTOSAR的COM层通信时限监测方法,其实施步骤如下:A kind of COM layer communication time limit monitoring method based on AUTOSAR, its implementation steps are as follows:

1)建立一个跟随COM层启动的监测警报器,在每一个通信实体初始化时创建时限参数和计时参数;1) Establish a monitoring alarm that follows the start of the COM layer, and create time limit parameters and timing parameters when each communication entity is initialized;

2)监测警报器定时遍历所有通信实体,且每次遍历时更新各个通信实体的计时参数;2) The monitoring alarm regularly traverses all communication entities, and updates the timing parameters of each communication entity each time it traverses;

3)根据时限参数和计时参数判断通信实体的状态,如果通信实体发送时间超时,则通知上层该通信实体发送失败;如果通信实体接收时间超时,则通知下层该通信实体接收失败;如果通信实体发送模式的时间点来临,则将该通信实体向下层传输,并重新设定该通信实体的时限参数。3) Judging the state of the communication entity according to the time limit parameter and the timing parameter, if the sending time of the communication entity is overtime, then notify the upper layer that the communication entity has failed to send; if the communication entity receiving time is overtime, then notify the lower layer that the communication entity has failed to receive; When the time point of the mode comes, the communication entity is transmitted to the lower layer, and the time limit parameter of the communication entity is reset.

作为本发明的进一步改进:As a further improvement of the present invention:

所述步骤1)中创建时限参数时,如果通信实体为IPDU则建立直接发送次数、直接发送间隔、周期发送间隔三种时限参数,并设置用于监控直接发送模式中直接发送次数的发送计数器;如果通信实体为直接发送模式,则设置直接发送次数、直接发送间隔两种时限参数;如果通信实体为周期发送模式,则设置周期发送间隔一种时限参数;如果通信实体为混合发送模式,则设置直接发送次数、直接发送间隔、周期发送间隔三种时限参数;所述步骤2)中通信实体发送模式的时间点来临时,如果通信实体为直接发送模式,则在计时参数触发直接发送间隔时将该通信实体向下层传输、并更新所述发送计数器,如果发送计数器等于直接发送次数,则结束传输通信实体;如果通信实体为周期发送模式,则在计时参数触发周期发送间隔时将该通信实体向下层传输;如果通信实体为混合发送模式,则将一方面在计时参数触发直接发送间隔时将该通信实体向下层传输、并更新所述发送计数器,如果发送计数器等于直接发送次数,则结束直接发送模式传输通信实体;同时在计时参数触发周期发送间隔时将该通信实体向下层传输。When creating the time limit parameter in the described step 1), if the communication entity is IPDU then establish three kinds of time limit parameters of direct sending times, direct sending interval, periodic sending interval, and be set to be used for monitoring the sending counter of direct sending times in the direct sending mode; If the communication entity is in the direct sending mode, set the two time limit parameters of direct sending times and direct sending interval; if the communication entity is in the periodic sending mode, set a time limit parameter of periodic sending interval; if the communicating entity is in the mixed sending mode, set Three time limit parameters of direct sending times, direct sending interval, and periodic sending interval; when the time point of the communication entity sending mode in the step 2) comes, if the communication entity is in the direct sending mode, then when the timing parameter triggers the direct sending interval, the The communication entity transmits to the lower layer and updates the sending counter. If the sending counter is equal to the number of direct sending times, the communication entity is terminated; if the communication entity is in the periodic sending mode, the communication entity is sent to the communication entity when the timing parameter triggers the periodic sending interval. Lower layer transmission; if the communication entity is in the mixed sending mode, on the one hand, when the timing parameter triggers the direct sending interval, the communication entity will be transferred to the lower layer, and the sending counter will be updated. If the sending counter is equal to the number of direct sending times, the direct sending will be ended The communication entity is transmitted in the mode; at the same time, the communication entity is transmitted to the lower layer when the timing parameter triggers the periodic sending interval.

本发明具有下述优点:The present invention has the following advantages:

1、本发明通过一个监测警报器解决了所有通信实体的时限监测问题,大大节省COM层占用的AUTOSAR OS的监测警报器资源数目,同时也免除了监测警报器数据结构相关的空间,具有占用资源少、维护简单、调试方便、处理速度快、收发效率高的优点。1. The present invention solves the time limit monitoring problem of all communication entities through a monitoring alarm, greatly saves the number of monitoring alarm resources of the AUTOSAR OS occupied by the COM layer, and also eliminates the space related to the data structure of the monitoring alarm, and has the advantages of occupying resources Less, simple maintenance, convenient debugging, fast processing speed, high sending and receiving efficiency.

2、本发明由于只操作一个监测警报器,将动态维护的监测警报器触发链表转换为一个静态的时限参数和计时参数,非常便于操作,而且减少了数据结构维护的开销,因此收发开销小、收发效率更高。2. Since the present invention only operates one monitoring siren, the monitoring siren trigger linked list of dynamic maintenance is converted into a static time limit parameter and timing parameter, which is very easy to operate, and reduces the overhead of data structure maintenance, so the sending and receiving overhead is small, Sending and receiving efficiency is higher.

附图说明 Description of drawings

图1为现有技术中COM层与上层、下层的交互原理结构示意图。FIG. 1 is a schematic structural diagram of the interaction principle between the COM layer and the upper layer and the lower layer in the prior art.

图2为现有技术中IPDU周期发送模式的发送监测示意图。FIG. 2 is a schematic diagram of transmission monitoring in the IPDU periodic transmission mode in the prior art.

图3为现有技术中IPDU直接发送模式的发送监测示意图。Fig. 3 is a schematic diagram of transmission monitoring in the IPDU direct transmission mode in the prior art.

图4为现有技术中IPDU混合发送模式的发送监测示意图。FIG. 4 is a schematic diagram of transmission monitoring in an IPDU mixed transmission mode in the prior art.

图5为本发明实施例的流程示意图。Fig. 5 is a schematic flowchart of an embodiment of the present invention.

图6为本发明实施例发送两个均为周期发送模式的IPDU的发送监测示意图。FIG. 6 is a schematic diagram of transmission monitoring for transmitting two IPDUs in a periodic transmission mode according to an embodiment of the present invention.

图7为本发明实施例发送一个周期发送模式的IPDU、另一个为直接发送模式的IPDU的发送监测示意图。FIG. 7 is a schematic diagram of sending an IPDU in a periodic sending mode and another IPDU in a direct sending mode according to an embodiment of the present invention.

图8为两个Signal的发送监测示意图。Fig. 8 is a schematic diagram of sending and monitoring two Signals.

具体实施方式 Detailed ways

如图5所示,本发明实施例的基于AUTOSAR的COM层通信时限监测方法,其实施步骤如下:As shown in Figure 5, the COM layer communication time limit monitoring method based on AUTOSAR of the embodiment of the present invention, its implementation steps are as follows:

1)建立一个跟随COM层启动的监测警报器,在每一个通信实体初始化时创建时限参数和计时参数;1) Establish a monitoring alarm that follows the start of the COM layer, and create time limit parameters and timing parameters when each communication entity is initialized;

2)监测警报器定时遍历所有通信实体,且每次遍历时更新各个通信实体的计时参数;2) The monitoring alarm regularly traverses all communication entities, and updates the timing parameters of each communication entity each time it traverses;

3)根据时限参数和计时参数判断通信实体的状态,如果通信实体发送时间超时,则通知上层该通信实体发送失败;如果通信实体接收时间超时,则通知下层该通信实体接收失败;如果通信实体发送模式的时间点来临,则将该通信实体向下层传输,并重新设定该通信实体的时限参数。3) Judging the state of the communication entity according to the time limit parameter and the timing parameter, if the sending time of the communication entity is overtime, then notify the upper layer that the communication entity has failed to send; if the communication entity receiving time is overtime, then notify the lower layer that the communication entity has failed to receive; When the time point of the mode comes, the communication entity is transmitted to the lower layer, and the time limit parameter of the communication entity is reset.

步骤1)中创建时限参数时,如果通信实体为IPDU则建立直接发送次数、直接发送间隔、周期发送间隔三种时限参数,并设置用于监控直接发送模式中直接发送次数的发送计数器;如果通信实体为直接发送模式,则设置直接发送次数、直接发送间隔两种时限参数;如果通信实体为周期发送模式,则设置周期发送间隔一种时限参数;如果通信实体为混合发送模式,则设置直接发送次数、直接发送间隔、周期发送间隔三种时限参数;所述步骤2)中通信实体发送模式的时间点来临时,如果通信实体为直接发送模式,则在计时参数触发直接发送间隔时将该通信实体向下层传输、并更新所述发送计数器,如果发送计数器等于直接发送次数,则结束传输通信实体;如果通信实体为周期发送模式,则在计时参数触发周期发送间隔时将该通信实体向下层传输;如果通信实体为混合发送模式,则将一方面在计时参数触发直接发送间隔时将该通信实体向下层传输、并更新所述发送计数器,如果发送计数器等于直接发送次数,则结束直接发送模式传输通信实体;同时在计时参数触发周期发送间隔时将该通信实体向下层传输。When creating the time limit parameter in step 1), if the communication entity is IPDU, then set up three time limit parameters of direct sending times, direct sending interval, and periodic sending interval, and set the sending counter for monitoring the direct sending times in the direct sending mode; if communication If the entity is in the direct sending mode, set the time limit parameters of direct sending times and direct sending interval; if the communication entity is in periodic sending mode, set a time limit parameter of periodic sending interval; if the communicating entity is in hybrid sending mode, set direct sending Times, direct sending interval, three kinds of time limit parameters of periodic sending interval; When the time point of the communication entity sending mode in the described step 2) comes, if the communication entity is the direct sending mode, then when the timing parameter triggers the direct sending interval, the communication The entity transmits to the lower layer and updates the sending counter. If the sending counter is equal to the number of direct sending, the transmission of the communication entity is ended; if the communication entity is in the periodic sending mode, the communication entity is transmitted to the lower layer when the timing parameter triggers the periodic sending interval ; If the communication entity is in the mixed sending mode, on the one hand, when the timing parameter triggers the direct sending interval, the communication entity will be transmitted to the lower layer, and the sending counter will be updated; if the sending counter is equal to the number of direct sending times, then the direct sending mode transmission will be ended The communication entity; at the same time, when the timing parameter triggers the periodic sending interval, the communication entity is transmitted to the lower layer.

监测警报器(ComAlarm)具有一个回调函数ComAlarmAction,步骤2)中通过定时执行回调函数ComAlarmAction来触发遍历通信实体、更新各个通信实体的计时参数,计时参数存储于IPDU控制结构内部。执行回调函数ComAlarmAction的定时时间(tick)非常短,时限参数中涉及时限的均为tick的整数倍。The monitoring alarm (ComAlarm) has a callback function ComAlarmAction. In step 2), the callback function ComAlarmAction is executed periodically to trigger traversal of communication entities and update the timing parameters of each communication entity. The timing parameters are stored in the IPDU control structure. The timing time (tick) for executing the callback function ComAlarmAction is very short, and the time limit parameters involved in the time limit parameters are integer multiples of ticks.

若当前收取的通信实体为Signal或者SignalGroup时,则设置时限参数ComRxTimeout、计时参数CurRxTime。ComRxTimeout代表收取的超时时间,计时参数CurRxTime在当前Signal或者SignalGroup被遍历时更新。计时参数CurRxTime在初始化时初始化为时限参数ComRxTimeout,每次更新计时参数CurRxTime自动减1,当计时参数CurRxTime为0时则代表Signal或者SignalGroup收取时间超时,则通知下层该Signal或者SignalGroup收取失败。If the currently received communication entity is Signal or SignalGroup, set the time limit parameter ComRxTimeout and the timing parameter CurRxTime. ComRxTimeout represents the timeout period for collection, and the timing parameter CurRxTime is updated when the current Signal or SignalGroup is traversed. The timing parameter CurRxTime is initialized to the time limit parameter ComRxTimeout during initialization, and the timing parameter CurRxTime is automatically decremented by 1 each time it is updated. When the timing parameter CurRxTime is 0, it means that the Signal or SignalGroup collection time has expired, and the lower layer is notified that the Signal or SignalGroup collection failure.

若当前发送的通信实体为Signal或者SignalGroup时,则设置时限参数ComTxTimeout、计时参数CurTxTime。ComTxTimeout代表发送的超时时间,计时参数CurTxTime在当前Signal或者SignalGroup被遍历时更新。计时参数CurTxTime在初始化时初始化为时限参数ComTxTimeout,每次更新计时参数CurTxTime自动减1,当计时参数CurTxTime为0时则代表Signal或者SignalGroup发送时间超时,则通知上层该Signal或者SignalGroup发送失败。If the currently sent communication entity is Signal or SignalGroup, set the time limit parameter ComTxTimeout and the timing parameter CurTxTime. ComTxTimeout represents the timeout period for sending, and the timing parameter CurTxTime is updated when the current Signal or SignalGroup is traversed. The timing parameter CurTxTime is initialized to the time limit parameter ComTxTimeout during initialization, and the timing parameter CurTxTime is automatically decremented by 1 each time it is updated. When the timing parameter CurTxTime is 0, it means that the sending time of the Signal or SignalGroup has expired, and the upper layer will be notified that the Signal or SignalGroup failed to send.

本实施例中,每一个IPDU具有3个参数ComDNFactor、ComDPFactor和ComPPFactor,3个参数ComDNFactor、ComDPFactor和ComPPFactor用于传递IPDU的发送模式信息,并传递发送模式的参数。3个参数ComDNFactor、ComDPFactor和ComPPFactor和IPDU发送模式的关系如下表所示:In this embodiment, each IPDU has 3 parameters ComDNFactor, ComDPFactor and ComPPFactor, and the 3 parameters ComDNFactor, ComDPFactor and ComPPFactor are used to transfer IPDU transmission mode information and transmit transmission mode parameters. The relationship between the three parameters ComDNFactor, ComDPFactor and ComPPFactor and the IPDU sending mode is shown in the following table:

 ComDNFactor ComDNFactor   ComDPFactor ComDPFactor   ComPPFactor ComPPFactor   IPDU发送模式 IPDU sending mode  有效 efficient   有效 efficient   无效 invalid   直接发送模式 Direct send mode  无效 invalid   无效 invalid   有效 efficient   周期发送模式 Periodic sending mode  有效 efficient   有效 efficient   有效 efficient   混合发送模式 Mixed sending mode

ComDNFactor、ComDPFactor和ComPPFactor传递发送模式的参数和直接发送次数(CurNFactor)、直接发送间隔(CurDTFactor)、周期发送间隔(CurPTFactor)相一一对应。The parameters of ComDNFactor, ComDPFactor and ComPPFactor transfer mode correspond to the number of direct transmissions (CurNFactor), direct transmission interval (CurDTFactor), and periodic transmission interval (CurPTFactor).

Com层启动时监测警报器(ComAlarm)一并启动,监测警报器(ComAlarm)初始化要做的事情有:装载每个Signal/SignalGroup的CurTxTime为无效值;装载每个Signal/SignalGroup的CurRxTime为无效值;装载每个IPDU的CurNFactor、CurDTFactor、CurPTFactor分别为无效值、无效值和ComPPFactor,其中CurPTFactor通过参数传递,CurNFactor、CurDTFactor则在COM层中进行定义。上述无效值也可以是对应类型的最大值。若上层请求传输一个Signal或者SignalGroup,就设置这个Signal或者SignalGroup的CurTxTime为ComTxTimeout。如果这个Signal/SignalGroup所在的IPDU发送模式为直接发送模式,则还要设置这个IPDU的CurNFactor为ComDNFactor,CurDTFactor为ComDPFactor。若下层中断提示一个Signal或者SignalGroup已经接收到,就设置这个Signal或者SignalGroup的CurRxTime为ComRxTimeout。When the Com layer starts, the monitoring alarm (ComAlarm) starts together, and the initialization of the monitoring alarm (ComAlarm) needs to do the following: load the CurTxTime of each Signal/SignalGroup as an invalid value; load the CurRxTime of each Signal/SignalGroup as an invalid value ; The CurNFactor, CurDTFactor, and CurPTFactor loaded with each IPDU are invalid values, invalid values, and ComPPFactor, respectively, where CurPTFactor is passed through parameters, and CurNFactor and CurDTFactor are defined in the COM layer. The above invalid value can also be the maximum value of the corresponding type. If the upper layer requests to transmit a Signal or SignalGroup, set the CurTxTime of the Signal or SignalGroup to ComTxTimeout. If the IPDU sending mode of the Signal/SignalGroup is the direct sending mode, the CurNFactor of the IPDU is also set to ComDNFactor, and the CurDTFactor is ComDPFactor. If the lower layer interrupt prompts that a Signal or SignalGroup has been received, set the CurRxTime of this Signal or SignalGroup to ComRxTimeout.

执行回调函数ComAlarmAction的具体过程如下:The specific process of executing the callback function ComAlarmAction is as follows:

a)遍历所有发送方向上的IPDU装载的Signal、SignalGroup的发送截止时间监测辅助参数,如果是有效的,就执行自减减操作。如果监测到某个Signal/SignalGroup的截止时间已到,则通过配置好的通知机制通知上层这个Signal/SignalGroup发送失败,并且修改这个Signal/SignalGroup的发送截止时限辅助参数为无效值。a) Traversing the sending deadline monitoring auxiliary parameters of Signal and SignalGroup carried by IPDUs in all sending directions, and if valid, perform a self-decrement operation. If it is detected that the deadline for a certain Signal/SignalGroup has expired, the configured notification mechanism will be used to notify the upper layer that the Signal/SignalGroup has failed to send, and modify the auxiliary parameter of the Signal/SignalGroup’s sending deadline to an invalid value.

b)遍历所有接收方向上的IPDU装载的Signal、SignalGroup的接收截止时间监测,如果是有效的,就执行自减减操作。如果监测到某个Signal/SignalGroup的截止时间已到,则通过配置好的通知机制通知上层这个Signal/SignalGroup接收失败,并且修改这个Signal/SignalGroup的接收截止时限辅助参数为无效值。b) Traversing the receiving cut-off time monitoring of Signal and SignalGroup carried by IPDUs in all receiving directions, if it is valid, perform the self-decrement operation. If it is detected that the deadline for a certain Signal/SignalGroup has expired, the configured notification mechanism will be used to notify the upper layer that the Signal/SignalGroup has failed to receive, and modify the auxiliary parameter of the Signal/SignalGroup’s reception deadline to an invalid value.

c)遍历所有发送方向上的IPDU的发送模式相关的时限监测,如果是有效的,就执行自减减操作。如果某个周期发送模式IPDU相关周期时限已到,则通过下层提供的服务向下层发送一次这个IPDU,并且重新装载这个IPDU的周期时限的相关辅助参数。c) Traverse the time limit monitoring related to the sending mode of the IPDU in all sending directions, and if it is valid, perform the self-decrement and decrement operation. If the period time limit of an IPDU in a certain periodic transmission mode has expired, the IPDU is sent to the lower layer once through the service provided by the lower layer, and the relevant auxiliary parameters of the period time limit of the IPDU are reloaded.

如果某个是直接发送模式,并且这个IPDU的CurNFactor不是无效值,则维护,当这个IPDU相关间隔时限已到,则通过下层提供的服务向下层发送一次这个IPDU,让这个IPDU的CurNFactor自减减,并且重设这个IPDU的直接发送间隔时限相关辅助参数,如果CurNFactor已经减到0,则装载为无效值,结束这个直接发送模式IPDU的传输。If a certain is in the direct sending mode, and the CurNFactor of this IPDU is not an invalid value, maintain it. When the relevant interval time limit of this IPDU has expired, send this IPDU once to the lower layer through the service provided by the lower layer, and let the CurNFactor of this IPDU decrease automatically. , and reset the auxiliary parameters related to the direct sending interval time limit of this IPDU, if the CurNFactor has been reduced to 0, then load it as an invalid value, and end the transmission of this direct sending mode IPDU.

如图6所示,IPDU1和IPDU2均为周期发送模式,其中:As shown in Figure 6, both IPDU1 and IPDU2 are in periodic transmission mode, where:

IPDU1的参数为:ComDNFactor=0、ComDPFactor=0、ComPPFactor=3,The parameters of IPDU1 are: ComDNFactor=0, ComDPFactor=0, ComPPFactor=3,

IPDU2的参数为:ComDNFactor=0、ComDPFactor=0、ComPPFactor=5。IPDU1的周期发送间隔是3Ticks,IPDU1的周期发送间隔是5Ticks。The parameters of IPDU2 are: ComDNFactor=0, ComDPFactor=0, ComPPFactor=5. The periodic sending interval of IPDU1 is 3Ticks, and the periodic sending interval of IPDU1 is 5Ticks.

由于IPDU1和IPDU2均为周期发送模式,因此IPDU1和IPDU2的三种时限参数中CurNFactor和CurDTFactor都为无效值,CurPTFactor分别为3和5。由于周期发送IPDU的特性,两个IPDU此时都要执行一次向下传输。以后每经过一个Tick,ComAlarm完成一次维护,维护过程中两个IPDU的控制结构中只有CurPTFactor有效,故只让CurPTFactor做自减减操作。Since both IPDU1 and IPDU2 are in periodic transmission mode, among the three time limit parameters of IPDU1 and IPDU2, CurNFactor and CurDTFactor are all invalid values, and CurPTFactor is 3 and 5 respectively. Due to the characteristics of periodically sending IPDUs, two IPDUs must perform a downward transmission at this time. After every Tick, ComAlarm completes a maintenance. During the maintenance process, only CurPTFactor is valid in the control structure of the two IPDUs, so only CurPTFactor is allowed to perform self-decreasing and decrementing operations.

当Ticks==3的时候,ComAlarm监测到IPDU1的CurPTFactor为0,即IPDU1的周期发送周期已到,执行IPDU1的第2次向下层传输操作,并再次装载IPDU1的CurPTFactor为用户配置的ComPPFactor。When Ticks==3, ComAlarm detects that the CurPTFactor of IPDU1 is 0, that is, the periodic sending period of IPDU1 has arrived, and executes the second transmission operation of IPDU1 to the lower layer, and reloads the CurPTFactor of IPDU1 as the ComPPFactor configured by the user.

当Ticks==5的时候,ComAlarm监测到IPDU2的CurPTFactor为0,即IPDU2的周期发送周期已到,执行IPDU2的第2次向下层传输操作,并再次装载IPDU2的CurPTFactor为用户配置的IPDU2的ComPPFactor(即为5)。When Ticks==5, ComAlarm detects that the CurPTFactor of IPDU2 is 0, that is, the periodic sending cycle of IPDU2 has arrived, and executes the second transmission operation of IPDU2 to the lower layer, and reloads the CurPTFactor of IPDU2 as the ComPPFactor of IPDU2 configured by the user (ie 5).

每当到3*k(k>2,k为自然数)个Tick后,ComAlarm监测到IPDU1的CurPTFactor为0,即IPDU1的周期发送周期已到,执行IPDU1的第k次向下层传输操作,并再次装载IPDU1的CurPTFactor为用户配置的IPDU1的ComPPFactor(即为3)。Every time after 3*k (k>2, k is a natural number) Ticks, ComAlarm detects that the CurPTFactor of IPDU1 is 0, that is, the periodic sending period of IPDU1 has arrived, and executes the kth downward transmission operation of IPDU1, and repeats The CurPTFactor loaded with IPDU1 is the ComPPFactor of IPDU1 configured by the user (that is, 3).

每当到5*k(k>2,k为自然数)个Tick后,ComAlarm监测到IPDU2的CurPTFactor为0,即IPDU2的周期发送周期已到,执行IPDU2的第k次向下层传输操作,并再次装载IPDU2的CurPTFactor为用户配置的IPDU2的ComPPFactor(即为5)。Every time 5*k (k>2, k is a natural number) Ticks, ComAlarm detects that the CurPTFactor of IPDU2 is 0, that is, the periodic sending period of IPDU2 has arrived, and executes the kth transmission operation of IPDU2 to the lower layer, and repeats The CurPTFactor loaded with IPDU2 is the ComPPFactor of IPDU2 configured by the user (that is, 5).

这样就用这个ComAlarm解决了两个都是周期发送模式的IPDU时限监测问题。同理,这样的IPDU的数目扩张到很多个时候本方法也是可行的。In this way, this ComAlarm is used to solve the problem of IPDU time limit monitoring in both periodic sending modes. Similarly, this method is also feasible when the number of such IPDUs expands to many times.

如图7所示,IPDU1为周期发送模式,IPDU2为直接发送模式,其中:As shown in Figure 7, IPDU1 is in periodic sending mode, and IPDU2 is in direct sending mode, where:

IPDU1的参数为:ComDNFactor=0、ComDPFactor=0、ComPPFactor=5,The parameters of IPDU1 are: ComDNFactor=0, ComDPFactor=0, ComPPFactor=5,

IPDU2的参数为:ComDNFactor=3、ComDPFactor=3、ComPPFactor=0。The parameters of IPDU2 are: ComDNFactor=3, ComDPFactor=3, ComPPFactor=0.

IPDU1的周期发送间隔是5Ticks,IPDU1的直接发送次数为3次、直接发送间隔为3Ticks。The periodic sending interval of IPDU1 is 5Ticks, the number of direct sending of IPDU1 is 3 times, and the direct sending interval is 3Ticks.

Ticks=0的时候,COM初始化,ComAlarm启动,IPDU1的辅助参数CurNFactor、CurDTFactor、CurPTFactor分别被初始化为无效值、无效值、5;IPDU2的辅助参数CurNFactor、CurDTFactor、CurPTFactor分别被初始化为无效值、无效值、无效值。由于周期发送IPDU的特性,IPDU1此时要执行一次向下传输。When Ticks=0, COM is initialized, ComAlarm starts, and the auxiliary parameters CurNFactor, CurDTFactor, and CurPTFactor of IPDU1 are initialized to invalid values, invalid values, and 5 respectively; the auxiliary parameters of IPDU2 CurNFactor, CurDTFactor, and CurPTFactor are initialized to invalid values, value, invalid value. Due to the characteristics of periodically sending IPDUs, IPDU1 needs to perform a downward transmission at this time.

当Ticks=1的时候,IPDU2由于上层驱动(如上层需要发送一个Signal/SignalGroup)而启动传输,此时,ComAlarm需要设置IPDU2的辅助参数CurNFactor、CurDTFactor、CurPTFactor分别为3、3、无效值。由于直接发送IPDU的特性,IPDU2此时要执行一次向下传输,并让CurNFactor自减减一次。When Ticks=1, IPDU2 starts transmission due to the upper layer driver (such as the upper layer needs to send a Signal/SignalGroup). At this time, ComAlarm needs to set the auxiliary parameters CurNFactor, CurDTFactor, and CurPTFactor of IPDU2 to 3, 3, and invalid values respectively. Due to the characteristics of sending IPDU directly, IPDU2 needs to perform a downward transmission at this time, and let CurNFactor decrement once.

当Ticks==4的时候,ComAlarm监测到IPDU2的CurDTFactor为0,即IPDU2的直接发送时限已到,执行IPDU2的第2次向下层传输操作,CurNFactor做自减减为1,并再次装载IPDU1的CurDTFactor为用户配置的IPDU2的ComDPFactor(即为3)。When Ticks==4, ComAlarm detects that the CurDTFactor of IPDU2 is 0, that is, the time limit for direct sending of IPDU2 has expired, and the second transmission operation of IPDU2 to the lower layer is performed, and the CurNFactor is automatically decremented to 1, and the IPDU1 is reloaded CurDTFactor is the ComDPFactor of IPDU2 configured by the user (that is, 3).

当Ticks==5的时候,ComAlarm监测到IPDU1的CurPTFactor为0,即IPDU1的周期发送时限已到,执行IPDU1的第2次向下层传输操作,并再次装载IPDU1的CurPTFactor为用户配置的IPDU1的ComPPFactor(即为5)。When Ticks==5, ComAlarm detects that the CurPTFactor of IPDU1 is 0, that is, the periodic sending time limit of IPDU1 has expired, and executes the second transmission operation of IPDU1 to the lower layer, and reloads the CurPTFactor of IPDU1 as the ComPPFactor of IPDU1 configured by the user (ie 5).

当Ticks==7的时候,ComAlarm监测到IPDU2的CurDTFactor为0,即IPDU2的直接发送时限已到,执行IPDU2的第3次向下层传输操作,CurNFactor做自减减为0。此时IDPU1完成3次发送,三个辅助参数设为无效值,直到下一个引起这个IPDU启动传输的Signal/SignalGroup到达后再次启动。When Ticks==7, ComAlarm detects that the CurDTFactor of IPDU2 is 0, that is, the time limit for direct sending of IPDU2 has arrived, and the third transmission operation of IPDU2 to the lower layer is executed, and CurNFactor is automatically decremented to 0. At this time, IDPU1 completes 3 transmissions, and the three auxiliary parameters are set to invalid values until the next Signal/SignalGroup that causes this IPDU to start transmission arrives and starts again.

每当到5*k(k>2,k为自然数)个Ticks后,ComAlarm监测到IPDU1的CurPTFactor为0,即IPDU2的周期发送周期已到,执行IPDU2的第k次向下层传输操作,并再次装载IPDU2的CurPTFactor为用户配置的IPDU1的ComPPFactor(即为5)。Every time 5*k (k>2, k is a natural number) Ticks, ComAlarm detects that the CurPTFactor of IPDU1 is 0, that is, the periodic sending cycle of IPDU2 has arrived, and executes the kth transmission operation of IPDU2 to the lower layer, and repeats The CurPTFactor loaded with IPDU2 is the ComPPFactor of IPDU1 configured by the user (that is, 5).

这样就用一个ComAlarm解决了两个IPDU,一个周期发送模式,一个N=3的直接发送模式的时限监测问题。显然也可以把这样的IPDU的数目扩张到很多个,并且还是用这个ComAlarm来监测。In this way, a ComAlarm solves the time limit monitoring problem of two IPDUs, a periodic sending mode, and a direct sending mode with N=3. Obviously, it is also possible to expand the number of such IPDUs to many, and still use this ComAlarm to monitor.

由于混合发送模式的一个IPDU的时限监测可以看做是两个IPDU:一个周期发送模式,一个是直接发送模式的时限监测问题,故也可以用一个ComAlarm解决。由于各种周期发送模式之间的IPDU是独立的,这样就可以用ComAlarm解决所有IPDU的发送相关的时限监测问题。Since the time limit monitoring of an IPDU in the mixed sending mode can be regarded as two IPDUs: one in the periodic sending mode and the other in the direct sending mode, it can also be solved with a ComAlarm. Since the IPDUs between various periodic transmission modes are independent, ComAlarm can be used to solve the time limit monitoring problems related to the transmission of all IPDUs.

如图8所示,创建时限参数时,配置Signal1:ComTxTimeout=7;配置Signal2:ComTxTimeout=3。即Signal1的发送超时时限为7Ticks,Signal2的发送超时时限为2Ticks。As shown in Figure 8, when creating the time limit parameter, configure Signal1: ComTxTimeout=7; configure Signal2: ComTxTimeout=3. That is, the sending timeout period of Signal1 is 7Ticks, and the sending timeout period of Signal2 is 2Ticks.

Ticks=0的时候,COM初始化,ComAlarm启动,Signal1和Signal2的辅助参数CurTxTime都被初始化为无效值。每经过一个Tick,ComAlarm完成一次维护,维护过程中如果Signal的CurTxTime不是无效值则自减减,如果CurTxTime为0时,触发Signal的发送超时动作通知上层并设置CurTxTime为无效值。When Ticks=0, COM is initialized, ComAlarm is started, and the auxiliary parameter CurTxTime of Signal1 and Signal2 are initialized to invalid values. Every time a Tick passes, ComAlarm completes maintenance. During the maintenance process, if the CurTxTime of Signal is not an invalid value, it will be automatically decremented. If the CurTxTime is 0, it will trigger the sending timeout action of Signal to notify the upper layer and set CurTxTime to an invalid value.

当Ticks=1的时候,COM上层发送Signal1,此时,ComAlarm中需要把Signal1辅助参数CurTxTime装载为7。When Ticks=1, the COM upper layer sends Signal1. At this time, the auxiliary parameter CurTxTime of Signal1 needs to be loaded as 7 in the ComAlarm.

当Ticks=2的时候,COM上层发送Signal2,此时,ComAlarm中需要把Signal1辅助参数CurTxTime装载为3。When Ticks=2, the COM upper layer sends Signal2. At this time, the auxiliary parameter CurTxTime of Signal1 needs to be loaded as 3 in the ComAlarm.

当Ticks=5的时候,Signal2的CurTxTime自减减到0,把它的CurTxTime设为无效值,并触发Signa2的发送超时动作以通知上层。Signal2完成监测。When Ticks=5, the CurTxTime of Signal2 is automatically decremented to 0, and its CurTxTime is set to an invalid value, and the sending timeout action of Signal2 is triggered to notify the upper layer. Signal2 completes monitoring.

当Ticks=6的时候,收到Signal1的发送成功确认,Signal1发送成功。设置它的CurTxTime为无效值。Signal1完成监测。When Ticks=6, the successful sending confirmation of Signal1 is received, and Signal1 is sent successfully. Set its CurTxTime to an invalid value. Signal1 completes monitoring.

这样,就利用一个ComAlarm解决了两个Signal的发送截止时间监测问题。由于SignalGroup的发送截止时间监测问题和Signal的发送截止时间问题基本是同样道理,所以也可以用一个ComAlarm来解决SignalGroup的发送截止时间监测问题。并且,Signal和SignalGroup的数目可以增加。同样的道理也可以用一个ComAlarm来解决Signal和SignalGroup的接收截止时间监测问题。并且Signal和SignalGroup的数目可以任意增加。In this way, a ComAlarm is used to solve the problem of monitoring the sending deadline of two Signals. Since SignalGroup's sending deadline monitoring problem is basically the same as Signal's sending deadline problem, a ComAlarm can also be used to solve SignalGroup's sending deadline monitoring problem. Also, the number of Signals and SignalGroups can be increased. In the same way, a ComAlarm can also be used to solve the receiving deadline monitoring problem of Signal and SignalGroup. And the number of Signal and SignalGroup can be increased arbitrarily.

由于IPDU的发送模式相关的时限监测问题和Signal/SignalGroup的截止时间相关的监测问题是独立的,就可以由同一个ComAlarm并行解决。至此,本文就用一个ComAlarm解决了Com层的所有的通信实体单元的时限监测问题。Since the time limit monitoring problem related to the sending mode of IPDU and the monitoring problem related to the deadline of Signal/SignalGroup are independent, they can be solved by the same ComAlarm in parallel. So far, this article uses a ComAlarm to solve the time limit monitoring problem of all communication entity units in the Com layer.

以上所述仅为本发明的优选实施方式,本发明的保护范围并不仅限于上述实施方式,凡是属于本发明原理的技术方案均属于本发明的保护范围。对于本领域的技术人员而言,在不脱离本发明的原理的前提下进行的若干改进和润饰,这些改进和润饰也应视为本发明的保护范围。The above descriptions are only preferred implementations of the present invention, and the scope of protection of the present invention is not limited to the above-mentioned implementations. All technical solutions belonging to the principle of the present invention belong to the scope of protection of the present invention. For those skilled in the art, some improvements and modifications made without departing from the principles of the present invention should also be regarded as the protection scope of the present invention.

Claims (1)

1.一种基于AUTOSAR的COM层通信时限监测方法,其特征在于其实施步骤如下:1. A COM layer communication time limit monitoring method based on AUTOSAR is characterized in that its implementation steps are as follows: 1)建立一个跟随COM层启动的监测警报器,在每一个通信实体初始化时创建时限参数和计时参数;1) Establish a monitoring alarm that follows the start of the COM layer, and create time limit parameters and timing parameters when each communication entity is initialized; 2)监测警报器定时遍历所有通信实体,且每次遍历时更新各个通信实体的计时参数;2) The monitoring alarm regularly traverses all communication entities, and updates the timing parameters of each communication entity each time it traverses; 3)根据时限参数和计时参数判断通信实体的状态,如果通信实体发送时间超时,则通知上层该通信实体发送失败;如果通信实体接收时间超时,则通知下层该通信实体接收失败;如果通信实体发送模式的时间点来临,则将该通信实体向下层传输,并重新设定该通信实体的时限参数;3) Judging the state of the communication entity according to the time limit parameter and timing parameter, if the sending time of the communication entity is overtime, notify the upper layer that the communication entity failed to send; if the communication entity receiving time exceeds the time limit, notify the lower layer that the communication entity failed to receive; When the time point of the mode arrives, transmit the communication entity to the lower layer, and reset the time limit parameter of the communication entity; 所述步骤1)中创建时限参数时,如果通信实体为IPDU则建立直接发送次数、直接发送间隔、周期发送间隔三种时限参数,并设置用于监控直接发送模式中直接发送次数的发送计数器;如果通信实体为直接发送模式,则设置直接发送次数、直接发送间隔两种时限参数;如果通信实体为周期发送模式,则设置周期发送间隔一种时限参数;如果通信实体为混合发送模式,则设置直接发送次数、直接发送间隔、周期发送间隔三种时限参数;所述步骤2)中通信实体发送模式的时间点来临时,如果通信实体为直接发送模式,则在计时参数触发直接发送间隔时将该通信实体向下层传输、并更新所述发送计数器,如果发送计数器等于直接发送次数,则结束传输通信实体;如果通信实体为周期发送模式,则在计时参数触发周期发送间隔时将该通信实体向下层传输;如果通信实体为混合发送模式,则将一方面在计时参数触发直接发送间隔时将该通信实体向下层传输、并更新所述发送计数器,如果发送计数器等于直接发送次数,则结束直接发送模式传输通信实体;同时在计时参数触发周期发送间隔时将该通信实体向下层传输。When creating the time limit parameter in the step 1), if the communication entity is an IPDU, then establish three time limit parameters, the number of direct transmission times, the direct transmission interval, and the periodic transmission interval, and set a transmission counter for monitoring the number of direct transmissions in the direct transmission mode; If the communication entity is in the direct sending mode, set the two time limit parameters of the direct sending times and the direct sending interval; if the communication entity is in the periodic sending mode, set a time limit parameter of the periodic sending interval; if the communication entity is in the mixed sending mode, set There are three time limit parameters: direct sending times, direct sending interval, and periodic sending interval; when the time point of the sending mode of the communication entity in step 2) comes, if the communication entity is in the direct sending mode, when the timing parameter triggers the direct sending interval, it will The communication entity transmits to the lower layer and updates the sending counter. If the sending counter is equal to the number of direct transmissions, the communication entity is terminated; if the communication entity is in the periodic sending mode, the communication entity is sent to the communication entity when the timing parameter triggers the periodic sending interval. Lower layer transmission; if the communication entity is in the mixed sending mode, on the one hand, when the timing parameter triggers the direct sending interval, the communication entity will be transferred to the lower layer, and the sending counter will be updated. If the sending counter is equal to the number of direct sending times, the direct sending will be ended The mode transmits the communication entity; at the same time, the communication entity is transmitted to the lower layer when the timing parameter triggers the periodic sending interval.
CN 201110159341 2011-06-14 2011-06-14 COM layer communication time limit monitoring method based on AUTOSAR Expired - Fee Related CN102231683B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN 201110159341 CN102231683B (en) 2011-06-14 2011-06-14 COM layer communication time limit monitoring method based on AUTOSAR

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN 201110159341 CN102231683B (en) 2011-06-14 2011-06-14 COM layer communication time limit monitoring method based on AUTOSAR

Publications (2)

Publication Number Publication Date
CN102231683A CN102231683A (en) 2011-11-02
CN102231683B true CN102231683B (en) 2013-10-30

Family

ID=44844223

Family Applications (1)

Application Number Title Priority Date Filing Date
CN 201110159341 Expired - Fee Related CN102231683B (en) 2011-06-14 2011-06-14 COM layer communication time limit monitoring method based on AUTOSAR

Country Status (1)

Country Link
CN (1) CN102231683B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103049324A (en) * 2013-01-08 2013-04-17 浙江大学 Method for managing read-write tasks of AUTOSAR (automotive open system architecture) NvM [NVRAM (nonvolatile random access memory) manager] on basis of priority bitmap

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7853941B1 (en) * 2004-03-11 2010-12-14 Dspace Gmbh Process for automatic matching of software
CN102073549A (en) * 2011-01-18 2011-05-25 浙江大学 Communication method between assemblies on basis of resource sharing

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7853941B1 (en) * 2004-03-11 2010-12-14 Dspace Gmbh Process for automatic matching of software
CN102073549A (en) * 2011-01-18 2011-05-25 浙江大学 Communication method between assemblies on basis of resource sharing

Also Published As

Publication number Publication date
CN102231683A (en) 2011-11-02

Similar Documents

Publication Publication Date Title
CN110758289B (en) A sleep and wake-up method for an in-vehicle hybrid network including in-vehicle Ethernet
CN107087033B (en) Message pushing method and device, storage medium and computer equipment
CN100596049C (en) A message retransmission method and system
CN103581225A (en) Distributed system node processing task method
CN108710597B (en) Method and system for optimizing MCU communication by using GPIO
CN104954411A (en) Method for sharing network resource by distributed system, terminal thereof and system thereof
CN103888441A (en) Information transmitting method between application and protocol stack and processing device
CN108055186B (en) Master-slave processor communication method and device
CN102307194A (en) Graceful restarting method and device for universal protocol process
WO2023160568A1 (en) Communication method and apparatus, and system and storage medium
WO2011131010A1 (en) Method and apparatus for timing
CN102231683B (en) COM layer communication time limit monitoring method based on AUTOSAR
CN100442713C (en) A Method of Improving the Efficiency of Communication Link Layer Protocol
CN102831007B (en) Accessing method for real-time processing shared resource in system and real-time processing system
WO2010007578A1 (en) Cableless usb connectivity over ieee 802.11 networks
CN109450757B (en) Method for starting CANopen master station and overall management device thereof
CN107171915B (en) Communication protocol changing method and device
CN117544504A (en) Data processing unit thermal updating method, device, communication equipment and storage medium
JP5262418B2 (en) Task scheduling apparatus and task scheduling method
CN110874473A (en) Virus detection method, device and system, cloud service system and storage medium
Hank Pelican: A new can controller supporting diagnosis and system optimization
WO2014169547A1 (en) Method and apparatus for processing operation on endpoint peripheral
CN115426393A (en) A method and device for realizing wireless control information interaction
CN113918640A (en) ETL flow execution method based on asynchronous mode
JP2004260562A (en) Method and device for transmitting and receiving packet

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C53 Correction of patent of invention or patent application
CB03 Change of inventor or designer information

Inventor after: Li Hong

Inventor after: Gu Zonghua

Inventor after: Wang Xuyang

Inventor after: Zhang Chengshuo

Inventor after: Chen Haojie

Inventor after: Wu Chaohui

Inventor before: Li Hong

Inventor before: Gu Zonghua

Inventor before: Wang Xuyang

Inventor before: Zhang Chengshuo

Inventor before: Chen Haojie

COR Change of bibliographic data

Free format text: CORRECT: INVENTOR; FROM: LI HONG GU ZONGHUA WANG XUYANG ZHANG CHENGSHUO CHEN HAOJIE TO: LI HONG GU ZONGHUA WANG XUYANG ZHANG CHENGSHUO CHEN HAOJIE WU ZHAOHUI

C14 Grant of patent or utility model
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20131030