CN116719244A - Simulation test method, system, device, equipment and storage medium - Google Patents

Simulation test method, system, device, equipment and storage medium Download PDF

Info

Publication number
CN116719244A
CN116719244A CN202310458688.7A CN202310458688A CN116719244A CN 116719244 A CN116719244 A CN 116719244A CN 202310458688 A CN202310458688 A CN 202310458688A CN 116719244 A CN116719244 A CN 116719244A
Authority
CN
China
Prior art keywords
simulation
target
function
tested
initial
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
CN202310458688.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.)
Chongqing Changan Automobile Co Ltd
Original Assignee
Chongqing Changan Automobile 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 Chongqing Changan Automobile Co Ltd filed Critical Chongqing Changan Automobile Co Ltd
Priority to CN202310458688.7A priority Critical patent/CN116719244A/en
Publication of CN116719244A publication Critical patent/CN116719244A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B17/00Systems involving the use of models or simulators of said systems
    • G05B17/02Systems involving the use of models or simulators of said systems electric
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01MTESTING STATIC OR DYNAMIC BALANCE OF MACHINES OR STRUCTURES; TESTING OF STRUCTURES OR APPARATUS, NOT OTHERWISE PROVIDED FOR
    • G01M17/00Testing of vehicles
    • G01M17/007Wheeled or endless-tracked vehicles

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Automation & Control Theory (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The application relates to a simulation test method, a simulation test system, simulation test device, simulation test equipment and a simulation test storage medium, and relates to the technical field of automobile tests. The method comprises the following steps: acquiring test data of a function to be tested in a vehicle and an initial simulation signal of the vehicle; the initial simulation signal comprises initial simulation data corresponding to the function to be tested; the initial simulation signal is used for indicating to generate an initial control instruction of the vehicle in the simulation scene according to the initial simulation data; further, according to the test data of the function to be tested, updating the initial simulation data in the initial simulation signal to obtain a target simulation signal; the target simulation signal comprises target simulation data after the initial simulation data is updated; the target simulation data is used for testing whether the function to be tested is normal. Thus, the test efficiency of the vehicle function can be improved.

Description

Simulation test method, system, device, equipment and storage medium
Technical Field
The application relates to the technical field of automobile testing, in particular to the technical field of automobile simulation testing, and specifically relates to a simulation testing method, system, device, equipment and storage medium.
Background
As the functions of vehicles become more and more complex, the functions of the vehicles need to be tested before the vehicles leave the factory.
In the related art, a method for testing functions of a vehicle mainly comprises the steps of constructing a simulation test environment in advance, and testing the functions of the vehicle in the simulation test environment by using a scene triggering mode. However, in the related art, each function of the vehicle needs to be tested by building a corresponding simulation test scene, which has a technical problem of low test efficiency.
Disclosure of Invention
The application provides a simulation test method, a simulation test system, a simulation test device, simulation test equipment and a simulation test storage medium, which at least solve the technical problem of low test efficiency in the related technology. The technical scheme of the application is as follows:
according to a first aspect of the present application, there is provided a simulation test method, including: acquiring test data of a function to be tested in a vehicle and an initial simulation signal of the vehicle; the initial simulation signal comprises initial simulation data corresponding to the function to be tested; the initial simulation signal is used for indicating to generate an initial control instruction of the vehicle in the simulation scene according to the initial simulation data; updating initial simulation data in the initial simulation signals according to the test data of the function to be tested to obtain target simulation signals; the target simulation signal comprises target simulation data after the initial simulation data is updated; the target simulation data is used for testing whether the function to be tested is normal.
According to the technical means, the method and the device can update the initial simulation data in the initial simulation signal according to the test data of the function to be tested to obtain the target simulation signal. Therefore, after the target simulation signal comprising the target simulation data is obtained through the test data, the function to be tested can be tested based on the target simulation signal, and thus, the simulation scene does not need to be built and deployed again, and the test efficiency is improved.
In one possible embodiment, the method further comprises: responding to the target simulation signal, and acquiring the activation state of a target function module corresponding to the function to be tested; and if the activation state of the target functional module is activated, determining that the function to be tested is normal.
According to the technical means, the method and the device can respond to the target simulation signal to acquire the activation state of the target function module corresponding to the function to be tested. And if the activation state of the target functional module is activated, determining that the function to be tested is normal. Therefore, the method for determining whether the function to be tested is normal can be simply, conveniently and easily realized by acquiring the activation state of the function to be tested.
In one possible embodiment, the method further comprises: responding to a target simulation signal, and generating a target control instruction of the vehicle in a simulation scene based on a target functional module corresponding to a function to be tested; the target control instruction is used for indicating to update the simulation state of the vehicle in the simulation scene.
According to the technical means, the method can respond to the target simulation signal and generate the target control instruction of the vehicle in the simulation scene based on the target functional module corresponding to the function to be tested. Therefore, as the target control instruction is used for indicating the simulation state of the updated vehicle in the simulation scene, a tester can determine whether the function to be tested can reach the expected effect by observing the simulation state of the updated vehicle in the simulation scene, and another method for determining whether the function to be tested is normal or not, which is relatively visual and has a relatively good effect, is realized.
In one possible embodiment, the method further comprises: under the condition of generating an initial control instruction and a target control instruction, if the activation states of the redundant function modules are activated, outputting the target control instruction; the target control instruction is used for indicating to update the simulation state of the vehicle in the simulation scene, and the redundant function modules comprise target function modules corresponding to functions to be tested.
According to the technical means, the method and the device can judge the activation states of the redundant function modules under the condition that the initial control instruction and the target control instruction are generated. And outputting a target control instruction when the activation states of the redundant function modules are activated. And outputting an initial control instruction when the activation states of the redundant function modules are not activated. In this way, determining to output the initial control instruction or the target control instruction can be achieved by judging the activation states of the plurality of redundant function modules.
In one possible implementation manner, the updating the initial simulation data in the initial simulation signal according to the test data of the function to be tested to obtain the target simulation signal includes: and replacing the test value of the function to be tested in the initial simulation data of the initial simulation data according to the fault value in the test data of the function to be tested, so as to obtain a target simulation signal.
According to the technical means, the method and the device can update the initial simulation data in the initial simulation signal according to the test data of the function to be tested to obtain the target simulation signal. Therefore, after the target simulation signal comprising the target simulation data is obtained through the test data, the function to be tested can be tested based on the target simulation signal, and thus, the simulation scene does not need to be built and deployed again, and the test efficiency is improved.
In one possible implementation manner, the acquiring the test data of the function to be tested in the vehicle includes: acquiring a test case of a function to be tested; performing script generation processing on the test cases of the functions to be tested to obtain target test scripts corresponding to the functions to be tested; and acquiring test data of the function to be tested from the target test script.
According to the technical means, the method and the device can update the initial simulation data in the initial simulation signal according to the test data of the function to be tested to obtain the target simulation signal. Therefore, after the target simulation signal comprising the target simulation data is obtained through the test data, the function to be tested can be tested based on the target simulation signal, and thus, the simulation scene does not need to be built and deployed again, and the test efficiency is improved.
According to a second aspect of the present application, a simulation test system is provided, including a fault injection module, a simulation scene module, a first control module, a second control module, and a test script module; the simulation scene module is used for simulating a scene where the vehicle is located; the first control module and the second control module are used for generating a control instruction of the vehicle according to the simulation data of the vehicle; the fault injection module is used for receiving the initial simulation signal of the vehicle sent by the first control module and the test data of the function to be tested sent by the test script module; the initial simulation signal comprises initial simulation data corresponding to the function to be tested; the initial simulation signal is used for indicating to generate an initial control instruction of the vehicle in the simulation scene according to the initial simulation data; the fault injection module is also used for updating the initial simulation data in the initial simulation signal according to the test data of the function to be tested to obtain a target simulation signal; the target simulation signal comprises target simulation data after the initial simulation data is updated; the target simulation data is used for testing whether the function to be tested is normal.
In one possible implementation, the test script module is further configured to: responding to the target simulation signal, and acquiring the activation state of a target function module corresponding to the function to be tested, which is sent by the second control module; and if the activation state of the target functional module is activated, determining that the function to be tested is normal.
In one possible implementation manner, the second control module is configured to: receiving a target simulation signal sent by a fault injection module, and generating a target control instruction of the vehicle in a simulation scene based on a target function module corresponding to a function to be tested; the target control instruction is used for indicating to update the simulation state of the vehicle in the simulation scene.
In one possible implementation manner, the simulation test system further includes an arbitration module, where the arbitration module is configured to: under the condition that an initial control instruction sent by a first control module and a target control instruction sent by a second control module are received, if the activation state of the second control module is activated, the target control instruction is sent to a simulation scene module; the target control instruction is used for indicating the simulation scene module to update the simulation state of the vehicle in the simulation scene, and the second control module comprises a target function module corresponding to the function to be tested.
According to a third aspect of the present application, there is provided a simulation test apparatus including an acquisition unit and an update unit;
the acquisition unit is used for acquiring test data of a function to be tested in the vehicle and an initial simulation signal of the vehicle; the initial simulation signal comprises initial simulation data corresponding to the function to be tested; the initial simulation signal is used for indicating to generate an initial control instruction of the vehicle in the simulation scene according to the initial simulation data; the updating unit is used for updating the initial simulation data in the initial simulation signal according to the test data of the function to be tested to obtain a target simulation signal; the target simulation signal comprises target simulation data after the initial simulation data is updated; the target simulation data is used for testing whether the function to be tested is normal.
In one possible implementation manner, the simulation test apparatus further includes a determining unit; the acquisition unit is also used for responding to the target simulation signal and acquiring the activation state of the target function module corresponding to the function to be tested; and the determining unit is used for determining that the function to be tested is normal if the activation state of the target function module is activated.
In one possible implementation manner, the simulation test apparatus further includes a generating unit; the generating unit is used for responding to the target simulation signal and generating a target control instruction of the vehicle in the simulation scene based on a target functional module corresponding to the function to be tested; the target control instruction is used for indicating to update the simulation state of the vehicle in the simulation scene.
In one possible implementation manner, the simulation test apparatus further includes an output unit; the output unit is used for outputting a target control instruction if the activation states of the redundant function modules are activated under the condition of generating the initial control instruction and the target control instruction; the target control instruction is used for indicating to update the simulation state of the vehicle in the simulation scene, and the redundant function modules comprise target function modules corresponding to functions to be tested.
In one possible implementation manner, the updating unit is specifically configured to: and replacing the test value of the function to be tested in the initial simulation data of the initial simulation data according to the fault value in the test data of the function to be tested, so as to obtain a target simulation signal.
In one possible implementation manner, the acquiring unit is specifically configured to: acquiring a test case of a function to be tested; performing script generation processing on the test cases of the functions to be tested to obtain target test scripts corresponding to the functions to be tested; and acquiring test data of the function to be tested from the target test script.
According to a fourth aspect of the present application, there is provided an electronic device, comprising: a processor; a memory for storing processor-executable instructions; wherein the processor is configured to execute instructions to implement the method of the first aspect and any of its possible embodiments described above.
According to a fifth aspect of the present application there is provided a computer readable storage medium, which when executed by a processor of an electronic device, enables the electronic device to perform the method of the first aspect and any of its possible embodiments.
According to a sixth aspect of the present application there is provided a computer program product comprising computer instructions which, when run on an electronic device, cause the electronic device to perform the method of the first aspect and any of its possible embodiments.
It should be noted that, the technical effects caused by any implementation manner of the second aspect to the sixth aspect may refer to the technical effects caused by the corresponding implementation manner in the first aspect, which is not described herein.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the application as claimed.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the application and together with the description, serve to explain the principles of the application and do not constitute a undue limitation on the application.
FIG. 1 is a flow chart illustrating a simulation test method in accordance with an exemplary embodiment;
FIG. 2 is a flow chart illustrating yet another simulation test method in accordance with an exemplary embodiment;
FIG. 3 is a flow chart illustrating yet another simulation test method in accordance with an exemplary embodiment;
FIG. 4 is a flowchart illustrating yet another simulation test method in accordance with an exemplary embodiment;
FIG. 5 is a schematic diagram of a simulation test system, shown in accordance with an exemplary embodiment;
FIG. 6 is a block diagram of a simulation test apparatus, shown in accordance with an exemplary embodiment;
fig. 7 is a block diagram of an electronic device, according to an example embodiment.
Detailed Description
In order to enable a person skilled in the art to better understand the technical solutions of the present application, the technical solutions of the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings.
It should be noted that the terms "first," "second," and the like in the description and the claims of the present application and the above figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments of the application described herein may be implemented in sequences other than those illustrated or otherwise described herein. The implementations described in the following exemplary examples do not represent all implementations consistent with the application. Rather, they are merely examples of apparatus and methods consistent with aspects of the application as detailed in the accompanying claims.
For easy understanding, the simulation test method provided by the application is specifically described below with reference to the accompanying drawings.
FIG. 1 is a flow chart illustrating a simulation test method, as shown in FIG. 1, according to an exemplary embodiment, comprising the steps of:
s101, the electronic equipment acquires test data of a function to be tested in the vehicle and an initial simulation signal of the vehicle.
The initial simulation signal comprises initial simulation data corresponding to the function to be tested; the initial simulation signal is used for indicating that an initial control instruction of the vehicle in the simulation scene is generated according to the initial simulation data.
As a possible implementation manner, the electronic device obtains test cases written by a tester according to the requirements of the functions to be tested in the vehicle, and carries out script generation processing on the test cases of the functions to be tested to obtain target test scripts corresponding to the functions to be tested in the vehicle; and the electronic equipment executes the target test script to acquire test data of the function to be tested in the vehicle.
As one possible implementation, the electronic device obtains an initial simulation signal of the vehicle.
The functions to be tested may include, for example, steering functions, braking functions of the vehicle, and other functions of the vehicle in an autopilot scenario.
For example, the simulation scenario may be generated for virtual test drive (virtual test drive, VTD) software.
Exemplary, the initial simulation data in the initial simulation signal of the vehicle includes vehicle dynamic data (X-direction coordinates, Y-direction coordinates, Z-direction coordinates, X-direction speed, Y-direction speed, Z-direction speed, X-direction acceleration, Y-direction acceleration, Z-direction acceleration, yaw angle, roll angle, pitch angle, etc. of the vehicle in the simulation scene), fusion positioning data, true value sensor data, information of a target object in the simulation scene, high-precision map data, navigation information; the target object may include an obstacle such as a road facility, a pedestrian, or another vehicle in the simulation scene.
S102, the electronic equipment updates initial simulation data in the initial simulation signals according to the test data of the function to be tested to obtain target simulation signals.
The target simulation signal comprises target simulation data after the initial simulation data is updated; the target simulation data is used for testing whether the function to be tested is normal.
As a possible implementation manner, the electronic device replaces the test value of the function to be tested in the initial simulation data according to the fault value in the test data of the function to be tested, so as to obtain the target simulation signal.
For example, when the following distance is too close, the test value of the following distance in the initial simulation data is 100 meters, the fault value of the following distance in the test data of the function to be tested is 50 meters, and the electronic device replaces the test value of the following distance in the initial simulation data with the following distance fault value of the following distance in the test data of the function to be tested by 50 meters, so as to obtain the target simulation signal comprising the target simulation data.
It can be appreciated that according to the technical scheme provided by the embodiment of the application, the initial simulation data in the initial simulation signal is updated according to the test data of the function to be tested, so as to obtain the target simulation signal. Therefore, after the target simulation signal comprising the target simulation data is obtained through the test data, the function to be tested can be tested based on the target simulation signal, and thus, the simulation scene does not need to be built and deployed again, and the test efficiency is improved.
In some embodiments, in order to determine whether the function to be tested is normal, as shown in fig. 2, the simulation test method provided by the embodiment of the present application further includes the following steps:
s201, the electronic equipment responds to a target simulation signal to acquire the activation state of a target function module corresponding to the function to be tested.
As a possible implementation manner, after the target function module corresponding to the function to be tested receives the target simulation signal, sending an activation state signal of the target function module to the electronic device; correspondingly, the electronic equipment acquires the activation state signal of the target function module, and judges whether the activation state of the target function module is activated or not according to the identification in the activation state signal.
It should be noted that, the target function module corresponding to the function to be tested may respond to the target simulation signal, which indicates that the target function module is activated; and if the target function module corresponding to the function to be tested does not respond to the target simulation signal, indicating that the target function module is not activated.
Illustratively, the target function is activated when the flag in the activation status signal is 1; when the mark in the activation state signal is 0, the target function module is not activated.
S202, if the activation state of the target function module is activated, the electronic equipment determines that the function to be tested is normal.
In the actual application process, if the activation state of the target function module is not activated, the electronic device determines that the function to be tested is abnormal.
It can be appreciated that, according to the technical scheme provided by the embodiment of the application, the activation state of the target function module corresponding to the function to be tested is obtained in response to the target simulation signal. And if the activation state of the target functional module is activated, determining that the function to be tested is normal. Therefore, the method for determining whether the function to be tested is normal can be simply, conveniently and easily realized by acquiring the activation state of the function to be tested.
In some embodiments, in order to determine whether the function to be tested is normal, as shown in fig. 3, the simulation test method provided by the embodiment of the present application further includes the following steps:
s301, the electronic equipment responds to a target simulation signal, and generates a target control instruction of the vehicle in a simulation scene based on a target function module corresponding to the function to be tested.
The target control instruction is used for indicating to update the simulation state of the vehicle in the simulation scene.
As one possible implementation, the target function module in the electronic device generates a target control instruction of the vehicle in the simulation scene in response to the fault value of the target simulation data in the target simulation signal. Further, the electronic device sends the target control instruction to the simulation scene. Correspondingly, the simulation scene receives the target control instruction and updates the simulation state of the vehicle in the simulation scene.
The target function module includes a redundant lateral control module and a redundant longitudinal control module, and the target control command includes a gear command, a steering angle command, and an acceleration/deceleration command.
It can be appreciated that according to the technical scheme provided by the embodiment of the application, the target control instruction of the vehicle in the simulation scene is generated by responding to the target simulation signal and based on the target functional module corresponding to the function to be tested. Therefore, as the target control instruction is used for indicating the simulation state of the updated vehicle in the simulation scene, a tester can determine whether the function to be tested can reach the expected effect by observing the simulation state of the updated vehicle in the simulation scene, and another method for determining whether the function to be tested is normal or not, which is relatively visual and has a relatively good effect, is realized.
In some embodiments, in order to determine whether the function to be tested is normal, as shown in fig. 4, the simulation test method provided by the embodiment of the present application further includes the following steps:
s401, under the condition that an initial control instruction and a target control instruction are generated, the electronic equipment judges the activation states of a plurality of redundant function modules.
As a possible implementation manner, in the case of generating the initial control instruction and the target control instruction, the activation states of the plurality of redundant function modules are determined according to the identifications of the received activation state signals of the plurality of redundant function modules.
Illustratively, the plurality of redundant function modules is activated when the identification in the activation status signal of the plurality of redundant function modules is 1; when the identification in the activation state signal of the plurality of redundant function modules is 0, the plurality of redundant function modules are not activated.
It can be understood that if the active states of the redundant function modules are activated, the electronic device determines that the active states of the redundant function modules are activated; if the activation state of the redundant function module is not activated in the redundant function modules, the electronic device judges that the activation state of the redundant function modules is not activated.
S402, under the condition that an initial control instruction and a target control instruction are generated, if the activation states of the redundant function modules are activated, the electronic equipment outputs the target control instruction.
The target control instruction is used for indicating to update the simulation state of the vehicle in the simulation scene, and the redundant function modules comprise target function modules corresponding to functions to be tested.
In the actual application process, when the activation states of the redundant function modules are not activated, the electronic equipment only outputs an initial control instruction. Meanwhile, under the condition that the activation states of the redundant function modules are not activated, the target control instruction is a preset default value. The default value is used to indicate that the target control instruction is invalid. Illustratively, the default value may be 0.
It can be understood that, in the technical solution provided in the embodiment of the present application, under the condition of generating the initial control instruction and the target control instruction, the activation states of the multiple redundant function modules are determined. And outputting a target control instruction when the activation states of the redundant function modules are activated. And outputting an initial control instruction when the activation states of the redundant function modules are not activated. In this way, determining to output the initial control instruction or the target control instruction can be achieved by judging the activation states of the plurality of redundant function modules.
The foregoing description of the solution provided by the embodiments of the present application has been mainly presented in terms of a method. In order to achieve the above functions, the simulation test apparatus or the electronic device includes a system, a hardware structure and/or a software module for executing the respective functions. Those of skill in the art will readily appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as hardware or combinations of hardware and computer software. Whether a function is implemented as hardware or computer software driven hardware depends upon the particular application and design constraints imposed on the solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
According to the method, the simulation test device or the electronic device can be divided into the functional modules in the system, for example, the simulation test device or the electronic device can comprise a simulation test system, each functional module corresponding to each functional division is included in the simulation test system, and two or more functions can be integrated into one processing module. The integrated modules may be implemented in hardware or in software functional modules. It should be noted that, in the embodiment of the present application, the division of the modules is schematic, which is merely a logic function division, and other division manners may be implemented in actual implementation.
As shown in fig. 5, an embodiment of the present application provides a simulation test system, where the simulation test system includes a fault injection module, a simulation scene module, a first control module, a second control module, a test script module, and a scene simulation platform; the simulation scene module is used for simulating a simulation scene of the vehicle; the first control module and the second control module are used for generating a control instruction of the vehicle according to the simulation data of the vehicle; the simulation scene platform is used for forwarding initial simulation signals received by the simulation scene module to the first control module.
The fault injection module is used for receiving the initial simulation signal of the vehicle sent by the first control module and the test data of the function to be tested sent by the test script module.
The initial simulation signal comprises initial simulation data corresponding to the function to be tested; the initial simulation signal is used for indicating the first control module to generate an initial control instruction of the vehicle in the simulation scene according to the initial simulation data.
The fault injection module is used for receiving an initial simulation signal of the vehicle sent by the first control module through a (zeroMQ, ZMQ) Protocol and a Protocol Buffers data format; the fault injection module is further configured to receive test data of the function to be tested sent by the test script module through a user datagram Protocol (user datagram Protocol, UDP) and a Protocol Buffers data format.
It should be noted that, the initial simulation signal of the vehicle is sent to the simulation scene platform by the simulation scene module through a transmission control protocol (transmission control protocol, TCP). The simulation scene platform forwards the received initial simulation signal to the first control module through a (ZeroMQ, ZMQ) Protocol and a Protocol Buffers data format.
Exemplary, the initial simulation data in the initial simulation signal of the vehicle includes vehicle dynamic data (X-direction coordinates, Y-direction coordinates, Z-direction coordinates, X-direction speed, Y-direction speed, Z-direction speed, X-direction acceleration, Y-direction acceleration, Z-direction acceleration, yaw angle, roll angle, pitch angle, etc. of the vehicle in the simulation scene), fusion positioning data, true value sensor data, information of a target object in the simulation scene, high-precision map data, navigation information; the target object may include an obstacle such as a road facility, a pedestrian, or another vehicle in the simulation scene.
The functions to be tested may include, for example, steering functions, braking functions of the vehicle, and other functions of the vehicle in an autopilot scenario.
In the actual application process, the first control module may be referred to as a main functional module, and the second control module may be referred to as a redundant functional module.
The fault injection module is also used for updating the initial simulation data in the initial simulation signal according to the test data of the function to be tested to obtain a target simulation signal.
The target simulation signal comprises target simulation data after the initial simulation data is updated; the target simulation data is used for testing whether the function to be tested is normal.
The implementation manner of obtaining the target simulation signal may refer to S102, which is not described herein.
It can be understood that the technical scheme provided by the embodiment of the application is a software in loop (SLI) fault injection simulation test method, which can perform simulation test on the functional safety and the expected functional safety of a vehicle.
As shown in fig. 5, the test script module in the above simulation test system is further configured to obtain, in response to the target simulation signal, an activation state of a target function module corresponding to the function to be tested, which is sent by the second control module.
As one possible implementation manner, the second control module sends the activation state of the target function module corresponding to the function to be tested to the fault injection module through a (ZeroMQ, ZMQ) Protocol and a Protocol Buffers data format; correspondingly, the fault injection module receives the activation state of the target function module corresponding to the function to be tested, and sends the activation state to the test script module through UDP communication.
If the activation state of the target function module is activated, the test script module determines that the function to be tested is normal.
In the actual application process, if the activation state of the target function module is not activated, the test script module determines that the function to be tested is abnormal.
And the test script module outputs the result of the normal or abnormal function to be detected, and the tester knows the normal or abnormal function to be detected by checking the result output by the test script.
The implementation manner of determining that the function to be tested is normal may refer to S202, which is not described herein.
In the actual application process, the test script module is further used for sending operations such as simulation scene loading, simulation scene starting, simulation scene stopping and the like to the simulation scene module according to a remote file copy command (SCP); the test script module is also used for sending a key signal to the simulation scene platform through a UDP communication Protocol and a Protocol Buffers data format; the key signal is used for indicating the vehicle function to be turned on or off and comprises a high level and a low level; the test script module is also used for receiving a state feedback signal of the first control module sent by the first control module forwarded by the simulation scene platform through a UDP communication Protocol and a Protocol Buffers data format.
As shown in fig. 5, the second control module in the simulation test system is configured to receive the target simulation signal sent by the fault injection module, and generate a target control instruction of the vehicle in the simulation scene based on the target functional module corresponding to the function to be tested.
The target control instruction is used for indicating to update the simulation state of the vehicle in the simulation scene; the target simulation signal is sent to the second control module by the fault injection module through a (ZeroMQ, ZMQ) Protocol and Protocol Buffers data format.
As one possible implementation, the target function module generates a target control instruction of the vehicle in the simulation scene in response to a fault value of the target simulation data in the target simulation signal. Further, the second control module sends the target control command and the activation state of the second control module to the arbitration module through a (ZeroMQ, ZMQ) Protocol and a Protocol Buffers data format.
The first control module includes a plurality of main function modules including data services, data verification, state machines, vertical control, horizontal control, human-machine interface, environment reconstruction, path planning, prediction, behavior decision, vertical planning.
The second control module comprises a plurality of redundant functional modules, wherein the plurality of redundant functional modules comprise path planning verification, behavior decision verification, transverse control verification, longitudinal control verification, redundant transverse control, redundant longitudinal control and redundant monitoring; the target control command includes a gear command, a steering angle command, and an acceleration/deceleration command.
In the actual application process, the first control module responds to initial simulation data in the initial simulation signal to generate an initial control instruction of the vehicle in a simulation scene. Further, the first control module sends the initial control command and the activation state of the first control module to the arbitration module through a (ZeroMQ, ZMQ) Protocol and a Protocol Buffers data format.
As shown in fig. 5, the simulation test system in the simulation test system further includes an arbitration module, where the arbitration module is configured to determine an activation state of the second control module when receiving the initial control instruction sent by the first control module and the target control instruction sent by the second control module.
The determination of the activation state of the second control module may refer to S401.
Under the condition that an initial control instruction sent by the first control module and a target control instruction sent by the second control module are received, if the activation state of the second control module is activated, the arbitration module sends the target control instruction to the simulation scene module.
The second control module comprises a target function module corresponding to the function to be tested.
The arbitration module sends the target control instruction to the simulation scene platform through a (zeroMQ, ZMQ) Protocol and Protocol Buffers data format; and the simulation scene platform forwards the received target control instruction to the simulation scene module.
In the actual application process, when the activation state of the second control module is not activated, the arbitration module only outputs an initial control instruction. Meanwhile, under the condition that the activation state of the second control module is not activated, the target control instruction is a preset default value. The default value is used to indicate that the target control instruction is invalid. Illustratively, the default value may be 0.
Fig. 6 is a block diagram illustrating a simulation test apparatus 600 according to an exemplary embodiment. Referring to fig. 6, the simulation test apparatus 600 includes: comprises an acquisition unit 601 and an updating unit 602;
an obtaining unit 601, configured to obtain test data of a function to be tested in a vehicle, and an initial simulation signal of the vehicle; the initial simulation signal comprises initial simulation data corresponding to the function to be tested; the initial simulation signal is used for indicating that an initial control instruction of the vehicle in the simulation scene is generated according to the initial simulation data.
The updating unit 602 is configured to update initial simulation data in the initial simulation signal according to test data of a function to be tested, so as to obtain a target simulation signal; the target simulation signal comprises target simulation data after the initial simulation data is updated; the target simulation data is used for testing whether the function to be tested is normal.
Optionally, as shown in fig. 6, the simulation test apparatus 600 provided in the embodiment of the present application further includes a determining unit 603; the obtaining unit 601 is further configured to obtain an activation state of a target function module corresponding to a function to be tested in response to the target simulation signal; and the determining unit 603 is configured to determine that the function to be tested is normal if the activation state of the target function module is activated.
Optionally, as shown in fig. 6, the simulation test apparatus 600 provided in the embodiment of the present application further includes a generating unit 604; the generating unit 604 is configured to generate, in response to the target simulation signal, a target control instruction of the vehicle in the simulation scene based on a target function module corresponding to the function to be tested; the target control instruction is used for indicating to update the simulation state of the vehicle in the simulation scene.
Optionally, as shown in fig. 6, the simulation test apparatus 600 provided in the embodiment of the present application further includes an output unit 605; an output unit 605 configured to output a target control instruction if the activation states of the plurality of redundant function modules are activated in the case of generating the initial control instruction and the target control instruction; the target control instruction is used for indicating to update the simulation state of the vehicle in the simulation scene, and the redundant function modules comprise target function modules corresponding to functions to be tested.
Optionally, as shown in fig. 6, the updating unit 602 provided in the embodiment of the present application is specifically configured to: and replacing the test value of the function to be tested in the initial simulation data of the initial simulation data according to the fault value in the test data of the function to be tested, so as to obtain a target simulation signal.
Optionally, as shown in fig. 6, the acquiring unit 601 provided in the embodiment of the present application is specifically configured to: acquiring a test case of a function to be tested; performing script generation processing on the test cases of the functions to be tested to obtain target test scripts corresponding to the functions to be tested; and acquiring test data of the function to be tested from the target test script.
The specific manner in which the various modules perform the operations in the apparatus of the above embodiments have been described in detail in connection with the embodiments of the method, and will not be described in detail herein.
Fig. 7 is a block diagram of an electronic device, according to an example embodiment. As shown in fig. 7, electronic device 700 includes, but is not limited to: a processor 701 and a memory 702.
The memory 702 is configured to store executable instructions of the processor 701. It will be appreciated that the processor 701 described above is configured to execute instructions to implement the simulation test method in the above embodiments.
It should be noted that the electronic device structure shown in fig. 7 is not limited to the electronic device, and the electronic device may include more or less components than those shown in fig. 7, or may combine some components, or may have different arrangements of components, as will be appreciated by those skilled in the art.
The processor 701 is a control center of the electronic device, connects various parts of the entire electronic device using various interfaces and lines, and performs various functions of the electronic device and processes data by running or executing software programs and/or modules stored in the memory 702, and calling data stored in the memory 702, thereby performing overall monitoring of the electronic device. The processor 701 may include one or more processing units. Alternatively, the processor 701 may integrate an application processor that primarily handles operating systems, user interfaces, applications, etc., with a modem processor that primarily handles wireless communications. It will be appreciated that the modem processor described above may not be integrated into the processor 701.
The memory 702 may be used to store software programs as well as various data. The memory 702 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, application programs (such as a determination unit, a processing unit, etc.) required for at least one functional module, and the like. In addition, the memory 702 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid-state storage device.
In an exemplary embodiment, a computer readable storage medium is also provided, such as a memory 702, comprising instructions executable by the processor 701 of the electronic device 700 to implement the simulation test method in the above embodiments.
In actual implementation, the functions of the acquisition unit 601, the updating unit 602, the determination unit 603, the generation unit 604, and the output unit 605 in fig. 6 may be implemented by the processor 701 in fig. 7 calling a computer program stored in the memory 702. For specific execution, reference may be made to the description of the simulation test method in the above embodiment, and details are not repeated here.
Alternatively, the computer readable storage medium may be a non-transitory computer readable storage medium, for example, a read-only memory (ROM), a random access memory (random access memory, RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, and the like.
In an exemplary embodiment, embodiments of the application also provide a computer program product comprising one or more instructions executable by the processor 701 of an electronic device to perform the simulation test method of the above-described embodiments.
It should be noted that, when the instructions in the computer readable storage medium or one or more instructions in the computer program product are executed by the processor of the electronic device, the respective processes of the above-mentioned embodiments of the simulation test method are implemented, and the same technical effects as those of the above-mentioned simulation test method can be achieved, so that repetition is avoided, and no further description is given here.
From the foregoing description of the embodiments, it will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-described division of functional modules is illustrated, and in practical application, the above-described functional allocation may be performed by different functional modules according to needs, i.e. the internal structure of the apparatus is divided into different functional modules, so as to perform all the classification parts or part of the functions described above.
In the several embodiments provided by the present application, it should be understood that the disclosed apparatus and method may be implemented in other manners. For example, the apparatus embodiments described above are merely illustrative, e.g., the division of modules or units is merely a logical function division, and there may be additional divisions when actually implemented, e.g., multiple units or components may be combined or integrated into another apparatus, or some features may be omitted or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be an indirect coupling or communication connection via some interfaces, devices or units, which may be in electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and the parts shown as units may be one physical unit or a plurality of physical units, may be located in one place, or may be distributed in a plurality of different places. Some or all of the classification units can be selected according to actual needs to achieve the purpose of the scheme of the embodiment.
In addition, each functional unit in the embodiments of the present application may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit. The integrated units may be implemented in hardware or in software functional units.
The integrated units, if implemented in the form of software functional units and sold or used as stand-alone products, may be stored in a readable storage medium. Based on such understanding, the technical solution of the embodiments of the present application, or the portion contributing to the prior art or the whole classification portion or portion of the technical solution, may be embodied in the form of a software product stored in a storage medium, where the software product includes several instructions to cause a device (may be a single-chip microcomputer, a chip or the like) or a processor (processor) to execute the whole classification portion or part of the steps of the method of the embodiments of the present application. And the aforementioned storage medium includes: a usb disk, a removable hard disk, a ROM, a RAM, a magnetic disk, or an optical disk, etc.
The present application is not limited to the above embodiments, and any changes or substitutions within the technical scope of the present application should be covered by the scope of the present application. Therefore, the protection scope of the application is subject to the protection scope of the claims.

Claims (13)

1. A simulation test method, the method comprising:
acquiring test data of a function to be tested in a vehicle and an initial simulation signal of the vehicle; the initial simulation signal comprises initial simulation data corresponding to the function to be tested; the initial simulation signal is used for indicating that an initial control instruction of the vehicle in a simulation scene is generated according to the initial simulation data;
updating the initial simulation data in the initial simulation signal according to the test data of the function to be tested to obtain a target simulation signal; the target simulation signal comprises target simulation data after the initial simulation data is updated; the target simulation data are used for testing whether the function to be tested is normal or not.
2. The simulation test method according to claim 1, wherein the method further comprises:
Responding to the target simulation signal, and acquiring the activation state of a target function module corresponding to the function to be tested;
and if the activation state of the target function module is activated, determining that the function to be tested is normal.
3. The simulation test method according to claim 1, wherein the method further comprises:
responding to the target simulation signal, and generating a target control instruction of the vehicle in a simulation scene based on a target functional module corresponding to the function to be tested; the target control instruction is used for indicating to update the simulation state of the vehicle in the simulation scene.
4. The simulation test method according to claim 1, wherein the method further comprises:
under the condition that the initial control instruction and the target control instruction are generated, if the activation states of the redundant function modules are activated, outputting the target control instruction; the target control instruction is used for indicating to update the simulation state of the vehicle in a simulation scene, and the redundant function modules comprise target function modules corresponding to the functions to be tested.
5. The simulation test method according to any one of claims 1 to 4, wherein updating the initial simulation data in the initial simulation signal according to the test data of the function to be tested to obtain a target simulation signal includes:
And replacing the test value of the function to be tested in the initial simulation data of the initial simulation data according to the fault value in the test data of the function to be tested, so as to obtain the target simulation signal.
6. The simulation test method according to any one of claims 1 to 4, wherein the acquiring test data of a function to be tested in a vehicle includes:
acquiring a test case of the function to be tested; performing script generation processing on the test cases of the functions to be tested to obtain target test scripts corresponding to the functions to be tested;
and acquiring the test data of the function to be tested from the target test script.
7. The simulation test system is characterized by comprising a fault injection module, a simulation scene module, a first control module, a second control module and a test script module; the simulation scene module is used for simulating a scene where the vehicle is located; the first control module and the second control module are both used for generating control instructions of the vehicle according to simulation data of the vehicle;
the fault injection module is used for receiving the initial simulation signal of the vehicle sent by the first control module and the test data of the function to be tested sent by the test script module; the initial simulation signal comprises initial simulation data corresponding to the function to be tested; the initial simulation signal is used for indicating that an initial control instruction of the vehicle in a simulation scene is generated according to the initial simulation data;
The fault injection module is further configured to update the initial simulation data in the initial simulation signal according to the test data of the function to be tested, so as to obtain a target simulation signal; the target simulation signal comprises target simulation data after the initial simulation data is updated; the target simulation data are used for testing whether the function to be tested is normal or not.
8. The simulation test system of claim 7, wherein the test script module is further configured to:
responding to the target simulation signal, and acquiring an activation state of a target function module corresponding to the function to be tested, which is sent by the second control module;
and if the activation state of the target function module is activated, determining that the function to be tested is normal.
9. The simulation test system of claim 7, wherein the second control module is configured to:
receiving the target simulation signal sent by the fault injection module, and generating a target control instruction of the vehicle in a simulation scene based on a target function module corresponding to the function to be tested; the target control instruction is used for indicating to update the simulation state of the vehicle in the simulation scene.
10. The simulation test system of claim 7, further comprising an arbitration module for:
under the condition that the initial control instruction sent by the first control module and the target control instruction sent by the second control module are received, if the activation state of the second control module is activated, the target control instruction is sent to the simulation scene module; the target control instruction is used for indicating the simulation scene module to update the simulation state of the vehicle in the simulation scene, and the second control module comprises a target function module corresponding to the function to be tested.
11. A simulation test apparatus, the apparatus comprising: an acquisition unit and an update unit;
the acquisition unit is used for acquiring test data of a function to be tested in a vehicle and an initial simulation signal of the vehicle; the initial simulation signal comprises initial simulation data corresponding to the function to be tested; the initial simulation signal is used for indicating that an initial control instruction of the vehicle in a simulation scene is generated according to the initial simulation data;
The updating unit is used for updating the initial simulation data in the initial simulation signal according to the test data of the function to be tested to obtain a target simulation signal; the target simulation signal comprises target simulation data after the initial simulation data is updated; the target simulation data are used for testing whether the function to be tested is normal or not.
12. An electronic device, comprising:
a processor;
a memory for storing the processor-executable instructions;
wherein the processor is configured to execute the instructions to implement the method of any one of claims 1 to 6.
13. A computer readable storage medium, characterized in that, when computer-executable instructions stored in the computer readable storage medium are executed by a processor of an electronic device, the electronic device is capable of performing the method of any one of claims 1 to 6.
CN202310458688.7A 2023-04-25 2023-04-25 Simulation test method, system, device, equipment and storage medium Pending CN116719244A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310458688.7A CN116719244A (en) 2023-04-25 2023-04-25 Simulation test method, system, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310458688.7A CN116719244A (en) 2023-04-25 2023-04-25 Simulation test method, system, device, equipment and storage medium

Publications (1)

Publication Number Publication Date
CN116719244A true CN116719244A (en) 2023-09-08

Family

ID=87874127

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310458688.7A Pending CN116719244A (en) 2023-04-25 2023-04-25 Simulation test method, system, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN116719244A (en)

Similar Documents

Publication Publication Date Title
EP3392792B1 (en) Evaluation device, evaluation system, and evaluation method
CN109032102A (en) Automatic driving vehicle test method, device, equipment and storage medium
EP3407545A1 (en) Evaluation device, evaluation system, and evaluation method
JP2017106911A (en) Device for supplying data to hardware-in-the-loop simulator
EP3598144A1 (en) Motion detection method, motion detection apparatus, and medium
CN115016323A (en) Automatic driving simulation test system and method
CN112311773B (en) Implementation method for intelligent automobile sensor interface system
CN113282069A (en) Chassis line control test method and device, computer equipment and storage medium
CN111199088A (en) Method and device for reproducing scene data
CN113133041B (en) Method and device for testing vehicle-to-vehicle communication function in dynamic interval train control vehicle
US11935341B2 (en) Data storage device and non-transitory tangible computer readable storage medium
CN113156480A (en) Vehicle positioning method, device, equipment and storage medium
CN116719244A (en) Simulation test method, system, device, equipment and storage medium
CN115657647A (en) Fault determination method, device, vehicle and storage medium
CN113268428B (en) Test method and system of fleet management system, storage medium and electronic device
CN116701096A (en) Cloud server testing method, virtual machine, vehicle machine system and storage medium
CN111782499B (en) Test case generation method and system
CN113625595A (en) Unmanned aerial vehicle deduction and fault diagnosis method and system
CN108733529B (en) Verification method and device for interleaving function of AXI (advanced extensible interface) cross switch
CN116136662B (en) Vehicle-mounted system simulation platform and testing method and device thereof
KR20070052540A (en) Virtual vehicle system and testing method for vehicle related service on telematics terminal
CN111475659B (en) Input data creation device and input data creation method
CN112289023B (en) Parking simulation test method and device for automatic driving and related equipment
CN115755832A (en) Vehicle function testing method and device, storage medium and vehicle function testing equipment
CN112585583B (en) Data processing method and device and intelligent vehicle

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