+

CN114363229A - A self-checking method and self-checking device for vehicle-machine testing - Google Patents

A self-checking method and self-checking device for vehicle-machine testing Download PDF

Info

Publication number
CN114363229A
CN114363229A CN202210008135.7A CN202210008135A CN114363229A CN 114363229 A CN114363229 A CN 114363229A CN 202210008135 A CN202210008135 A CN 202210008135A CN 114363229 A CN114363229 A CN 114363229A
Authority
CN
China
Prior art keywords
message
bus
self
vehicle
verified
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.)
Pending
Application number
CN202210008135.7A
Other languages
Chinese (zh)
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.)
Cienet Technologies (beijing) Co ltd
Original Assignee
Cienet Technologies (beijing) Co ltd
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 Cienet Technologies (beijing) Co ltd filed Critical Cienet Technologies (beijing) Co ltd
Priority to CN202210008135.7A priority Critical patent/CN114363229A/en
Publication of CN114363229A publication Critical patent/CN114363229A/en
Priority to PCT/CN2022/143933 priority patent/WO2023131073A1/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/40Bus networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/06Management of faults, events, alarms or notifications
    • H04L41/0631Management of faults, events, alarms or notifications using root cause analysis; using analysis of correlation between notifications, alarms or events based on decision criteria, e.g. hierarchy, tree or time analysis
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/06Management of faults, events, alarms or notifications
    • H04L41/0677Localisation of faults
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/50Testing arrangements

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Small-Scale Networks (AREA)

Abstract

The invention discloses a vehicle-mounted test-oriented self-checking method and a vehicle-mounted test-oriented self-checking device, which are used for detecting communication of a CAN bus between test equipment and a vehicle-mounted system. The self-checking method comprises the following steps: acquiring a data frame containing the CAN message to be sent from the test equipment or the vehicle-mounted machine system from the data channel, decoding to obtain the CAN message and storing the decoded CAN message; acquiring CAN information to be verified in real time from a CAN bus, and storing the CAN information to be verified; comparing the CAN message to be verified with the decoded CAN message, arbitrating to determine whether the CAN message is correctly transmitted through a CAN bus, and recording failure times; and if the failure times of the CAN messages sent on the CAN bus are judged to exceed the threshold value, the CAN messages corresponding to the failure times are packaged and sent again through the CAN bus. The invention CAN quickly and efficiently locate the reason of CAN message sending failure, save the test cost and improve the test efficiency.

Description

一种面向车机测试的自检方法及自检装置A self-checking method and self-checking device for vehicle-machine testing

技术领域technical field

本发明涉及一种面向车机测试的自检方法,同时也涉及相应的自检装置,属于汽车电子技术领域。The invention relates to a self-inspection method for vehicle and machine testing, and also relates to a corresponding self-inspection device, belonging to the technical field of automotive electronics.

背景技术Background technique

CAN(Controller Area Network)是控制器局域网络的简称,是目前国际上应用最广泛的现场总线之一。电动汽车作为电子产品,车机系统内部具有复杂的通信设备,需要使用CAN协议进行内部通信。然而,在车机系统的使用过程中,存在很多不易判断原因导致的CAN消息发送失败,需要对其开展专门的测试工作。CAN (Controller Area Network) is the abbreviation of Controller Area Network, which is one of the most widely used field buses in the world. As an electronic product, an electric vehicle has complex communication equipment inside the vehicle-machine system, and needs to use the CAN protocol for internal communication. However, in the process of using the vehicle-machine system, there are many failures in CAN message transmission caused by difficult to determine the reasons, and special testing work is required.

通常,在车机测试的过程中,通常采用车机测试系统(简称测试系统,通常由安装测试软件的计算机实现)发送测试指令,通过分析车机系统返回的日志文件,或者通过其他验证手段来验证车机系统处理指令的合理性。这就需要分析大量基于CAN总线触发的测试用例。由于CAN总线由CAN_High和CAN_Low两条信号线共同构成一组差分信号线,若要分析其是否有输出信号,需要连接逻辑分析仪,查看输出波形图,不能通过简单地闭环来完成自检。并且在验证的过程中,如果接收端没有收到CAN信息,却无法判断是发送端发生错误还是接收端接收出错,因而无法快速解决问题。Usually, in the process of vehicle-machine testing, the vehicle-machine test system (referred to as the test system, usually implemented by a computer with test software) is usually used to send test instructions, and the log files returned by the vehicle-machine system are analyzed, or other verification methods are used. Verify the rationality of the instructions processed by the vehicle-machine system. This requires analyzing a large number of test cases triggered by the CAN bus. Since the CAN bus is composed of two signal lines CAN_High and CAN_Low together to form a set of differential signal lines, if you want to analyze whether it has an output signal, you need to connect a logic analyzer to view the output waveform, and you cannot simply close the loop to complete the self-test. And in the process of verification, if the receiving end does not receive the CAN information, it cannot judge whether an error occurs at the transmitting end or the receiving end receives an error, so the problem cannot be solved quickly.

所以,如何避免CAN消息发送失败导致出错,或者快速解决CAN消息发送失败导致的问题,仍然是现有车机测试场景亟待解决的痛点之一。Therefore, how to avoid errors caused by the failure of CAN message transmission, or how to quickly solve the problem caused by the failure of CAN message transmission, is still one of the pain points to be solved urgently in the existing vehicle-machine test scenarios.

发明内容SUMMARY OF THE INVENTION

本发明所要解决的首要技术问题在于提供一种面向车机测试的自检方法。The primary technical problem to be solved by the present invention is to provide a self-inspection method for vehicle and machine testing.

本发明所要解决的另一技术问题在于提供一种面向车机测试的自检装置。Another technical problem to be solved by the present invention is to provide a self-inspection device for vehicle and machine testing.

为实现上述技术目的,本发明采用以下技术方案:For realizing the above-mentioned technical purpose, the present invention adopts the following technical solutions:

根据本发明实施例的第一方面,提供一种面向车机测试的自检方法,用于对测试设备和车机系统之间的CAN总线的通信进行检测,包括以下步骤:According to a first aspect of the embodiments of the present invention, a self-checking method for vehicle-machine testing is provided, which is used to detect the communication of the CAN bus between the test equipment and the vehicle-machine system, including the following steps:

从数据通道获取来自测试设备或车机系统中将要发送的包含CAN消息的数据帧,解码后获得所述CAN消息并且存储解码后CAN消息;Obtain the data frame containing the CAN message to be sent from the test equipment or the vehicle-machine system from the data channel, obtain the CAN message after decoding, and store the decoded CAN message;

从CAN总线实时获取待验证CAN消息,并且对所述待验证CAN消息进行存储;Obtain the CAN message to be verified in real time from the CAN bus, and store the CAN message to be verified;

比对所述待验证CAN消息和所述解码后CAN消息,进行仲裁,确认所述CAN消息是否通过所述CAN总线进行了正确发送,并记录失败次数;Compare the CAN message to be verified and the decoded CAN message, conduct arbitration, confirm whether the CAN message is correctly sent through the CAN bus, and record the number of failures;

如果判断出发送在所述CAN总线上的CAN消息失败次数超过门限值,则将与失败次数对应的CAN消息通过所述CAN总线打包补发。If it is determined that the number of failures of the CAN message sent on the CAN bus exceeds the threshold value, the CAN message corresponding to the number of failures is packaged and reissued through the CAN bus.

其中较优地,比对所述待验证CAN消息和所述解码后CAN消息,进行仲裁,确认所述CAN消息是否通过所述CAN总线进行了正确发送,包括以下子步骤:Preferably, compare the CAN message to be verified and the decoded CAN message, conduct arbitration, and confirm whether the CAN message is correctly sent through the CAN bus, including the following sub-steps:

从所述CAN总线获得所述待验证CAN消息时,记录从所述CAN总线上接收的接收时间t2和接收内容c2;When obtaining the to-be-verified CAN message from the CAN bus, record the receiving time t2 and the received content c2 received from the CAN bus;

从所述数据通道接收到数据帧后,解析出CAN消息的预计的发送时间t1及发送内容c1;After receiving the data frame from the data channel, parse out the expected sending time t1 and sending content c1 of the CAN message;

根据所述接收时间t2,确定出与所述接收内容c2所对应的发送时间,然后再确定与所述接收内容c2所对应的解码后CAN消息;According to the receiving time t2, determine the sending time corresponding to the receiving content c2, and then determine the decoded CAN message corresponding to the receiving content c2;

将所述接收内容c2中的待验证CAN消息与所述接收内容c2所对应的解码后CAN消息进行比较,如果一致则判断为成功;如果不一致则判断为失败。Comparing the to-be-verified CAN message in the received content c2 with the decoded CAN message corresponding to the received content c2, if they are consistent, it is judged as success; if they are inconsistent, it is judged as failure.

其中较优地,所述失败次数是指连续失败的次数,如果有一次发送成功,则将失败次数清零。Preferably, the number of failures refers to the number of consecutive failures, and if there is one successful transmission, the number of failures is reset to zero.

其中较优地,所述打包补发是指将从所述测试设备或所述车机系统发送失败的所有CAN消息,封装到消息帧,以一个数据包的形式,通过所述CAN总线发送给所述发送失败的CAN消息的接收方。Preferably, the packaged reissue refers to encapsulating all CAN messages that fail to be sent from the test device or the vehicle-machine system into message frames, and in the form of a data packet, sent to the CAN bus through the CAN bus. The receiver of the failed CAN message.

其中较优地,所述打包补发还包括由数据通道告知测试系统已完成CAN消息的补发。Preferably, the packaged reissue also includes informing the testing system by the data channel that reissue of the CAN message has been completed.

根据本发明实施例的第二方面,提供一种面向车机测试的自检装置,用于对测试设备和车机系统之间的CAN总线的通信进行检测,包括:According to a second aspect of the embodiments of the present invention, a self-checking device for vehicle-machine testing is provided, which is used to detect the communication of the CAN bus between the test equipment and the vehicle-machine system, including:

所述自检装置包括CAN收发模块和CAN自检监测模块;The self-checking device includes a CAN transceiver module and a CAN self-checking monitoring module;

所述CAN收发模块通过CAN总线与所述测试设备和所述车机系统连接;The CAN transceiver module is connected with the test equipment and the vehicle-machine system through the CAN bus;

所述CAN自检监测模块通过数据通道与所述测试设备和所述车机系统连接,并且通过CAN总线连接所述测试设备和所述车机系统。The CAN self-test monitoring module is connected with the test equipment and the vehicle-machine system through a data channel, and is connected with the test equipment and the vehicle-machine system through a CAN bus.

其中较优地,所述CAN自检监测模块通过数据服务器,利用所述数据通道与所述测试设备和所述车机系统连接,以获得来自所述测试设备和所述车机系统的数据帧。Preferably, the CAN self-inspection monitoring module is connected to the test equipment and the vehicle-machine system through a data server using the data channel to obtain data frames from the test equipment and the vehicle-machine system .

其中较优地,所述CAN自检监测模块从数据通道获取来自测试设备或车机系统中将要发送的包含CAN消息的数据帧,解码后获得所述CAN消息并且存储解码后CAN消息;Preferably, the CAN self-check monitoring module obtains the data frame containing the CAN message from the test equipment or the vehicle-machine system from the data channel, obtains the CAN message after decoding, and stores the decoded CAN message;

所述CAN收发模块从CAN总线实时获取待验证CAN消息,并且对所述待验证CAN消息进行存储;The CAN transceiver module obtains the CAN message to be verified in real time from the CAN bus, and stores the CAN message to be verified;

所述CAN自检监测模块比对所述待验证CAN消息和所述解码后CAN消息,进行仲裁,确认所述CAN消息是否通过所述CAN总线进行了正确发送,并记录失败次数;如果判断出发送在所述CAN总线上的CAN消息失败次数超过门限值,则将与失败次数对应的CAN消息通过所述CAN总线打包补发。The CAN self-check monitoring module compares the CAN message to be verified and the decoded CAN message, conducts arbitration, confirms whether the CAN message is correctly sent through the CAN bus, and records the number of failures; If the number of failures of the CAN message sent on the CAN bus exceeds the threshold value, the CAN message corresponding to the number of failures is packaged and reissued through the CAN bus.

其中较优地,所述CAN自检监测模块被配置为执行以下操作:Preferably, the CAN self-check monitoring module is configured to perform the following operations:

从所述CAN总线获得所述待验证CAN消息时,记录从所述CAN总线上接收的接收时间t2和接收内容c2;When obtaining the to-be-verified CAN message from the CAN bus, record the receiving time t2 and the received content c2 received from the CAN bus;

从所述数据通道接收到数据帧后,解析出CAN消息的预计的发送时间t1及发送内容c1;After receiving the data frame from the data channel, parse out the expected sending time t1 and sending content c1 of the CAN message;

根据所述接收时间t2,确定出与所述接收内容c2所对应的发送时间,然后再确定与所述接收内容c2所对应的解码后CAN消息;According to the receiving time t2, determine the sending time corresponding to the receiving content c2, and then determine the decoded CAN message corresponding to the receiving content c2;

将所述接收内容c2中的待验证CAN消息与所述接收内容c2所对应的解码后CAN消息进行比较,如果一致则判断为成功;如果不一致则判断为失败。Comparing the to-be-verified CAN message in the received content c2 with the decoded CAN message corresponding to the received content c2, if they are consistent, it is judged as success; if they are inconsistent, it is judged as failure.

其中较优地,所述打包补发是指将从所述测试设备或所述车机系统发送失败的所有CAN消息,封装到消息帧,以一个数据包的形式,通过所述CAN总线发送给所述发送失败的CAN消息的接收方。Preferably, the packaged reissue refers to encapsulating all CAN messages that fail to be sent from the test device or the vehicle-machine system into message frames, and in the form of a data packet, sent to the CAN bus through the CAN bus. The receiver of the failed CAN message.

与现有技术相比较,本发明所提供的面向车机测试的自检方法及自检装置具有以下技术效果:(1)快速高效地对CAN消息发送失败的原因进行定位,节约人力资源、时间成本和测试成本;(2)使测试系统持续正常工作,自动容灾,有效地提高了测试效率。Compared with the prior art, the self-inspection method and self-inspection device for vehicle and machine testing provided by the present invention have the following technical effects: (1) quickly and efficiently locate the cause of the failure of CAN message transmission, saving human resources and time cost and test cost; (2) make the test system continue to work normally, automatic disaster recovery, and effectively improve the test efficiency.

附图说明Description of drawings

图1A为本发明的一个实施例中,测试系统的整体结构示意图;1A is a schematic diagram of the overall structure of a testing system in an embodiment of the present invention;

图1B为本发明的一个实施例中,测试系统的连接关系示意图;1B is a schematic diagram of a connection relationship of a test system in an embodiment of the present invention;

图2为图1所示的实施例中,测试系统的硬件配置示意图;2 is a schematic diagram of the hardware configuration of the test system in the embodiment shown in FIG. 1;

图3为图1所示的实施例中,CAN自检监测模块的结构示意图;3 is a schematic structural diagram of a CAN self-check monitoring module in the embodiment shown in FIG. 1;

图4为本发明的一个实施例中,面向车机测试的自检方法流程图;4 is a flowchart of a self-checking method for vehicle-machine testing in an embodiment of the present invention;

图5为图4所示的实施例中,判断CAN总线中CAN消息是否符合预期的流程图;Fig. 5 is in the embodiment shown in Fig. 4, the flow chart of judging whether the CAN message in the CAN bus meets the expectation;

图6为图4所示的实施例中,自检方法的另一示例的部分流程图;FIG. 6 is a partial flowchart of another example of the self-checking method in the embodiment shown in FIG. 4;

图7为本发明的另一个实施例中,CAN自检监测模块的结构示意图;7 is a schematic structural diagram of a CAN self-check monitoring module in another embodiment of the present invention;

图8为本发明的另一个实施例中,面向车机测试的自检方法流程图。FIG. 8 is a flowchart of a self-checking method for vehicle-machine testing in another embodiment of the present invention.

具体实施方式Detailed ways

下面结合附图和具体实施例对本发明的技术内容进行详细具体的说明。The technical content of the present invention will be described in detail below with reference to the accompanying drawings and specific embodiments.

如图1A所示,典型的车机测试系统100包括测试设备1100、自检装置1200以及车机系统1300。其中,自检装置1200包括CAN收发模块1210和CAN自检监测模块1220。As shown in FIG. 1A , a typical vehicle-machine testing system 100 includes a test equipment 1100 , a self-checking device 1200 and a vehicle-machine system 1300 . The self-checking device 1200 includes a CAN transceiver module 1210 and a CAN self-checking monitoring module 1220 .

测试设备1100通过有线或无线通信方式与CAN收发模块1210连接。同时,测试设备1100与CAN自检监测模块1220通过通信网络1230连接。CAN收发模块1210通过CAN总线与测试设备1100和车机系统1300连接。并且,CAN自检监测模块1220通过数据通道连接车机系统1300,还通过CAN总线连接测试设备1100和车机系统1300。如图1B所示,CAN收发模块也可以被CAN模块代替,其作为测试系统的CAN接口,测试系统通过该CAN模块与车机系统之间在CAN总线上通信。CAN自检监测模块则通过USB连接线或网线与CAN模块通信,同时也通过CAN总线与车机系统及测试系统进行通信。The test equipment 1100 is connected to the CAN transceiver module 1210 through wired or wireless communication. At the same time, the test equipment 1100 is connected with the CAN self-test monitoring module 1220 through the communication network 1230 . The CAN transceiver module 1210 is connected to the test equipment 1100 and the vehicle-machine system 1300 through the CAN bus. In addition, the CAN self-test monitoring module 1220 is connected to the vehicle-machine system 1300 through a data channel, and is also connected to the test equipment 1100 and the vehicle-machine system 1300 through a CAN bus. As shown in FIG. 1B , the CAN transceiver module can also be replaced by a CAN module, which serves as the CAN interface of the test system, and the test system communicates with the vehicle-machine system on the CAN bus through the CAN module. The CAN self-test monitoring module communicates with the CAN module through a USB cable or a network cable, and also communicates with the vehicle-machine system and the test system through the CAN bus.

本发明实施例中,测试设备1100是具有通信功能、业务处理功能的电子设备。如图2所示,测试设备1100包括处理器1210、存储器1220、接口装置1230、通信装置1240、显示装置1250、输入装置1260、扬声器1270、麦克风1280。其中,处理器1210包括中央处理器CPU、微处理器MCU等。存储器1220包括ROM(只读存储器)、RAM(随机存取存储器)、诸如硬盘的非易失性存储器等,用于存储控制处理器1210进行操作以执行本发明实施例提供的包含CAN消息的数据帧的指令。接口装置1230包括USB接口、耳机接口等。通信装置1240包括有线通信和无线通信。显示装置1250包括液晶显示屏、触摸显示屏等。输入装置1260包括触摸屏、键盘等。扬声器1270和麦克风1280用于输入/输出语音信息。In this embodiment of the present invention, the testing device 1100 is an electronic device having a communication function and a service processing function. As shown in FIG. 2 , the test equipment 1100 includes a processor 1210 , a memory 1220 , an interface device 1230 , a communication device 1240 , a display device 1250 , an input device 1260 , a speaker 1270 , and a microphone 1280 . The processor 1210 includes a central processing unit CPU, a microprocessor MCU, and the like. The memory 1220 includes a ROM (Read Only Memory), a RAM (Random Access Memory), a non-volatile memory such as a hard disk, etc., for storing data including CAN messages provided by the control processor 1210 to operate to execute the embodiments of the present invention frame command. The interface device 1230 includes a USB interface, an earphone interface, and the like. The communication device 1240 includes wired communication and wireless communication. The display device 1250 includes a liquid crystal display, a touch display, and the like. The input device 1260 includes a touch screen, a keyboard, and the like. The speaker 1270 and the microphone 1280 are used to input/output voice information.

如图3所示,即图1中CAN自检监测模块1220的结构框图。CAN自检监测模块1220包括数据帧获取模块7100、CAN消息获取模块7200、数据验证模块7300、CAN消息发送模块7400和数据帧发送模块7500。CAN自检监测模块1220的数据帧获取模块7100、数据验证模块7300和数据帧发送模块7500,通过数据通道与机车系统1300或测试设备1100进行通信;CAN自检监测模块1220的CAN消息获取模块7200和CAN消息发送模块7400通过CAN总线与机车系统1300或测试设备1100进行通信,因此实现两路独立的通信,从而可以通过CAN自检监测模块1220对CAN总线上的数据传送情况进行监测,并及时补发CAN消息。As shown in FIG. 3 , which is a structural block diagram of the CAN self-check monitoring module 1220 in FIG. 1 . The CAN self-check monitoring module 1220 includes a data frame acquisition module 7100 , a CAN message acquisition module 7200 , a data verification module 7300 , a CAN message transmission module 7400 and a data frame transmission module 7500 . The data frame acquisition module 7100 , the data verification module 7300 and the data frame transmission module 7500 of the CAN self-check monitoring module 1220 communicate with the locomotive system 1300 or the test equipment 1100 through the data channel; the CAN message acquisition module 7200 of the CAN self-check monitoring module 1220 The CAN message sending module 7400 communicates with the locomotive system 1300 or the test equipment 1100 through the CAN bus, so two independent communications are realized, so that the CAN self-check monitoring module 1220 can monitor the data transmission on the CAN bus, and timely Reissue CAN messages.

数据帧获取模块7100用于从数据通信获取待验证的数据帧,该数据帧包含在CAN总线上即将传输的CAN消息中。CAN消息获取模块7200用于从CAN总线获取与所述数据帧对应的CAN消息。数据验证模块7300用于验证从CAN总线接收的CAN消息与从数据通信获得的数据帧中携带的CAN消息的一致性,即对针对所述CAN消息帧发送的正确性进行验证。The data frame obtaining module 7100 is used for obtaining the data frame to be verified from the data communication, and the data frame is included in the CAN message to be transmitted on the CAN bus. The CAN message obtaining module 7200 is configured to obtain the CAN message corresponding to the data frame from the CAN bus. The data verification module 7300 is used to verify the consistency of the CAN message received from the CAN bus and the CAN message carried in the data frame obtained from data communication, that is, to verify the correctness of sending the CAN message frame.

当数据验证模块7300验证出CAN总线上没能连续成功发送的CAN消息帧的数目超过预设的阈值时,利用由数据帧获取模块7100接收到的数据帧,将其转换成对应的CAN消息帧(即,未发出的消息帧),并由CAN消息发送模块7400打包发送给机车系统1300(或者测试设备1100)。数据帧发送模块7500用于发送验证的测试结果给测试设备1100(或者机车系统1300)。When the data verification module 7300 verifies that the number of CAN message frames that cannot be successfully sent continuously on the CAN bus exceeds the preset threshold, the data frame received by the data frame acquisition module 7100 is used to convert it into a corresponding CAN message frame (ie, unsent message frames), and are packaged and sent to the locomotive system 1300 (or the test equipment 1100) by the CAN message sending module 7400. The data frame sending module 7500 is used for sending the verified test result to the test equipment 1100 (or the locomotive system 1300).

如图4所示,本发明还提供一种面向车机测试的自检方法,具体包括以下步骤:As shown in FIG. 4 , the present invention also provides a self-inspection method for vehicle-machine testing, which specifically includes the following steps:

S4100:通过数据帧获取模块7100从数据通道获取来自测试设备或车机系统中将要发送的包含CAN消息的数据帧(该数据帧中携带有CAN消息),解码后获得CAN消息并且将该CAN消息进行存储。S4100: Obtain a data frame containing a CAN message (the data frame carries a CAN message) to be sent from the test equipment or the vehicle-machine system from the data channel through the data frame obtaining module 7100, decode the CAN message and obtain the CAN message. to store.

数据帧一般包括帧头、数据部分和帧尾,其中,帧头和帧尾包含一些必要的控制信息,例如同步信息、差错控制信息等,数据部分则包含实际待传输的CAN消息,例如车辆行驶速度,车内温度,车窗车门开关情况等。The data frame generally includes a frame header, a data part and a frame trailer. The frame header and frame trailer contain some necessary control information, such as synchronization information, error control information, etc., and the data part contains the actual CAN messages to be transmitted, such as vehicle driving. Speed, interior temperature, window and door opening and closing conditions, etc.

在具体实施时,数据帧可以在软件测试过程中由用户控制将终端设备与应用服务器通信时,终端设备生成的日志文件中产生的数据帧发送至实施该方法的数据验证服务器,并由该数据验证服务器根据该数据帧验证其编码处理是否正确。另外,数据帧也可以由用户直接将用于进行编码处理的应用程序部署在数据验证服务器上,由数据验证服务器在该应用程序与应用服务器通信的过程中,自动获取该数据帧,并与CAN自检监测模块1220或测试设备1100进行信息比对,其详细处理过程此处不再赘述。In specific implementation, the data frame can be controlled by the user to communicate with the application server during the software testing process, the data frame generated in the log file generated by the terminal device is sent to the data verification server implementing the method, and the data The validation server verifies that its encoding process is correct based on the data frame. In addition, the data frame can also be directly deployed by the user on the data verification server for encoding processing, and the data verification server automatically acquires the data frame during the communication between the application and the application server, and communicates with the CAN The self-checking monitoring module 1220 or the testing equipment 1100 performs information comparison, and the detailed processing process thereof will not be repeated here.

通过数据帧获取模块7100从数据通道获取来自测试设备1100或车机系统1300中将要发送的包含CAN消息的数据帧(该数据帧中携带有CAN消息),解码后获得CAN消息并且将其作为解码后CAN消息进行存储。Through the data frame acquisition module 7100, the data frame containing the CAN message to be sent from the test equipment 1100 or the vehicle-machine system 1300 is obtained from the data channel (the data frame carries the CAN message), and the CAN message is obtained after decoding and used as the decoding After CAN messages are stored.

S4200:通过CAN消息获取模块7200从CAN总线实时获取待验证的CAN消息,并且将实时检测到的CAN消息进行存储。S4200: Obtain the CAN message to be verified from the CAN bus in real time through the CAN message obtaining module 7200, and store the CAN message detected in real time.

CAN消息获取模块7200,从CAN总线实时获取的CAN总线上的待验证的CAN消息,并将其作为待验证CAN消息进行存储。The CAN message acquisition module 7200 acquires the CAN message to be verified on the CAN bus in real time from the CAN bus, and stores it as the CAN message to be verified.

S4300:通过数据验证模块7300比对待验证CAN消息和解码后CAN消息,进行仲裁,确认CAN消息是否通过CAN总线进行了正确发送,并记录失败次数。S4300: The data verification module 7300 compares the CAN message to be verified and the decoded CAN message, performs arbitration, confirms whether the CAN message is correctly sent through the CAN bus, and records the number of failures.

待验证CAN消息来自CAN总线,因此需要判断待验证CAN消息(来自测试设备1100或车机系统1300)发送是否符合预期,即可分析出测试系统是否正确地发送(接收)了测试消息。The CAN message to be verified comes from the CAN bus, so it is necessary to judge whether the CAN message to be verified (from the test equipment 1100 or the vehicle system 1300 ) is sent as expected, and then it can be analyzed whether the test system sends (receives) the test message correctly.

如图5所示,从数据通道接收到数据帧后,解析出CAN消息的预计发送时间t1及发送内容(即解码后CAN消息)c1。由于数据通道是通过单片机从测试设备1100直接获得数据,不是从CAN总线获得,因此从数据通道获得的数据帧的准确性是可靠的,可以用作仲裁的基准。As shown in FIG. 5 , after the data frame is received from the data channel, the expected sending time t1 of the CAN message and the sending content (ie, the decoded CAN message) c1 are parsed. Since the data channel obtains data directly from the test equipment 1100 through the microcontroller, not from the CAN bus, the accuracy of the data frame obtained from the data channel is reliable and can be used as a benchmark for arbitration.

从CAN总线获得的待验证CAN消息,并已记录从CAN总线上接收的接收时间t2和接收的内容(即待验证CAN消息)c2。The CAN message to be verified is obtained from the CAN bus, and the reception time t2 and the received content (ie the CAN message to be verified) c2 received from the CAN bus have been recorded.

首先根据待验证CAN消息的接收时间t2与实时获得的数据帧的发送时间进行比对,以接收时间t2相关的t2-1s至t2+1s的区间去查找数据帧进行比对,确定出该待验证CAN消息所对应的发送时间t1,从而进一步根据发送时间t1确定对应的解码后CAN消息。也可以较优的,通过用户设定的一个时间范围值(t2-Δt,t2+Δt),在该时间范围内查找与待验证CAN消息对应的数据帧,并将该数据帧与待验证CAN消息进行比对。Firstly, according to the receiving time t2 of the CAN message to be verified and the sending time of the data frame obtained in real time, compare the data frame with the interval from t2-1s to t2+1s related to the receiving time t2 to find the data frame for comparison, and determine the waiting time. The sending time t1 corresponding to the CAN message is verified, so as to further determine the corresponding decoded CAN message according to the sending time t1. It is also preferable to search for the data frame corresponding to the CAN message to be verified within this time range through a time range value (t2-Δt, t2+Δt) set by the user, and compare the data frame with the CAN message to be verified. messages are compared.

