Dual-cell terminal power consumption testing method, system, computer device, and storage medium
By considering leakage current in the power consumption test of dual-cell mobile terminals, using the power supply scheme of fake batteries and program-controlled power supply, the actual power consumption value of dual-cell terminals is accurately measured, and the problem of inaccurate test results in the prior art is solved.
Patent Information
- Application Number
- CN202210961492.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-08-11
- Publication Date
- 2025-05-27
- Estimated Expiration
- 2042-08-11
AI Technical Summary
The prior art does not consider the impact of leakage current on the power consumption of dual-cell mobile terminals, resulting in inaccurate test results.
The program-controlled power supply is connected to the fake battery as the power supply, and a communication connection is established with the tester, a test plan is generated and a test command is sent to test the leakage power consumption and operating power consumption respectively, and the final power consumption value of the dual-cell terminal is finally calculated.
Accurately measure the actual power consumption value of the double-cell terminal, fully consider the impact of leakage current on power consumption, and improve the accuracy of the test results.
Smart Images

Figure CN115327217B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of power consumption testing, and particularly to a method for testing the power consumption of a dual-cell terminal, a system for testing the power consumption of a dual-cell terminal, a computer device, and a computer-readable storage medium. Background Art
[0002] In order to ensure that the usage performance meets the requirements, a series of tests are generally carried out on the terminal before leaving the factory, such as power consumption testing, which is mainly used to test the power consumption of each hardware and software of the terminal during operation, so as to improve the terminal according to the test results.
[0003] Currently, the commonly used power consumption testing method mainly tests the power consumption values of the terminal under test in different business scenarios under different locations and different network conditions, so as to determine the power consumption situation of the terminal. However, for a dual-cell mobile terminal, due to the special design scheme adopted by the dummy battery of the dual-cell mobile terminal to balance the voltages of the two cells, leakage current will be caused. However, the currently commonly used method does not consider the influence of the leakage current on the power consumption value, so it is impossible to accurately determine the power consumption of the dual-cell mobile terminal. Summary of the Invention
[0004] The present invention is completed in order to at least partially solve the technical problem that in the prior art, the terminal power consumption test only considers the business scenario and network conditions and does not consider the influence of the leakage current on the power consumption value, resulting in inaccurate test results.
[0005] According to one aspect of the present invention, there is provided a method for testing the power consumption of a dual-cell terminal. The dual-cell terminal under test is connected to a programmable power supply through a dummy battery as its power supply, and a communication connection is established with a tester through the dummy battery. The method includes:
[0006] The test platform generates a test plan for testing the power consumption of the dual-cell terminal under test, and generates a number of test instructions according to the test plan and sends them to the tester. One of the test instructions is used to indicate the test of the leakage power consumption of the dual-cell terminal under test, and the remaining test instructions are used to indicate the test of the operating power consumption of the dual-cell terminal under test;
[0007] The tester receives each test instruction sent by the test platform, tests the leakage power consumption value and the operating power consumption value of the dual-cell terminal under test respectively based on each test instruction, and feeds back the test results to the test platform; and,
[0008] The test platform receives the test results sent by the tester, and obtains the final power consumption value of the dual-cell terminal under test based on the operating power consumption value and the leakage power consumption value of the dual-cell terminal under test in the test results.
[0009] Optionally, the test of the leakage power consumption of the dual-cell DUT includes: testing the power consumption of the dual-cell DUT after it is powered off; the test of the operating power consumption of the dual-cell DUT includes: testing the power consumption of the dual-cell DUT after it is in the screen-off standby state, and any one or more of the tests of the power consumption of the dual-cell DUT when running each preset service.
[0010] Optionally, the leakage power consumption value of the dual-cell DUT includes: the average current value of the dual-cell DUT within a preset duration after it is powered off; the operating power consumption value of the dual-cell DUT includes: any one or more of the average current value of the dual-cell DUT within a preset duration after it is in the screen-off standby state, and the average current value of the dual-cell DUT when running each preset service for a preset duration.
[0011] Optionally, the test platform obtains the final power consumption value of the dual-cell DUT based on the operating power consumption value and the leakage power consumption value of the dual-cell DUT, including:
[0012] The test platform calculates the difference between the average current value of the dual-cell DUT within a preset duration after it is in the screen-off standby state and any one or more of the average current values of the dual-cell DUT when running each preset service for a preset duration and the average current value of the dual-cell DUT within a preset duration after it is powered off, to obtain several net current values;
[0013] Multiply the several net current values by 2 respectively to obtain several actual current values; and,
[0014] Based on the several actual current values, obtain the final power consumption value of the dual-cell DUT.
[0015] Optionally, the test platform calculates the final power consumption value of the dual-cell DUT using the following formula:
[0016] P = B 1 a + B 2 A 1 +…+ B n A m
[0017] In the formula, P represents the final power consumption value of the dual-cell DUT; m represents the total number of preset services that the dual-cell DUT needs to run; a represents the actual current value corresponding to the power consumption of the dual-cell DUT after it is in the screen-off standby state, B 1 represents the power consumption ratio corresponding to the power consumption of the dual-cell DUT after it is in the screen-off standby state; A 1 represents the actual current value corresponding to the power consumption of the dual-cell DUT when running the first preset service, B 2 represents the power consumption ratio corresponding to the power consumption of the dual-cell DUT when running the first preset service; A mrepresents the actual current value corresponding to the power consumption of the dual-cell DUT running the m-th preset service, B m+1 represents the power consumption ratio corresponding to the power consumption of the dual-cell DUT running the m-th preset service, and B 1 +B 2 +…+B m+1 = 100%.
[0018] Optionally, after the tester receives each test instruction sent by the test platform, it further includes:
[0019] The tester executes the test instruction and returns the execution result for the test instruction to the test platform, and the execution result includes an error message;
[0020] The test platform sends several test instructions to the tester, specifically:
[0021] The test platform sequentially sends each test instruction to the tester, and for each test instruction sent, it receives the execution result of the test instruction returned by the tester, and selects the next test instruction to send to the tester based on the execution result of the test instruction until all the generated test instructions are sent.
[0022] Optionally, after the tester receives each test instruction sent by the test platform, it further includes:
[0023] The tester generates corresponding several operation instructions according to each test instruction;
[0024] The tester sequentially sends the several operation instructions corresponding to each test instruction to the dual-cell DUT, so that for each operation instruction received by the dual-cell DUT, it executes the operation instruction and returns the execution result of the operation instruction to the tester, and the execution result includes an error message; and,
[0025] The tester receives the execution result returned by the dual-cell DUT, and after modifying the operation instruction based on the execution result, it resends it or selects the next operation instruction to send to the dual-cell DUT.
[0026] Optionally, it further includes:
[0027] The tester determines whether the test conditions for the power consumption test corresponding to each test instruction are met according to the execution results of each operation instruction corresponding to each test instruction returned by the dual-cell DUT. If they are met, the power consumption test corresponding to the test instruction is performed on the dual-cell DUT.
[0028] Optionally, after the test platform sends several test instructions to the tester, it further includes:
[0029] The test platform also sends the number of test instructions to the tester;
[0030] The tester receives the number of test instructions sent by the test platform, and after executing all the test instructions based on the number of test instructions, feeds back a power consumption test execution completion message to the test platform; and,
[0031] The test platform receives a message from the tester indicating that the power consumption test is completed;
[0032] The test platform calculates the final power consumption value of the dual-cell terminal under test based on the operating power consumption value and the leakage power consumption value of the dual-cell terminal under test in the test results, specifically:
[0033] After receiving the power consumption test completion message sent by the tester, the test platform calculates the final power consumption value of the dual-cell terminal under test based on the operating power consumption value and leakage power consumption value of the dual-cell terminal under test in the test results.
[0034] According to another aspect of the present invention, there is provided a dual-cell terminal power consumption test system, comprising: a test platform and a tester, wherein the dual-cell terminal under test is connected to a programmable power supply as its power supply through a dummy battery, and establishes a communication connection with the tester through the dummy battery;
[0035] The test platform is used to generate a test plan for testing the power consumption of the dual-cell terminal under test, and generate a number of test instructions according to the test plan and send them to the tester, wherein one test instruction is used to instruct to test the leakage power consumption of the dual-cell terminal under test, and the remaining test instructions are used to instruct to test the operating power consumption of the dual-cell terminal under test;
[0036] The tester is used to receive each test instruction sent by the test platform, test the leakage power consumption value and the operating power consumption value of the dual-cell tested terminal based on each test instruction, and feed back the test results to the test platform;
[0037] The test platform is also used to receive the test results sent by the tester, and derive the final power consumption value of the dual-cell terminal under test based on the operating power consumption value and the leakage power consumption value of the dual-cell terminal under test in the test results.
[0038] According to another aspect of the present invention, there is provided a computer device, comprising a memory and a processor, wherein the memory stores a computer program, and when the processor runs the computer program stored in the memory, the processor executes the operations performed by any device in the aforementioned dual-cell terminal power consumption test method.
[0039] According to another aspect of the present invention, there is provided a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, the processor executes the operations performed by any device in the aforementioned dual-cell terminal power consumption test method.
[0040] The technical solution provided by the present invention may include the following beneficial effects:
[0041] For the dual-cell terminal power consumption testing method provided by the present invention, the testing platform first tests the power consumption generated by the leakage current of the dual-cell terminal, and then removes the influence of the leakage power consumption on the operating power consumption of the dual-cell terminal to be measured, so as to more accurately measure the actual power consumption value of the dual-cell terminal.
[0042] Other features and advantages of the present invention will be described in the following specification, and, in part, will be obvious from the specification, or will be understood by implementing the present invention. The objectives and other advantages of the present invention can be achieved and obtained by the structures specifically pointed out in the specification, claims and drawings. Description of the Drawings
[0043] The drawings are used to provide a further understanding of the technical solution of the present invention, and constitute a part of the specification. Together with the embodiments of the present invention, they are used to explain the technical solution of the present invention and do not constitute a limitation to the technical solution of the present invention.
[0044] Figure 1 It is a schematic flowchart of the dual-cell terminal power consumption testing method provided by the embodiment of the present invention;
[0045] Figure 2 It is a schematic structural diagram of the dual-cell terminal power consumption testing system provided by the embodiment of the present invention;
[0046] Figure 3 It is a schematic structural diagram of the computer device provided by the embodiment of the present invention. Detailed Embodiments
[0047] To make the objectives, technical solutions and advantages of the embodiments of the present invention clearer, the following will describe the detailed embodiments of the present invention with reference to the accompanying drawings. It should be understood that the specific embodiments described herein are only used to illustrate and explain the present invention and are not used to limit the present invention.
[0048] Figure 1 It is a schematic flowchart of the dual-cell terminal power consumption testing method provided by the embodiment of the present invention. Among them, the dual-cell terminal to be measured is connected to a programmable power supply through a dummy battery as its power supply, and is communicatively connected to a tester through the dummy battery.
[0049] It should be noted that "dual-cell" refers to the design of the battery cells of the terminal. Configuring a "dummy battery" for the dual-cell terminal is to facilitate power consumption testing. Specifically, the dummy battery replaces the real battery of the terminal and is connected to the tester to supply power to the terminal, so as to facilitate the tester to test the power consumption of the terminal.
[0050] Such as Figure 1As shown, the method includes the following steps S101 to S103.
[0051] S101. The test platform generates a test plan for testing the power consumption of the dual-cell terminal under test, and generates several test instructions according to the test plan and sends them to the tester. One of the test instructions is used to indicate the test of the leakage power consumption of the dual-cell terminal under test, and the remaining test instructions are used to indicate the test of the operating power consumption of the dual-cell terminal under test.
[0052] In this step, the leakage power consumption is the power consumption generated by the leakage current of the dual-cell terminal; and the operating power consumption is the power consumption generated when the dual-cell terminal is operating normally, which includes the leakage power consumption. The operating power consumption test of the dual-cell terminal under test can be one or more power consumption tests, which can be specifically set and adjusted by those skilled in the art according to actual needs, and each power consumption test corresponds to one test instruction.
[0053] S102. The tester receives each test instruction sent by the test platform, respectively tests the leakage power consumption value and the operating power consumption value of the dual-cell terminal under test based on each test instruction, and feeds back the test results to the test platform.
[0054] In this step, after the tester establishes a connection with the programmable power supply through a dummy battery, it can monitor the power consumption of the dual-cell terminal under test when executing different test instructions. Moreover, every time the tester completes a test instruction, it encapsulates the test result into a data packet containing the test instruction and sends it to the test platform, which is received and saved by the test platform. According to different test instructions, the test results can include several power consumption values.
[0055] S103. The test platform receives the test results sent by the tester, and obtains the final power consumption value of the dual-cell terminal under test based on the operating power consumption value and the leakage power consumption value of the dual-cell terminal under test in the test results.
[0056] In this step, the test platform first tests the power consumption generated by the leakage current of the dual-cell terminal, and then removes the influence of the leakage power consumption on the operating power consumption of the dual-cell terminal under test, so as to more accurately measure the actual power consumption value of the dual-cell terminal.
[0057] In a specific embodiment, in step S101, for the power consumption tests indicated by several test instructions generated by the test plan, among them, the test of the leakage power consumption of the dual-cell terminal under test includes: testing the power consumption after the dual-cell terminal under test is turned off; the test of the operating power consumption of the dual-cell terminal under test includes: testing the power consumption after the dual-cell terminal under test is in the screen-off standby state, and any one or more of the tests of the power consumption of the dual-cell terminal under test when running various preset services.
[0058] In this embodiment, the test plan may include multiple test tasks. Among them, the test tasks in the first aspect include testing the power consumption of the dual-cell terminal under test after shutdown, the test tasks in the second aspect include testing the power consumption of the dual-cell terminal under test after the screen is turned off and in standby mode, and the test tasks in the third aspect include testing the power consumption of the dual-cell terminal under test when running various preset services respectively.
[0059] Among them, for the test tasks in the third aspect, different service types can be customized according to different types of terminals. For example, for mobile phone terminals, call services, instant messaging services, game services, video services, audio services, social services, etc. can be tested; for tablet computer terminals, game services, video services, audio services, etc. can be tested. The service types to be tested can be adjusted according to the service types supported by the terminal, or can also be adjusted according to the service types commonly used by users.
[0060] As for the test instructions, they are one or more instructions that can independently complete a complete test task generated according to the test plan. For the test tasks in the third aspect, since the test instructions corresponding to different service types are different, such as the test instructions for testing call services, the test instructions for testing audio services, etc., the test tasks in the third aspect can include multiple test instructions. While the test tasks in the first aspect and the second aspect each only include one test instruction.
[0061] It should be noted that one or more tests can be selected from testing the power consumption of the dual-cell terminal under test after the screen is turned off and in standby mode, and separately testing the power consumption of the dual-cell terminal under test when running various preset services according to actual needs. For example, when choosing to test the power consumption of the dual-cell terminal under test when running various preset services, the influence of the design scheme of the dual cells themselves and the leakage current generated by the dummy battery of the dual-cell terminal on the power consumption situation of the terminal is fully considered, and the power consumption performance of the dual-cell terminal can be measured more accurately.
[0062] In a specific implementation manner, in step S102, the leakage power consumption values and operating power consumption values of the dual-cell terminal under test respectively obtained based on each test instruction are specifically:
[0063] The leakage power consumption value of the dual-cell terminal under test includes: the average value of the current within a preset duration after the dual-cell terminal under test is shut down; the operating power consumption value of the dual-cell terminal under test includes: the average value of the current within a preset duration after the dual-cell terminal under test is in the screen-off standby state, and any one or more of the average values of the current when the dual-cell terminal under test runs various preset services for a preset duration.
[0064] In this embodiment, using the average value of the current as the power consumption index can better measure the change of the power consumption situation.
[0065] In a specific embodiment, step S103 includes the following steps S103a to S103d.
[0066] S103a. The test platform receives the test results sent by the tester. The test results include the operating power consumption value and the leakage power consumption value of the dual-cell terminal under test.
[0067] S103b. The test platform calculates the difference between the average current value of the dual-cell terminal under test within a preset duration after the screen is turned off and any one or more of the average current values of the dual-cell terminal under test when running each preset service for a preset duration and the average current value of the dual-cell terminal under test within a preset duration after shutdown, to obtain a number of net current values.
[0068] S103c. The test platform multiplies each of the net current values by 2 to obtain a number of actual current values.
[0069] S103d. The test platform obtains the final power consumption value of the dual-cell terminal under test based on the number of actual current values.
[0070] In this embodiment, when the operating power consumption test includes testing the power consumption of the dual-cell terminal under test after the screen is turned off and testing the power consumption of the dual-cell terminal under test when running one or more preset services respectively, the test results received by the test platform include, on the one hand, the test results of the power consumption of the dual-cell terminal under test after shutdown, on the second hand, the test results of the power consumption of the dual-cell terminal under test after the screen is turned off, and on the third hand, the test results of the power consumption of the dual-cell terminal under test when running one or more preset services.
[0071] For the received test results, the test platform first corrects the average current values included in the test results of the second and third aspects other than the leakage power consumption test result according to the influence of the leakage current on the dual-cell terminal under test, to obtain a number of net current values. The specific correction method is: net current value = average current value - leakage current. The leakage current refers to the average current value included in the test results of the first aspect, that is, the average current value measured by connecting the dual-cell terminal under test to the tester through a dummy battery in the shutdown state.
[0072] Then, according to the influence of the dual-cell design scheme on the power consumption, the obtained net current values are corrected to obtain a number of actual current values. The specific modification method is: actual current value = net current value * 2.
[0073] Finally, the final power consumption value of the dual-cell terminal under test is obtained based on the number of actual current values obtained. Specifically, the final power consumption value of the dual-cell terminal under test is calculated according to the number of actual current values based on the preset different power consumption ratios.
[0074] In a specific embodiment, in step S103d, the test platform calculates the final power consumption value of the dual-cell DUT using the following formula:
[0075] P = B 1 a + B 2 A 1 +…+ B n A m
[0076] In the formula, P represents the final power consumption value of the dual-cell DUT; m represents the total number of preset services that the dual-cell DUT needs to run; a represents the actual current value corresponding to the power consumption after the dual-cell DUT goes into the screen-off standby state, and B 1 represents the power consumption ratio corresponding to the power consumption after the dual-cell DUT goes into the screen-off standby state; A 1 represents the actual current value corresponding to the power consumption of the dual-cell DUT when running the first preset service, and B 2 represents the power consumption ratio corresponding to the power consumption of the dual-cell DUT when running the first preset service; A m represents the actual current value corresponding to the power consumption of the dual-cell DUT when running the m-th preset service, and B m+1 represents the power consumption ratio corresponding to the power consumption of the dual-cell DUT when running the m-th preset service, and B 1 + B 2 +…+ B m+1 = 100%.
[0077] In a specific embodiment, in step S102, after the tester receives each test instruction sent by the test platform, it further includes:
[0078] The tester executes the test instruction and returns the execution result for the test instruction to the test platform, and the execution result includes an error message.
[0079] Correspondingly, in step S101, the test platform sends several test instructions to the tester, specifically:
[0080] The test platform sequentially sends each test instruction to the tester, and for each test instruction sent, it receives the execution result of the test instruction returned by the tester, and selects the next test instruction to send to the tester based on the execution result of the test instruction until all the generated test instructions are sent.
[0081] In this embodiment, the test platform determines whether to select the next test instruction based on the execution result returned by the tester when executing each test instruction. For example, if the test platform issues a test call instruction to a terminal that does not support the call service through the tester, or the terminal does not respond to a certain test instruction, the tester will return an error message to the test platform, and the test platform will select the next test instruction for testing.
[0082] Of course, if the execution result is a success message, the test platform sends the next test instruction to the tester according to the established order.
[0083] In a specific implementation manner, in step S102, after the tester receives each test instruction sent by the test platform, the following steps S102a to S102c are further included.
[0084] S102a. The tester generates a corresponding number of operation instructions according to each test instruction;
[0085] S102b. The tester sequentially sends the corresponding number of operation instructions of each test instruction to the dual-cell terminal under test, so that each time the dual-cell terminal under test receives an operation instruction, it executes the operation instruction and returns the execution result of the operation instruction to the tester. The execution result includes an error message;
[0086] S102c. The tester receives the execution result returned by the dual-cell terminal under test, and based on the execution result, modifies the operation instruction and resends it or selects the next operation instruction to send to the dual-cell terminal under test.
[0087] In this embodiment, after the tester receives each test instruction sent by the test platform, it can generate one or more operation instructions according to the test instruction and send them to the dual-cell terminal under test. The operation instruction is specifically a complete set of instructions for operating the dual-cell terminal under test generated by the tester according to the test instruction. For example, according to the test instruction for the video service, it generates multiple operation instructions such as opening the video APP, selecting a certain video for playback, clicking to end playback after playing for a preset duration, and closing the video APP.
[0088] After the dual-cell DUT establishes a communication connection with the tester through the dummy battery, it can receive the operation instructions sent by the tester. For each operation instruction received by the dual-cell DUT, it executes the instruction and returns the execution result of the instruction to the tester. Then, the tester decides whether to modify and resend the instruction or select the next operation instruction according to the execution result. Specifically, if the dual-cell DUT does not support or respond to a certain operation instruction, it will return an error message to the tester. The tester will modify the instruction and resend it to the DUT or select the next operation instruction and send it to the DUT. For example, if the dual-cell DUT does not respond to the operation instruction of playing a video, the power consumption of the DUT during video playback cannot be tested, and an error message will be returned to the tester. At this time, the tester needs to select an instruction to play another video (i.e., modify the play instruction) or an instruction to directly close the video APP (i.e., select the next operation instruction), and return the corresponding message to the test platform.
[0089] Of course, if the execution result is a success message, the tester sends the next operation instruction to the dual-cell DUT in the established order.
[0090] In a specific embodiment, after step S102c, the following step S102d is further included.
[0091] S102d. The tester determines whether the test conditions for the power consumption test corresponding to each test instruction are met according to the execution results of the operation instructions corresponding to each test instruction returned by the dual-cell DUT. If so, the power consumption test corresponding to the test instruction is performed on the dual-cell DUT.
[0092] In this embodiment, the tester also determines whether the power consumption test corresponding to each test instruction can be performed according to the execution results of the operation instructions corresponding to each test instruction returned by the dual-cell DUT, that is, determines whether the test conditions for the test instruction are met. In other words, the tester makes a judgment every time it receives the execution result of an operation instruction until it determines that the test conditions for the test instruction are met, and then performs the power consumption test corresponding to the test instruction on the dual-cell DUT. Taking the test instruction for testing the video service as an example, after the tester receives the success messages of opening the video APP, selecting a predetermined video for playback, clicking to end playback after playing for a preset duration, and closing the video APP returned by the dual-cell DUT, it determines that the test conditions for testing the video service are met, and can start testing the power consumption of the dual-cell DUT when running the video service.
[0093] In a specific embodiment, when the test platform sends several test instructions to the tester in step S101, the number of test instructions is also sent to the tester.
[0094] Accordingly, when the tester receives each test instruction sent by the test platform in step S102, it also receives the number of test instructions sent by the test platform, and after completing all the test instructions based on the number of test instructions, it feeds back a message indicating that the power consumption test has been completed to the test platform.
[0095] Accordingly, step S103 further includes: the test platform receives the message indicating that the power consumption test has been completed sent by the tester, and after receiving the message indicating that the power consumption test has been completed sent by the tester, it obtains the final power consumption value of the dual-cell terminal under test based on the operating power consumption value and the leakage power consumption value of the dual-cell terminal under test in the test results.
[0096] In this embodiment, for several test instructions sent by the test platform, after the tester finishes executing all the test instructions, it sends a message indicating that the power consumption test has been completed to the test platform to inform the test platform that the tester has completed all the power consumption test work; after the test platform receives the message indicating that the power consumption test has been completed sent by the tester, it retrieves the test results corresponding to each test task it has saved, and then obtains the final power consumption value of the dual-cell terminal under test according to the test results.
[0097] It should be noted that the order of the above steps is only a specific example proposed for illustrating the embodiments of the present invention. The present invention does not limit the order of the above steps, and those skilled in the art can adjust it as needed in actual applications; moreover, the size of the serial numbers of the above steps does not limit their execution order.
[0098] The dual-cell terminal power consumption test method provided by the embodiments of the present invention adds a test on the power consumption generated by the leakage current during the process of testing the power consumption of the dual-cell terminal, removes the influence of the leakage power consumption from the screen-off standby power consumption and the power consumption of running different services of the dual-cell terminal under test, and then obtains the final power consumption value of the dual-cell terminal under test by combining the results after removal with their respective power consumption ratios, thereby fully considering the influence of the leakage current of the dual-cell terminal on its actual power consumption value and being able to measure the actual power consumption value of the dual-cell terminal more accurately.
[0099] Figure 2 It is a schematic structural diagram of the dual-cell terminal power consumption test system provided by the embodiments of the present invention. As Figure 2 shown, the system includes: a test platform 100 and a tester 200, wherein the dual-cell terminal under test 300 is connected to a programmable power supply 302 through a dummy battery 301 as its power supply, and establishes a communication connection with the tester 200 through the dummy battery 301.
[0100] Among them, the test platform 100 is used to generate a test plan for testing the power consumption of the dual-cell DUT 300, and generate a number of test instructions according to the test plan and send them to the tester 200. One of the test instructions is used to indicate the test of the leakage power consumption of the dual-cell DUT 300, and the remaining test instructions are used to indicate the test of the operating power consumption of the dual-cell DUT 300; the tester 200 is used to receive each test instruction sent by the test platform 100, respectively test the leakage power consumption value and the operating power consumption value of the dual-cell DUT 300 based on each test instruction, and feedback the test results to the test platform 100; the test platform 100 is also used to receive the test results sent by the tester 200, and obtain the final power consumption value of the dual-cell DUT 300 based on the operating power consumption value and the leakage power consumption value of the dual-cell DUT 300 in the test results.
[0101] In a specific embodiment, among the test instructions generated by the test platform 100, the test of the leakage power consumption of the dual-cell DUT 300 includes: testing the power consumption after the dual-cell DUT 300 is powered off; the test of the operating power consumption of the dual-cell DUT 300 includes: testing the power consumption after the dual-cell DUT 300 is in the screen-off standby state, and any one or more of the tests of the power consumption of the dual-cell DUT 300 when running various preset services.
[0102] In a specific embodiment, the tester 200 tests the leakage power consumption value of the dual-cell DUT 300 including: the average current value within a preset duration after the dual-cell DUT 300 is powered off; the tester 200 tests the operating power consumption value of the dual-cell DUT 300 including: the average current value within a preset duration after the dual-cell DUT 300 is in the screen-off standby state, and any one or more of the average current values of the dual-cell DUT 300 when running various preset services for a preset duration.
[0103] In a specific embodiment, the test platform 100 is specifically used to: calculate the difference between the average current value within a preset duration after the dual-cell DUT 300 is in the screen-off standby state and any one or more of the average current values of the dual-cell DUT 300 when running various preset services for a preset duration and the average current value within a preset duration after the dual-cell DUT 300 is powered off, to obtain a number of net current values; multiply the number of net current values by 2 respectively to obtain a number of actual current values; and, obtain the final power consumption value of the dual-cell DUT 300 based on the number of actual current values.
[0104] In a specific embodiment, the test platform 100 calculates the final power consumption value of the dual-cell DUT 300 using the following formula:
[0105] P = B 1 a + B 2A 1 +…+B n A m
[0106] In the formula, P represents the final power consumption value of the dual-cell terminal under test; m represents the total number of preset services that the dual-cell terminal under test needs to run; a represents the actual current value corresponding to the power consumption after the dual-cell terminal under test goes into the screen-off standby state, and B 1 represents the power consumption ratio corresponding to the power consumption after the dual-cell terminal under test goes into the screen-off standby state; A 1 represents the actual current value corresponding to the power consumption of the dual-cell terminal under test when running the first preset service, and B 2 represents the power consumption ratio corresponding to the power consumption of the dual-cell terminal under test when running the first preset service; A m represents the actual current value corresponding to the power consumption of the dual-cell terminal under test when running the m-th preset service, and B m+1 represents the power consumption ratio corresponding to the power consumption of the dual-cell terminal under test when running the m-th preset service, and B 1 +B 2 +…+B m+1 = 100%.
[0107] In a specific embodiment, after receiving each test instruction sent by the test platform 100, the tester 200 is further configured to execute the test instruction and return the execution result of the test instruction to the test platform 100, and the execution result includes an error message.
[0108] Correspondingly, the test platform 100 is specifically configured to: sequentially send each test instruction to the tester 200, and receive the execution result of the test instruction returned by the tester 200 for each sent test instruction, and select the next test instruction to send to the tester 200 based on the execution result of the test instruction until all the generated test instructions are sent.
[0109] In a specific embodiment, after receiving each test instruction sent by the test platform 100, the tester 200 is further configured to: generate a corresponding number of operation instructions according to each test instruction; sequentially send the corresponding number of operation instructions of each test instruction to the dual-cell terminal under test 300, so that for each received operation instruction, the dual-cell terminal under test 300 executes the operation instruction and returns the execution result of the operation instruction to the tester 200, and the execution result includes an error message; and receive the execution result returned by the dual-cell terminal under test 300, and re-send the operation instruction after modifying it based on the execution result or select the next operation instruction to send to the dual-cell terminal under test 300.
[0110] In a specific embodiment, the tester 200 is further configured to: determine whether the test conditions for the power consumption test corresponding to each test instruction are met according to the execution results of each operation instruction corresponding to each test instruction returned by the dual-cell DUT 300. If the conditions are met, perform the power consumption test corresponding to the test instruction on the dual-cell DUT 300.
[0111] In a specific embodiment, after sending a number of test instructions to the tester 200, the test platform 100 is further configured to send the number of test instructions to the tester 200.
[0112] Correspondingly, the tester 200 is further configured to receive the number of test instructions sent by the test platform 100, and after executing all the test instructions based on the number of test instructions, feedback a message indicating that the power consumption test has been completed to the test platform 100; and receive the message indicating that the power consumption test has been completed sent by the tester 200.
[0113] Correspondingly, the test platform 100 is specifically configured to: after receiving the message indicating that the power consumption test has been completed sent by the tester 200, obtain the final power consumption value of the dual-cell DUT 300 based on the operating power consumption value and the leakage power consumption value of the dual-cell DUT 300 in the test results.
[0114] In the dual-cell terminal power consumption test system provided by the embodiments of the present invention, the test platform is responsible for generating a test plan, generating a number of test instructions according to the test plan and sending them to the tester, and receiving the test results returned by the tester. According to the respective preset different power consumption ratios of the operating power consumptions including the leakage current power consumption in the test results returned by the tester, the final power consumption value of the dual-cell DUT is calculated; the tester generates corresponding operation instructions according to the test instructions and sends them to the dual-cell DUT to instruct it to perform corresponding operations. After the operations are completed, the operating power consumption of the dual-cell DUT is tested according to the test instructions and returned to the test platform. The dual-cell DUT is connected to a programmable power supply through a dummy battery as its power supply, and a communication connection is established with the tester through the dummy battery. The dual-cell DUT receives the operation instructions of the tester and performs corresponding operations according to the operation instructions. The dummy battery connects the dual-cell DUT and the programmable power supply, making the programmable power supply the power supply of the dual-cell DUT, and further enabling the tester to measure the average current value of the dual-cell DUT when executing different test instructions, so that the test platform calculates the final power consumption value of the dual-cell DUT according to the average current value and the preset power consumption ratios of the operating power consumptions, fully considering the influence of the leakage current of the dual-cell terminal on its actual power consumption value, and being able to measure the actual power consumption value of the dual-cell terminal more accurately.
[0115] Based on the same technical concept, the embodiments of the present invention correspondingly further provide a computer device, such as Figure 3As shown, the computer device includes a memory 31 and a processor 32. A computer program is stored in the memory 31. When the processor 32 runs the computer program stored in the memory 31, the processor 32 performs the operations executed by the test platform or the tester in the foregoing dual-cell terminal power consumption test method.
[0116] Based on the same inventive concept, an embodiment of the present invention correspondingly further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the processor performs the operations executed by the test platform or the tester in the foregoing dual-cell terminal power consumption test method.
[0117] In summary, for the dual-cell terminal power consumption test method, system, computer device, and storage medium provided by the embodiments of the present invention, during the process of testing the power consumption of the dual-cell terminal, a test on the power consumption generated by the leakage current is added, and the influence of the leakage power consumption is removed from the various operating power consumptions of the dual-cell terminal under test. Then, according to the results after removal and combined with their respective power consumption ratios, the final power consumption value of the dual-cell terminal under test is obtained. Therefore, the influence of the leakage current of the dual-cell terminal on its actual power consumption value is fully considered, and the actual power consumption value of the dual-cell terminal can be measured more accurately.
[0118] Those of ordinary skill in the art will understand that all or some of the steps in the methods disclosed above, and the functional modules / units in the systems and devices, can be implemented as software, firmware, hardware, and appropriate combinations thereof. In the hardware implementation, the division of functional modules / units mentioned above does not necessarily correspond to the division of physical components; for example, one physical component may have multiple functions, or one function or step may be executed by several physical components in cooperation. Some or all of the physical components may be implemented as software executed by a processor, such as a central processing unit, a digital signal processor, or a microprocessor, or may be implemented as hardware, or may be implemented as an integrated circuit, such as an application-specific integrated circuit. Such software can be distributed on a computer-readable medium, which may include a computer storage medium (or non-transitory medium) and a communication medium (or transitory medium). As is well known to those of ordinary skill in the art, the term computer storage medium includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storing information, such as computer-readable instructions, data structures, program modules, or other data. Computer storage media include, but are not limited to, RAM, ROM, EEPROM, flash memory, or other memory technologies, CD-ROM, digital versatile disk (DVD), or other optical disk storage, magnetic cartridges, tapes, magnetic disk storage, or other magnetic storage devices, or any other medium that can be used to store the desired information and can be accessed by a computer. In addition, as is well known to those of ordinary skill in the art, a communication medium typically contains computer-readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transmission mechanism, and may include any information delivery medium.
[0119] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions described in the foregoing embodiments, or perform equivalent replacements for some or all of the technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for testing the power consumption of a dual - cell terminal, characterized in that, the dual - cell terminal under test is connected to a programmable power supply through a dummy battery as its power supply, and is communicatively connected to a tester through the dummy battery. The method includes: The test platform generates a test plan for testing the power consumption of the dual - cell terminal under test, and generates several test instructions according to the test plan and sends them to the tester. One of the test instructions is used to indicate testing the leakage power consumption of the dual - cell terminal under test, and the remaining test instructions are used to indicate testing the operating power consumption of the dual - cell terminal under test; The tester receives each test instruction sent by the test platform, respectively tests the leakage power consumption value and the operating power consumption value of the dual - cell terminal under test based on each test instruction, and feeds back the test results to the test platform; and, The test platform receives the test results sent by the tester, and obtains the final power consumption value of the dual - cell terminal based on the operating power consumption value and the leakage power consumption value of the dual - cell terminal in the test results; The leakage power consumption value of the dual - cell terminal under test includes: the average value of the current within a preset time after the dual - cell terminal under test is powered off; the operating power consumption value of the dual - cell terminal under test includes: the average value of the current within a preset time after the dual - cell terminal under test is in the screen - off standby state, and any one or more of the average values of the current when the dual - cell terminal under test runs each preset service for a preset time; The test platform obtaining the final power consumption value of the dual - cell terminal based on the operating power consumption value and the leakage power consumption value of the dual - cell terminal under test includes: The test platform calculates the difference between the average value of the current within a preset time after the dual - cell terminal under test is in the screen - off standby state and any one or more of the average values of the current when the dual - cell terminal under test runs each preset service for a preset time and the average value of the current within a preset time after the dual - cell terminal under test is powered off, and obtains several net current values; Multiply each of the net current values by 2 to obtain several actual current values; and, Based on the several actual current values, obtain the final power consumption value of the dual - cell terminal; The test platform calculates the final power consumption value of the dual - cell terminal using the following formula: P = B 1 a + B 2 A 1 +…+ B m+1 A m Wherein, P represents the final power consumption value of the dual-cell terminal under test; m represents the total number of preset services that the dual-cell terminal under test needs to run; a represents the actual current value corresponding to the power consumption after the dual-cell terminal under test goes into the screen-off standby state, B 1 represents the power consumption ratio corresponding to the power consumption after the dual-cell terminal under test goes into the screen-off standby state; A 1 represents the actual current value corresponding to the power consumption of the dual-cell terminal under test when running the first preset service, B 2 represents the power consumption ratio corresponding to the power consumption of the dual-cell terminal under test when running the first preset service; A m represents the actual current value corresponding to the power consumption of the dual-cell terminal under test when running the m-th preset service, B m+1 represents the power consumption ratio corresponding to the power consumption of the dual-cell terminal under test when running the m-th preset service, and B 1 +B 2 +…+B m+1 = 100%.
2. The method according to claim 1, characterized in that, Testing the leakage power consumption of the dual - cell terminal under test includes: testing the power consumption of the dual - cell terminal after it is powered off; testing the operating power consumption of the dual - cell terminal under test includes: testing the power consumption of the dual - cell terminal after it is in the screen - off standby state, and any one or more of testing the power consumption of the dual - cell terminal when it runs each preset service.
3. The method according to claim 1, characterized in that, After the tester receives each test instruction sent by the test platform, it further includes: The tester executes the test instruction and returns the execution result for the test instruction to the test platform, and the execution result includes an error message; The test platform sending several test instructions to the tester is specifically: The test platform sequentially sends each test instruction to the test instrument, and for each test instruction sent, it receives the execution result of that test instruction returned by the test instrument, and based on the execution result of that test instruction, selects the next test instruction to send to the test instrument until all the generated test instructions are sent.
4. The method according to claim 1, wherein, after the test instrument receives each test instruction sent by the test platform, it further includes: the test instrument generates corresponding several operation instructions according to each test instruction; the test instrument sequentially sends the several operation instructions corresponding to each test instruction to the dual-cell device under test, so that for each operation instruction received by the dual-cell device under test, it executes that operation instruction and returns the execution result of that operation instruction to the test instrument, and the execution result includes an error message; and, the test instrument receives the execution result returned by the dual-cell device under test, and based on the execution result, modifies that operation instruction and resends it or selects the next operation instruction to send to the dual-cell device under test.
5. The method according to claim 4, wherein, it further includes: the test instrument determines whether the test conditions for the power consumption test corresponding to each test instruction are met according to the execution results of each operation instruction corresponding to each test instruction returned by the dual-cell device under test. If so, it performs the power consumption test corresponding to that test instruction on the dual-cell device under test.
6. The method according to claim 1, wherein, after the test platform sends several test instructions to the test instrument, it further includes: the test platform also sends the number of test instructions to the test instrument; the test instrument receives the number of test instructions sent by the test platform, and after executing all the test instructions based on the number of test instructions, feeds back a message indicating that the power consumption test is completed to the test platform; and, the test platform receives the message indicating that the power consumption test is completed sent by the test instrument; the test platform obtains the final power consumption value of the dual-cell device under test based on the operating power consumption value and the leakage power consumption value of the dual-cell device under test in the test result, specifically: after the test platform receives the message indicating that the power consumption test is completed sent by the test instrument, it obtains the final power consumption value of the dual-cell device under test based on the operating power consumption value and the leakage power consumption value of the dual-cell device under test in the test result.
7. A dual-cell terminal power consumption test system, wherein, it includes: a test platform and a test instrument, wherein the dual-cell device under test is connected to a programmable power supply through a dummy battery as its power supply, and is communicatively connected to the test instrument through the dummy battery; the test platform is used to generate a test plan for testing the power consumption of the dual-cell device under test, and generate several test instructions according to the test plan and send them to the test instrument, wherein one test instruction is used to indicate the test of the leakage power consumption of the dual-cell device under test, and the remaining test instructions are used to indicate the test of the operating power consumption of the dual-cell device under test; the test instrument is used to receive each test instruction sent by the test platform, respectively test the leakage power consumption value and the operating power consumption value of the dual-cell device under test based on each test instruction, and feed back the test result to the test platform; The test platform is also used to receive the test results sent by the tester, and obtain the final power consumption value of the dual-cell terminal under test based on the operating power consumption value and the leakage power consumption value of the dual-cell terminal under test in the test results; The tester tests the leakage power consumption value of the dual-cell terminal under test, including: the average current value within a preset duration after the dual-cell terminal under test is powered off; the tester tests the operating power consumption value of the dual-cell terminal under test, including: any one or more of the average current values within a preset duration after the dual-cell terminal under test is in the screen-off standby state, and the average current values of the dual-cell terminal under test when running each preset service for a preset duration; Specifically, the test platform is used to: calculate the difference between the average current value within a preset duration after the dual-cell terminal under test is in the screen-off standby state and any one or more of the average current values of the dual-cell terminal under test when running each preset service for a preset duration and the average current value within a preset duration after the dual-cell terminal under test is powered off, to obtain several net current values; multiply the several net current values by 2 respectively to obtain several actual current values; and obtain the final power consumption value of the dual-cell terminal under test based on the several actual current values; The test platform calculates the final power consumption value of the dual-cell terminal under test using the following formula: P = B 1 a + B 2 A 1 +…+ B m+1 A m Wherein, P represents the final power consumption value of the dual-cell terminal under test; m represents the total number of preset services that the dual-cell terminal under test needs to run; a represents the actual current value corresponding to the power consumption after the dual-cell terminal under test enters the screen-off standby state, B 1 represents the power consumption ratio corresponding to the power consumption after the dual-cell terminal under test enters the screen-off standby state; A 1 represents the actual current value corresponding to the power consumption of the dual-cell terminal under test when running the first preset service, B 2 represents the power consumption ratio corresponding to the power consumption of the dual-cell terminal under test when running the first preset service; A m represents the actual current value corresponding to the power consumption of the dual-cell terminal under test when running the m-th preset service, B m+1 represents the power consumption ratio corresponding to the power consumption of the dual-cell terminal under test when running the m-th preset service, and B 1 +B 2 +…+B m+1 = 100%.
8. A computer device, characterized in that, it includes a memory and a processor, and a computer program is stored in the memory. When the processor runs the computer program stored in the memory, the processor executes the operations performed by any device in the dual-cell terminal power consumption test method according to any one of claims 1 to 6.
9. A computer-readable storage medium, on which a computer program is stored, characterized in that, when the computer program is executed by a processor, the processor executes the operations performed by any device in the dual-cell terminal power consumption test method according to any one of claims 1 to 6.
Citation Information
Patent Citations
Test system of terminal devices
CN108595299A