Control method, device and system of vehicle safety test system, medium and program
By generating target testing programs and switching communication interfaces, the existing safety testing system cannot adapt to changes in communication protocols of different models is solved, efficient and low-cost safety testing is achieved, and the system's generalization rate and development efficiency are improved.
Patent Information
- Application Number
- CN202510035477.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-09
- Publication Date
- 2025-04-15
AI Technical Summary
The existing safety testing system cannot adapt to the changes in communication protocols of different models, resulting in a long transformation cycle and high cost, affecting the development progress of new models.
By obtaining the test requirements documents and communication protocol data files of the vehicle to be tested, a target test program is generated, and the communication interface between the information collection device and the vehicle to be tested is switched to realize safety testing of different vehicle models.
It improves the generalization rate of safety testing systems, simplifies the editing and execution of test programs, reduces the testing costs, and shortens the vehicle development cycle.
Smart Images

Figure CN119827876A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of vehicle testing technology, and in particular to a control method, device, system, medium and program of a vehicle safety testing system. Background Art
[0002] In recent years, electric vehicles have achieved a leap forward in industrialization and scale. As electric vehicles have high voltage and high current power circuits, their safety issues cannot be ignored, and it is necessary to further standardize the special testing items for electric vehicles. Electric vehicles produced in the assembly workshop must undergo a series of safety standard tests such as vehicle insulation, equipotential, AC and DC charging performance, etc.
[0003] The current safety test system only supports electric vehicles in the mass production stage or those that have been launched on the market. The test system supplier programs them according to the communication protocol of the vehicle to be tested. If the communication protocol of the vehicle to be tested changes, the test system will not be able to test normally and the test system needs to be modified.
[0004] However, during the research and development stage of electric vehicles, there are many newly developed models involved. Because the communication protocols and other related documents of different models are different, or the communication protocols and other related documents of the same model may change during the development process, the original safety test system can no longer be used. The test system supplier must rebuild the test system before it can continue to be used. The transformation cycle is long, which affects the development progress of new models. In addition, each transformation requires payment to the test system supplier, resulting in excessively high testing costs. Summary of the invention
[0005] In view of this, the present invention provides a control method, device, system, medium and program for a vehicle safety test system to solve the problem that the existing technology requires the original safety test system to be modified due to different communication protocols of different vehicle models, the modification cycle is long, it is easy to affect the vehicle development progress and the development cost is too high.
[0006] In a first aspect, the present invention provides a control method for a vehicle safety test system, the safety test system comprising a host computer and an information collection device, the method is applied to the host computer, the method comprising:
[0007] Obtain the test requirement document and communication protocol data file of the vehicle to be tested;
[0008] Generate target test program based on test requirement document and communication protocol data file;
[0009] Execute the target test program, switch the communication interface between the information collection device and the vehicle to be tested, and perform safety tests on the vehicle to be tested.
[0010] Beneficial effect: The control method of the vehicle safety test system provided by the present invention can conveniently and quickly edit the test program according to the test requirement document of the vehicle to be tested and the communication protocol data file, automatically generate and execute the target test program, thereby switching the communication interface between the information acquisition device and the vehicle to be tested, so that the safety test system can adapt to vehicles with different communication protocols, and perform safety tests on vehicles of different models, thereby improving the universality of the safety test system, improving the utilization efficiency, and reducing the use cost.
[0011] In an optional implementation, generating a target test program based on a test requirement document and a communication protocol data file includes:
[0012] Generate an information collection program for the information collection device according to the communication protocol data file;
[0013] Generate functional test control procedures for the vehicle to be tested based on the test requirement document;
[0014] Generate a target test program based on the information collection program and the functional test control program.
[0015] Beneficial effects: In the embodiment of the present invention, the host computer generates an information collection program according to the communication protocol data file, so as to switch the communication interface between the information collection device and the vehicle to be tested, thereby automatically collecting information from vehicles with different communication protocols, and generates a functional test control program according to the test requirement document, which is convenient for performing various automated tests on the vehicle to be tested. Finally, by encapsulating the information collection program and the functional test control program to obtain the target test program, the automated test of the vehicle is realized, which is conducive to improving the convenience of the safety test system.
[0016] In an optional implementation, generating an information collection program for the information collection device according to the communication protocol data file includes:
[0017] Parsing the data format file in the communication protocol data file to obtain a signal parsing function; wherein the data format file is used to characterize the data format corresponding to the communication protocol of the vehicle to be tested; the signal parsing function is used to map the information collection signal to the physical value of the information collection device to switch the communication interface between the information collection device and the vehicle to be tested;
[0018] Encapsulate the signal analysis function and generate an information collection program.
[0019] Beneficial effect: The present invention parses the data format file of the vehicle to be tested and generates an information acquisition program according to the obtained signal analysis function, so as to facilitate mapping the information acquisition signal to the physical value of the information acquisition device, realize switching of the communication interface between the information acquisition device and the vehicle to be tested, and thus automatically collect information from vehicles with different communication protocols.
[0020] In an optional implementation, based on the test requirement document, a functional test control program for the vehicle to be tested is generated, including:
[0021] Extract the text information of the requirements in the test requirement document, transform the text information of the requirements, and obtain the functional test requirements of the vehicle to be tested;
[0022] Determine at least one function call function corresponding to the functional test requirement, and determine a timing relationship between at least one function call function;
[0023] At least one function call function and the timing relationship are encapsulated to obtain a function test control program for the vehicle to be tested.
[0024] Beneficial effect: The present invention obtains the functional test requirements of the vehicle to be tested by extracting the requirement text information in the test requirement document, and then maps the functional test requirements to the function call function, and determines the function timing relationship to encapsulate the function call function to generate an executable functional test control program, which is convenient for performing various automated safety tests on the vehicle to be tested.
[0025] In an optional implementation, executing a target test program, switching a communication interface between an information collection device and a vehicle to be tested, and performing a safety test on the vehicle to be tested, includes:
[0026] Execute the information collection program in the target test program, and control the information collection device to connect to the target communication interface corresponding to the vehicle to be tested;
[0027] The safety test of the vehicle to be tested is carried out according to the functional test control program in the target test program, and the actual vehicle test data is collected by using the information collection device, and the safety test result of the vehicle to be tested is obtained according to the actual vehicle test data.
[0028] Beneficial effect: In the embodiment of the present invention, the communication interface between the information collection device and the vehicle to be tested is switched by executing the information collection program, which facilitates information collection according to the communication protocol type of the vehicle to be tested, and automatically performs various safety tests on the vehicle to be tested by executing the functional test control program. The safety test results are obtained by analyzing the actual vehicle test data fed back by the information collection device, thereby realizing automated safety testing of vehicles of different models and improving the universality and test efficiency of the test system.
[0029] In an optional implementation, the safety test system further includes a power supply device; and performing safety tests on the vehicle to be tested according to the functional test control program in the target test program, including:
[0030] Execute the functional test control program in the target test program, control the power supply device to connect to the charging interface of the vehicle to be tested in a corresponding manner, and perform a safety test on the vehicle to be tested; wherein the functional test control program includes at least one of the vehicle insulation test control program, the equipotential test control program, the fast charging test control program, and the slow charging test control program.
[0031] Beneficial effect: The present invention switches the power supply mode of the power supply device, thereby facilitating various tests such as vehicle insulation test, equipotential test, fast charging test and slow charging test on the vehicle to be tested, and through the execution of the functional test control program, the test process can be automated.
[0032] In an optional implementation, obtaining the safety test result of the vehicle to be tested according to the actual vehicle test data includes:
[0033] Generate safety test reports and obtain safety test results based on preset report templates and actual vehicle test data.
[0034] Beneficial effect: By generating a safety test report based on actual vehicle test data for developers to review, it is convenient for developers to maintain and modify the tested vehicle.
[0035] In an optional embodiment, the method further includes:
[0036] According to the communication protocol data file, the key file of the vehicle to be tested is obtained;
[0037] Based on the preset key verification function, the legitimacy of the key file is verified;
[0038] When it is detected that the key file has passed the legality verification, the step of generating a target test program based on the test requirement document and the communication protocol data file is executed.
[0039] Beneficial effect: The present invention verifies the legitimacy of the key file of the vehicle to be tested by means of a preset key verification function. When the key file is reasonable, a target test program is regenerated to protect the data security of the vehicle to be tested, prevent information leakage, and improve the legitimacy and security of the test process.
[0040] In a second aspect, the present invention provides a control device for a vehicle safety test system, the safety test system comprising a host computer and an information collection device, the control device is applied to the host computer, and the control device comprises:
[0041] An acquisition module is used to acquire the test requirement document and communication protocol data file of the vehicle to be tested;
[0042] A first processing module, used for generating a target test program based on a test requirement document and a communication protocol data file;
[0043] The second processing module is used to execute the target test program, switch the communication interface between the information collection device and the vehicle to be tested, and perform safety test on the vehicle to be tested.
[0044] In a third aspect, the present invention provides a vehicle safety test system, comprising: a host computer and an information collection device;
[0045] The host computer includes a memory and a processor, which are communicatively connected to each other. The memory stores computer instructions, and the processor executes the control method of the vehicle safety test system of the first aspect or any corresponding embodiment thereof by executing the computer instructions.
[0046] In some optional embodiments, the system further includes a power supply device, which is used to provide a DC power supply or an AC power supply to the system and the vehicle to be tested.
[0047] In a fourth aspect, the present invention provides a computer-readable storage medium having computer instructions stored thereon, the computer instructions being used to enable a computer to execute the control method for a vehicle safety testing system of the first aspect or any corresponding embodiment thereof.
[0048] In a fifth aspect, the present invention provides a computer program product, including computer instructions, which are used to enable a computer to execute the control method of a vehicle safety test system according to the first aspect or any corresponding embodiment thereof.
[0049] The beneficial effects of the present invention are:
[0050] The control method of the vehicle safety test system provided by the present invention can conveniently and quickly edit the test program according to the test requirement document of the vehicle to be tested and the communication protocol data file, automatically generate and execute the target test program, thereby switching the communication interface between the information acquisition device and the vehicle to be tested, so that the safety test system can adapt to vehicles with different communication protocols, and perform safety tests on vehicles of different models, thereby improving the universality of the safety test system, improving the use efficiency, and reducing the use cost. BRIEF DESCRIPTION OF THE DRAWINGS
[0051] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0052] Figure 1 is a structural block diagram of a vehicle safety test system according to an embodiment of the present invention;
[0053] Figure 2 is a structural block diagram of another vehicle safety test system according to an embodiment of the present invention;
[0054] Figure 3 is a schematic diagram of a connection structure of a vehicle safety test system according to an embodiment of the present invention;
[0055] Figure 4 is a flow chart of a control method of a vehicle safety test system according to an embodiment of the present invention;
[0056] Figure 5 is a flow chart of another control method of a vehicle safety test system according to an embodiment of the present invention;
[0057] Figure 6 is a flow chart of a vehicle safety testing method according to an embodiment of the present invention;
[0058] Figure 7 is a schematic diagram of a flow chart of automatically generating a test program according to an embodiment of the present invention;
[0059] Figure 8 is a structural block diagram of a control device of a vehicle safety test system according to an embodiment of the present invention;
[0060] Fig. 9 It is a schematic diagram of the hardware structure of the host computer of an embodiment of the present invention. DETAILED DESCRIPTION
[0061] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.
[0062] Since electric vehicles have high voltage and high current power circuits, their safety issues cannot be ignored. Relevant departments have issued a series of standards and regulations to further regulate special testing items for electric vehicles such as pure electric vehicles, plug-in hybrid vehicles, and extended-range electric vehicles. Electric vehicles produced in the final assembly workshop are required to undergo a series of safety tests such as vehicle insulation, equipotential, and AC and DC charging performance.
[0063] The current safety test system only supports electric vehicles in the mass production stage or already on the market. The test system supplier programs it according to the communication protocol of the vehicle to be tested. If the communication protocol of the vehicle to be tested changes, the test system will not be able to test normally and the test system needs to be modified. In the research and development stage of electric vehicles, there are many newly developed models involved. Different models have different communication protocols and other related documents, or the communication protocol and other related documents of the same model may change during the development process, resulting in the original safety test system being unable to continue to be used. The test system supplier needs to re-modify the test system before it can continue to be used. The modification cycle is long, which affects the development progress of new models, and each modification requires payment to the test system supplier, resulting in excessively high testing costs. Therefore, the existing safety test system is not suitable for the safety test needs of the research and development stage of electric vehicles.
[0064] In order to improve the application limitations of the existing electric vehicle safety test system and solve the problem that the safety test needs to be reprogrammed to configure different vehicle model information, the embodiment of the present invention provides a control scheme for a vehicle safety test system, and provides a safety test system for non-mass production electric vehicles, which can conveniently and quickly edit the test program and automatically generate the test program, so that the safety test system can adapt to vehicle models with different communication protocols, improve the universality of the test system, improve the use efficiency, and reduce the use cost. The present invention controls the safety test system of electric vehicles before the mass production stage, especially in the research and development stage.
[0065] According to an embodiment of the present invention, a vehicle safety test system is provided. Figure 1 As shown, the vehicle safety test system includes a host computer 101 and an information acquisition device 102, wherein the host computer 101 obtains a test requirement document and a communication protocol data file of the vehicle to be tested; generates a target test program based on the test requirement document and the communication protocol data file; executes the target test program, switches the communication interface between the information acquisition device 102 and the vehicle to be tested, and performs a safety test on the vehicle to be tested.
[0066] In some optional embodiments, such as Figure 2As shown, the vehicle safety test system includes two parts: a hardware system and a software system. The hardware system specifically includes a host computer 101, an information collection device 102, and a power supply device 103. The information collection device 102 includes a signal processing device and a collection terminal device. The power supply device 103 is used to provide a DC power supply or an AC power supply for the vehicle safety test system and the vehicle to be tested. Exemplarily, the hardware system can be integrated in the same mechanical structure box.
[0067] In some optional embodiments, such as Figure 3 As shown, the CAN acquisition interface of the acquisition end device realizes interactive communication with the vehicle through the OBD interface of the vehicle to collect the charging status data of the vehicle to be tested. For non-commercial vehicles, connection communication can be carried out according to custom pins, and the CAN acquisition interface has 125kpbs-8Mpbs CANFD signal acquisition capability. The acquisition end device has a wired interface, which is connected to the power supply device 103, and has a circuit protection function, which can realize anti-reverse connection protection and circuit isolation. The acquisition end device has an expansion interface module, which can collect other data and upgrade functions through the expansion module in the form of an interface card.
[0068] In some optional embodiments, see again Figure 3 The signal processing device has the functions of protocol definition, configuration and bidirectional conversion of WIFI, Bluetooth, RS232, USB, etc. The signal processing device can be connected to the host computer by wired or wireless means to transmit data and control signals in both directions. The signal processing device and the acquisition end device communicate at high speed in a wired manner to achieve signal transmission. The signal processing device can convert the type of signal collected by the acquisition end device, and perform protocol conversion according to a configurable and defined program, and then send the processed data to the host computer through a wired or wireless connection. In addition, the signal processing device can also perform reverse transmission according to the instructions issued by the host computer.
[0069] In some optional embodiments, see again Figure 3 The power supply device 103 can provide power for the vehicle safety test system and the vehicle to be tested, can provide a low-voltage DC power supply below 36V for the acquisition terminal device and the signal processing device, and provide a standard 220V or 380V low-voltage AC charging power supply and DC charging power supply for the vehicle to be tested. The charging power supply of the power supply device 103 has a power isolation function, and the low-voltage DC power supply has an energy storage and circuit protection function to prevent damage to the electrical device due to abnormal current or voltage.
[0070] In some optional embodiments, see again Figure 3 The host computer 101 provides a running environment for the host computer software and realizes human-computer interaction to improve user experience. The host computer 101 is connected to the power supply device 103 through a serial port to control the vehicle charging process.
[0071] In the embodiment of the present invention, see again Figure 2 The software system of the vehicle safety test system mainly includes the host computer software and the information collection terminal program in the information collection device 102. The host computer software runs independently in the host computer 101 to control the entire test system. The host computer software can establish a communication connection with the hardware system, obtain the test data collected by the information collection device 102 in the hardware system, and issue control instructions to control the charging process and data collection process of the vehicle to be tested.
[0072] The present invention is based on the hardware system and software system, and can realize the functions of whole vehicle insulation resistance detection, whole vehicle insulation monitoring function test, whole vehicle AC charging system detection, whole vehicle DC charging system detection, and potential detection of various high-voltage components of the whole vehicle in non-mass production, especially in the research and development stage.
[0073] For details about the specific working principle and workflow of the host computer 101, please refer to the description of the method embodiment below, which will not be repeated here.
[0074] The vehicle safety test system provided by the embodiment of the present invention realizes automatic recognition and detection of test requirement documents through a software system, then extracts the messages and signals that need to be detected from the data format file (Database for CAN, DBC) in the communication protocol data file of the vehicle to be tested, collects the power supply device and the vehicle energy CAN messages through the hardware system, verifies each other, controls the test process through the internal logic of the program, obtains the actual vehicle test data corresponding to the vehicle model to be tested, and then automatically outputs the actual vehicle test data to generate a test report and stores it in the database, thereby completing the vehicle safety test.
[0075] According to an embodiment of the present invention, a control method embodiment of a vehicle safety test system is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.
[0076] In this embodiment, a control method for a vehicle safety test system is provided, which can be used for example Figure 1 The host computer 101 shown is, for example, a computer, a tablet computer, etc. Figure 4 is a flow chart of a control method of a vehicle safety test system according to an embodiment of the present invention. Figure 4 As shown, the process includes the following steps:
[0077] Step S401, obtaining the test requirement document and communication protocol data file of the vehicle to be tested.
[0078] Specifically, the test requirement document includes a series of test requirements for the vehicle to be tested, such as the need to conduct vehicle insulation testing, equipotential testing, etc. The host computer software has the ability to extract document content and can extract test requirements from the test requirement document. The test requirement document may include but is not limited to Txt text documents, Word documents, Excel tables and other format files.
[0079] Specifically, the communication protocol data file includes the data format files of the vehicle to be tested, such as DBC files and key files. The host computer software can extract the signals required for the test and encrypt the access information according to the DBC files and key files of different models. Among them, the key file is a private format file generated by the test demander using encryption tools to encrypt the original key by numerical value and code encryption. After generation, it cannot be read in plain text, which can protect the information security of the vehicle and prevent key leakage.
[0080] Step S402: Generate a target test program based on the test requirement document and the communication protocol data file.
[0081] Specifically, the host computer has execution script functions and API call functions for all sub-level functions of the safety test system. The host computer generates the target test program and stores it in the database based on the test requirements extracted from the test requirement document and the signals and encrypted access information extracted from the DBC file and key file of the vehicle to be tested.
[0082] Step S403, executing the target test program, switching the communication interface between the information collection device and the vehicle to be tested, and performing a safety test on the vehicle to be tested.
[0083] Specifically, the host computer executes the target test program, controls the signal processing device to send a test request to the acquisition end device, switches the communication interface between the information acquisition device and the vehicle to be tested, and performs safety tests on the vehicle to be tested. The acquisition end device obtains the feedback of the actual vehicle test data, reversely converts it through the signal processing device and sends it to the host computer software. Finally, the host computer automatically generates a test report based on the actual vehicle test data and stores it in the database.
[0084] The control method of the vehicle safety test system provided by the present invention can conveniently and quickly edit the test program according to the test requirement document of the vehicle to be tested and the communication protocol data file, automatically generate and execute the target test program, thereby switching the communication interface between the information acquisition device and the vehicle to be tested, so that the safety test system can adapt to vehicles with different communication protocols, and perform safety tests on vehicles of different models, thereby improving the universality of the safety test system, improving the use efficiency, and reducing the use cost.
[0085] In this embodiment, a control method for a vehicle safety test system is provided, which can be used for example Figure 1The host computer 101 shown is, for example, a computer, a tablet computer, etc. Figure 5 is a flow chart of a control method of a vehicle safety test system according to an embodiment of the present invention. Figure 5 As shown, the process includes the following steps:
[0086] Step S501, obtain the test requirement document and communication protocol data file of the vehicle to be tested. For details, please refer to Figure 4 Step S401 of the illustrated embodiment will not be described in detail here.
[0087] Step S502: Generate a target test program based on the test requirement document and the communication protocol data file.
[0088] Specifically, the above step S502 includes:
[0089] Step S5021, generating an information collection program for the information collection device according to the communication protocol data file.
[0090] Specifically, firstly, the data format file in the communication protocol data file is parsed to obtain a signal parsing function, and then the signal parsing function is encapsulated to generate an information collection program.
[0091] In some optional implementations, a program written in Python, such as the cantools library, can be used to read DBC files, and the information in the DBC files can be easily loaded, parsed, and queried. After reading the DBC file, the signal information therein needs to be parsed, for example, the required signal can be found by the signal name or ID. Next, a signal parsing function needs to be created, which will receive the original message data and return the parsed physical value. Finally, the parsed signal value needs to be mapped to the physical value of the information acquisition device, for example, the parsed signal value (which may be a digital quantity or an analog quantity) is converted into a physical quantity that the information acquisition device can understand (such as temperature, pressure, speed, etc.).
[0092] It should be noted that data format files such as DBC files are used to characterize the data format corresponding to the communication protocol of the vehicle to be tested. DBC files are a standard file format for describing the Controller Area Network (CAN) communication protocol. They are usually used in automobiles and other embedded systems to facilitate communication between different devices. DBC files contain CAN communication signals, message IDs, data lengths, cycles and other information. This information is crucial for developers to develop, test, diagnose and analyze CAN communication protocols to ensure that communication between different electronic control units (ECUs) can be carried out accurately and reliably.
[0093] It should be noted that the signal analysis function is used to map the information collection signal to the physical value of the information collection device so as to switch the communication interface between the information collection device and the vehicle to be tested.
[0094] The present invention parses the data format file of the vehicle to be tested and generates an information collection program according to the obtained signal analysis function, so as to facilitate mapping the information collection signal to the physical value of the information collection device, realize the switching of the communication interface between the information collection device and the vehicle to be tested, and thus automatically collect information from vehicles with different communication protocols.
[0095] Step S5022: Generate a functional test control program for the vehicle to be tested based on the test requirement document.
[0096] Specifically, the requirement text information in the test requirement document is extracted, and the requirement text information is converted to obtain the functional test requirement of the vehicle to be tested. Then, at least one function call function corresponding to the functional test requirement is determined, and the timing relationship between at least one function call function is determined, and at least one function call function and the timing relationship are encapsulated to obtain a functional test control program for the vehicle to be tested.
[0097] In some optional implementations, a program written in, but not limited to, VBA / python language can be used to automatically extract textual requirement information from a test requirement document, convert the textual requirement information into specific executable functional test requirements, map the functional test requirements to an API call function, and encapsulate the function according to the timing relationship of the API call function to generate a functional test control program.
[0098] The present invention obtains the functional test requirements of the vehicle to be tested by extracting the requirement text information in the test requirement document, then maps the functional test requirements to the function call function, and determines the function timing relationship to encapsulate the function call function to generate an executable functional test control program, which is convenient for performing various automated safety tests on the vehicle to be tested.
[0099] Step S5023, generating a target test program based on the information collection program and the functional test control program.
[0100] In some optional implementations, before generating the target test program, a key file of the vehicle to be tested may be obtained according to the communication protocol data file. Then, based on a preset key verification function, the key file is verified for legitimacy. When it is detected that the key file passes the legitimacy verification, the step of generating the target test program based on the test requirement document and the communication protocol data file is executed.
[0101] Exemplarily, the legality and validity of the key file can be verified through but not limited to the automatic encryption algorithm and key verification function pre-written in C++. When the key file is reasonable, the target test program is regenerated to protect the data security of the vehicle under test, prevent information leakage, and improve the legality and security of the test process.
[0102] In the embodiment of the present invention, the host computer generates an information collection program according to the communication protocol data file, so as to switch the communication interface between the information collection device and the vehicle to be tested, thereby automatically collecting information from vehicles with different communication protocols, and generates a functional test control program according to the test requirement document, so as to facilitate various automated tests on the vehicle to be tested. Finally, by encapsulating the information collection program and the functional test control program to obtain the target test program, the automated test of the vehicle is realized, which is conducive to improving the convenience of the safety test system.
[0103] Step S503, executing the target test program, switching the communication interface between the information collection device and the vehicle to be tested, and performing a safety test on the vehicle to be tested.
[0104] Specifically, the above step S503 includes:
[0105] Step S5031, executing the information collection program in the target test program, and controlling the information collection device to connect to the target communication interface corresponding to the vehicle to be tested.
[0106] Specifically, the information collection program controls the information collection device to switch the communication interface according to the communication protocol corresponding to the vehicle to be tested, so that information can be collected from vehicles with different communication protocols.
[0107] In some optional implementations, the information collection terminal program running in the collection terminal device and the signal processing device, that is, the information collection program, can also be used to: detect whether the operating status of the power supply chip inside the collection terminal device is normal; detect whether the internal temperature of the collection terminal device is normal; configure the pin definition of the communication interface with the vehicle to be tested, and support two modes: automatic detection pin definition and user customization; support configuration of the functions of the signal processing device, including signal forwarding mode, signal shielding, signal screening, signal sending, signal interface, signal customization, signal conversion processing, firmware upgrade, etc.
[0108] Step S5032, performing safety test on the vehicle to be tested according to the functional test control program in the target test program, and using the information collection device to collect actual vehicle test data, and obtaining the safety test result of the vehicle to be tested based on the actual vehicle test data.
[0109] Specifically, the safety test system also includes a power supply device, which executes a functional test control program in the target test program, controls the power supply device to connect to the charging interface of the vehicle to be tested in a corresponding manner, and performs a safety test on the vehicle to be tested; wherein the functional test control program includes at least one of a whole vehicle insulation test control program, an equipotential test control program, a fast charging test control program, and a slow charging test control program.
[0110] The present invention switches the power supply mode of the power supply device, thereby facilitating various tests such as vehicle insulation test, equipotential test, fast charging test and slow charging test on the vehicle to be tested, and can realize automatic operation of the test process through the execution of the functional test control program.
[0111] In some optional implementations, a safety test report may be generated based on a preset report template and actual vehicle test data to obtain safety test results for developers to review, thereby facilitating developers to maintain and modify the vehicle under test.
[0112] In the embodiment of the present invention, the communication interface between the information collection device and the vehicle to be tested is switched by executing the information collection program, which facilitates information collection according to the communication protocol type of the vehicle to be tested, and various safety tests are automatically performed on the vehicle to be tested by executing the functional test control program. The actual vehicle test data fed back by the information collection device is analyzed to obtain the safety test results, thereby realizing automated safety testing of vehicles of different models and improving the universality and test efficiency of the test system.
[0113] The control method of the vehicle safety test system provided in this embodiment is aimed at non-mass-produced electric vehicles. It can automatically generate target test programs and safety test reports according to the signals, encrypted access information and test requirements of different vehicle models. There is no need to manually write test programs and compile test reports. The entire test process is fully automated, which improves the commonality of the test system, solves the problems of long cycle and high cost caused by developing a set of test programs for each vehicle model separately, and greatly improves the detection efficiency.
[0114] The control method of the vehicle safety test system of the present invention is described in detail below with reference to a specific application example. Figure 6 As shown, the application example includes the following steps:
[0115] Step S11, collecting the test requirements of the vehicle to be tested with a customized requirement document template, and collecting the DBC file and key file of the vehicle to be tested.
[0116] Step S2: Turn on the power of the safety test system and open the host computer software.
[0117] Step S3: Import the test requirement document, preset report template, DBC file and key file of the vehicle to be tested through the host computer software.
[0118] Step S4: Through the automatic test program generation function of the host computer software, according to the required test work in the test requirement document, an executable program or readable script file corresponding to the vehicle to be tested is generated, including vehicle signal acquisition, charging control, report compilation and other codes, and then the executable program or readable script file is named by the user and saved in the database so that it can be directly called when testing the same type of vehicle to be tested in the future.
[0119] like Figure 7 As shown, the host computer software includes parsing, processing, packaging and running debugging modules, and has the function of automatically generating test programs. Its specific logic and process are as follows:
[0120] Step S41, in the upper computer software, import the test requirement document with the requirement list, the preset report template, the DBC file and the key file.
[0121] Step S42, the parsing module converts the above document into parameters executable by the processing module, specifically including:
[0122] 1) Automatically extract the requirement text information from the test requirement document through a program written in, but not limited to, VBA / python language;
[0123] 2) Automatically obtain the DBC signal analysis function through the DBC file through a program written in, but not limited to, Python;
[0124] 3) Verify the legality and validity of the key file through, but not limited to, the automatic encryption algorithm and key verification function pre-written in C++, and execute subsequent functions when reasonable, if unreasonable, exit the parsing module and prompt abnormal information;
[0125] 4) Convert the text information of the requirements into specific executable requirements, generate a test list and working condition requirements, and verify whether the test boundary meets the functional requirements. If it does, proceed to the next step. If not, a pop-up window will prompt the reason for the difference between the specific test boundary and the functional requirements and exit the analysis module;
[0126] 5) Convert the required DBC file into a signal analysis function and map it to the physical value of the information acquisition device.
[0127] Step S43, the processing module maps the functional test requirements of the vehicle to be tested to the API call function, generates an executable script, and checks the rationality of the function input parameters. If it is reasonable, it executes the subsequent functions, otherwise it exits the processing module.
[0128] Step S44, the encapsulation module detects whether the timing relationship between the script and the function meets the execution condition, and if so, encapsulates the script into an EXE executable program and a readable script file.
[0129] Step S45, the running debugging module can run the EXE executable program and the readable script file, wherein the EXE executable program can also be directly run in the host computer system environment. For fixed-function and mass-produced vehicles, the program can be run using the EXE binary file, and for debugging and non-standard production environments, the readable script file can be used to run, which is convenient for debugging.
[0130] Step S5: Run the generated executable program or readable script file, connect the charging power supply of the test system power supply device and the charging interface of the vehicle to be tested according to the prompt of the host computer interface, and control the test system acquisition end device to connect to the OBD interface or custom signal acquisition pins and other parts of the vehicle to be tested.
[0131] Step S6: The host computer software will determine whether the test conditions are met based on the connection status. If not, a prompt will be displayed to remind the user to check whether the connection in step S5 is normal. If it is met, the user will be prompted to click Next to perform vehicle insulation, equipotential, fast charging and slow charging tests.
[0132] Step S7: After all test requirements are completed, the executable program ends, and the host computer interface prompts the user to disconnect the connection between the test system and the charging interface, OBD interface, etc. of the vehicle to be tested.
[0133] Step S8: The host computer automatically compiles a safety test report based on the actual vehicle data according to the preset report template imported in step S3, and saves it to the database after being named by the user. The user can also choose to print or copy the report.
[0134] The safety test system for non-mass-produced electric vehicles of the present invention can automatically generate target test programs and safety test reports according to key data such as DBC of different models and different test requirements, without the need for manual writing of test programs and preparation of test reports, thereby improving the universality of the test system, solving the problems of long cycle and high cost caused by developing a set of test programs separately for each model, greatly improving the test efficiency, and reducing the test cost.
[0135] In this embodiment, a control device for a vehicle safety test system is also provided, which is used to implement the above-mentioned embodiments and preferred implementation modes, and will not be repeated hereafter. As used below, the term "module" may be a combination of software and / or hardware that implements a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.
[0136] This embodiment provides a control device for a vehicle safety test system, which can be applied to Figure 1 The host computer 101 shown in FIG. Figure 8 As shown, the control device includes:
[0137] The acquisition module 801 is used to acquire the test requirement document and the communication protocol data file of the vehicle to be tested;
[0138] A first processing module 802 is used to generate a target test program based on a test requirement document and a communication protocol data file;
[0139] The second processing module 803 is used to execute the target test program, switch the communication interface between the information collection device and the vehicle to be tested, and perform safety test on the vehicle to be tested.
[0140] In some optional embodiments, the device is also used for:
[0141] According to the communication protocol data file, the key file of the vehicle to be tested is obtained;
[0142] Based on the preset key verification function, the legitimacy of the key file is verified;
[0143] When it is detected that the key file has passed the legality verification, the step of generating a target test program based on the test requirement document and the communication protocol data file is executed.
[0144] In some optional implementations, the first processing module 802 is further configured to:
[0145] Generate an information collection program for the information collection device according to the communication protocol data file;
[0146] Generate functional test control procedures for the vehicle to be tested based on the test requirement document;
[0147] Generate a target test program based on the information collection program and the functional test control program.
[0148] In some optional implementations, the first processing module 802 is further configured to:
[0149] Parsing the data format file in the communication protocol data file to obtain a signal parsing function; wherein the data format file is used to characterize the data format corresponding to the communication protocol of the vehicle to be tested; the signal parsing function is used to map the information collection signal to the physical value of the information collection device to switch the communication interface between the information collection device and the vehicle to be tested;
[0150] Encapsulate the signal analysis function and generate an information collection program.
[0151] In some optional implementations, the first processing module 802 is further configured to:
[0152] Extract the text information of the requirements in the test requirement document, transform the text information of the requirements, and obtain the functional test requirements of the vehicle to be tested;
[0153] Determine at least one function call function corresponding to the functional test requirement, and determine a timing relationship between at least one function call function;
[0154] At least one function call function and the timing relationship are encapsulated to obtain a function test control program for the vehicle to be tested.
[0155] In some optional implementations, the second processing module 803 is further configured to:
[0156] Execute the information collection program in the target test program, and control the information collection device to connect to the target communication interface corresponding to the vehicle to be tested;
[0157] The safety test of the vehicle to be tested is carried out according to the functional test control program in the target test program, and the actual vehicle test data is collected by using the information collection device, and the safety test result of the vehicle to be tested is obtained according to the actual vehicle test data.
[0158] In some optional implementations, the safety test system further includes a power supply device; and the second processing module 803 is further used for:
[0159] Execute the functional test control program in the target test program, control the power supply device to connect to the charging interface of the vehicle to be tested in a corresponding manner, and perform a safety test on the vehicle to be tested; wherein the functional test control program includes at least one of the vehicle insulation test control program, the equipotential test control program, the fast charging test control program, and the slow charging test control program.
[0160] In some optional implementations, the second processing module 803 is further configured to:
[0161] Generate safety test reports and obtain safety test results based on preset report templates and actual vehicle test data.
[0162] The further functional description of each of the above modules and units is the same as that of the above corresponding embodiments and will not be repeated here.
[0163] The control device of the vehicle safety test system in this embodiment is presented in the form of a functional unit, where the unit refers to an ASIC (Application Specific Integrated Circuit) circuit, a processor and memory that executes one or more software or fixed programs, and / or other devices that can provide the above functions.
[0164] The embodiment of the present invention also provides a host computer having the above Figure 8 The control device of the vehicle safety test system is shown.
[0165] See also Fig. 9 , Fig. 9 is a schematic diagram of the structure of a host computer provided by an optional embodiment of the present invention, such as Fig. 9 As shown, the host computer includes: one or more processors 10, a memory 20, and interfaces for connecting various components, including high-speed interfaces and low-speed interfaces. The various components are connected to each other using different buses for communication, and can be installed on a common mainboard or installed in other ways as needed. The processor can process instructions executed in the host computer, including instructions stored in or on the memory to display graphical information of the GUI on an external input / output device (such as a display device coupled to the interface). In some optional embodiments, if necessary, multiple processors and / or multiple buses can be used together with multiple memories and multiple memories. Similarly, multiple devices can be connected, and each device provides some necessary operations (for example, as a server array, a group of blade servers, or a multi-processor system). Fig. 9 A processor 10 is taken as an example.
[0166] The processor 10 may be a central processing unit, a network processor or a combination thereof. The processor 10 may further include a hardware chip. The hardware chip may be a dedicated integrated circuit, a programmable logic device or a combination thereof. The programmable logic device may be a complex programmable logic device, a field programmable gate array, a general purpose array logic or any combination thereof.
[0167] The memory 20 stores instructions executable by at least one processor 10, so that the at least one processor 10 executes the method shown in the above embodiment.
[0168] The memory 20 may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function; the data storage area may store data created according to the use of the host computer, etc. In addition, the memory 20 may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some optional embodiments, the memory 20 may optionally include a memory remotely arranged relative to the processor 10, and these remote memories may be connected to the host computer via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0169] The memory 20 may include a volatile memory, such as a random access memory; the memory may also include a non-volatile memory, such as a flash memory, a hard disk or a solid state drive; the memory 20 may also include a combination of the above types of memory.
[0170] The host computer also includes an input device 30 and an output device 40. The processor 10, the memory 20, the input device 30 and the output device 40 can be connected via a bus or other means. Fig. 9 The example of connecting through bus is taken in the following.
[0171] The input device 30 can receive input digital or character information, and generate key signal input related to the user settings and function control of the host computer, such as a touch screen, a keypad, a mouse, a track pad, a touch pad, an indicator rod, one or more mouse buttons, a trackball, a joystick, etc. The output device 40 may include a display device, an auxiliary lighting device (e.g., an LED) and a tactile feedback device (e.g., a vibration motor), etc. The above-mentioned display device includes but is not limited to a liquid crystal display, a light emitting diode, a display and a plasma display. In some optional embodiments, the display device can be a touch screen.
[0172] The embodiment of the present invention also provides a computer-readable storage medium. The method according to the embodiment of the present invention can be implemented in hardware, firmware, or can be implemented as a computer code that can be recorded in a storage medium, or can be implemented as a computer code that is originally stored in a remote storage medium or a non-temporary machine-readable storage medium and will be stored in a local storage medium through a network download, so that the method described herein can be stored in such software processing on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only storage memory, a random access memory, a flash memory, a hard disk or a solid-state hard disk, etc.; further, the storage medium can also include a combination of the above types of memories. It can be understood that a computer, a processor, a microprocessor controller, or programmable hardware includes a storage component that can store or receive software or computer code. When the software or computer code is accessed and executed by a computer, a processor, or hardware, the method shown in the above embodiment is implemented.
[0173] A part of the present invention may be applied as a computer program product, such as a computer program instruction, which, when executed by a computer, can call or provide the method and / or technical solution according to the present invention through the operation of the computer. Those skilled in the art should understand that the existence of the computer program instruction in a computer-readable medium includes, but is not limited to, a source file, an executable file, an installation package file, etc., and accordingly, the way in which the computer program instruction is executed by the computer includes, but is not limited to: the computer directly executes the instruction, or the computer compiles the instruction and then executes the corresponding compiled program, or the computer reads and executes the instruction, or the computer reads and installs the instruction and then executes the corresponding installed program. Here, the computer-readable medium may be any available computer-readable storage medium or communication medium accessible to the computer.
[0174] Although the embodiments of the present invention have been described in conjunction with the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the present invention, and such modifications and variations are all within the scope defined by the appended claims.
Claims
1. A control method for a vehicle safety test system, characterized in that: The safety test system includes a host computer and an information collection device. The method is applied to the host computer. The method includes: Obtain the test requirement document and communication protocol data file of the vehicle to be tested; Generate a target test program based on the test requirement document and the communication protocol data file; The target test program is executed, the communication interface between the information collection device and the vehicle to be tested is switched, and a safety test is performed on the vehicle to be tested.
2. The method according to claim 1, characterized in that The generating a target test program based on the test requirement document and the communication protocol data file comprises: generating an information collection program for the information collection device according to the communication protocol data file; Based on the test requirement document, generating a functional test control program for the vehicle to be tested; Based on the information collection program and the functional test control program, a target test program is generated.
3. The method according to claim 2, characterized in that The step of generating an information collection program for the information collection device according to the communication protocol data file comprises: Parsing the data format file in the communication protocol data file to obtain a signal parsing function; wherein the data format file is used to characterize the data format corresponding to the communication protocol of the vehicle to be tested; the signal parsing function is used to map the information collection signal to the physical value of the information collection device to switch the communication interface between the information collection device and the vehicle to be tested; The signal analysis function is encapsulated to generate an information collection program.
4. The method according to claim 2, characterized in that: The generating, based on the test requirement document, a functional test control program for the vehicle to be tested comprises: Extracting textual requirement information from the test requirement document, converting the textual requirement information, and obtaining functional test requirements of the vehicle to be tested; Determine at least one function call function corresponding to the functional test requirement, and determine a timing relationship between at least one of the function call functions; At least one of the function call functions and the timing relationship is encapsulated to obtain a function test control program for the vehicle to be tested.
5. The method according to any one of claims 2 to 4, characterized in that: The executing the target test program, switching the communication interface between the information collection device and the vehicle to be tested, and performing a safety test on the vehicle to be tested, includes: Executing the information collection program in the target test program, controlling the information collection device to connect to the target communication interface corresponding to the vehicle to be tested; The vehicle to be tested is subjected to a safety test according to the functional test control program in the target test program, and actual vehicle test data is collected by using the information collection device, and the safety test result of the vehicle to be tested is obtained according to the actual vehicle test data.
6. The method according to claim 5, characterized in that The safety test system further includes a power supply device; and the safety test of the vehicle to be tested is performed according to the functional test control program in the target test program, including: Execute the functional test control program in the target test program, control the power supply device to connect to the charging interface of the vehicle to be tested in a corresponding manner, and perform a safety test on the vehicle to be tested; wherein the functional test control program includes at least one of a whole vehicle insulation test control program, an equipotential test control program, a fast charging test control program, and a slow charging test control program.
7. The method according to claim 5, characterized in that The step of obtaining the safety test result of the vehicle to be tested according to the actual vehicle test data includes: Based on the preset report template and the actual vehicle test data, a safety test report is generated to obtain the safety test results.
8. The method according to any one of claims 2 to 4, characterized in that: The method further comprises: Obtaining a key file of the vehicle to be tested according to the communication protocol data file; Based on a preset key verification function, the legitimacy of the key file is verified; When it is detected that the key file has passed the legality verification, the step of generating a target test program based on the test requirement document and the communication protocol data file is executed.
9. A control device for a vehicle safety test system, characterized in that: The safety test system includes a host computer and an information collection device. The control device is applied to the host computer. The control device includes: An acquisition module is used to acquire the test requirement document and communication protocol data file of the vehicle to be tested; A first processing module, configured to generate a target test program based on the test requirement document and the communication protocol data file; The second processing module is used to execute the target test program, switch the communication interface between the information collection device and the vehicle to be tested, and perform safety test on the vehicle to be tested.
10. A vehicle safety test system, characterized in that: include: Host computer and information collection device; The host computer includes a memory and a processor, the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the control method of the vehicle safety test system according to any one of claims 1 to 8 by executing the computer instructions.
11. The vehicle safety test system according to claim 10, characterized in that: The system also includes a power supply device; The power supply device is used to provide a DC power supply or an AC power supply to the system and the vehicle to be tested.
12. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a computer to execute the control method of the vehicle safety test system according to any one of claims 1 to 8.
13. A computer program product, characterized in that The method comprises computer instructions, wherein the computer instructions are used to enable a computer to execute the control method of the vehicle safety test system according to any one of claims 1 to 8.