由此实现将时间对应的待验证CAN消息(来自CAN总线)与解码后CAN消息(来自数据通道)进行比较。在此,将检测CAN消息的错误码定义如下:In this way, the time-corresponding CAN message to be verified (from the CAN bus) is compared with the decoded CAN message (from the data channel). Here, the error codes for detecting CAN messages are defined as follows:

0001:车机系统侧发送消息丢失0001: The message sent by the vehicle system side is lost

0002:测试装置侧发送消息丢失0002: The message sent by the test device side is lost

0003:延迟超出预置的阈值0003: Delay exceeds preset threshold

0004:协议帧解析失败,误码告警。0004: The protocol frame parsing failed, and an error alarm occurred.

如果数据验证模块7300判断出:在发送时间t1发出数据帧,但是与发送时间t1对应的接收时间t2的时间范围内没有接收到来自CAN总线的待验证CAN消息,那么就判断为失败原因为0001或0002。将会在网络页面显示验证结果为0001(如果在t1时间是车机系统1300发送CAN消息)或0002(如果在t1时间是测试设备1100发送CAN消息)。If the data verification module 7300 determines that the data frame is sent at the sending time t1, but the CAN message to be verified from the CAN bus is not received within the time range of the receiving time t2 corresponding to the sending time t1, then it is determined that the failure reason is 0001 or 0002. The verification result will be displayed on the web page as 0001 (if the vehicle-machine system 1300 sends a CAN message at time t1) or 0002 (if the test device 1100 sends a CAN message at time t1).

如果在与发送时间t1对应的接收时间t2接收到来自CAN总线的待验证CAN消息,那么进行下一步骤:验证消息帧内容是否一致。If the CAN message to be verified from the CAN bus is received at the receiving time t2 corresponding to the sending time t1, the next step is performed: verifying whether the content of the message frame is consistent.

如果CAN总线接收成功,数据验证模块7300则会验证消息帧内容是否一致。如果发送内容c1和接收内容c2不一致,即待验证CAN消息与解码后CAN消息不同,可判断出该失败的原因可能为延迟(t2-t1)超出预设的阈值(根据CAN总线为高速或低速来进行设定阈值)或协议帧解析失败导致误码告警,验证结果将会在网络页面显示0003或0004。如判断出该失败的原因可能为延迟(t2-t1)超出预设的阈值(根据CAN总线为高速或低速来进行设定阈值),则验证结果会在网络页面显示为0003;如果是协议帧解析失败而导致误码告警,则验证结果将会在网络页面显示为0004。If the CAN bus is successfully received, the data verification module 7300 will verify whether the content of the message frame is consistent. If the sent content c1 and the received content c2 are inconsistent, that is, the CAN message to be verified is different from the decoded CAN message, it can be judged that the reason for the failure may be that the delay (t2-t1) exceeds the preset threshold (depending on whether the CAN bus is high-speed or low-speed to set the threshold) or the failure to parse the protocol frame results in a bit error alarm, and the verification result will display 0003 or 0004 on the web page. If it is determined that the reason for the failure may be that the delay (t2-t1) exceeds the preset threshold (the threshold is set according to whether the CAN bus is high-speed or low-speed), the verification result will be displayed as 0003 on the network page; if it is a protocol frame If the parsing fails and a bit error alarm occurs, the verification result will be displayed as 0004 on the web page.

如果发送内容c1和接收内容c2一致,则表示记录CAN总线接收成功。If the sent content c1 is consistent with the received content c2, it means that the CAN bus is successfully received.

S4400:将验证结果提供至访问自身的网络页面进行展示。S4400: Provide the verification result to the web page of the access self for display.

如图6所示,本发明所提供的自检方法的另一实施例,在前述步骤的基础上还包括以下步骤:As shown in FIG. 6 , another embodiment of the self-checking method provided by the present invention further includes the following steps on the basis of the foregoing steps:

S5100:判断出测试设备CAN收发模块发送在CAN总线上的CAN消息连续失败的次数超过事先设定的门限值。S5100: It is judged that the number of consecutive failures of CAN messages sent by the CAN transceiver module of the test equipment on the CAN bus exceeds a preset threshold value.

在步骤S4300中已判断出并记录了CAN总线消息发送失败的失败次数。在步骤S5100中判断失败次数是否超过预定的门限值。如果失败次数已超过预定的门限值,则进入下一步;如果失败次数没有超过预定的门限值,则等待下一次判断。In step S4300, the number of failures of CAN bus message transmission failures has been determined and recorded. In step S5100, it is determined whether the number of failures exceeds a predetermined threshold value. If the number of failures has exceeded the predetermined threshold, proceed to the next step; if the number of failures does not exceed the predetermined threshold, wait for the next judgment.

此处失败原因不做区分,无论是CAN总线接收失败的次数超过门限值、发送内容c1和接收内容c2不一致的次数超过门限值以及两种情况失败的次数加起来超过门限值都会进入下一步。并且,前述失败的次数是连续失败的次数,即,如果有一次发送成功,则将失败次数清零。The reasons for failure are not distinguished here. Whether the number of CAN bus reception failures exceeds the threshold value, the number of times that the transmitted content c1 and the received content c2 are inconsistent exceeds the threshold value, and the sum of the number of failures in both cases exceeds the threshold value, the entry will be entered. Next step. In addition, the aforementioned number of failures is the number of consecutive failures, that is, if there is a successful transmission, the number of failures is cleared to zero.

S5200:监测模块启动应急模式,将失败次数对应的CAN消息打包补发。S5200: The monitoring module starts the emergency mode, and packages and reissues the CAN messages corresponding to the number of failures.

从测试设备1100或车机系统1300发送失败的CAN消息,通过CAN消息发送模块7400,以消息帧(携带有要发送的CAN消息)形式,打包发送至CAN总线,同时由数据通道告知测试系统已完成CAN消息的发送。The CAN message that fails to be sent from the test equipment 1100 or the vehicle system 1300 is packaged and sent to the CAN bus through the CAN message sending module 7400 in the form of a message frame (carrying the CAN message to be sent), and the test system is notified by the data channel. Complete the sending of the CAN message.

打包补发是指将从所述测试设备或所述车机系统发送失败的每个CAN消息,封装到消息帧,以一个数据包的形式,在判定失败后的设定时间内,通过所述CAN总线发送给所述发送失败的CAN消息的接收方Packing and re-issuing means that each CAN message that fails to be sent from the test equipment or the vehicle-machine system is encapsulated into a message frame, and in the form of a data packet, within the set time after the failure is judged, through the The CAN bus is sent to the receiver of the failed CAN message

