CN111752774B - Sleep pressure test method, system, computer device and storage medium - Google Patents

Sleep pressure test method, system, computer device and storage medium Download PDF

Info

Publication number
CN111752774B
CN111752774B CN202010435865.6A CN202010435865A CN111752774B CN 111752774 B CN111752774 B CN 111752774B CN 202010435865 A CN202010435865 A CN 202010435865A CN 111752774 B CN111752774 B CN 111752774B
Authority
CN
China
Prior art keywords
sleep
usb
tested
current
dormancy
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010435865.6A
Other languages
Chinese (zh)
Other versions
CN111752774A (en
Inventor
李龙
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Xian Fibocom Wireless Software Inc
Original Assignee
Xian Fibocom Wireless Software Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Xian Fibocom Wireless Software Inc filed Critical Xian Fibocom Wireless Software Inc
Priority to CN202010435865.6A priority Critical patent/CN111752774B/en
Publication of CN111752774A publication Critical patent/CN111752774A/en
Application granted granted Critical
Publication of CN111752774B publication Critical patent/CN111752774B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/22Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
    • G06F11/2273Test methods
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Power Sources (AREA)

Abstract

The application relates to a sleep pressure test method, a sleep pressure test system, computer equipment and a storage medium. The method comprises the following steps: displaying a dormant configuration page, and determining a communication address, a power-off frequency and a driving protocol of the USB component to be tested, which are configured based on the dormant configuration page; determining a protocol type of a driving protocol, and acquiring a corresponding keyword library according to the protocol type; determining target level parameters of the USB component to be tested based on the driving protocol and the keyword library; generating a dormancy control instruction according to the target level parameter and the power-off frequency; and issuing a dormancy control instruction to the USB component to be tested corresponding to the communication address so that the USB component to be tested performs dormancy pressure test based on the dormancy control instruction. By adopting the method, the test efficiency of the sleep pressure test can be improved.

Description

Sleep pressure test method, system, computer device and storage medium
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to a sleep pressure testing method, a sleep pressure testing system, a computer device, and a storage medium.
Background
With the development of science and technology, the requirements of people on electronic products are also becoming more and more strict. Currently, electronic products need to be subjected to a strict pressure test before leaving the factory, and a sleep test of a USB (Universal Serial Bus universal serial bus) module is an important one. Through repeated and repeated control of the USB module to enter the dormant state, whether the quality of the product meets the standard or not can be judged based on the dormant state of the USB module, and defective products are prevented from flowing into the market.
At present, the USB module is powered off and powered on mainly through manual operation, so that the USB module can be controlled to enter a dormant state through power-off treatment on the USB module, and the USB module can be awakened through power-on treatment on the USB module. However, manually powering off the USB module may result in reduced efficiency of the sleep pressure test.
Disclosure of Invention
In view of the foregoing, it is desirable to provide a sleep pressure test method, system, computer device, and storage medium capable of testing efficiency of the sleep pressure test.
A sleep pressure testing method, the method comprising:
displaying a dormant configuration page, and determining a communication address, a power-off frequency and a driving protocol of a USB component to be tested, which are configured based on the dormant configuration page;
determining the protocol type of the driving protocol, and acquiring a corresponding keyword library according to the protocol type;
determining a target level parameter of the USB component to be tested based on the driving protocol and a keyword library;
generating a dormancy control instruction according to the target level parameter and the power-off frequency;
and sending the dormancy control instruction to the USB component to be tested corresponding to the communication address, so that the USB component to be tested performs dormancy pressure test based on the dormancy control instruction.
In one embodiment, the method further comprises:
when the operation of clicking the sleep mode configuration control occurs, acquiring sleep mode parameters configured based on the sleep configuration page, and determining a connection mode with the USB module;
generating a corresponding dormancy configuration instruction based on the connection mode and the dormancy mode parameter;
and sending the dormancy configuration instruction to the USB module so that the USB module carries out corresponding configuration according to dormancy mode parameters in the dormancy configuration instruction.
In one embodiment, the determining the protocol type of the driving protocol and obtaining the corresponding keyword library according to the protocol type includes:
when the protocol type is a text type, acquiring a keyword library corresponding to the text type; the keyword library corresponding to the text type comprises a first keyword and a second keyword;
the USB component to be tested comprises a control pin; the determining, based on the driving protocol and the keyword library, the target level parameter of the USB component to be tested includes:
screening out target paragraphs corresponding to control pins from the driving protocol according to the first keywords;
Based on the second keyword, position information among all control pins is screened out from the target paragraph;
and determining a target level parameter according to the position information.
In one embodiment, the sleep configuration page has a sleep power consumption acquisition control therein; the method further comprises the steps of:
when the operation of clicking the sleep power consumption acquisition control is performed, acquiring the real-time current of the USB component to be tested in the sleep; the real-time current comprises a current value and acquisition time;
determining an extreme current according to the current value and the acquisition time;
and distinguishing and displaying the real-time current and the extreme current in the sleep configuration page, and determining the sleep power consumption of the USB component to be tested in the sleep time based on the real-time current and the extreme current.
In one embodiment, determining the extreme current from the current value and the acquisition time comprises:
acquiring a description point template and setting parameters;
determining the coordinates of the points corresponding to the current value and the acquisition time according to the setting parameters;
drawing a current trend curve on the dotting template based on the dotting coordinates;
and judging the corner points in the current trend curve as extreme currents.
A sleep pressure testing apparatus, the apparatus comprising:
the information acquisition module is used for displaying a dormant configuration page and determining a communication address, a power-off frequency and a driving protocol of the USB component to be tested, which are configured based on the dormant configuration page;
the instruction generation module is used for determining the protocol type of the driving protocol and acquiring a corresponding keyword library according to the protocol type; determining a target level parameter of the USB component to be tested based on the driving protocol and a keyword library; generating a dormancy control instruction according to the target level parameter and the power-off frequency;
and the control module is used for sending the dormancy control instruction to the USB component to be tested corresponding to the communication address so that the USB component to be tested performs dormancy and awakening operations based on the dormancy control instruction.
A computer device comprising a memory storing a computer program and a processor which when executing the computer program performs the steps of:
displaying a dormant configuration page, and determining a communication address, a power-off frequency and a driving protocol of a USB component to be tested, which are configured based on the dormant configuration page;
Determining the protocol type of the driving protocol, and acquiring a corresponding keyword library according to the protocol type;
determining a target level parameter of the USB component to be tested based on the driving protocol and a keyword library;
generating a dormancy control instruction according to the target level parameter and the power-off frequency;
and sending the dormancy control instruction to the USB component to be tested corresponding to the communication address, so that the USB component to be tested performs dormancy pressure test based on the dormancy control instruction.
A computer readable storage medium having stored thereon a computer program which when executed by a processor performs the steps of:
displaying a dormant configuration page, and determining a communication address, a power-off frequency and a driving protocol of a USB component to be tested, which are configured based on the dormant configuration page;
determining the protocol type of the driving protocol, and acquiring a corresponding keyword library according to the protocol type;
determining a target level parameter of the USB component to be tested based on the driving protocol and a keyword library;
generating a dormancy control instruction according to the target level parameter and the power-off frequency;
and sending the dormancy control instruction to the USB component to be tested corresponding to the communication address, so that the USB component to be tested performs dormancy pressure test based on the dormancy control instruction.
According to the sleep pressure testing method, the sleep pressure testing system, the computer equipment and the storage medium, the communication address, the power-off frequency and the driving protocol of the USB component to be tested can be obtained based on the sleep configuration page by displaying the sleep configuration page; the protocol type of the driving protocol can be judged by acquiring the driving protocol, and a corresponding keyword library is acquired according to the protocol type; the target level parameters of all the control pins in the USB component to be tested can be determined based on the keyword library by acquiring the keyword library, and a dormancy control instruction is generated according to the target level parameters of all the control pins and the acquired power-off frequency; by generating the sleep control instruction, the sleep control instruction can be issued to the USB component to be tested corresponding to the communication address, so that when the USB component to be tested can carry out sleep pressure test based on the sleep control instruction. Because the user only needs to dispose communication address, outage frequency and the drive protocol of the USB subassembly that awaits measuring in dormancy configuration page, can generate dormancy control command to the USB subassembly that awaits measuring can carry out pressure test based on dormancy control command is automatic, compares in traditional needs manual work and cuts off, supply power for the USB module, and this application can promote dormancy pressure test's test efficiency greatly.
Drawings
FIG. 1 is a diagram of an application environment of a sleep pressure test method in one embodiment;
FIG. 2 is a flow chart of a sleep pressure test method according to an embodiment;
FIG. 3 is a schematic diagram of a test computer connected to a USB device under test according to one embodiment;
FIG. 4 is a flow chart illustrating a method of configuring a sleep mode according to an embodiment;
FIG. 5A is a schematic diagram showing a list of real-time currents in one embodiment;
FIG. 5B is a schematic diagram showing a real-time current graphically in one embodiment;
FIG. 6 is a block diagram of a sleep pressure testing apparatus in one embodiment;
fig. 7 is an internal structural diagram of a computer device in one embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application will be further described in detail with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the present application.
The sleep pressure testing method provided by the application can be applied to an application environment shown in figure 1. The test computer 102 communicates with the USB device under test 104 via a serial port line, a USB (Universal Serial Bus ) line, or a GPIB (General-Purpose Interface Bus, universal interface bus) line. The test computer 102 may be, but not limited to, various personal computers, notebook computers, tablet computers, and the test computer 102 may be implemented by a stand-alone test computer or a test computer cluster composed of a plurality of test computers. The USB component 104 to be tested comprises a power supply, a test base, a relay and a USB module. The test computer 102 is provided with a sleep control platform for controlling the USB device under test 104 to enter a sleep state or wake up from sleep.
In one embodiment, as shown in fig. 2, a sleep pressure testing method is provided, and the method is applied to the test computer in fig. 1 for illustration, and includes the following steps:
s202, a dormant configuration page is displayed, and the communication address, the power-off frequency and the driving protocol of the USB component to be tested configured based on the dormant configuration page are determined.
The sleep configuration page is written based on an automatic test framework, and can be used for carrying out corresponding configuration on sleep pressure test tasks.
Specifically, a developer may write an automation script for implementing the sleep stress test based on the automation test framework and generate a sleep stress test application based on the automation script. When the dormant power consumption test is required to be carried out on the USB component to be tested, a user can open the dormant configuration page by clicking an application identifier of the dormant pressure test application. The USB component to be tested is a set of system formed by combining a power supply, a test bottom plate, a relay and a USB module. The power supply refers to a device for supplying power; the test base plate is a PCB (Printed Circuit Board printed circuit board) board capable of controlling the relay to be switched on and switched off according to an automatic script written by a developer, and comprises a serial port, a USB interface and the like; the USB module is a communication module including a USB interface, and based on the communication module, communication data can be sent and received. The computer to be tested indirectly controls the USB module to enter the dormant state or enter the wake-up state by controlling the switch and the closing of the relay, so that the dormant state of the USB module can be further analyzed later. The sleep refers to that the whole USB module does not receive and transmit communication data, so that the USB module is in a low-power consumption state. The awake state refers to a state in which the USB module performs frequent data transmission and reception, and thus is in high power consumption. The USB module includes a standby power source so that the USB module can consume power based on the power consumption required by the standby power source to maintain the sleep state.
As shown in fig. 3, when the test computer is connected with the USB component to be tested, that is, when the test computer is connected with the serial port interface in the test base board through the serial port line, and the DTR (Data Terminal Ready data ready) control pin in the serial port interface in the test base board is connected with the input end of the relay, and the output end of the relay is connected with the USB module, the test computer obtains the communication address of the test base board through the serial port line and the preset serial port protocol, and displays the communication address in the device selection control of the sleep configuration page. When confirming that the user selects one communication address in the equipment selection control, the test computer takes the communication address selected by the user as the communication address of the current USB component to be tested. FIG. 3 is a schematic diagram of a test computer connected to a USB device under test according to one embodiment.
Meanwhile, the user can configure the power-off frequency for the current USB component to be tested in the dormant configuration page and upload the driving protocol based on the dormant configuration page. The driving protocol refers to a protocol for driving the test base plate to operate. The drive protocol includes testing the level states that each pin in the serial interface in the backplane should get under different conditions. The level state comprises a high level exceeding a preset voltage threshold and a low level smaller than or equal to the preset voltage threshold. The protocol type of the driving protocol may be text type or image type. For example, the drive protocol may be a schematic circuit diagram of the test chassis, or instructions for use of the test chassis.
In one embodiment, the drive protocol is pre-stored in the test chassis. When the test computer determines the communication address of the current USB component to be tested, the test computer pulls the driving protocol from the test base plate according to the communication address.
In one embodiment, the sleep configuration page includes at least one of a sleep control, a power down frequency setting control, a scene cut control, and a device selection control. The dormancy control is used for generating dormancy control instructions. The power-off frequency setting control is used for setting the dormancy and awakening frequency of the USB component to be tested. The scene switching control is used for controlling the USB component to be tested to switch different scenes, such as sleep pressure test in the Bluetooth-on scene and sleep pressure test in the WIFI-on scene. The developer can write different test scripts for different scenes in advance, so that the scenes can be switched based on the scene switching control. Because one test computer can test a plurality of USB components to be tested at the same time, the USB components to be tested which are required to be set currently can be determined based on the device selection control.
S204, determining the protocol type of the driving protocol, and acquiring a corresponding keyword library according to the protocol type.
S206, determining the target level parameters of the USB component to be tested based on the driving protocol and the keyword library.
The target level parameter refers to a level value that should be set by each control pin in the serial interface in the test backplane. The control pins are pins of an interface which is positioned in the USB component to be tested and connected with the test computer. For example, when the test computer is connected with the test base plate through the serial port line, the control pin is a pin in the serial port interface in the test base plate connected with the serial port line. The serial interface generally has 9 control pins, and each control pin corresponds to a different function, for example, the serial interface has a DTR (Data Terminal Ready data ready) control pin. Since the arrangement order of the control pins in the serial interfaces produced by manufacturers of different serial interfaces is different, it is necessary to determine the arrangement order of the pins based on the driving protocol.
The target level parameters include a first target level parameter and a second target level parameter. The first target level parameter refers to a level value required by each control pin in the serial interface when the control relay is in a closed state. The second target level parameter refers to a level value required by each control pin in the serial interface when the control relay is in an off state.
Specifically, a keyword library related to the type of the driving protocol is preset in the test computer. When the driving protocol is obtained, the test computer determines that the driving protocol is of an image type or a text type, and obtains a corresponding keyword library according to the type of the driving protocol.
When the driving type is the image type, the corresponding keyword library contains the names of all the control pins in the serial interface. The test computer performs image recognition on the circuit schematic diagram of the image type, searches the position information among the control pins in the circuit schematic diagram according to the names of the control pins, and determines the arrangement sequence of the control pins in the serial port interface according to the position information, so that the test computer can determine the target level parameters of the control pins in the USB component to be tested according to the arrangement sequence. The names of the control pins in the circuit schematic diagram are identified, and the test computer can identify the names of the control pins in the circuit schematic diagram based on a preset image identification algorithm. For example, when determining that the DTR control pins are located at the start positions of the control pins, the test computer may determine that the first target level parameters of the control pins are: 1. 0, 0; the second target level parameter is: 0. 0, 0; wherein 1 represents a high level and 0 represents a low level.
When the driving type is the text type, the testing computer acquires a keyword library corresponding to the text type. The keyword library corresponding to the text type comprises a first keyword and a second keyword. The test computer screens out target paragraphs corresponding to the control pins from the drive protocol according to the first keywords; based on the second keyword, position information among all control pins is screened out from the target paragraph; and determining target level parameters of each control pin according to the position information.
In one embodiment, after the test computer obtains the driving protocol, the driving protocol may be displayed on the screen, so that the user may determine, based on the displayed driving protocol, the position information of the DTR control pins in the serial port interface, determine, according to the position information of the DTR control pins, target level parameters of each control pin, and input the determined target level parameters into the sleep configuration page. For example, when determining that the DTR control pin is located at the start position in each control pin, the user may set the first target level parameter to: 1. 0, 0; setting the second target level parameter to: 0. 0, 0; wherein 1 represents a high level and 0 represents a low level.
S208, generating a dormancy control instruction according to the target level parameter and the outage frequency.
S210, issuing a sleep control instruction to the USB component to be tested corresponding to the communication address, so that the USB component to be tested performs sleep pressure test based on the sleep control instruction.
Specifically, the test computer converts the target level parameter into a corresponding serial communication code based on a serial protocol, and generates a sleep control instruction according to the serial communication code and the power-off frequency. And the computer to be tested transmits the generated serial port communication instruction to the USB test assembly of the pair according to the communication address, namely to the test base plate, so that the test base plate controls the level conversion of each control pin in the serial port interface at the power-off frequency. For example, when the power-off frequency is 1/s (once per second), the test base plate turns the level of the DTR control pin at a frequency of 1/s, so that when the DTR pin is at a high level, namely the DTR pin outputs 1.8V level, the relay connected with the DTR pin is in a closed state, and the USB module connected with the relay firstly can enter an awake state; when the DTR pin is at a low level, that is, the DTR pin outputs 0V, the relay connected with the DTR pin is in an off state, so that the USB module connected with the relay can enter a sleep state.
According to the sleep pressure testing method, the communication address, the power-off frequency and the driving protocol of the USB component to be tested can be obtained based on the sleep configuration page by displaying the sleep configuration page; the protocol type of the driving protocol can be judged by acquiring the driving protocol, and a corresponding keyword library is acquired according to the protocol type; the target level parameters of all the control pins in the USB component to be tested can be determined based on the keyword library by acquiring the keyword library, and a dormancy control instruction is generated according to the target level parameters of all the control pins and the acquired power-off frequency; by generating the sleep control instruction, the sleep control instruction can be issued to the USB component to be tested corresponding to the communication address, so that when the USB component to be tested can carry out sleep pressure test based on the sleep control instruction. Because the user only needs to dispose communication address, outage frequency and the drive protocol of the USB subassembly that awaits measuring in dormancy configuration page, can generate dormancy control command to the USB subassembly that awaits measuring can carry out pressure test based on dormancy control command is automatic, compares in traditional needs manual work and cuts off, supply power for the USB module, and this application can promote dormancy pressure test's test efficiency greatly.
In addition, the protocol type is determined, and the target level parameters of each control pin in the USB component to be tested are determined according to the protocol type, so that the scheme can be compatible with various protocol types and different communication interfaces produced by different manufacturers.
In one embodiment, as shown in fig. 4, the sleep pressure testing method further includes:
s402, when the operation of clicking the sleep mode configuration control occurs, acquiring sleep mode parameters configured based on a sleep configuration page, and determining a connection mode with the USB module;
s404, generating a corresponding dormancy configuration instruction based on the connection mode and the dormancy mode parameter;
s406, the dormancy configuration instruction is sent to the USB module, so that the USB module carries out corresponding configuration according to dormancy mode parameters in the dormancy configuration instruction.
The sleep configuration page is provided with a sleep mode configuration control, and the sleep mode configuration control is used for setting a sleep mode of the USB module. The connection method comprises USB connection and serial connection.
Specifically, when it is determined that the user clicks the sleep mode configuration control, the test computer may generate a popup window for inputting sleep mode parameters in the sleep configuration page based on the clicking operation of the user, and the user may input sleep mode parameters in the popup window.
Further, when the USB module has a USB interface and a serial interface, the user may connect the USB module with the test computer based on the serial interface or the USB interface. The test computer generates a corresponding USB communication instruction based on the USB communication protocol, generates a serial port communication instruction based on the serial port protocol, and sends the USB communication instruction and the serial port communication instruction to the USB interface. When the test computer receives response information returned by the USB module based on the USB communication instruction, the USB module can be considered to be connected with the test computer based on the USB interface; when the test computer receives the response information returned by the USB module based on the USB communication instruction, the USB module can be considered to be connected with the test computer based on the serial port.
Further, the test computer generates a sleep configuration instruction based on the sleep mode parameter and the connection mode, and sends the sleep configuration instruction to the USB module, so that the USB module performs configuration of the sleep mode according to the sleep mode parameter in the sleep configuration instruction.
In this embodiment, because the sleep instruction is generated based on the connection mode, the present application may be compatible with different connection modes, thereby improving efficiency of sleep pressure test.
In one embodiment, determining a protocol type of the driving protocol and obtaining a corresponding keyword library according to the protocol type includes: when the protocol type is a text type, acquiring a keyword library corresponding to the text type; the keyword library corresponding to the text type comprises a first keyword and a second keyword; based on the driving protocol and the keyword library, determining the target level parameters of each control pin in the USB component to be tested comprises: screening out target paragraphs corresponding to the control pins from the driving protocol according to the first keywords; based on the second keyword, position information among all control pins is screened out from the target paragraph; and determining the target level parameter according to the position information.
The first keywords comprise names of control pins in the serial interfaces. The second keyword is a word having a positional meaning, for example, the second keyword may be: first row, first digit, first order, etc.
Specifically, when the protocol type of the driving protocol is a text type, the test computer acquires a keyword library corresponding to the text type, searches for paragraphs containing names of control pins in the driving protocol of the text type based on the names of the control pins, and refers to the searched paragraphs as target paragraphs. Meanwhile, the test computer searches the position information of each control pin in the target paragraph according to the second keyword, and determines the arrangement sequence of each control pin in the serial interface based on the position information. For example, when the target paragraph is "DTR control pin is located at the first row of the first bits; when the TXD (data transmitting end) control pin is located at the first row of the second bits ", the test computer may determine that the position information corresponding to the DTR control pin is the" first row of the first bits "based on the second keyword; the position information corresponding to the TXD control pin is 'first row second position', so that the test computer can determine the arrangement sequence between the DTR and the TXD according to the position information. And then, the test computer determines the target level parameters according to the arrangement sequence of the control pins.
In this embodiment, since the target level parameter can be automatically determined based on the first keyword and the second keyword, the test efficiency of the sleep pressure test can be improved.
In one embodiment, the sleep pressure testing method further includes: when the operation of clicking the sleep power consumption acquisition control is performed, acquiring the real-time current of the USB component to be tested in the sleep; the real-time current comprises a current value and acquisition time; determining an extreme current according to the current value and the acquisition time; and distinguishing and displaying the real-time current and the extreme current in the sleep configuration page, and determining the sleep power consumption of the USB component to be tested in the sleep time based on the real-time current and the extreme current.
The sleep configuration page is provided with a sleep power consumption acquisition control, and the sleep power consumption acquisition control is used for acquiring power consumed by the USB module during sleep. The sleep power consumption includes average sleep power consumption and general sleep power consumption. The average dormancy power consumption is determined based on the real-time current, and can truly reflect the dormancy power consumption information of the communication component to be tested in the dormancy time. The general sleep power consumption is power consumption information determined based on real-time current excluding extreme current, and is used to reflect a normal power consumption value that a communication component to be tested should consume when data is not transceived and the operation is normal. The extreme current value refers to a current bump and a current dip during the sleep period. When the USB device under test is in error, an extreme current is generated.
Specifically, when the USB module is confirmed to be in the sleep state, the test computer can acquire real-time current in the USB module at a preset acquisition frequency. The real-time current comprises a current value and the acquisition time of the current. The test computer sequences the plurality of real-time currents according to the acquisition time to obtain a real-time current sequence, and traverses each real-time current in the real-time current sequence. When the test computer obtains the real-time current of the current traversal order, the test computer determines the front-end real-time current which is adjacent to the real-time current of the current traversal order and is positioned before the real-time current of the current traversal order, and the back-end real-time current which is adjacent to the real-time current of the current traversal order and is positioned after the real-time current of the current traversal order. The test computer extracts the current value of the current real-time current, the current value of the preceding real-time current and the current value of the subsequent real-time current in the current traversal order, and when the current value of the current real-time current in the current traversal order is larger than the current value of the preceding real-time current and smaller than the current value of the subsequent real-time current, the current in the current traversal order can be considered as a current protrusion, and at the moment, the test computer judges the current in the current traversal order as an extreme current. When the current value of the real-time current of the current traversal sequence is smaller than the current value of the preceding real-time current and smaller than the current value of the following real-time current, the real-time current of the current traversal sequence can be considered as a current sudden drop, and the test computer judges the real-time current of the current traversal sequence as an extreme current.
The sleep configuration page is provided with a display area for displaying the collected real-time current and the extreme current. Presentation forms include, but are not limited to, a curve presentation as shown in fig. 5 and a list presentation. FIG. 5A is a schematic diagram showing a list of real-time currents in one embodiment; fig. 5B is a schematic diagram showing a real-time current curve in one embodiment. After determining the extreme current, the test computer may draw a current curve with the collection time as an abscissa and the current value as an ordinate, and display the drawn current curve in the display area, and then, based on the collection time of the extreme current, display the extreme current in the current curve in a distinguishing manner, for example, highlight display the extreme current in the drawn current curve according to the collection time of the extreme current and the current value. Alternatively, after determining the extreme current, the test computer may generate a current list based on the acquisition time and the current value, and display the generated current list in the display area, and then, distinguish the display of the extreme current in the current list based on the acquisition time of the extreme current.
Further, the test computer counts the number value of the real-time current received in the sleep time period, and superimposes the current values of the real-time currents to obtain a current sum, and average sleep power consumption is obtained according to the current sum and the number value, so that a user can determine the actual sleep power consumption of the USB component to be tested in the sleep time period based on the average sleep power consumption. The test computer deletes the extreme current from all the received real-time currents, and then calculates the general sleep power consumption based on the real-time current deleting the extreme current, so that a user can determine the specific power consumption value which should be consumed by the USB component to be tested in an ideal state within the sleep time based on the general sleep power consumption, namely the power consumption value which should be consumed under the conditions that the transmitted data is not received at all and the operation is normal. Therefore, the user can further analyze the running condition of the USB component to be tested based on the average sleep power consumption and the general sleep power consumption.
In this embodiment, because the real-time current is automatically collected based on the automated test script, compared with the traditional manual collection of the current value, the current detection method and device can accurately obtain the extreme current, and determine the accurate sleep power consumption based on the extreme current and the real-time current.
In one embodiment, determining the extreme current from the current value and the acquisition time comprises: acquiring a description point template and setting parameters; determining the coordinates of the points corresponding to the current value and the acquisition time according to the set parameters; drawing a current trend curve on a dotting template based on dotting coordinates; the corner points in the current trend curve are determined as extreme currents.
Specifically, the test computer prestores a dotting template and setting parameters configured for the dotting template. The dotting template refers to a template that includes coordinate axes but does not include a current curve. The setting parameters include an axis coordinate scale value and a Y-axis coordinate unit. The axis coordinate scale values include a Y-axis coordinate scale value, and an X-axis coordinate scale value. The scale value of the axis coordinate refers to numerical information represented by unit scales on the axis coordinate; the axis coordinate unit refers to unit information of coordinate axes, for example, the axis coordinate unit of the Y axis may be milliamp, and the corresponding axis coordinate scale value may be 1, so that each unit scale on the Y axis coordinate may be expressed as 1 milliamp. When all the real-time currents in the dormancy are obtained, the test computer obtains the setting information of the USB module, and determines the unit information of the current value in the obtained real-time currents according to the setting information of the USB module, for example, the unit of the current value which is agreed to be output in the setting information of the programmable power supply is milliamp. The test computer obtains a conversion relation between a preset axis coordinate unit and the setting information, and converts a unit of a current value in the real-time current into a Y-axis coordinate unit based on the conversion relation.
Further, the test computer sequences all the real-time currents in the sleep time according to the acquisition time to obtain a real-time current sequence, and traverses the first real-time current sequence according to the arrangement order to convert each real-time current into a description point in the description point template. More specifically, the test computer acquires the real-time current of the current traversal sequence and records the sequence value of the current traversal sequence, for example, the test computer is provided with a sequence value with an initial value of 0, and when the test computer acquires the real-time current positioned at the head of the real-time current sequence, the test computer sets the sequence value to be 1; when the test computer obtains the next real-time current after the head of the real-time current sequence, the test computer adds 1 to the sequence value, and the sequence value at the moment is 2. The test computer divides the current value in the real-time current by the Y-axis coordinate scale value to obtain a Y-axis description point corresponding to the real-time current of the current traversal sequence, divides the sequence value corresponding to the current traversal sequence by the X-axis scale value to obtain an X-axis description point corresponding to the real-time current of the current traversal sequence, combines the X-axis description point and the Y-axis description point to obtain a description point coordinate, and draws the description point of the real-time current of the current traversal sequence in the description point template based on the description point coordinate. When the real-time current sequence is traversed, the test computer is connected with each drawing point in the drawing point template to obtain a current trend curve, so that the test computer can identify the current trend curve, and the corner points, namely the salient point and the salient point, in the current trend curve are judged to be extreme current values.
In one embodiment, the test computer correspondingly displays a current trend curve, acquires an extreme current value selected by a user in the current trend curve, and correspondingly corrects and identifies the generated extreme current value according to the extreme current value selected by the user, so that the accuracy of determining the extreme current value is improved.
In the embodiment, through drawing the current trend curve, the corner points in the current trend curve can be rapidly identified; through quick determination of the corner points, the corner points can be determined to be the extreme currents, so that the determination efficiency of the extreme currents can be improved, and the determination efficiency of the dormancy power consumption can be improved.
In one embodiment, a sleep pressure testing system is provided, the system comprising: testing a computer and a USB component to be tested; the USB component to be tested comprises a power supply, a test bottom plate, a relay and a USB module; the power supply is used for providing voltage for the test base plate and the relay; the test computer is used for displaying a dormancy configuration page, acquiring a communication address, a power-off frequency and a driving protocol of the USB component to be tested based on the dormancy configuration page, generating a dormancy control instruction based on the driving protocol and the power-off frequency, and transmitting the dormancy control instruction to the USB component to be tested corresponding to the communication address; the test base plate is used for receiving the dormancy control instruction and controlling the opening and closing of the relay according to the power-off frequency in the dormancy control instruction; the relay is used for transmitting the voltage provided by the power supply to the USB module when the relay is closed; when the USB module is disconnected, the voltage provided by the power supply is paused to be transmitted to the USB module; the USB module is used for entering a dormant state when no voltage is received; upon receiving the voltage, the wake-up state is entered from the sleep state.
Specifically, as shown in fig. 3, a power supply is connected to the test base plate and the relay to supply electric power to the test base plate and the relay. For example, the power supply may provide a 5V voltage to the test floor and the relay. The test computer is connected with the test base plate through a serial port line, a dormant pressure test application is operated in the test computer, and the level state of the DTR control pin in the test base plate can be controlled to overturn based on the dormant pressure test application. For example, the test computer may generate a sleep control command and send the sleep control command to the connection serial port in the test backplane, so that the serial port interface may repeatedly convert from 0 volt to 1.8 volts or from 1.8 volts to 0 volt according to the sleep control command. The DTR control pin in the test bottom plate is connected with the input section of the relay, when the DTR pin is 1.8V, the relay is in a closed state, and the voltage provided by the power supply at the output end of the relay is the voltage provided by the power supply at the output end of the relay, for example, in the above example, the relay outputs 5V voltage; when the DTR pin is 0V, the relay is in an off state, and the output end of the relay does not provide voltage. The output end of the relay is connected with the USB module, so that when the relay does not output voltage, the USB module enters a dormant state, and when the relay outputs voltage, the USB module enters an awake state.
In this embodiment, only the level state of the DTR pin needs to be controlled, so that sleep control of the USB module can be achieved.
In one embodiment, the test computer is further configured to obtain a preset communication instruction, and send the communication instruction to the USB module according to the power-off frequency; and when receiving reply information of the USB module to the communication instruction, judging that the USB module is in an awakening state.
Specifically, because the relay is turned on and off according to the power-off frequency, the test computer can judge whether the relay is in a closed state according to the power-off frequency, so that the running state of the USB module at the moment can be determined. The test computer obtains a preset communication instruction and sends the communication instruction to the USB module in a wired or wireless mode according to the power-off frequency. When the USB module receives the communication instruction and is in the wake-up state, reply information is generated based on the communication instruction, and the reply information is returned to the computer to be tested. When the USB module receives the communication instruction but is in a dormant state, the USB module discards the communication instruction. Therefore, the test computer can judge that the USB module is in the wake-up state when receiving the reply information, and further can count the success probability of the USB module entering the sleep state in a preset counting time period.
In this embodiment, since the communication instruction is sent to the USB module at the power-off frequency, the success probability of the USB entering the sleep state may be determined according to the reply information, and then the USB module may be optimized according to the success probability.
It should be understood that, although the steps in the flowcharts of fig. 2 and 4 are shown in order as indicated by the arrows, these steps are not necessarily performed in order as indicated by the arrows. The steps are not strictly limited to the order of execution unless explicitly recited herein, and the steps may be executed in other orders. Moreover, at least some of the steps in fig. 2, 4 may include steps or stages that are not necessarily performed at the same time, but may be performed at different times, or the order in which the steps or stages are performed is not necessarily sequential, but may be performed in rotation or alternatively with at least some of the other steps or stages.
In one embodiment, as shown in fig. 6, there is provided a sleep pressure testing apparatus 600 comprising: an information acquisition module 602, an instruction generation module 604, and a control module 606, wherein:
The information acquisition module 602 is configured to display a sleep configuration page, and determine a communication address, a power-off frequency and a driving protocol of the USB component to be tested configured based on the sleep configuration page;
the instruction generating module 604 is configured to determine a protocol type of the driving protocol, and obtain a corresponding keyword library according to the protocol type; determining target level parameters of the USB component to be tested based on the driving protocol and the keyword library; generating a dormancy control instruction according to the target level parameter and the outage frequency;
the control module 606 is configured to issue a sleep control instruction to the USB component to be tested corresponding to the communication address, so that the USB component to be tested performs sleep and wake operations based on the sleep control instruction.
In one embodiment, the sleep pressure testing apparatus 600 is further configured to obtain sleep mode parameters configured based on the sleep configuration page and determine a connection mode with the USB module when the operation of clicking the sleep mode configuration control occurs; generating a corresponding dormancy configuration instruction based on the connection mode and the dormancy mode parameter; and sending the dormancy configuration instruction to the USB module so that the USB module carries out corresponding configuration according to the dormancy mode parameters in the dormancy configuration instruction.
In one embodiment, the instruction generating module 604 further includes a keyword library obtaining module 6041, configured to obtain, when the protocol type is a text type, a keyword library corresponding to the text type; the keyword library corresponding to the text type comprises a first keyword and a second keyword; the USB component to be tested comprises a control pin; based on the driving protocol and the keyword library, determining the target level parameter of the USB component to be tested comprises: screening out target paragraphs corresponding to the control pins from the driving protocol according to the first keywords; based on the second keyword, position information among all control pins is screened out from the target paragraph; and determining the target level parameter according to the position information.
In one embodiment, the sleep pressure testing apparatus 600 is further configured to obtain a real-time current of the USB component under test in sleep when the operation of clicking the sleep power consumption obtaining control occurs; the real-time current comprises a current value and acquisition time; determining an extreme current according to the current value and the acquisition time; and distinguishing and displaying the real-time current and the extreme current in the sleep configuration page, and determining the sleep power consumption of the USB component to be tested in the sleep time based on the real-time current and the extreme current.
In one embodiment, the sleep pressure testing apparatus 600 is further configured to obtain a dotting template and a setting parameter; determining the coordinates of the points corresponding to the current value and the acquisition time according to the set parameters; drawing a current trend curve on a dotting template based on dotting coordinates; the corner points in the current trend curve are determined as extreme currents.
For specific limitations of the sleep pressure test apparatus, reference may be made to the above limitations of the sleep pressure test method, and no further description is given here. The above-described modules in the sleep pressure test apparatus may be implemented in whole or in part by software, hardware, or a combination thereof. The above modules may be embedded in hardware or may be independent of a processor in the computer device, or may be stored in software in a memory in the computer device, so that the processor may call and execute operations corresponding to the above modules.
In one embodiment, a computer device is provided, which may be a terminal, and the internal structure of which may be as shown in fig. 7. The computer device includes a processor, a memory, a communication interface, a display screen, and an input device connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The communication interface of the computer device is used for carrying out wired or wireless communication with an external terminal, and the wireless mode can be realized through WIFI, an operator network, NFC (near field communication) or other technologies. The computer program when executed by a processor implements a sleep pressure test method. The display screen of the computer equipment can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer equipment can be a touch layer covered on the display screen, can also be keys, a track ball or a touch pad arranged on the shell of the computer equipment, and can also be an external keyboard, a touch pad or a mouse and the like.
It will be appreciated by those skilled in the art that the structure shown in fig. 7 is merely a block diagram of some of the structures associated with the present application and is not limiting of the computer device to which the present application may be applied, and that a particular computer device may include more or fewer components than shown, or may combine certain components, or have a different arrangement of components.
In one embodiment, a computer device is provided comprising a memory and a processor, the memory having stored therein a computer program, the processor when executing the computer program performing the steps of:
displaying a dormant configuration page, and determining a communication address, a power-off frequency and a driving protocol of the USB component to be tested, which are configured based on the dormant configuration page;
determining a protocol type of a driving protocol, and acquiring a corresponding keyword library according to the protocol type;
determining target level parameters of the USB component to be tested based on the driving protocol and the keyword library;
generating a dormancy control instruction according to the target level parameter and the outage frequency;
and issuing a dormancy control instruction to the USB component to be tested corresponding to the communication address so that the USB component to be tested performs dormancy pressure test based on the dormancy control instruction.
In one embodiment, the sleep configuration page has a sleep mode configuration control therein; the USB component to be tested comprises a USB module; the processor when executing the computer program also implements the steps of:
when the operation of clicking the sleep mode configuration control occurs, acquiring sleep mode parameters configured based on a sleep configuration page, and determining a connection mode with the USB module;
generating a corresponding dormancy configuration instruction based on the connection mode and the dormancy mode parameter;
and sending the dormancy configuration instruction to the USB module so that the USB module carries out corresponding configuration according to the dormancy mode parameters in the dormancy configuration instruction.
In one embodiment, the processor when executing the computer program further performs the steps of:
when the protocol type is a text type, acquiring a keyword library corresponding to the text type; the keyword library corresponding to the text type comprises a first keyword and a second keyword;
the USB component to be tested comprises a control pin; based on the driving protocol and the keyword library, determining the target level parameter of the USB component to be tested comprises:
screening out target paragraphs corresponding to the control pins from the driving protocol according to the first keywords;
based on the second keyword, position information among all control pins is screened out from the target paragraph;
And determining the target level parameter according to the position information.
In one embodiment, the processor when executing the computer program further performs the steps of:
when the operation of clicking the sleep power consumption acquisition control is performed, acquiring the real-time current of the USB component to be tested in the sleep; the real-time current comprises a current value and acquisition time;
determining an extreme current according to the current value and the acquisition time;
and distinguishing and displaying the real-time current and the extreme current in the sleep configuration page, and determining the sleep power consumption of the USB component to be tested in the sleep time based on the real-time current and the extreme current.
In one embodiment, the processor when executing the computer program further performs the steps of:
acquiring a description point template and setting parameters;
determining the coordinates of the points corresponding to the current value and the acquisition time according to the set parameters;
drawing a current trend curve on a dotting template based on dotting coordinates;
the corner points in the current trend curve are determined as extreme currents.
In one embodiment, a computer readable storage medium is provided having a computer program stored thereon, which when executed by a processor, performs the steps of:
displaying a dormant configuration page, and determining a communication address, a power-off frequency and a driving protocol of the USB component to be tested, which are configured based on the dormant configuration page;
Determining a protocol type of a driving protocol, and acquiring a corresponding keyword library according to the protocol type;
determining target level parameters of the USB component to be tested based on the driving protocol and the keyword library;
generating a dormancy control instruction according to the target level parameter and the outage frequency;
and issuing a dormancy control instruction to the USB component to be tested corresponding to the communication address so that the USB component to be tested performs dormancy pressure test based on the dormancy control instruction.
In one embodiment, the sleep configuration page has a sleep mode configuration control therein; the USB component to be tested comprises a USB module; the computer program when executed by the processor also performs the steps of:
when the operation of clicking the sleep mode configuration control occurs, acquiring sleep mode parameters configured based on a sleep configuration page, and determining a connection mode with the USB module;
generating a corresponding dormancy configuration instruction based on the connection mode and the dormancy mode parameter;
and sending the dormancy configuration instruction to the USB module so that the USB module carries out corresponding configuration according to the dormancy mode parameters in the dormancy configuration instruction.
In one embodiment, the computer program when executed by the processor further performs the steps of:
when the protocol type is a text type, acquiring a keyword library corresponding to the text type; the keyword library corresponding to the text type comprises a first keyword and a second keyword;
The USB component to be tested comprises a control pin; based on the driving protocol and the keyword library, determining the target level parameter of the USB component to be tested comprises:
screening out target paragraphs corresponding to the control pins from the driving protocol according to the first keywords;
based on the second keyword, position information among all control pins is screened out from the target paragraph;
and determining the target level parameter according to the position information.
In one embodiment, the computer program when executed by the processor further performs the steps of:
when the operation of clicking the sleep power consumption acquisition control is performed, acquiring the real-time current of the USB component to be tested in the sleep; the real-time current comprises a current value and acquisition time;
determining an extreme current according to the current value and the acquisition time;
and distinguishing and displaying the real-time current and the extreme current in the sleep configuration page, and determining the sleep power consumption of the USB component to be tested in the sleep time based on the real-time current and the extreme current.
In one embodiment, the computer program when executed by the processor further performs the steps of:
acquiring a description point template and setting parameters;
determining the coordinates of the points corresponding to the current value and the acquisition time according to the set parameters;
Drawing a current trend curve on a dotting template based on dotting coordinates;
the corner points in the current trend curve are determined as extreme currents.
Those skilled in the art will appreciate that implementing all or part of the above described methods may be accomplished by way of a computer program stored on a non-transitory computer readable storage medium, which when executed, may comprise the steps of the embodiments of the methods described above. Any reference to memory, storage, database, or other medium used in embodiments provided herein may include at least one of non-volatile and volatile memory. The nonvolatile Memory may include Read-Only Memory (ROM), magnetic tape, floppy disk, flash Memory, optical Memory, or the like. Volatile memory can include random access memory (Random Access Memory, RAM) or external cache memory. By way of illustration, and not limitation, RAM can be in the form of a variety of forms, such as static random access memory (Static Random Access Memory, SRAM) or dynamic random access memory (Dynamic Random Access Memory, DRAM), and the like.
The technical features of the above embodiments may be arbitrarily combined, and all possible combinations of the technical features in the above embodiments are not described for brevity of description, however, as long as there is no contradiction between the combinations of the technical features, they should be considered as the scope of the description.
The above examples merely represent a few embodiments of the present application, which are described in more detail and are not to be construed as limiting the scope of the invention. It should be noted that it would be apparent to those skilled in the art that various modifications and improvements could be made without departing from the spirit of the present application, which would be within the scope of the present application. Accordingly, the scope of protection of the present application is to be determined by the claims appended hereto.

Claims (10)

1. A sleep pressure testing method, the method comprising:
displaying a dormant configuration page, and determining a communication address, a power-off frequency and a driving protocol of a USB component to be tested, which are configured based on the dormant configuration page;
determining the protocol type of the driving protocol, and acquiring a corresponding keyword library according to the protocol type;
determining a target level parameter of the USB component to be tested based on the driving protocol and a keyword library;
Generating a dormancy control instruction according to the target level parameter and the power-off frequency;
issuing the dormancy control instruction to a USB component to be tested corresponding to the communication address so that the USB component to be tested performs dormancy pressure test based on the dormancy control instruction;
the determining the protocol type of the driving protocol and obtaining the corresponding keyword library according to the protocol type comprises the following steps:
when the protocol type is a text type, acquiring a keyword library corresponding to the text type; the keyword library corresponding to the text type comprises a first keyword and a second keyword;
the USB component to be tested comprises a control pin; the determining, based on the driving protocol and the keyword library, the target level parameter of the USB component to be tested includes:
screening out target paragraphs corresponding to control pins from the driving protocol according to the first keywords;
based on the second keyword, position information among all control pins is screened out from the target paragraph;
and determining a target level parameter according to the position information.
2. The method of claim 1, wherein the sleep configuration page has a sleep mode configuration control therein; the USB component to be tested comprises a USB module; the method further comprises the steps of:
When the operation of clicking the sleep mode configuration control occurs, acquiring sleep mode parameters configured based on the sleep configuration page, and determining a connection mode with the USB module;
generating a corresponding dormancy configuration instruction based on the connection mode and the dormancy mode parameter;
and sending the dormancy configuration instruction to the USB module so that the USB module carries out corresponding configuration according to dormancy mode parameters in the dormancy configuration instruction.
3. The method of claim 1, wherein the sleep configuration page is a page configured accordingly for a sleep stress test task.
4. The method of claim 1, wherein the sleep configuration page has a sleep power consumption acquisition control therein; the method further comprises the steps of:
when the operation of clicking the sleep power consumption acquisition control is performed, acquiring the real-time current of the USB component to be tested in the sleep; the real-time current comprises a current value and acquisition time;
determining an extreme current according to the current value and the acquisition time;
and distinguishing and displaying the real-time current and the extreme current in the sleep configuration page, and determining the sleep power consumption of the USB component to be tested in the sleep time based on the real-time current and the extreme current.
5. The method of claim 4, wherein determining an extreme current from the current value and the acquisition time comprises:
acquiring a description point template and setting parameters;
determining the coordinates of the points corresponding to the current value and the acquisition time according to the setting parameters;
drawing a current trend curve on the dotting template based on the dotting coordinates;
and judging the corner points in the current trend curve as extreme currents.
6. A sleep pressure testing system, the system comprising: testing a computer and a USB component to be tested; the USB component to be tested comprises a power supply, a test bottom plate, a relay and a USB module;
the power supply is used for providing voltage for the test bottom plate and the relay;
the test computer is used for displaying a dormant configuration page, acquiring a communication address, a power-off frequency and a driving protocol of a USB component to be tested based on the dormant configuration page, determining a protocol type of the driving protocol, acquiring a corresponding keyword library according to the protocol type, acquiring a keyword library corresponding to the text type when the protocol type is the text type, wherein the keyword library corresponding to the text type comprises a first keyword and a second keyword, screening out a target paragraph corresponding to a control pin from the driving protocol according to the first keyword, screening out position information among all the control pins from the target paragraph based on the second keyword, determining a target level parameter according to the position information, generating a dormant control instruction according to the target level parameter and the power-off frequency, and transmitting the dormant control instruction to the USB component to be tested corresponding to the communication address;
The test base plate is used for receiving the dormancy control instruction and controlling the opening and closing of the relay according to the dormancy control instruction;
the relay is used for transmitting the voltage provided by the power supply to the USB module when the relay is closed; when the USB module is disconnected, the voltage provided by the power supply is paused to be transmitted to the USB module;
the USB module is used for entering a dormant state when no voltage is received; upon receiving the voltage, the wake-up state is entered from the sleep state.
7. The system of claim 6, wherein the test computer is further configured to obtain a preset communication command and send the communication command to the USB module according to a power-off frequency; and when receiving the reply information of the USB module to the communication instruction, judging that the USB module is in an awakening state.
8. A sleep pressure testing apparatus, the apparatus comprising:
the information acquisition module is used for displaying a dormant configuration page and determining a communication address, a power-off frequency and a driving protocol of the USB component to be tested, which are configured based on the dormant configuration page; the USB component to be tested comprises a control pin;
The instruction generation module is used for determining the protocol type of the driving protocol, and acquiring a keyword library corresponding to the text type when the protocol type is the text type; the keyword library corresponding to the text type comprises a first keyword and a second keyword; screening out target paragraphs corresponding to control pins from the driving protocol according to the first keywords; based on the second keyword, position information among all control pins is screened out from the target paragraph; determining a target level parameter according to the position information; generating a dormancy control instruction according to the target level parameter and the power-off frequency;
and the control module is used for sending the dormancy control instruction to the USB component to be tested corresponding to the communication address so that the USB component to be tested performs dormancy and awakening operations based on the dormancy control instruction.
9. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor implements the steps of the method of any one of claims 1 to 5 when the computer program is executed.
10. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 5.
CN202010435865.6A 2020-05-21 2020-05-21 Sleep pressure test method, system, computer device and storage medium Active CN111752774B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010435865.6A CN111752774B (en) 2020-05-21 2020-05-21 Sleep pressure test method, system, computer device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010435865.6A CN111752774B (en) 2020-05-21 2020-05-21 Sleep pressure test method, system, computer device and storage medium

Publications (2)

Publication Number Publication Date
CN111752774A CN111752774A (en) 2020-10-09
CN111752774B true CN111752774B (en) 2024-03-15

Family

ID=72673472

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010435865.6A Active CN111752774B (en) 2020-05-21 2020-05-21 Sleep pressure test method, system, computer device and storage medium

Country Status (1)

Country Link
CN (1) CN111752774B (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102023912A (en) * 2009-09-11 2011-04-20 鸿富锦精密工业(深圳)有限公司 Dormancy wake-up testing system and method
CN102937928A (en) * 2011-08-16 2013-02-20 鸿富锦精密工业(深圳)有限公司 Main board sleeping and waking device
CN108563600A (en) * 2018-04-26 2018-09-21 上海移远通信技术股份有限公司 Switching circuit and device for the test of electronic product dormancy power consumption

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100647370B1 (en) * 2004-04-20 2006-11-23 주식회사 하이닉스반도체 Multi-protocol serial interface system
US8850252B2 (en) * 2011-11-03 2014-09-30 Nvidia Corporation USB host wake from sleep state for mobile devices

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102023912A (en) * 2009-09-11 2011-04-20 鸿富锦精密工业(深圳)有限公司 Dormancy wake-up testing system and method
CN102937928A (en) * 2011-08-16 2013-02-20 鸿富锦精密工业(深圳)有限公司 Main board sleeping and waking device
CN108563600A (en) * 2018-04-26 2018-09-21 上海移远通信技术股份有限公司 Switching circuit and device for the test of electronic product dormancy power consumption

Also Published As

Publication number Publication date
CN111752774A (en) 2020-10-09

Similar Documents

Publication Publication Date Title
US6457134B1 (en) Portable computer with differentiated time-out feature
CN111639002B (en) Sleep power consumption testing method, system, computer equipment and storage medium
CN104516812A (en) Method and device for testing software
CN102737724A (en) System and method for testing nonvolatile random access memory (NVRAM)
CN112839323A (en) Bluetooth device testing method and device, terminal and computer readable storage medium
CN104199767A (en) Test method and device
CN105335653A (en) Abnormal data detection method and apparatus
US7401737B2 (en) Apparatus and method for a mobile personal computer system (MPC) with a built-in scanner
CN113268416A (en) Application program testing method and device, storage medium and terminal
CN111858364A (en) Parameter configuration method, device and system of test terminal
CN107391021A (en) Recognition methods, device, storage medium and the mobile terminal of blank screen gesture
CN111752774B (en) Sleep pressure test method, system, computer device and storage medium
CN113031752A (en) Chip voltage adjusting method, performance testing method and device and electronic equipment
CN112834898B (en) Method, device and equipment for testing stability of power chip of storage device
JP4727370B2 (en) Wireless communication terminal and control method thereof
CN113568833A (en) Test case determination method and device, computer equipment and readable storage medium
CN111522587B (en) Electronic device and device wake-up method
CN113434179B (en) Online upgrade method, device and equipment of programmable power supply and storage medium
KR20190086375A (en) Controller, operating state acquisition system and method
CN113032232B (en) Correlation method, correlation device and equipment for performance detection of equipment
CN112732498B (en) Test method, device, equipment and storage medium for simulating single-point power-on and power-off of equipment
CN115114152A (en) Automatic testing method and system based on control attribute and image recognition, electronic equipment and storage medium
CN112445670B (en) eMMC test method and device
CN116047259A (en) Detection system and detection method
CN109491825B (en) Method, device, storage medium and terminal for positioning abnormal starting problem

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant