Test method, device, system and apparatus for air conditioner test case
By generating operation command messages and using electronic loads to simulate the air conditioning system response, combined with comparison with a list of expected feedback values, the problems of time-consuming, labor-intensive, and error-prone existing air conditioning testing systems have been solved, achieving efficient and automated testing.
Patent Information
- Application Number
- CN202611237672.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-14
- Publication Date
- 2026-11-06
AI Technical Summary
Existing air conditioning function test case systems rely on real vehicle loads and manual operation, resulting in time-consuming, labor-intensive, error-prone, and low accuracy testing.
By generating operation instruction messages based on a pre-set test case list and simulating the electrical response of the air conditioning system using an electronic load, a list of status feedback signals is generated and compared with a list of expected feedback values to achieve automated testing.
It achieves physical-level closed-loop feedback without the need for actual air conditioning unit load conditions, improving testing efficiency and accuracy, and reducing the skill requirements for automation testing personnel and maintenance costs.
Smart Images

Figure CN123048398A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of vehicle technology, and in particular to testing methods, equipment, systems and devices for air conditioning test cases. Background Technology
[0002] The existing air conditioner function test case system requires writing function test cases according to the air conditioner function specifications, and manually verifying each test case. Each time the software is iterated, the test cases need to be manually verified once, which is time-consuming, labor-intensive, and extremely costly. It is also very easy to make mistakes and has a low accuracy rate.
[0003] The above content is only used to help understand the technical solution of the present invention and does not represent an admission that the above content is prior art. Summary of the Invention
[0004] The main purpose of this application is to provide a testing method, equipment, system and apparatus for air conditioning test cases, which aims to solve the technical problem that the testing of vehicle air conditioning controllers in the prior art relies on actual vehicle load, manual operation and subjective judgment.
[0005] Firstly, this application provides a testing method for air conditioner test cases, which includes: Based on the preset test case list, the corresponding operation instruction message of the air conditioning test subsystem is generated, and the list of status feedback signals fed back by the air conditioning test subsystem based on the operation instruction message is obtained. The list of status feedback signals is compared with the list of expected feedback values in the list of preset test cases to obtain the comparison results. The list of expected feedback values includes a list of expected fixed values and a list of numerical ranges divided by index parity. The expected fixed values are the fixed values that need to be precisely matched at the corresponding index positions. The numerical ranges divided by index parity are the corresponding valid numerical ranges matched for the status feedback signals according to the index parity attribute to determine whether the status feedback signal is in a valid numerical range. The valid numerical ranges include the numerical ranges set for temperature-type signals and the numerical ranges set for status mode-type signals. The test results are output based on the comparison results, using a list of preset test cases.
[0006] Compared with related technologies, the testing method of this air conditioner test case has at least the following beneficial effects: It generates operation command messages corresponding to the air conditioner test subsystem based on a preset test case list, and obtains a list of status feedback signals fed back by the air conditioner test subsystem based on the operation command messages; it compares the list of status feedback signals with the list of expected feedback values in the preset test case list to obtain comparison results. The list of expected feedback values includes a list of expected fixed values and a list of numerical intervals divided by index parity. The expected fixed values are fixed values that need to be precisely matched at the corresponding index positions. The numerical intervals divided by index parity are valid numerical intervals matched to the status feedback signals according to the index parity attribute to determine whether the status feedback signals are in valid numerical intervals. Valid numerical intervals include the numerical intervals set for temperature-related signals and the numerical intervals set for status mode-related signals; it outputs the test results of the preset test case list based on the comparison results, realizing physical-level closed-loop feedback through electronic load without the need for a real air conditioner box load, and executing automated testing through test cases to output results.
[0007] In some possible implementations of the first aspect, the air conditioning test subsystem includes the air conditioner controller under test and an electronic load. Based on a preset test case list, it generates operation command messages corresponding to the air conditioning test subsystem and obtains a list of status feedback signals from the air conditioning test subsystem based on the operation command messages, including: Based on the preset test case list, generate the operation instruction message corresponding to the air conditioner controller under test, and send the operation instruction message to the air conditioner controller under test; Receive the status feedback signal fed back by the air conditioner controller under test after it outputs an electronic control signal to the electronic load in response to the operation command message; A list of state feedback signals is generated based on the state feedback signals.
[0008] In some possible implementations of the first aspect, an operation instruction message corresponding to the air conditioner controller under test is generated based on a preset test case list, and the operation instruction message is sent to the air conditioner controller under test; a status feedback signal is received after the air conditioner controller under test outputs an electronic control signal to the electronic load in response to the operation instruction message; a status feedback signal list is generated based on the status feedback signal, thereby realizing physical-level closed-loop feedback through the electronic load without the need for a real air conditioner box load, thus improving processing efficiency.
[0009] In some possible implementations of the first aspect, the step of generating an operation instruction message corresponding to the air conditioner controller under test based on a preset test case list and sending the operation instruction message to the air conditioner controller under test includes: By running a preset automated script engine, the target test case is automatically indexed and parsed from the preset test case list, and the preconditions, initialization values, memory values and operation step sequences in the target test case are extracted. Generate an initialization message based on preconditions, initialization values, and memory values; An initialization message is sent to the air conditioner controller under test to bring the air conditioner controller under test into the initial state; Based on the sequence of operation steps, the corresponding operation instruction message for the air conditioner controller under test is generated sequentially, and the operation instruction message is sent to the air conditioner controller under test.
[0010] In some possible implementations of the first aspect, a pre-defined automated script engine is run to automatically index and parse target test cases from a pre-defined test case list, extracting preconditions, initialization values, memory values, and operation step sequences from the target test cases. An initialization message is generated based on the preconditions, initialization values, and memory values. This initialization message is then sent to the air conditioner controller under test (UDT) to bring it into its initial state. Finally, operation instruction messages corresponding to the UDT are generated sequentially based on the operation step sequence and sent to the UDT. Testers do not need to master script programming; they can add, delete, modify, and query test cases by filling in natural language descriptions. The mapping between signal names and CAN signal objects, and the conversion from text to physical values, are all automatically completed by the script, greatly reducing the skill requirements for automation testers. Furthermore, when the air conditioner signal definition changes, only the header and mapping dictionary need to be modified; the main script remains unchanged, resulting in extremely low maintenance costs.
[0011] In some possible implementations of the first aspect, the electronic load includes a multi-subsystem coupled model and an electrothermal coupled model, and the state feedback signal includes a stepper motor feedback signal, a mechanical motion feedback signal, a refrigerant flow feedback signal, an electrical feedback signal, and a temperature feedback signal. The step of receiving the state feedback signal fed back by the air conditioner controller under test after outputting an electrical control signal to the electronic load in response to an operation command message includes: The system receives the electronic control signal output by the air conditioner controller under test in response to the operation command message and sends it to the multi-subsystem coupling model to obtain the stepper motor feedback signal, mechanical motion feedback signal and refrigerant flow feedback signal from the electronic load feedback. The system receives the electrical control signal output by the air conditioner controller under test in response to the operation command message and sends it to the electrothermal coupling model to obtain the electrical feedback signal and temperature feedback signal from the electronic load.
[0012] In some possible implementations of the first aspect, the air conditioner controller under test is received in response to the operation command message and outputs an electronic control signal to a multi-subsystem coupling model to obtain the stepper motor feedback signal, mechanical motion feedback signal and refrigerant flow feedback signal of the electronic load feedback; The system receives the electrical control signals from the air conditioner controller under test in response to the operation command message and outputs them to the electrothermal coupling model to obtain the electrical feedback signals and temperature feedback signals from the electronic load. By simulating the electrical control signals using models corresponding to different loads, the simulation efficiency and accuracy are improved.
[0013] In some possible implementations of the first aspect, the comparison results include a first comparison result and a second comparison result. The step of comparing the list of state feedback signals with the list of expected feedback values in the preset test case list to obtain the comparison results includes: The list of status feedback signals is compared with the expected fixed values in the list of expected feedback values in the list of preset test cases to obtain the first comparison result; The list of status feedback signals is compared with the numerical ranges divided by the odd and even indexes in the list of expected feedback values in the list of preset test cases to obtain a second comparison result.
[0014] In some possible implementations of the first aspect, the list of status feedback signals is compared with the expected fixed values in the expected feedback value list of the preset test case list to obtain a first comparison result; the list of status feedback signals is then compared with the numerical ranges divided by the parity index in the expected feedback value list of the preset test case list to obtain a second comparison result. A two-level judgment mechanism combining precise comparison of fixed values and checking range values according to index rules is implemented through hierarchical judgment logic with effective ranges. This significantly improves the reusability of test cases and the accuracy of judgments.
[0015] In some possible implementations of the first aspect, the step of comparing the values corresponding to the list of state feedback signals with the expected fixed values in the list of expected feedback values in the preset test case list to obtain the first comparison result includes: Identify the first index position of all values in the expected feedback value list that do not contain a valid range identifier; Determine the first actual value corresponding to the first index position from the list of status feedback signals; The first actual value is compared with the expected fixed value corresponding to the expected feedback value list to obtain the first comparison result.
[0016] In some possible implementations of the first aspect, the first index position that does not contain a valid range identifier is identified in the expected feedback value list; the first actual value corresponding to the first index position is determined from the status feedback signal list; the first actual value is compared with the expected fixed value corresponding to the expected feedback value list to obtain the first comparison result. A two-level judgment mechanism combining precise fixed value comparison and range value checking according to index rules is implemented through hierarchical judgment logic with valid range. This significantly improves the reusability of test cases and the accuracy of judgment.
[0017] In some possible implementations of the first aspect, the numerical interval of the index parity partition includes a first preset numerical interval and a second preset numerical interval. The step of comparing the numerical interval of the index parity partition with the expected feedback value list in the preset test case list to obtain a second comparison result includes: Identify the second index position of all valid range identifiers in the list of expected feedback values; Determine the second actual value corresponding to the second index position from the list of status feedback signals; When the index value corresponding to the second actual value is odd, determine whether the second actual value belongs to the first preset value range and obtain the first judgment result. The first preset value range is the range of gear values set according to the temperature signal. When the index value corresponding to the second actual value is even, it is determined whether the second actual value belongs to the second preset value range, and the second judgment result is obtained. The second preset value range is the gear value range set according to the state mode signal. The second comparison result is determined based on the first and second judgment results.
[0018] In some possible implementations of the first aspect, the second index position of all valid range identifiers in the expected feedback value list is identified; the second actual value corresponding to the second index position is determined from the status feedback signal list; when the index value corresponding to the second actual value is odd, it is determined whether the second actual value belongs to a first preset value range to obtain a first judgment result, where the first preset value range is a range of gear values set according to temperature-type signals; when the index value corresponding to the second actual value is even, it is determined whether the second actual value belongs to a second preset value range to obtain a second judgment result, where the second preset value range is a range of gear values set according to status mode-type signals; a second comparison result is determined based on the first and second judgment results. A two-level judgment mechanism combining fixed-value precise comparison and range value checking according to index rules is implemented through hierarchical judgment logic with valid ranges. This significantly improves the reusability of test cases and the accuracy of judgments.
[0019] Secondly, this application provides a testing device for air conditioner test cases. The testing device for air conditioner test cases includes: a memory, a processor, and a computer program stored in the memory and executable on the processor. The computer program is configured to implement the steps of the testing method for air conditioner test cases as described above.
[0020] Thirdly, this application provides a test system for air conditioning test cases. The test system includes test equipment for air conditioning test cases and an air conditioning test subsystem. The air conditioning test subsystem includes an on-board bus communication analyzer, an air conditioning controller under test, and an electronic load. The vehicle bus communication analyzer is used to receive operation instruction messages generated by the test equipment for air conditioning test cases and send the operation instruction messages to the air conditioning controller under test. The air conditioner controller under test is used to generate electrical control signals based on operation command messages and send the electrical control signals to the electronic load; An electronic load is used to simulate the electrical response of the vehicle air conditioning system based on electronic control signals and send the generated status feedback signal to the air conditioning controller under test. The air conditioning controller under test is used to send status feedback signals to the vehicle bus communication analyzer. The vehicle bus communication analyzer is a test device used to send status feedback signals to air conditioning test cases; The testing equipment is used to generate a list of status feedback signals based on the status feedback signals, and compare the list of status feedback signals with the list of expected feedback values in the preset test case list to obtain the comparison results; Test equipment is used to output test results based on a pre-set list of test cases according to the comparison results.
[0021] Compared with related technologies, the testing system of this air conditioning test case has at least the following beneficial effects: the vehicle bus communication analyzer receives the operation command message generated by the test equipment of the air conditioning test case and sends the operation command message to the air conditioning controller under test; the air conditioning controller under test generates an electronic control signal based on the operation command message and sends the electronic control signal to the electronic load; the electronic load simulates the electrical response of the vehicle air conditioning system according to the electronic control signal and sends the generated status feedback signal to the air conditioning controller under test; the air conditioning controller under test sends the status feedback signal to the vehicle bus communication analyzer; the vehicle bus communication analyzer sends the status feedback signal to the test equipment of the air conditioning test case; the test equipment generates a status feedback signal list based on the status feedback signal and compares the status feedback signal list with the expected feedback value list in the preset test case list to obtain the comparison result; the test equipment outputs the test results of the preset test case list based on the comparison result, realizing physical-level closed-loop feedback through the electronic load without the need for a real air conditioning box load, and performing automated testing through test cases to output results.
[0022] Fourthly, this application provides a testing apparatus for air conditioner test cases, the testing apparatus for air conditioner test cases comprising: The model processing module is used to generate operation instruction messages corresponding to the air conditioning test subsystem based on a preset test case list, and to obtain a list of status feedback signals fed back by the air conditioning test subsystem based on the operation instruction messages. The numerical comparison module is used to compare the list of status feedback signals with the list of expected feedback values in the preset test case list to obtain the comparison results. The list of expected feedback values includes a list of expected fixed values and a list of numerical intervals divided by index parity. The expected fixed values are fixed values that need to be precisely matched at the corresponding index positions. The numerical intervals divided by index parity are valid numerical intervals matched to the status feedback signals according to the index parity attribute to determine whether the status feedback signals are in valid numerical intervals. Valid numerical intervals include the numerical intervals set for temperature-type signals and the numerical intervals set for status mode-type signals. The results generation module is used to output test results based on the comparison results and a list of preset test cases.
[0023] Compared with related technologies, the testing device for this air conditioner test case has at least the following beneficial effects: It generates operation command messages corresponding to the air conditioner test subsystem based on a preset test case list, and obtains a list of status feedback signals from the air conditioner test subsystem based on the operation command messages; it compares the list of status feedback signals with the list of expected feedback values in the preset test case list to obtain a comparison result. The list of expected feedback values includes a list of expected fixed values and a list of numerical intervals divided by index parity. The expected fixed values are fixed values that need to be precisely matched at the corresponding index positions. The numerical intervals divided by index parity are valid numerical intervals matched to the status feedback signals according to the index parity attribute to determine whether the status feedback signals are within a valid numerical interval. The valid numerical intervals include the numerical intervals set for temperature-related signals and the numerical intervals set for status mode-related signals; based on the comparison result, it outputs the test results of the preset test case list, realizing physical-level closed-loop feedback through electronic load without the need for a real air conditioner box load, and executing automated testing through test cases to output results.
[0024] Fifthly, this application provides a computer program product, which includes a computer program that, when executed by a processor, implements the steps of the test method for the air conditioner test cases as described above. Attached Figure Description
[0025] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.
[0026] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0027] Figure 1 This is a flowchart illustrating an embodiment of the test method for air conditioner test cases in this application; Figure 2 This is a schematic diagram of a hardware-in-the-loop test system for an embodiment of the test method for air conditioner test cases in this application; Figure 3 This is a flowchart illustrating another embodiment of the test method for air conditioner test cases in this application; Figure 4 This is a flowchart illustrating another embodiment of the test method for air conditioner test cases in this application; Figure 5 A simplified flowchart illustrating the testing method for air conditioner test cases provided in this application embodiment; Figure 6 This is a schematic diagram of the module structure of the test device for the air conditioner test cases in the embodiments of this application; Figure 7 This is a schematic diagram of the hardware operating environment involved in the test method of the air conditioner test cases in this application embodiment.
[0028] The realization of the purpose, functional features and advantages of this application will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation
[0029] It should be understood that the specific embodiments described herein are merely illustrative of the technical solutions of this application and are not intended to limit this application.
[0030] To better understand the technical solution of this application, a detailed description will be provided below in conjunction with the accompanying drawings and specific implementation methods.
[0031] The main solution of this application embodiment is as follows: An operation instruction message corresponding to the air conditioning test subsystem is generated based on a preset test case list, and a list of status feedback signals fed back by the air conditioning test subsystem based on the operation instruction message is obtained; the list of status feedback signals is compared with the list of expected feedback values in the preset test case list to obtain a comparison result. The list of expected feedback values includes a list of expected fixed values and a list of numerical intervals divided by index parity. The expected fixed values are fixed values that need to be precisely matched at the corresponding index positions. The numerical intervals divided by index parity are valid numerical intervals matched to the status feedback signals according to the index parity attribute, to determine whether the status feedback signals are in valid numerical intervals. Valid numerical intervals include the numerical intervals set for temperature-related signals and the numerical intervals set for status mode-related signals; the test results of the preset test case list are output based on the comparison result.
[0032] In the process of developing the anti-pinch algorithm for the car window motor, the existing air conditioning function test case system writes function test cases according to the air conditioning function specifications, and manually verifies each test case. Each time the software is iterated, the test cases need to be manually verified once, which is time-consuming, labor-intensive and has a very high time cost. It is also very easy to make mistakes and has a low accuracy rate.
[0033] This application provides a solution that generates operation command messages corresponding to an air conditioning test subsystem based on a preset test case list, and obtains a list of status feedback signals fed back by the air conditioning test subsystem based on the operation command messages. The status feedback signal list is compared with the list of expected feedback values in the preset test case list to obtain a comparison result. The list of expected feedback values includes a list of expected fixed values and a list of numerical intervals divided by index parity. The expected fixed values are fixed values that need to be precisely matched at the corresponding index positions. The numerical intervals divided by index parity are valid numerical intervals matched to the status feedback signals according to the index parity attribute to determine whether the status feedback signals are within valid numerical intervals. Valid numerical intervals include the numerical intervals set for temperature-related signals and the numerical intervals set for status mode-related signals. Based on the comparison result, the test results of the preset test case list are output. This achieves physical-level closed-loop feedback through electronic load without the need for a real air conditioning unit load, and executes automated testing through test cases to output results.
[0034] The executing entity in this embodiment can be a computing service device with data processing, network communication, and program execution functions, such as an in-vehicle computer, tablet computer, personal computer, or mobile phone, or an electronic device capable of performing the above functions, such as a test device for air conditioning test cases. This embodiment does not specifically limit it in this way. The following uses a test device for air conditioning test cases as an example to describe this embodiment and the following embodiments.
[0035] This application provides a testing method for air conditioner test cases, referring to... Figure 1 , Figure 1 This is a flowchart illustrating a feasible embodiment of the testing method for the air conditioner test cases of this application.
[0036] In this embodiment, the testing method for air conditioner test cases includes steps S10 to S30: Step S10: Generate operation instruction messages corresponding to the air conditioning test subsystem based on the preset test case list, and obtain the status feedback signal list of the air conditioning test subsystem based on the operation instruction messages; In this embodiment, the air conditioning test system consists of test equipment for air conditioning test cases (such as a PC host computer), an air conditioning test subsystem, and an air conditioning test subsystem. The air conditioning test subsystem includes an on-board bus communication analyzer, an air conditioner controller under test, and electronic loads. In this embodiment, the hardware execution level consists of a PC host computer, an on-board analyzer (CANoe or TSMaster), an air conditioner controller under test, and electronic loads (programmable solenoid valves, damper motors simulating the air conditioning unit, various sensors, etc.). For example, refer to... Figure 2 , Figure 2 This diagram illustrates a hardware-in-the-loop (HIL) testing system. To verify test cases for hardware-in-the-loop (HIL) testing of the controller software without actual vehicle thermal management system components, a pre-built HIL testing environment is established. The hardware includes a host computer, an onboard bus communication analyzer, the air conditioning controller under test (UDT), electronic loads, and a power supply. By establishing a simulated air conditioning unit operating environment, the electronic loads can run in a real-time machine, receiving electronic control signals (such as hardwired drive, PWM, LIN, CAN commands, etc.) output by the air conditioning controller, calculating the physical response of the controlled object in real time, and feeding back sensor signals (temperature, pressure, position, etc.) to the UDT, forming a closed-loop verification environment. The specific load configuration can be adjusted according to the software integration level of the ECU under test (e.g., integrating only the temperature of each damper sensor, or integrating the blower & compressor speed, or the solenoid valve opening, etc., the electronic load configuration can be adjusted accordingly based on the current software integration combination). The pre-designed test case list consists of multiple test cases pre-written according to the functional specifications of the air conditioning system. Each test case can be stored in an Excel spreadsheet. Each test case includes at least a test case ID, test function description, preconditions and modes, memory values, initialization values, operation step sequence, and expected feedback list. Preconditions refer to the functions that the vehicle can and cannot perform in different modes. Memory values refer to the temperature corresponding to the last time the air conditioning was turned on. Initialization values refer to the parameter values corresponding to adjusting the air conditioning to the initial state. A multi-bus test environment supporting Python scripts (multi-buses include but are not limited to CAN, LIN, FlexRay, and Ethernet) is run. By reading the pre-designed Excel test case list, the system automatically completes the air conditioning controller's memory pre-setting, power mode switching, operation command sequence sending, feedback signal acquisition, and multi-dimensional expected value comparison, ultimately outputting and recording the PASS / FAIL result.
[0037] In some feasible implementations, step S10 further includes: generating an operation instruction message corresponding to the air conditioner controller under test based on a preset test case list, and sending the operation instruction message to the air conditioner controller under test; receiving a status feedback signal fed back by the air conditioner controller under test after outputting an electronic control signal to the electronic load in response to the operation instruction message; and generating a status feedback signal list based on the status feedback signal.
[0038] In this embodiment, the air conditioning test subsystem includes an air conditioning controller under test and an electronic load. The preset test case list consists of multiple test cases pre-written according to the air conditioning system functional specifications. Each test case can be stored in an Excel spreadsheet. Each test case includes at least a test case ID, test function description, preconditions and modes, memory values, initialization values, operation step sequence, and expected feedback list. Preconditions refer to the functions that the vehicle can and cannot perform in different modes. Memory values refer to the temperature corresponding to the last time the air conditioning was turned on. Initialization values refer to the parameter values corresponding to adjusting the air conditioning to the initial state.
[0039] By building a hardware-in-the-loop testing environment, operation instruction messages corresponding to the air conditioner controller under test are generated based on the test cases stored in the host computer. When the air conditioner controller receives the instruction message, it determines the electrical control signal fed back by the air conditioner controller under test through model calculation.
[0040] For example, the electronic control signals include at least one of hard-wired drive signals, PWM signals, LIN bus signals, and CAN bus signals. The electrical response of the vehicle air conditioning unit is simulated using a pre-built electronic load model and the aforementioned electronic control signals to obtain a list of state feedback signals, wherein the list of state feedback signals includes at least one state feedback signal. The electronic load model is used to receive the electronic control signals output by the air conditioning controller under test, calculate the simulated physical response based on the electronic control signals, and feed back the simulated sensor signals to the air conditioning controller under test.
[0041] In some feasible implementations, the step of generating operation instruction messages corresponding to the air conditioner controller under test based on a preset test case list and sending the operation instruction messages to the air conditioner controller under test includes: automatically indexing and parsing target test cases from the preset test case list by running a preset automated script engine, extracting preconditions, initialization values, memory values, and operation step sequences from the target test cases; generating initialization messages based on preconditions, initialization values, and memory values; sending the initialization messages to the air conditioner controller under test to enable the air conditioner controller under test to enter the initial state; and sequentially generating operation instruction messages corresponding to the air conditioner controller under test based on the operation step sequence and sending the operation instruction messages to the air conditioner controller under test.
[0042] In this embodiment, by running a preset automated script engine on the host computer, target test cases are indexed and read from a preset test case table. The preconditions, initialization values, memory values, and operation step sequences in the target test cases are parsed. An initialization message is generated based on the preconditions, initialization values, and memory values, and is sent to the air conditioner controller under test (DUT) via the vehicle bus communication analyzer to bring the DUT into its initial state, ensuring successful completion of subsequent tests. Operation command messages are then sent sequentially to the DUT via the vehicle bus communication analyzer according to the operation step sequence, and the operation command messages are then transmitted to the DUT.
[0043] For example, an automation script engine can be implemented using the Python programming language, which can call an Excel spreadsheet to automatically index and parse test cases.
[0044] Step S20: Compare the list of status feedback signals with the list of expected feedback values in the preset test case list to obtain the comparison results; In this embodiment, the expected feedback value list includes a list of expected fixed values and a list of numerical intervals divided by index parity. The expected fixed value is a fixed value that needs to be precisely matched at the corresponding index position. The numerical intervals divided by index parity are valid numerical intervals that are matched to the status feedback signal according to the index parity attribute, so as to determine whether the status feedback signal is in a valid numerical interval. The valid numerical intervals include the range of values set for temperature-type signals and the range of values set for status mode-type signals.
[0045] For example, the expected feedback value list includes fixed value items and valid range identifier items. The valid range identifier items indicate that the corresponding state signal does not need to match precisely, but only needs to fall within a preset value range to meet the judgment condition. A first comparison result and a second comparison result are obtained by comparing the expected feedback value list (including fixed value items and valid range identifier items) in the state feedback signal list with the list of expected feedback values in the preset test case list.
[0046] Step S30: Output the test results of the preset test case list based on the comparison results.
[0047] In this embodiment, the comparison results include a first comparison result and a second comparison result. Based on the first and second comparison results, the test results for the preset test cases are output, including test pass and test fail.
[0048] This embodiment generates operation command messages corresponding to the air conditioning test subsystem based on a preset test case list, and obtains a list of status feedback signals fed back by the air conditioning test subsystem based on the operation command messages. The list of status feedback signals is compared with the list of expected feedback values in the preset test case list to obtain a comparison result. The list of expected feedback values includes a list of expected fixed values and a list of value intervals divided by index parity. The expected fixed values are fixed values that need to be precisely matched at the corresponding index positions. The value intervals divided by index parity are valid value intervals matched to the status feedback signals according to the index parity attribute to determine whether the status feedback signals are within valid value intervals. Valid value intervals include the value intervals set for temperature-related signals and the value intervals set for status mode-related signals. Based on the comparison result, the test results of the preset test case list are output, realizing physical-level closed-loop feedback through electronic load without the need for a real air conditioning unit load, and executing automated testing through test cases to output results.
[0049] In one feasible embodiment of this application, content that is the same as or similar to the above embodiments can be referred to the above description, and will not be repeated hereafter. Based on this, please refer to... Figure 3 The step of receiving a status feedback signal from the air conditioner controller under test after it outputs an electronic control signal to the electronic load in response to an operation command message includes: Step S1021: Receive the electrical control signal output by the air conditioner controller under test in response to the operation command message into the multi-subsystem coupling model to obtain the stepper motor feedback signal, mechanical motion feedback signal, and refrigerant flow feedback signal from the electronic load feedback.
[0050] In this embodiment, the electronic load includes a multi-subsystem coupling model and an electrothermal coupling model. The state feedback signals include stepper motor feedback signals, mechanical motion feedback signals, refrigerant flow feedback signals, electrical feedback signals, and temperature feedback signals. By determining the load type corresponding to the electronic control signal, the electronic control signal is input into the multi-subsystem coupling model to simulate the electrical response of the vehicle air conditioning unit, thereby obtaining the stepper motor feedback signal, mechanical motion feedback signal, and refrigerant flow feedback signal. The load types include stepper motor-type loads and resistive loads. When the electronic control signal is a stepper motor-type load, the multi-subsystem coupling model is selected and invoked. This multi-subsystem coupling model is a physical simulation model constructed from the models corresponding to the electrical subsystem, mechanical subsystem, and fluid subsystem. The electrical subsystem model is used to calculate the phase current based on the stepper pulse signal output by the air conditioning controller under test. The mechanical subsystem model is used to calculate the electromagnetic torque based on the phase current and the rotor angular displacement based on the difference between the electromagnetic torque and the load torque. The rotor angular displacement corresponds to the valve needle position. The fluid subsystem model is used to query a preset opening-flow characteristic curve based on the valve needle position to obtain the refrigerant flow rate value.
[0051] When the electronic control signal is a resistive load, the electrothermal coupling model is selected. This model is constructed from an electrical model and a thermal model. The electrical model calculates the electrical power based on the real-time voltage and the resistance value changing with temperature. The thermal model calculates the change in core temperature of the resistive load over time based on the heat balance equation, where electrical power is treated as a heat source and ambient temperature as a dissipation term. Different models are used to process the electronic control signal depending on the load type. When the load type of the electronic control signal is a stepper motor type load, the multi-subsystem coupling model is used to simulate the electrical response of the vehicle air conditioning unit, obtaining the stepper motor feedback signal, mechanical motion feedback signal, and refrigerant flow feedback signal.
[0052] For example, when the physical component is a stepper motor-type load, the preferred stepper motor-type load is an electronic expansion valve (EXV), which controls the valve needle position via a stepper motor to regulate refrigerant flow. The simulation model can be decomposed into three subsystems: electrical, mechanical, and fluid. The electrical subsystem converts the stepper pulses output by the air conditioning controller into phase currents of the motor. Its dynamic characteristics can be approximated by an RL circuit (resistor-inductor circuit): V(t) = Ldi(t) / dt + R i(t) + Vemf(t); Where V(t): applied phase voltage, i(t): phase current, L: coil inductance, R: coil resistance, Vemf(t): back electromotive force generated by motion.
[0053] The mechanical subsystem is used to convert electromagnetic force into mechanical motion. The mechanical dynamics of a stepper motor can be simplified as follows: Jd2θ(t) / dt2+Bdθ(t) / dt+Tload=Te(θ,i); Where θ: rotor angular displacement (i.e., valve needle position), J: rotor moment of inertia, B: damping coefficient, Tload: load torque (caused by refrigerant pressure difference), Te: electromagnetic torque, which is a function of current i and rotor position θ.
[0054] The fluid subsystem is used to calculate the refrigerant flow rate Q based on the valve needle position θ, where the relationship between the valve needle position θ and the refrigerant flow rate l can be described by a lookup table function, which can usually be built based on the opening-flow characteristic curve provided by the valve manufacturer.
[0055] For example, when the load type of the electronic control signal is a stepper motor type load, the electronic control signal is input into a multi-subsystem coupling model to simulate the electrical response of the vehicle air conditioning unit, and the stepper motor feedback signal, mechanical motion feedback signal and refrigerant flow feedback signal are obtained.
[0056] Step S1022: Receive the electrical control signal output by the air conditioner controller under test in response to the operation command message and send it to the electrothermal coupling model to obtain the electrical feedback signal and temperature feedback signal from the electronic load.
[0057] In this embodiment, the electrical control signal output by the air conditioner controller under test in response to the operation command message is received. This signal is then input into the electrothermal coupling model to simulate the electrical response of the vehicle air conditioning unit, obtaining electrical feedback signals and temperature feedback signals. When the electrical control signal is a resistive load, a PTC heater is preferred, as it has a self-limiting temperature characteristic where resistance increases with temperature. The electronic load model uses an electrothermal coupling model. The electrical model calculates the electrical power based on the real-time voltage and the resistance value that changes with temperature, expressed as: P(t) = V(t)² / R(T); Where R(T) is the resistance that varies with temperature, and V(t) is the voltage.
[0058] The thermal model calculates the temperature rise process of the PTC heater core based on the heat balance equation, and its expression is as follows: C_thdT(t) / dt=P(t) K (T(t) Tamb); Where C_th: heat capacity, T(t): PTC core temperature, Tamb: ambient temperature, K: thermal conductivity, the core temperature T(t) calculated by the thermal model is used to simulate the feedback of the temperature sensor.
[0059] For example, when the load type of the electronic control signal is a resistive load, the electrical feedback signal and temperature feedback signal are obtained by simulating the electrical response of the vehicle air conditioning unit in the electrothermal coupling model through inputting the electronic control signal. In this embodiment, the test equipment generates a list of status feedback signals based on the stepper motor feedback signal, mechanical motion feedback signal, refrigerant flow feedback signal, electrical feedback signal, and temperature feedback signal.
[0060] A state feedback signal list is constructed using the analog sensor signals output by the two models described above. This is achieved by converting the physical quantities output by the models into analog sensor signals, which are then fed back to the ECU to form a closed-loop control. The analog physical quantities calculated by the physical response layer are transmitted to the sensor signal feedback layer. The sensor signal feedback layer converts the analog physical quantities into electrical signals that the air conditioner controller under test can recognize, and outputs them to the signal acquisition terminal of the air conditioner controller under test through a hardware interface, forming a closed-loop control circuit.
[0061] In practice, when the simulated physical quantity is temperature, the sensor signal feedback layer converts the temperature into the corresponding resistance or voltage value according to the preset NTC thermistor temperature-resistance characteristic table; when the simulated physical quantity is position or angle, the sensor signal feedback layer converts the position or angle into the corresponding simulated voltage signal (such as 0.5V~4.5V) and outputs it.
[0062] This embodiment determines the load type corresponding to the electronic control signal; based on the load type, the electronic control signal is input into a multi-subsystem coupling model to simulate the electrical response of the vehicle air conditioning unit, obtaining stepper motor feedback signals, mechanical motion feedback signals, and refrigerant flow feedback signals; the electronic control signal is input into an electrothermal coupling model to simulate the electrical response of the vehicle air conditioning unit, obtaining electrical feedback signals and temperature feedback signals; a state feedback signal list is generated based on the stepper motor feedback signal, mechanical motion feedback signal, refrigerant flow feedback signal, electrical feedback signal, and temperature feedback signal; the electronic control signal is generated based on a preset test case list; the state feedback signal list is compared with the expected feedback value list in the preset test case list to obtain the comparison result; based on the comparison result, the test results of the preset test case list are output. This achieves physical-level closed-loop feedback through electronic load models corresponding to different loads without requiring a real air conditioning unit load, improving simulation efficiency and accuracy, and executing automated testing through test cases to output results.
[0063] In one feasible embodiment of this application, content that is the same as or similar to the above embodiments can be referred to the above description, and will not be repeated hereafter. Based on this, please refer to... Figure 4 Step S20 may include steps S201 to S202: Step S201: Compare the list of status feedback signals with the expected fixed values in the list of expected feedback values in the preset test case list to obtain the first comparison result; The first comparison result is obtained by comparing the 28 state signal values in the state feedback signal list with the expected fixed values in the expected feedback value list. The 28 state signal values are arranged in the order of (a0~a27).
[0064] In some feasible implementations, step S201 may include: steps S2011~S2013: Step S2011: Identify the first index positions in the expected feedback value list that do not contain a valid range identifier; For example, since the order of the 28 expected signals in the expected feedback list is fixed, and the order of the tested signals also corresponds to the order in the expected list, the first index position of all signals in the expected feedback value list that do not contain a valid range identifier is determined first, so that the corresponding actual value can be directly found from the status feedback list later. The first index position can be determined according to the signal number, such as signal numbers A0, A2, A4, etc.
[0065] Step S2012: Determine the first actual value corresponding to the first index position from the list of status feedback signals; For example, after determining all first index positions that do not contain valid range identifiers, the actual signal value in the status feedback signal list is determined based on the signal number corresponding to the first index position. Since the signal order in the status feedback signal list corresponds one-to-one with the signal order in the expected feedback list, determining the corresponding first actual value through the first index position avoids repeated traversal and improves processing efficiency.
[0066] Step S2013: Compare the first actual value with the expected fixed value corresponding to the expected feedback value list to obtain the first comparison result.
[0067] The first actual value is compared with the corresponding expected fixed value in the expected feedback value list to obtain the first comparison result. That is, the first comparison result is obtained by making an exact equality judgment on the fixed value parts. If any actual value is not equal to the corresponding expected fixed value, the comparison result of the test case is determined to be unsuccessful.
[0068] Step S202: Compare the list of status feedback signals with the numerical ranges divided by the odd and even indexes in the list of expected feedback values in the preset test case list to obtain a second comparison result; For example, a second comparison result is obtained by comparing the 28 state signal values contained in the state feedback signal list with the numerical ranges divided by the parity index in the expected feedback value list.
[0069] In some feasible implementations, step S202 may include: steps S2021~S2023: The numerical intervals for index parity division include a first preset numerical interval and a second preset numerical interval.
[0070] Step S2021: Identify the second index position of all valid range identifiers in the expected feedback value list; The first preset value range is a range of gear values set based on temperature-related signals, and the second preset value range is a range of gear values set based on status mode-related signals. Since the order of the 28 expected signals in the expected feedback list is fixed, and the order of the tested signals also corresponds to the order in the expected feedback list, the second index position of all valid range identifiers in the expected feedback value list is determined first to facilitate direct retrieval of the corresponding actual value from the status feedback list later. The second index position can be determined based on the signal number, such as A0, A1, A2, etc.
[0071] Step S2022: Determine the second actual value corresponding to the second index position from the list of status feedback signals; After determining the second index position of all valid range identifiers, the actual value of the signal in the status feedback signal list is determined according to the signal number corresponding to the second index position. Since the signal order in the status feedback signal list corresponds one-to-one with the signal order in the expected feedback list, determining the corresponding second actual value through the second index position avoids repeated traversal and improves processing efficiency.
[0072] Step S2023: When the index value corresponding to the second actual value is odd, determine whether the second actual value belongs to the first preset value range and obtain the first judgment result; Specifically, for items in the expected feedback value list that contain a valid range identifier, the system determines whether the second actual value falls within a preset corresponding numerical range based on the parity of its index in the state feedback signal value list. This mechanism is derived from the design patterns of real vehicle air conditioning signals, where even-numbered positions are mostly temperature-related displays (range 0-9), and odd-numbered positions are mostly fan speed or automatic mode displays (range 0-7). The "KEEP" marker in the table is uniformly mapped to "valid range," and the script automatically adapts to the range based on index parity. This allows a single test case to adaptively verify multiple automatic states, significantly improving the reusability and accuracy of test cases.
[0073] For example, the first preset numerical range is the integer range of 0 to 7, and the second preset numerical range is the integer range of 0 to 9. When the index is odd, it is determined whether the second actual value falls within the integer range of 0 to 7, and the first determination result is obtained.
[0074] Step S2024: When the index value corresponding to the second actual value is even, determine whether the second actual value belongs to the second preset value range and obtain the second determination result. For example, the second preset numerical range is the integer range of 0 to 9. When the index is even, it is determined whether the second actual value falls within the integer range of 0 to 9, and a second determination result is obtained.
[0075] Step S2025: Determine the second comparison result based on the first judgment result and the second judgment result.
[0076] If the actual value of any valid range verification item does not fall within the corresponding preset value range, the comparison result of the test case is determined to be unsuccessful.
[0077] For example, for signals whose expected values include the "valid range" marker, a two-level judgment mechanism is implemented, combining precise comparison of fixed values with checking range values according to index rules. In conventional automated testing, the expected value can only be a single fixed value. However, in air conditioning HMIs (Human-Machine Interfaces), some states (such as automatic fan speed and automatic mode display) only need to be within a reasonable range after specific operations (such as automatic fan speed display 0~7 and automatic temperature setting 0~9), without demanding specific values. This application solves the problem through the following steps: a) Identifying the index positions of all values within the "valid range" from the expected list; b) Splitting the actual signal value list by index into: a valid_list of actual values corresponding to the valid range indexes, and an invalid_list of actual values corresponding to the remaining fixed value indices; c) Performing an element-by-element equality comparison between invalid_list and the corresponding fixed expected value, and directly determining failure if any value is not equal; d) Applying different numerical range checks to the values in valid_list according to the parity of their indices in the original 28 signal lists—all signal values within the valid range and at even index positions (0, 2, 4…) must be between 0 and 9, and all signal values at odd index positions (1, 3, 5…) must be between 0 and 7; e) Only when the fixed values are equal and all range values simultaneously satisfy their respective parity intervals is the operation deemed to have passed.
[0078] This embodiment determines the load type corresponding to the electronic control signal; based on the load type, the electronic control signal is input into a multi-subsystem coupling model to simulate the electrical response of the vehicle air conditioning unit, obtaining stepper motor feedback signals, mechanical motion feedback signals, and refrigerant flow feedback signals; the electronic control signal is input into an electrothermal coupling model to simulate the electrical response of the vehicle air conditioning unit, obtaining electrical feedback signals and temperature feedback signals; a state feedback signal list is generated based on the stepper motor feedback signal, mechanical motion feedback signal, refrigerant flow feedback signal, electrical feedback signal, and temperature feedback signal; the state feedback signal list is compared with the expected fixed value in the expected feedback value list in the preset test case list to obtain a first comparison result; the state feedback signal list is compared with a preset value range in the expected feedback value list in the preset test case list to obtain a second comparison result. The preset value range is a value range pre-divided according to the parity of the index. A two-level judgment mechanism combining precise comparison of fixed values and checking of range values according to the index rule is implemented through hierarchical judgment logic with effective range. It significantly improves the reusability and accuracy of test cases, and enables physical-level closed-loop feedback through electronic load models corresponding to different loads without the need for actual air conditioning unit load. This improves simulation efficiency and accuracy, and allows automated testing to be performed through test cases, outputting results.
[0079] For example, to help understand the implementation flow of the test method for air conditioner test cases obtained in this embodiment in conjunction with the above embodiments, please refer to... Figure 5 , Figure 5 A simplified flowchart of a testing method for air conditioner test cases is provided, specifically: The first step, S1, involves acquiring test data and generating a test case list through structured processing, which is then stored in an Excel spreadsheet. The "TestCase_HMI" worksheet in the Excel workbook is read, and all test case IDs and their corresponding data areas are parsed out. The memory settings, initial values, operation step sequences, and expected feedback value lists for each test case are extracted. Complex test cases for the air conditioning HMI are abstracted into a structured table, and automatic mapping from natural language descriptions to physical signal values is implemented. Each column in the Excel table corresponds to an air conditioning status signal (such as temperature setting, airflow, mode, etc.), and the cell content uses engineer-readable text (e.g., "ON", "OFF", "BlowFace", "Lv5", "HI", "KEEP", etc.). The script has a built-in mapping dictionary: Switch type: "ON"→2, "OFF"→1, "Initial"→0; Wind direction mode: "BlowFace"→1, "BlowFace&Foot"→2...; Air volume level: "Lv1"~"Lv9"→1~9, "LO"→16, "HI"→31; Cyclic mode: "Internal"→1, "External"→2, "Auto"→0; Special marker: "KEEP" is mapped to "Valid Range", indicating that the signal does not need to be precisely matched, but only needs to fall within a reasonable range. Through the above mapping, the text list read directly from the Excel row is converted into a list of values that can be set for CAN signals. At the same time, the signal name in the header (such as "DrTempDisp") is automatically associated with the predefined CAN signal object (containing message ID, start bit, length, resolution, offset), realizing the conversion of "signal name → signal object → message byte array", without the need to manually write signal packaging code. The second step is the test data parsing and mapping process. Step S2 executes test cases, performing the following steps sequentially for each case: IGN power-on; sending a Memory setting message via the CAN bus to simulate writing the air conditioner controller's memory value; powering off and then on again to restore the controller to its memory state; selecting different initialization procedures based on the mode specified in the test case (e.g., OFF mode or other modes) and sending initial state setting messages; executing operation steps in sequence, each operation corresponding to a CAN signal setting message (ID 387 or 381), and waiting for the state to stabilize after sending; receiving air conditioner status feedback messages in real time from the CAN bus and parsing out 28 status signal values (a0~a27). Step S3 automatically compares the expected results, comparing the collected actual status signal list with the expected list of test cases. The expected list contains fixed values and a "valid range" marker (corresponding to "KEEP" or a random valid range in the original table). The comparison is divided into two parts: the fixed value part performs an exact equality judgment; the "effective range" part checks whether it falls into the preset value range (odd index 0~9, even index 0~7) according to the parity of its index in the signal list.Step S4: Output the test results. If all checks pass, record the test case as PASS; if any step fails, record FAIL. Write the results to a text file and update the pass / fail counter in the graphical interface.
[0080] It should be noted that the above examples are only for understanding this application and do not constitute a limitation on the testing methods of the air conditioner test cases in this application. Any simple modifications based on this technical concept are within the protection scope of this application.
[0081] This application also provides a test system for air conditioning test cases, characterized in that the test system includes test equipment for air conditioning test cases and an air conditioning test subsystem, the air conditioning test subsystem including an on-board bus communication analyzer, an air conditioning controller under test, and an electronic load; The vehicle bus communication analyzer is used to receive operation instruction messages generated by the test equipment for air conditioning test cases and send the operation instruction messages to the air conditioning controller under test. The air conditioner controller under test is used to generate electrical control signals based on operation command messages and send the electrical control signals to the electronic load; An electronic load is used to simulate the electrical response of the vehicle air conditioning system based on electronic control signals and send the generated status feedback signal to the air conditioning controller under test. The air conditioning controller under test is used to send status feedback signals to the vehicle bus communication analyzer. The vehicle bus communication analyzer is a test device used to send status feedback signals to air conditioning test cases; The testing equipment is used to generate a list of status feedback signals based on the status feedback signals, and compare the list of status feedback signals with the list of expected feedback values in the preset test case list to obtain the comparison results; Test equipment is used to output test results based on a pre-set list of test cases according to the comparison results.
[0082] This application also provides a testing device for air conditioner test cases, please refer to... Figure 6 The test apparatus for air conditioner test cases includes: The model processing module 10 is used to generate operation instruction messages corresponding to the air conditioning test subsystem based on a preset test case list, and to obtain a list of status feedback signals fed back by the air conditioning test subsystem based on the operation instruction messages. The numerical comparison module 20 is used to compare the list of state feedback signals with the list of expected feedback values in the preset test case list to obtain a comparison result. The list of expected feedback values includes a list of expected fixed values and a list of numerical intervals divided by index parity. The expected fixed values are fixed values that need to be precisely matched at the corresponding index positions. The numerical intervals divided by index parity are valid numerical intervals matched to the state feedback signals according to the index parity attribute to determine whether the state feedback signals are within valid numerical intervals. Valid numerical intervals include the numerical intervals set for temperature-type signals and the numerical intervals set for state mode-type signals; and The result generation module 30 is used to output test results based on the comparison results and a list of preset test cases.
[0083] In some feasible implementations, the air conditioning test subsystem includes an air conditioner controller under test, an electronic load, and a model processing module 10, which is also used to generate operation instruction messages corresponding to the air conditioner controller under test based on a preset test case list, and send the operation instruction messages to the air conditioner controller under test. Receive the status feedback signal fed back by the air conditioner controller under test after it outputs an electronic control signal to the electronic load in response to the operation command message; and A list of state feedback signals is generated based on the state feedback signals.
[0084] In some feasible implementations, the model processing module 10 is also used to automatically index and parse target test cases from a preset test case list by running a preset automated script engine, and extract the preconditions, initialization values, memory values and operation step sequences in the target test cases; Generate an initialization message based on preconditions, initialization values, and memory values; An initialization message is sent to the air conditioner controller under test to put it into its initial state; and Based on the sequence of operation steps, the corresponding operation instruction message for the air conditioner controller under test is generated sequentially, and the operation instruction message is sent to the air conditioner controller under test.
[0085] In some feasible implementations, the electronic load includes a multi-subsystem coupled model and an electrothermal coupled model, and the state feedback signals include stepper motor feedback signals, mechanical motion feedback signals, refrigerant flow feedback signals, electrical feedback signals, and temperature feedback signals. The model processing module 10 is also used to receive the electrical control signals output by the air conditioner controller under test in response to the operation command message to the multi-subsystem coupled model, so as to obtain the stepper motor feedback signals, mechanical motion feedback signals, and refrigerant flow feedback signals from the electronic load. The system receives the electrical control signal output by the air conditioner controller under test in response to the operation command message and sends it to the electrothermal coupling model to obtain the electrical feedback signal and temperature feedback signal from the electronic load.
[0086] In some feasible implementations, the comparison results include a first comparison result and a second comparison result. The numerical comparison module 20 is further used to compare the list of state feedback signals with the expected fixed values in the expected feedback value list of the preset test case list to obtain the first comparison result; and The list of status feedback signals is compared with the numerical ranges divided by the odd and even indexes in the list of expected feedback values in the list of preset test cases to obtain a second comparison result.
[0087] In some feasible implementations, the numerical comparison module 20 is also used to identify all first index positions in the list of expected feedback values that do not contain a valid range identifier; Determine the first actual value corresponding to the first index position from the list of state feedback signals; and The first actual value is compared with the expected fixed value corresponding to the expected feedback value list to obtain the first comparison result.
[0088] In some feasible implementations, the numerical ranges for index parity division include a first preset numerical range and a second preset numerical range. The numerical comparison module 20 is also used to identify the second index positions of all valid range identifiers in the expected feedback value list. Determine the second actual value corresponding to the second index position from the list of status feedback signals; When the index value corresponding to the second actual value is odd, it is determined whether the second actual value belongs to the first preset value range to obtain the first determination result. The first preset value range is a range of gear values set according to temperature signals; and When the index value corresponding to the second actual value is even, it is determined whether the second actual value belongs to the second preset value range, and the second judgment result is obtained. The second preset value range is the gear value range set according to the state mode signal. The second comparison result is determined based on the first and second judgment results.
[0089] The air conditioning test case testing device provided in this application, employing the air conditioning test case testing method in the above embodiments, can improve the technical problem that vehicle air conditioning controller testing relies on actual vehicle load, manual operation, and subjective judgment. Compared with the prior art, the beneficial effects of the air conditioning test case testing device provided in this application are the same as the beneficial effects of the air conditioning test case testing method provided in the above embodiments, and other technical features in the air conditioning test case testing device are the same as those disclosed in the methods of the above embodiments, and will not be repeated here.
[0090] This application provides a testing device for air conditioner test cases. The testing device for air conditioner test cases includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the testing method for air conditioner test cases in the above embodiment one.
[0091] The following is for reference. Figure 7 The diagram illustrates a structural schematic of a test device suitable for implementing air conditioner test cases in the embodiments of this application. The test device for the air conditioner test cases in the embodiments of this application may include, but is not limited to, mobile terminals such as mobile phones, laptops, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (Portable Application Description), PMPs (Portable Media Players), in-vehicle terminals (e.g., in-vehicle navigation terminals), and fixed terminals such as digital TVs and desktop computers. Figure 7 The test equipment for the air conditioner test cases shown is merely an example and should not impose any limitations on the functionality and scope of use of the embodiments of this application.
[0092] like Figure 7As shown, the test equipment for air conditioning test cases may include a processing unit 1001 (e.g., a central processing unit, a graphics processing unit, etc.), which can perform various appropriate actions and processes according to a program stored in ROM (Read Only Memory) 1002 or a program loaded from storage device 1003 into RAM (Random Access Memory) 1004. RAM 1004 also stores various programs and data required for the operation of the test equipment for air conditioning test cases. The processing unit 1001, ROM 1002, and RAM 1004 are interconnected via bus 1005. Input / output (I / O) interface 1006 is also connected to the bus. Typically, the following systems can be connected to I / O interface 1006: input devices 1007 including, for example, touch screens, touchpads, keyboards, mice, image sensors, microphones, accelerometers, gyroscopes, etc.; output devices 1008 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; storage devices 1003 including, for example, magnetic tapes, hard disks, etc.; and communication devices 1009. Communication device 1009 allows the test equipment for air conditioning test cases to communicate wirelessly or wiredly with other devices to exchange data. Although the figure shows test equipment for air conditioning test cases with various systems, it should be understood that implementation or possession of all the systems shown is not required. More or fewer systems may be implemented alternatively.
[0093] Specifically, according to the embodiments disclosed in this application, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments disclosed in this application include a computer program product comprising a computer program carried on a computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via a communication device, or installed from storage device 1003, or installed from ROM 1002. When the computer program is executed by processing device 1001, it performs the functions defined in the methods of the embodiments disclosed in this application.
[0094] The air conditioning test case testing equipment provided in this application, employing the air conditioning test case testing method described in the above embodiments, can improve the technical problem that vehicle air conditioning controller testing relies on actual vehicle load, manual operation, and subjective judgment. Compared with the prior art, the beneficial effects of the air conditioning test case testing equipment provided in this application are the same as those of the air conditioning test case testing method provided in the above embodiments, and other technical features in the air conditioning test case testing equipment are the same as those disclosed in the previous embodiment method, and will not be repeated here.
[0095] It should be understood that the various parts disclosed in this application can be implemented using hardware, software, firmware, or a combination thereof. In the description of the above embodiments, specific features, structures, materials, or characteristics can be combined in any suitable manner in one or more embodiments or examples.
[0096] The above are merely specific embodiments of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
[0097] This application provides a computer-readable storage medium having computer-readable program instructions (i.e., a computer program) stored thereon, which are used to execute the test method of the air conditioner test cases in the above embodiments.
[0098] The computer-readable storage medium provided in this application may be, for example, a USB flash drive, but is not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or any combination thereof. More specific examples of computer-readable storage media may include, but are not limited to: electrical connections having one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof. In this embodiment, the computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, system, or device. The program code contained on the computer-readable storage medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (Radio Frequency), etc., or any suitable combination thereof.
[0099] The aforementioned computer-readable storage medium may be included in the test equipment of the air conditioner test case; or it may exist independently and not be assembled into the test equipment of the air conditioner test case.
[0100] The aforementioned computer-readable storage medium carries one or more programs. When these programs are executed by the test equipment of the air conditioning test cases, the test equipment of the air conditioning test cases causes the following: It generates operation instruction messages corresponding to the air conditioning test subsystem based on a preset test case list, and obtains a list of status feedback signals fed back by the air conditioning test subsystem based on the operation instruction messages; it compares the list of status feedback signals with the list of expected feedback values in the preset test case list to obtain a comparison result. The list of expected feedback values includes a list of expected fixed values and a list of numerical intervals divided by index parity. The expected fixed values are fixed values that need to be precisely matched at the corresponding index positions. The numerical intervals divided by index parity are valid numerical intervals matched to the status feedback signals according to the index parity attribute, to determine whether the status feedback signals are within a valid numerical interval. The valid numerical intervals include the numerical intervals set for temperature-related signals and the numerical intervals set for status mode-related signals; and it outputs the test results of the preset test case list based on the comparison result.
[0101] Computer program code for performing the operations of this application can be written in one or more programming languages or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, and C++, and conventional procedural programming languages such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a Local Area Network (LAN) or a Wide Area Network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0102] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0103] The modules described in the embodiments of this application can be implemented in software or hardware. The names of the modules do not necessarily limit the functionality of the unit itself.
[0104] The readable storage medium provided in this application is a computer-readable storage medium that stores computer-readable program instructions (i.e., a computer program) for executing the test method of the above-described air conditioning test cases. This improves upon the technical problem that vehicle air conditioning controller testing relies on actual vehicle load, manual operation, and subjective judgment. Compared with the prior art, the beneficial effects of the computer-readable storage medium provided in this application are the same as the beneficial effects of the test method of the air conditioning test cases provided in the above embodiments, and will not be elaborated upon here.
[0105] This application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the test method for the air conditioner test cases as described above.
[0106] The computer program product provided in this application can improve the technical problem that the testing of vehicle air conditioning controllers relies on actual vehicle load, manual operation, and subjective judgment. Compared with the prior art, the beneficial effects of the computer program product provided in this application are the same as the beneficial effects of the testing method of the air conditioning test cases provided in the above embodiments, and will not be repeated here.
[0107] The above are only some embodiments of this application and do not limit the patent scope of this application. All equivalent structural transformations made under the technical concept of this application and using the contents of the specification and drawings of this application, or direct / indirect applications in other related technical fields, are included in the patent protection scope of this application.
Claims
1. A testing method for air conditioner test cases, characterized in that, The testing methods for the air conditioner test cases include: Based on a preset test case list, an operation instruction message corresponding to the air conditioning test subsystem is generated, and a list of status feedback signals fed back by the air conditioning test subsystem based on the operation instruction message is obtained. The list of status feedback signals is compared with the list of expected feedback values in the preset test case list to obtain a comparison result. The list of expected feedback values includes a list of expected fixed values and a list of value intervals divided by index parity. The expected fixed values are fixed values that need to be precisely matched at the corresponding index positions. The value intervals divided by index parity are valid value intervals matched to the status feedback signals according to the index parity attribute to determine whether the status feedback signal is within the valid value interval. The valid value intervals include the value intervals set for temperature-type signals and the value intervals set for status mode-type signals; and The test results of the preset test case list are output based on the comparison results.
2. The test method for the air conditioner test cases as described in claim 1, characterized in that, The air conditioning test subsystem includes an air conditioner controller under test and an electronic load. The subsystem generates operation command messages corresponding to the air conditioning test subsystem based on a preset test case list and obtains a list of status feedback signals from the air conditioning test subsystem based on the operation command messages, including: Based on a pre-set test case list, an operation instruction message corresponding to the air conditioner controller under test is generated, and the operation instruction message is sent to the air conditioner controller under test; Receive the status feedback signal fed back by the air conditioner controller under test after it outputs an electronic control signal to the electronic load in response to the operation command message; and A list of state feedback signals is generated based on the state feedback signals.
3. The test method for the air conditioner test cases as described in claim 2, characterized in that, The step of generating an operation instruction message corresponding to the air conditioner controller under test based on a preset test case list and sending the operation instruction message to the air conditioner controller under test includes: By running a preset automated script engine, the target test case is automatically indexed and parsed from the preset test case list, and the preconditions, initialization values, memory values and operation step sequences in the target test case are extracted. An initialization message is generated based on the aforementioned preconditions, the initialization value, and the memory value. The initialization message is sent to the air conditioner controller under test to bring the air conditioner controller under test into the initial state; and Based on the sequence of operation steps, operation instruction messages corresponding to the air conditioner controller under test are generated sequentially, and the operation instruction messages are sent to the air conditioner controller under test.
4. The test method for the air conditioner test cases as described in claim 2, characterized in that, The electronic load includes a multi-subsystem coupling model and an electrothermal coupling model. The status feedback signal includes a stepper motor feedback signal, a mechanical motion feedback signal, a refrigerant flow feedback signal, an electrical feedback signal, and a temperature feedback signal. The step of receiving the status feedback signal fed back by the air conditioner controller under test after outputting an electrical control signal to the electronic load in response to the operation command message includes: The test air conditioner controller responds to the operation command message and outputs an electronic control signal to the multi-subsystem coupling model to obtain the stepper motor feedback signal, mechanical motion feedback signal and refrigerant flow feedback signal from the electronic load. The air conditioner controller under test receives the operation command message and outputs an electrical control signal to the electrothermal coupling model to obtain the electrical feedback signal and temperature feedback signal from the electronic load.
5. The test method for the air conditioner test cases as described in any one of claims 1 to 4, characterized in that, The comparison results include a first comparison result and a second comparison result. The step of comparing the list of state feedback signals with the list of expected feedback values in the preset test case list to obtain the comparison results includes: The list of state feedback signals is compared with the expected fixed values in the expected feedback value list of the preset test case list to obtain a first comparison result; and The list of state feedback signals is compared with the numerical ranges divided by the odd and even indexes in the list of expected feedback values in the list of preset test cases to obtain a second comparison result.
6. The test method for the air conditioner test cases as described in claim 5, characterized in that, The step of comparing the values corresponding to the status feedback signal list with the expected fixed values in the expected feedback value list of the preset test case list to obtain a first comparison result includes: Identify the first index positions in the list of expected feedback values that do not contain a valid range identifier; Determine the first actual value corresponding to the first index position from the list of state feedback signals; and The first actual value is compared with the expected fixed value corresponding to the expected feedback value list to obtain the first comparison result.
7. The test method for the air conditioner test cases as described in claim 5, characterized in that, The numerical intervals for index parity division include a first preset numerical interval and a second preset numerical interval. The step of comparing the numerical intervals for index parity division in the state feedback signal list with the expected feedback value list in the preset test case list to obtain a second comparison result includes: Identify the second index position of all valid range identifiers in the list of expected feedback values; Determine the second actual value corresponding to the second index position from the list of state feedback signals; When the index value corresponding to the second actual value is odd, it is determined whether the second actual value belongs to a first preset value range to obtain a first determination result. The first preset value range is a range of gear values set according to temperature signals. When the index value corresponding to the second actual value is even, it is determined whether the second actual value belongs to the second preset value range, and a second determination result is obtained. The second preset value range is the gear value range set according to the state mode signal. The second comparison result is determined based on the first judgment result and the second judgment result.
8. A testing device for air conditioner test cases, characterized in that, The device includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, the computer program being configured to implement the steps of the test method for the air conditioner test case as described in any one of claims 1 to 7.
9. A testing system for air conditioner test cases, characterized in that, The testing system includes the testing equipment for the air conditioning test cases as described in claim 8 and an air conditioning testing subsystem, wherein the air conditioning testing subsystem includes an on-board bus communication analyzer, an air conditioning controller under test, and an electronic load; The vehicle bus communication analyzer is used to receive the operation instruction message generated by the test equipment of the air conditioning test case, and send the operation instruction message to the air conditioning controller under test; The air conditioner controller under test is used to generate an electronic control signal based on the operation command message and send the electronic control signal to the electronic load; The electronic load is used to simulate the electrical response of the vehicle air conditioning system according to the electronic control signal, and send the generated status feedback signal to the air conditioning controller under test. The air conditioner controller under test is used to send the status feedback signal to the vehicle bus communication analyzer; The vehicle bus communication analyzer is used to send the status feedback signal to the test equipment of the air conditioning test case; The testing equipment is used to generate a list of state feedback signals based on the state feedback signals, and compare the list of state feedback signals with the list of expected feedback values in the preset test case list to obtain a comparison result; The testing equipment is used to output test results from the preset test case list based on the comparison results.
10. A testing device for air conditioner test cases, characterized in that, The device includes: The model processing module is used to generate operation instruction messages corresponding to the air conditioning test subsystem based on a preset test case list, and to obtain a list of status feedback signals fed back by the air conditioning test subsystem based on the operation instruction messages. A numerical comparison module is used to compare the list of state feedback signals with the list of expected feedback values in the preset test case list to obtain a comparison result. The list of expected feedback values includes a list of expected fixed values and a list of numerical intervals divided by index parity. The expected fixed values are fixed values that need to be precisely matched at the corresponding index positions. The numerical intervals divided by index parity are valid numerical intervals matched to the state feedback signals according to the index parity attribute to determine whether the state feedback signal is within the valid numerical interval. The valid numerical intervals include the numerical intervals set for temperature-type signals and the numerical intervals set for state mode-type signals; and The result generation module is used to output the test results of the preset test case list based on the comparison results.