由此,本发明通过设置CAN接收失败的门限值,该值代表了测试系统发送CAN消息连续失败次数,当比对发现测试系统发送CAN消息连续失败次数超过门限时,CAN自检监测模块将启动发送机制。从测试系统发送失败的CAN消息将从自检监测模块发送至CAN总线中,同时由数据通道告知测试系统,其已完成CAN消息的发送。Thus, the present invention sets the threshold value of CAN receiving failure, and this value represents the number of consecutive failures in sending CAN messages by the testing system. Start the sending mechanism. The CAN message that fails to be sent from the test system will be sent to the CAN bus from the self-test monitoring module, and the test system will be informed by the data channel that it has completed the sending of the CAN message.

S5300:将容灾处理结果提供至访问自身的网络页面进行展示。S5300: Provide the disaster recovery processing result to the web page of the access self for display.

图7为本发明的另一个实施例中,CAN自检监测模块的结构示意图。其中,CAN自检监测模块构成CAN总线协议的一个节点,包括CAN控制器和CAN收发器。CAN控制器包括单片机(例如独立CAN通信控制器MCP2515,也可以是Arduino或者其他单片机),本发明实施例中采用树莓派系统。由于树莓派本身并不支持CAN总线,因此使用SP I接口的CAN控制器,搭配一个收发器完成CAN功能。这是本领域的公知技术,故在此不做详细描述。CAN自检监测模块中的CAN控制器与测试设备1100通过USB、有线或无线连接方式进行信息交互,并控制CAN收发器从CAN总线接收或发送CAN消息,从而与车机系统1300或测试设备1100通信。FIG. 7 is a schematic structural diagram of a CAN self-check monitoring module in another embodiment of the present invention. Among them, the CAN self-check monitoring module constitutes a node of the CAN bus protocol, including the CAN controller and the CAN transceiver. The CAN controller includes a single-chip microcomputer (for example, an independent CAN communication controller MCP2515, which may also be an Arduino or other single-chip computers), and a Raspberry Pi system is used in the embodiment of the present invention. Since the Raspberry Pi itself does not support the CAN bus, the CAN controller with the SP I interface is used with a transceiver to complete the CAN function. This is a well-known technology in the art, so it will not be described in detail here. The CAN controller in the CAN self-check monitoring module exchanges information with the test equipment 1100 through USB, wired or wireless connection, and controls the CAN transceiver to receive or send CAN messages from the CAN bus, so as to communicate with the vehicle system 1300 or the test equipment 1100 communication.

如图8所示,测试系统1在CAN总线上发送测试指令,CAN自检监测模块1220通过CAN总线接口监测到测试指令或CAN消息,并传递给控制器(例如树莓派);同时,测试系统1通过数据通道(例如网线或USB线),以数据帧(即将CAN消息作为数据帧的数据部分)的形式,发送给控制器(树莓派)测试系统1在CAN总线上发送的CAN消息(测试指令)。控制器(树莓派)通过WebSocket接口或者USB传输线接收到该条信息。控制器判断由测试系统发送出来的CAN消息是否符合预置的指令,并将比对结果反馈给测试系统。As shown in FIG. 8 , the test system 1 sends a test command on the CAN bus, and the CAN self-check monitoring module 1220 monitors the test command or CAN message through the CAN bus interface, and transmits it to the controller (for example, Raspberry Pi); at the same time, the test System 1 sends the CAN message sent by system 1 on the CAN bus in the form of a data frame (that is, taking the CAN message as the data part of the data frame) through a data channel (such as a network cable or a USB cable) to the controller (Raspberry Pi). (test command). The controller (Raspberry Pi) receives this information through the WebSocket interface or the USB transmission line. The controller judges whether the CAN message sent by the test system conforms to the preset instruction, and feeds back the comparison result to the test system.

如果测试系统连续发生CAN消息的次数超出了预置,CAN自检监测模块可发送预置的CAN消息至CAN总线,完成容灾。If the number of consecutive CAN messages in the test system exceeds the preset number, the CAN self-check monitoring module can send preset CAN messages to the CAN bus to complete disaster recovery.

本发明实施例中的数据验证是由控制器(树莓派)实现。即,控制器实现数据帧获取、数据验证和数据帧发送。同时,利用CAN控制器和CAN收发器配合实现从CAN总线上收发CAN消息。The data verification in the embodiment of the present invention is implemented by a controller (Raspberry Pi). That is, the controller implements data frame acquisition, data verification, and data frame transmission. At the same time, the CAN controller and the CAN transceiver are used to cooperate to realize sending and receiving CAN messages from the CAN bus.

可在测试用例开始之前(但不限于此),测试系统向车机发送一条测试指令,同时测试系统通过USB通信或者网络通信(数据通信是一种方式,但不限于此)告知CAN自检监测模块,CAN总线发送过来的数据以备比对使用。Before the test case starts (but not limited to this), the test system sends a test command to the vehicle, and the test system informs the CAN self-test monitoring through USB communication or network communication (data communication is one way, but not limited to this). module, the data sent by the CAN bus is used for comparison.

CAN自检监测模块通过对比来自CAN总线监测到的数据和来自数据通信的CAN发送比对数据,如果比对成功,判断该次通信测试系统发送成功。如果比对失败,对进行测试系统发送失败的计数,存放在CAN自检监测模块的数据库中,同时将该次失败发送回测试系统。The CAN self-inspection monitoring module compares the data monitored from the CAN bus with the CAN sent comparison data from the data communication. If the comparison is successful, it is judged that the communication test system is sent successfully. If the comparison fails, the count of the failure to be sent by the test system is stored in the database of the CAN self-check monitoring module, and the failure is sent back to the test system at the same time.

综上所述,本发明所提供的面向车机测试的自检方法及自检装置具有以下技术效果:(1)快速高效地对CAN消息发送失败的原因进行定位,节约人力资源、时间成本和测试成本;(2)使测试系统持续正常工作,自动容灾,有效地提高了测试效率。To sum up, the self-checking method and self-checking device for vehicle-machine testing provided by the present invention have the following technical effects: (1) quickly and efficiently locate the cause of CAN message sending failure, saving human resources, time cost and Test cost; (2) Make the test system continue to work normally, automatic disaster recovery, and effectively improve the test efficiency.

上面对本发明所提供的面向车机测试的自检方法及自检装置进行了详细的说明。对本领域的一般技术人员而言,在不背离本发明实质内容的前提下对它所做的任何显而易见的改动,都将构成对本发明专利权的侵犯,将承担相应的法律责任。The self-inspection method and self-inspection device for vehicle-machine testing provided by the present invention have been described in detail above. For those of ordinary skill in the art, any obvious changes made to the present invention without departing from the essential content of the present invention will constitute an infringement of the patent right of the present invention, and will bear corresponding legal responsibilities.

Claims (10)

1.一种面向车机测试的自检方法,用于对测试设备和车机系统之间的CAN总线的通信进行检测,其特征在于包括以下步骤:1. a self-inspection method oriented to vehicle-machine testing, for detecting the communication of the CAN bus between test equipment and vehicle-machine system, it is characterized in that comprising the following steps: 从数据通道获取来自测试设备或车机系统中将要发送的包含CAN消息的数据帧,解码后获得所述CAN消息并且存储解码后CAN消息;Obtain the data frame containing the CAN message to be sent from the test equipment or the vehicle-machine system from the data channel, obtain the CAN message after decoding, and store the decoded CAN message; 从CAN总线实时获取待验证CAN消息,并且对所述待验证CAN消息进行存储;Obtain the CAN message to be verified in real time from the CAN bus, and store the CAN message to be verified; 比对所述待验证CAN消息和所述解码后CAN消息,进行仲裁,确认所述CAN消息是否通过所述CAN总线进行了正确发送,并记录失败次数;Compare the CAN message to be verified and the decoded CAN message, conduct arbitration, confirm whether the CAN message is correctly sent through the CAN bus, and record the number of failures; 如果判断出发送在所述CAN总线上的CAN消息失败次数超过门限值,则将与失败次数对应的CAN消息通过所述CAN总线打包补发。If it is determined that the number of failures of the CAN message sent on the CAN bus exceeds the threshold value, the CAN message corresponding to the number of failures is packaged and reissued through the CAN bus. 2.如权利要求1所述的自检方法,其特征在于,2. The self-checking method according to claim 1, characterized in that, 比对所述待验证CAN消息和所述解码后CAN消息,进行仲裁,确认所述CAN消息是否通过所述CAN总线进行了正确发送,包括以下子步骤:Compare the CAN message to be verified and the decoded CAN message, conduct arbitration, and confirm whether the CAN message is correctly sent through the CAN bus, including the following sub-steps: 从所述CAN总线获得所述待验证CAN消息时,记录从所述CAN总线上接收的接收时间t2和接收内容c2;When obtaining the to-be-verified CAN message from the CAN bus, record the receiving time t2 and the received content c2 received from the CAN bus; 从所述数据通道接收到数据帧后,解析出CAN消息的预计的发送时间t1及发送内容c1;After receiving the data frame from the data channel, parse out the expected sending time t1 and sending content c1 of the CAN message; 根据所述接收时间t2,确定出与所述接收内容c2所对应的发送时间,然后再确定与所述接收内容c2所对应的解码后CAN消息;According to the receiving time t2, determine the sending time corresponding to the receiving content c2, and then determine the decoded CAN message corresponding to the receiving content c2; 将所述接收内容c2中的待验证CAN消息与所述接收内容c2所对应的解码后CAN消息进行比较,如果一致则判断为成功;如果不一致则判断为失败。Comparing the to-be-verified CAN message in the received content c2 with the decoded CAN message corresponding to the received content c2, if they are consistent, it is judged as success; if they are inconsistent, it is judged as failure. 3.如权利要求2所述的自检方法,其特征在于:3. self-checking method as claimed in claim 2, is characterized in that: 所述失败次数是指连续失败的次数,如果有一次发送成功,则将失败次数清零。The number of failures refers to the number of consecutive failures. If there is one successful transmission, the number of failures is cleared to zero. 4.如权利要求1所述的自检方法,其特征在于:4. self-checking method as claimed in claim 1, is characterized in that: 所述打包补发是指将从所述测试设备或所述车机系统发送失败的每个CAN消息,封装到消息帧,以一个数据包的形式,在判定失败后的设定时间内,通过所述CAN总线发送给所述发送失败的CAN消息的接收方。The packaged and reissued means that each CAN message that fails to be sent from the test equipment or the vehicle-machine system is encapsulated into a message frame. The CAN bus is sent to the receiver of the failed CAN message. 5.如权利要求4所述的自检方法,其特征在于:5. self-checking method as claimed in claim 4, is characterized in that: 所述打包补发还包括由数据通道告知测试系统已完成CAN消息的补发。The packaged reissue also includes informing the testing system through the data channel that the reissue of the CAN message has been completed. 6.一种面向车机测试的自检装置,用于对测试设备和车机系统之间的CAN总线的通信进行检测,其特征在于包括:6. A self-checking device for vehicle-machine testing, for detecting the communication of the CAN bus between the test equipment and the vehicle-machine system, it is characterized in that comprising: 所述自检装置包括CAN收发模块和CAN自检监测模块;The self-checking device includes a CAN transceiver module and a CAN self-checking monitoring module; 所述CAN收发模块通过CAN总线与所述测试设备和所述车机系统连接;The CAN transceiver module is connected with the test equipment and the vehicle-machine system through the CAN bus; 所述CAN自检监测模块通过数据通道与所述测试设备和所述车机系统连接,并且通过CAN总线连接所述测试设备和所述车机系统。The CAN self-test monitoring module is connected with the test equipment and the vehicle-machine system through a data channel, and is connected with the test equipment and the vehicle-machine system through a CAN bus. 7.如权利要求6所述的自检装置,其特征在于:7. The self-checking device of claim 6, wherein: 所述CAN自检监测模块通过数据服务器,利用所述数据通道与所述测试设备和所述车机系统连接,以获得来自所述测试设备和所述车机系统的数据帧。The CAN self-inspection monitoring module is connected with the test equipment and the vehicle-machine system through the data server and the data channel, so as to obtain data frames from the test equipment and the vehicle-machine system. 8.如权利要求6所述的自检装置,其特征在于:8. The self-checking device of claim 6, wherein: 所述CAN自检监测模块从数据通道获取来自测试设备或车机系统中将要发送的包含CAN消息的数据帧,解码后获得所述CAN消息并且存储解码后CAN消息;The CAN self-check monitoring module obtains the data frame containing the CAN message from the test equipment or the vehicle-machine system from the data channel, obtains the CAN message after decoding, and stores the decoded CAN message; 所述CAN收发模块从CAN总线实时获取待验证CAN消息,并且对所述待验证CAN消息进行存储;The CAN transceiver module obtains the CAN message to be verified in real time from the CAN bus, and stores the CAN message to be verified; 所述CAN自检监测模块比对所述待验证CAN消息和所述解码后CAN消息,进行仲裁,确认所述CAN消息是否通过所述CAN总线进行了正确发送,并记录失败次数;如果判断出发送在所述CAN总线上的CAN消息失败次数超过门限值,则将与失败次数对应的CAN消息通过所述CAN总线打包补发。The CAN self-check monitoring module compares the CAN message to be verified and the decoded CAN message, conducts arbitration, confirms whether the CAN message is correctly sent through the CAN bus, and records the number of failures; If the number of failures of the CAN message sent on the CAN bus exceeds the threshold value, the CAN message corresponding to the number of failures is packaged and reissued through the CAN bus. 9.如权利要求8所述的自检装置,其特征在于:9. The self-checking device of claim 8, wherein: 所述CAN自检监测模块被配置为执行以下操作:The CAN self-test monitoring module is configured to perform the following operations: 从所述CAN总线获得所述待验证CAN消息时,记录从所述CAN总线上接收的接收时间t2和接收内容c2;When obtaining the to-be-verified CAN message from the CAN bus, record the receiving time t2 and the received content c2 received from the CAN bus; 从所述数据通道接收到数据帧后,解析出CAN消息的预计的发送时间t1及发送内容c1;After receiving the data frame from the data channel, parse out the expected sending time t1 and sending content c1 of the CAN message; 根据所述接收时间t2,确定出与所述接收内容c2所对应的发送时间,然后再确定与所述接收内容c2所对应的解码后CAN消息;According to the receiving time t2, determine the sending time corresponding to the receiving content c2, and then determine the decoded CAN message corresponding to the receiving content c2; 将所述接收内容c2中的待验证CAN消息与所述接收内容c2所对应的解码后CAN消息进行比较,如果一致则判断为成功;如果不一致则判断为失败。Comparing the to-be-verified CAN message in the received content c2 with the decoded CAN message corresponding to the received content c2, if they are consistent, it is judged to be successful; if they are inconsistent, it is judged to be a failure. 10.如权利要求9所述的自检装置,其特征在于:10. The self-checking device according to claim 9, characterized in that: 所述打包补发是指将从所述测试设备或所述车机系统发送失败的所有CAN消息,封装到消息帧,以一个数据包的形式,通过所述CAN总线发送给所述发送失败的CAN消息的接收方。The packaged and reissued means that all CAN messages that have failed to be sent from the test equipment or the vehicle-machine system are encapsulated into message frames, and sent to the failed sender in the form of a data packet through the CAN bus. Receiver of CAN messages.
CN202210008135.7A 2022-01-05 2022-01-05 A self-checking method and self-checking device for vehicle-machine testing Pending CN114363229A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202210008135.7A CN114363229A (en) 2022-01-05 2022-01-05 A self-checking method and self-checking device for vehicle-machine testing
PCT/CN2022/143933 WO2023131073A1 (en) 2022-01-05 2022-12-30 Self-checking method and apparatus for head unit testing

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210008135.7A CN114363229A (en) 2022-01-05 2022-01-05 A self-checking method and self-checking device for vehicle-machine testing

Publications (1)

Publication Number Publication Date
CN114363229A true CN114363229A (en) 2022-04-15

Family

ID=81107684

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210008135.7A Pending CN114363229A (en) 2022-01-05 2022-01-05 A self-checking method and self-checking device for vehicle-machine testing

Country Status (2)

Country Link
CN (1) CN114363229A (en)
WO (1) WO2023131073A1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2023131073A1 (en) * 2022-01-05 2023-07-13 瞬联软件科技(北京)有限公司 Self-checking method and apparatus for head unit testing
WO2024230162A1 (en) * 2023-05-10 2024-11-14 北京经纬恒润科技股份有限公司 Test system and method for unmanned device controller

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN118714058B (en) * 2024-08-29 2025-01-10 山东云海国创云计算装备产业创新中心有限公司 Bus controller module verification method, system, program product, device and medium
CN119178281B (en) * 2024-10-25 2025-05-02 佛山市艾凯控股集团有限公司 A vehicle refrigerator control method and system based on CAN communication data

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006237832A (en) * 2005-02-23 2006-09-07 Toyota Motor Corp Communication node failure detection apparatus and method
CN106559286A (en) * 2016-11-15 2017-04-05 中国电子科技集团公司第四十研究所 A kind of error-code testing method and system based on CAN
CN107222362A (en) * 2017-05-26 2017-09-29 南京越博动力系统股份有限公司 A kind of vehicle CAN network automatic test platform and its optimization method
WO2017179817A1 (en) * 2016-04-14 2017-10-19 슈어소프트테크주식회사 Method for interface evaluation test between automotive electronic components
CN108803585A (en) * 2018-09-11 2018-11-13 安徽江淮汽车集团股份有限公司 A kind of test method and system of T-BOX controllers
CN110429990A (en) * 2019-07-08 2019-11-08 北京汽车股份有限公司 The EMC testing method and equipment of vehicle-mounted T-Box
CN112083710A (en) * 2020-09-04 2020-12-15 南京信息工程大学 Vehicle-mounted network CAN bus node monitoring system and method

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
AT504018A1 (en) * 2006-07-05 2008-02-15 Tttech Computertechnik Ag METHOD AND DEVICE FOR CONSTRUCTION OF A COMMUNICATION SYSTEM BASED ON CAN COMMUNICATION CONTROLLERS WITH INCREASED DATA TRANSMISSION
CN111104272B (en) * 2019-12-10 2023-04-18 北京振兴计量测试研究所 CAN bus controller testing method based on RX and TX
CN111880508A (en) * 2020-06-24 2020-11-03 东风电驱动系统有限公司 Automatic calibration and test method and device for T-box parameters
CN114363229A (en) * 2022-01-05 2022-04-15 瞬联软件科技(北京)有限公司 A self-checking method and self-checking device for vehicle-machine testing

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006237832A (en) * 2005-02-23 2006-09-07 Toyota Motor Corp Communication node failure detection apparatus and method
WO2017179817A1 (en) * 2016-04-14 2017-10-19 슈어소프트테크주식회사 Method for interface evaluation test between automotive electronic components
CN106559286A (en) * 2016-11-15 2017-04-05 中国电子科技集团公司第四十研究所 A kind of error-code testing method and system based on CAN
CN107222362A (en) * 2017-05-26 2017-09-29 南京越博动力系统股份有限公司 A kind of vehicle CAN network automatic test platform and its optimization method
CN108803585A (en) * 2018-09-11 2018-11-13 安徽江淮汽车集团股份有限公司 A kind of test method and system of T-BOX controllers
CN110429990A (en) * 2019-07-08 2019-11-08 北京汽车股份有限公司 The EMC testing method and equipment of vehicle-mounted T-Box
CN112083710A (en) * 2020-09-04 2020-12-15 南京信息工程大学 Vehicle-mounted network CAN bus node monitoring system and method

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2023131073A1 (en) * 2022-01-05 2023-07-13 瞬联软件科技(北京)有限公司 Self-checking method and apparatus for head unit testing
WO2024230162A1 (en) * 2023-05-10 2024-11-14 北京经纬恒润科技股份有限公司 Test system and method for unmanned device controller

Also Published As

Publication number Publication date
WO2023131073A1 (en) 2023-07-13

Similar Documents

Publication Publication Date Title
CN114363229A (en) A self-checking method and self-checking device for vehicle-machine testing
EP2696534B1 (en) Method and device for monitoring quick path interconnect link
CN110610092A (en) In-vehicle network system, gateway device, and abnormal detection method
US11880690B1 (en) Method, system and apparatus for monitoring bios booting process of server
CN112249088B (en) Method for mutual diagnosis and data synchronization of double-display system, double-display system and train
CN105183575A (en) Processor fault diagnosis method, device and system
WO2021134418A1 (en) Data checking method and apparatus
CN109032867A (en) A kind of method for diagnosing faults, device and equipment
JP7582446B2 (en) Protocol analyzer, protocol error detection program, and protocol error detection method
CN114124745A (en) Method and system for diagnosing MVB communication fault
WO2020259339A1 (en) Bus monitoring device and method, storage medium, and electronic device
KR20120126873A (en) System for Dynamic Analysis of Embedded Software of Vehicle using UDS
CN112395147B (en) Debugging device on SOC
CN115776690B (en) Test device, system and method for vehicle-mounted encryption network simulation test
CN116257268B (en) Device upgrading method, device, electronic device and storage medium
CN107391036A (en) The VPD information access method and system of a kind of storage
CN110191027A (en) A Communication Error Diagnosis Method Between CCU and MCU
CN114697236B (en) Communication monitoring method and device
JPS6072351A (en) How to monitor the operating status of a packet communication system
CN113626279B (en) I2C communication monitoring method, device, CPLD and medium
CN108648298B (en) Message processing method and device, storage medium and electronic equipment
US7500154B2 (en) Method and system for generating a console log
CN114257610B (en) A monitoring system and method for a vehicle networking terminal
CN115622918B (en) A network protocol transmission data monitoring method and system
CN116991651B (en) Error injection method, system on chip, computer equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
AD01 Patent right deemed abandoned
AD01 Patent right deemed abandoned

Effective date of abandoning: 20250704

点击 这是indexloc提供的php浏览器服务,不要输入任何密码和下载