A computer power-on / off state testing device and method

By designing a computer power-on/off status testing device and connecting it to the computer via a hardware interface, the problem of low testing reliability in existing technologies is solved, enabling reliable testing and status judgment when the computer crashes.

CN115437867BActive Publication Date: 2026-06-26INSPUR (SHANDONG) COMPUTER TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
INSPUR (SHANDONG) COMPUTER TECH CO LTD
Filing Date
2022-09-23
Publication Date
2026-06-26

AI Technical Summary

Technical Problem

Existing technologies that use software scripts to test computer power-on/off states suffer from low reliability, especially when the computer crashes and the test cannot continue.

Method used

Design a computer power-on/off state testing device, including a button module, a control module, and a signal communication module. It is connected to the computer under test through a hardware interface to realize test signal control and status information feedback for power-on/off state.

Benefits of technology

It improves the reliability of computer power-on/off status testing, enabling testing to continue even when the computer crashes, and achieves accurate judgment of power-on/off status through a hardware interface.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115437867B_ABST
    Figure CN115437867B_ABST
Patent Text Reader

Abstract

The application provides a computer on-off state testing device, which is in communication connection with a state testing interface of a computer to be tested and comprises a key module, a control module and a signal communication module; the control module acquires key information input by a user through the key module and outputs corresponding testing signals to the signal communication module according to the input key information; and the signal communication module sends the testing signals output by the control module to the state testing interface of the computer to be tested; after receiving the testing signals sent by the signal communication module, the computer to be tested executes corresponding testing operations according to the current state and the testing signals; wherein the testing signals include high and low information of a level signal, time interval information of the level signal, the number of times of sending the level signal and duration information of the level signal; and the application further provides a computer on-off state testing method, which effectively improves the reliability of computer on-off state testing.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of computer testing, and in particular to a device and method for testing the power-on / off state of a computer. Background Technology

[0002] Powering on and off is a necessary test in the computer product development process. It is used to test the computer's startup process and can be divided into powering on and off, restarting, and entering and waking from standby and sleep states. Through repeated testing, the functional reliability of the computer system can be reflected.

[0003] Current computer power-on, restart, standby, and hibernation tests are generally implemented by writing scripts to call relevant commands, and the number of tests and test duration can be set. However, the execution of scripts depends on the stable operation of the computer itself. When the computer crashes, the power-on / off state test cannot continue. Furthermore, the test is performed in software, which cannot fully test the hardware conditions required to implement the functions. This is detrimental to improving the reliability of computer power-on / off state tests. Summary of the Invention

[0004] In order to solve the problems existing in the prior art, the present invention innovatively proposes a computer power-on / off status testing device and method, which effectively solves the problem of low test reliability caused by the existing technology of testing power-on / off status through software scripts, and effectively improves the reliability of computer power-on / off status testing.

[0005] The first aspect of this invention provides a computer power-on / off state testing device, communicatively connected to the state testing interface of a computer under test, comprising: a button module, a control module, and a signal communication module. The control module acquires button information input by the user through the button module and outputs a corresponding test signal to the signal communication module based on the input button information. The signal communication module sends the test signal output by the control module to the state testing interface of the computer under test. After receiving the test signal sent by the signal communication module, the computer under test performs a corresponding test operation based on its current state and the test signal. The test signal includes high / low level information, time interval information, number of times the level signal is sent, and duration information of the level signal.

[0006] Optionally, the computer power-on / off status testing device further includes a connector module, one end of which is communicatively connected to the test interface of the computer under test, and the other end of which is communicatively connected to the signal communication module.

[0007] Optionally, the test interface of the computer under test includes a power-on signal interface and a restart signal interface. The power-on signal interface is communicatively connected to the first signal output terminal of the signal communication module through a connector module, and the first signal input terminal of the signal communication module is communicatively connected to the first signal output terminal of the control module. The restart signal interface is communicatively connected to the second signal output terminal of the signal communication module through a connector module, and the second signal input terminal of the signal communication module is communicatively connected to the second signal output terminal of the control module.

[0008] Furthermore, the test interface of the computer under test includes a debug signal interface, which is communicatively connected to the third signal input terminal of the signal communication module through a connector module. The third signal output terminal of the signal communication module is communicatively connected to the third signal output terminal of the control module, and is used to send the current power-on / off status information of the computer under test to the control module through the connector module and the signal communication module.

[0009] Optionally, the control module acquires the key information input by the user through the key module, determines the corresponding test signal according to the preset correspondence between key information and test signals, and outputs the corresponding test signal to the computer under test through the signal communication module; wherein, the key information includes key position information, key mode information, and key duration information.

[0010] Optionally, the power-on / off state of the computer under test includes power-on state, power-off state, restart state, sleep state, and hibernation state.

[0011] Furthermore, after the computer under test receives the test signal sent by the signal communication module, it determines the test signal based on its current state and the specific nature of the test signal:

[0012] The computer under test receives a test signal sent by the signal communication module; the type of test signal is determined based on the correspondence between the test signal received by the computer under test and the power-on / off state of the computer under test.

[0013] If the test signal type is the first signal type, the computer under test will set its power-on / off state to the restart state;

[0014] If the test signal type is the second signal type, the computer under test obtains the current power-on / off state and sets its own power-on / off state to the corresponding power-on / off state according to the current power-on / off state and the operating system power management option settings; wherein, the operating system power management option settings include the next power-on / off state corresponding to the current power-on / off state;

[0015] If the test signal type is the third signal type, the computer under test will set its power-on / off state to forced shutdown.

[0016] Optionally, the computer power-on / off status testing device further includes a display module, the data input terminal of which is communicatively connected to the data output terminal of the control module, for displaying test signal information and power-on / off status information of the computer under test.

[0017] The second aspect of this invention provides a method for testing the power-on / off state of a computer, implemented based on the computer power-on / off state testing device described in the first aspect of this invention, comprising:

[0018] The control module acquires the key information input by the user through the key module, and outputs the corresponding test signal to the signal communication module according to the input key information;

[0019] The signal communication module receives the test signal output by the control module and sends the received test signal output by the control module to the status test interface of the computer under test.

[0020] After receiving the test signal sent by the signal communication module, the computer under test performs the corresponding test operation according to the current state and the test signal to realize the power-on / off state test of the computer; wherein, the test signal includes the high / low level information of the level signal, the time interval information of the level signal, the number of times the level signal is sent, and the duration information of the level signal.

[0021] Optionally, it also includes:

[0022] The computer under test (BUT) obtains the current power-on / off status information of the BUT through the debugging signal interface and sends it to the control module via the connector module and signal communication module.

[0023] The control module compares the current power-on / off state sent by the computer under test with the current power-on / off state corresponding to the key input information by the user through the key module. If they match, the actual power-on / off state of the computer under test matches the preset power-on / off state; otherwise, the actual power-on / off state of the computer under test does not match the preset power-on / off state.

[0024] The technical solution adopted in this invention has the following technical effects:

[0025] 1. In the technical solution of this invention, the control module acquires the key information input by the user through the key module, and outputs the corresponding test signal to the status test interface of the computer under test according to the input key information; after receiving the test signal sent by the signal communication module, the computer under test executes the corresponding test operation according to the current status and the test signal; wherein, the test signal includes high and low level information of the level signal, time interval information of the level signal, number of times the level signal is sent, and duration information of the level signal, which can realize the control of different numbers of tests and different test times, solve the problem of low test reliability caused by the existing technology of using software scripts to perform power-on and power-off status tests, and effectively improve the reliability of computer power-on and power-off status tests.

[0026] 2. The test interface of the computer under test in the technical solution of the present invention includes a debugging signal interface, which can send the current power-on / off status information of the computer under test to the control module through the connector module and the signal communication module, so as to facilitate the determination of whether the current power-on / off status sent by the computer under test is consistent with the current power-on / off status corresponding to the key information input by the user through the key module.

[0027] 3. The key information in the technical solution of this invention includes key position information, key mode information, and key duration information; correspondingly, the power-on / off state of the computer under test includes power-on state, power-off state, restart state, sleep state, and hibernation state, which can realize the test control of different power-on / off states.

[0028] 4. The computer power-on / off status testing device in the technical solution of the present invention also includes a display module, which can display test signal information and power-on / off status information of the computer under test in real time.

[0029] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit the invention. Attached Figure Description

[0030] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0031] Figure 1 This is a schematic diagram of the device in Embodiment 1 of the present invention;

[0032] Figure 2 This is a schematic flowchart of the method in Embodiment 1 of the present invention;

[0033] Figure 3 This is another flowchart illustrating the method of Embodiment 1 in the present invention. Detailed Implementation

[0034] To clearly illustrate the technical features of this solution, the invention will be described in detail below through specific embodiments and in conjunction with the accompanying drawings. The following disclosure provides many different embodiments or examples for implementing different structures of the invention. To simplify the disclosure of the invention, components and arrangements of specific examples are described below. Furthermore, reference numerals and / or letters may be repeated in different examples. This repetition is for simplification and clarity and does not in itself indicate a relationship between the various embodiments and / or arrangements discussed. It should be noted that the components illustrated in the drawings are not necessarily drawn to scale. Descriptions of well-known components, processing techniques, and processes are omitted in this invention to avoid unnecessarily limiting the invention.

[0035] Example 1

[0036] like Figure 1 As shown, the present invention provides a computer power-on / off state testing device 1, which is communicatively connected to the state testing interface of a computer under test 2. The device includes: a button module 11, a control module 12, and a signal communication module 13. The control module 12 acquires button information input by the user through the button module 11 and outputs a corresponding test signal to the signal communication module 13 based on the input button information. The signal communication module 13 sends the test signal output by the control module 12 to the state testing interface of the computer under test 2. After receiving the test signal sent by the signal communication module 13, the computer under test 2 performs a corresponding test operation based on its current state and the test signal. The test signal includes high / low level information, time interval information, number of times the level signal is sent, and duration information of the level signal.

[0037] Furthermore, the computer power-on / off status testing device 1 also includes a connector module 14. One end of the connector module 14 is communicatively connected to the test interface of the computer under test 2, and the other end of the connector module 14 is communicatively connected to the signal communication module 13. Specifically, the connector module 14 includes a first connector 141 and a second connector 142. The first connector 141 is disposed on the computer power-on / off status testing device 1, and the second connector 142 can be disposed on the computer under test 2. The first connector 141 and the second connector 142 are communicatively connected via a cable.

[0038] The test interface of the computer under test 2 includes a power-on signal interface and a restart signal interface. The power-on signal interface is connected to the first signal output terminal of the signal communication module 13 via the connector module 14, and the first signal input terminal of the signal communication module 13 is connected to the first signal output terminal of the control module 12. The restart signal interface is connected to the second signal output terminal of the signal communication module 13 via the connector module 14, and the second signal input terminal of the signal communication module 13 is connected to the second signal output terminal of the control module 12.

[0039] Preferably, the test interface of the computer under test 2 includes a debug signal interface, which is connected to the third signal input terminal of the signal communication module 13 via the connector module 14. The third signal output terminal of the signal communication module 13 is connected to the third signal output terminal of the control module 12, and is used to send the current power-on / off status information of the computer under test 2 to the control module 12 via the connector module 14 and the signal communication module 13. The computer under test (DUT) 2 receives its current power-on / off status information via the debugging signal interface and sends it to the control module 12 through the connector module 14 and the signal communication module 13. The control module 12 compares the current power-on / off status sent by the DUT 2 with the current power-on / off status corresponding to the key input by the user via the key module 11. If the current power-on / off status sent by the DUT 2 matches the current power-on / off status corresponding to the key input by the user via the key module 11, then the actual power-on / off status of the DUT 2 matches the preset power-on / off status. If the current power-on / off status sent by the DUT 2 does not match the current power-on / off status corresponding to the key input by the user via the key module 11, then the actual power-on / off status of the DUT 2 does not match the preset power-on / off status and needs to be adjusted again until the current power-on / off status sent by the DUT 2 matches the current power-on / off status corresponding to the key input by the user via the key module 11.

[0040] The control module 12 acquires the key information input by the user through the key module 11, determines the corresponding test signal according to the preset correspondence between key information and test signals, and outputs the corresponding test signal to the computer under test 2 through the signal communication module 13. The key information includes key position information, key mode information, and key duration information. Key position information indicates which key is being pressed; key mode information indicates the meaning of different key positions in the current mode; and key duration information indicates the duration the key is pressed. Different key position information, different key mode information, and different key duration information correspond to different key information, i.e., different test signal information (i.e., whether the level signal is a power-on or restart signal, the number of times the level signal is sent, the high / low level information, the time interval information, the number of times the level signal is sent, and the duration information). The key position information, key mode information, and key duration information correspond one-to-one with the test signal information. The power-on / off states of the computer under test 2 include power-on, power-off, restart, sleep, and hibernation states. Different test signal types (power-on signal or restart signal) correspond to different power-on and power-off states of the computer under test. Specifically, the power-on signal corresponds to the power-on state, power-off state, sleep state, and hibernation state, while the restart signal corresponds to the restart state. Different test signal information (i.e., whether the level signal is a power-on or restart signal, the number of times the level signal is sent, the high / low level information, the time interval information, the number of times the level signal is sent, and the duration of the level signal) represents the test information for the power-on and power-off states under test. This includes the power-on / power-off state type, the number of tests for each power-on / power-off state, whether the power-on / power-off state has been adjusted (adjustment is required under low-level signals), the test time interval for each power-on / power-off state, and the duration of each power-on / power-off state test, among other test configuration information.

[0041] Furthermore, after receiving the test signal sent by the signal communication module, the computer under test 2, based on its current state and the specific nature of the test signal, will:

[0042] The computer under test receives a test signal sent by the signal communication module; the type of test signal is determined based on the correspondence between the test signal received by the computer under test and the power-on / off state of the computer under test.

[0043] If the test signal type is the first signal type (reboot signal), the computer under test will set its power-on / off state to reboot state.

[0044] If the test signal type is the second signal type (power-on signal), the computer under test obtains the current power-on / power-off state and sets its own power-on / power-off state to the corresponding power-on / power-off state according to the current power-on / power-off state and the operating system power management option settings; wherein, the operating system power management option settings include the next power-on / power-off state corresponding to the current power-on / power-off state;

[0045] The power management options in the computer operating system allow you to configure the power button settings (for example, in Windows 10: Start -> Settings -> System -> Power & sleep -> Additional power settings -> Choose what the power buttons do -> When I press the power button -> Select the appropriate function). In these settings, you can configure the next power on / off state corresponding to the current power on / off state. Specifically, if the computer under test is currently powered on, the next power on / off state can be powered off, sleep, hibernation, or standby. These settings can be flexibly configured according to the specific situation to test different power on / off states. If the computer under test is currently powered off, the next power on / off state can be powered on. If the computer under test is currently powered off, the next power on / off state can be powered on. Similarly, if the computer is currently powered off, the next power on / off state can be powered off. This allows you to control the computer's power on / off, standby, hibernation, and wake-up states.

[0046] If the test signal type is the third signal type (forced shutdown signal, in the power-on state, the test level signal is the power-on signal, and the test level signal is kept at a low level for more than 3 seconds, which can realize the forced shutdown of the computer), then the computer under test will set its own power-on state to forced shutdown state.

[0047] It should be noted that the control module 12 in the technical solution of this invention can simulate the output level signal of the restart button or the power button being pressed; that is, when the power or restart button of the computer under test is pressed, in principle, a low-level signal is provided to the motherboard of the computer under test. After receiving the restart or power-on signal, the motherboard performs corresponding actions. Therefore, the control module of this invention can simulate the output of a low-level restart signal or a low-level power-on signal (if the duration of the low-level power-on signal reaches more than the preset duration, it is a forced shutdown signal) and connect to the motherboard to achieve the same effect as pressing a button.

[0048] Furthermore, the computer power-on / off status testing device 1 also includes a display module 15, whose data input terminal is communicatively connected to the data output terminal of the control module 12, and is used to display test signal information and the power-on / off status information of the computer under test 2.

[0049] In this invention, the control module acquires key information input by the user through the key module and outputs corresponding test signals to the status test interface of the computer under test based on the input key information. After receiving the test signals sent by the signal communication module, the computer under test executes corresponding test operations based on its current status and the test signals. The test signals include high / low level information, time interval information, number of times the level signals are sent, and duration information, which can achieve control over different number of tests and different test times. This solves the problem of low test reliability caused by existing technology using software scripts for power-on / off status testing, and effectively improves the reliability of computer power-on / off status testing.

[0050] The test interface of the computer under test in the technical solution of the present invention includes a debugging signal interface, which can send the current power-on / off status information of the computer under test to the control module through the connector module and the signal communication module, so as to facilitate the determination of whether the current power-on / off status sent by the computer under test is consistent with the current power-on / off status corresponding to the key information input by the user through the key module.

[0051] The key information in the technical solution of this invention includes key position information, key mode information, and key duration information; correspondingly, the power-on / off state of the computer under test includes power-on state, power-off state, restart state, sleep state, and hibernation state, which can realize the test control of different power-on / off states.

[0052] The computer power-on / off status testing device in the technical solution of the present invention also includes a display module, which can display test signal information and power-on / off status information of the computer under test in real time.

[0053] Example 2

[0054] like Figure 2 As shown, the present invention also provides a method for testing the power-on / off state of a computer, which is based on a computer power-on / off state testing device in Embodiment 1, and includes:

[0055] S1, the control module obtains the key information input by the user through the key module, and outputs the corresponding test signal to the signal communication module according to the input key information;

[0056] S2, the signal communication module receives the test signal output by the control module and sends the received test signal output by the control module to the status test interface of the computer under test;

[0057] S3. After receiving the test signal sent by the signal communication module, the computer under test performs the corresponding test operation according to the current state and the test signal to realize the computer power-on / off state test. The test signal includes the high / low level information, the time interval information of the level signal, the number of times the level signal is sent, and the duration information of the level signal.

[0058] In step S1, the control module acquires the key information input by the user through the key module, determines the corresponding test signal based on the preset correspondence between key information and test signals, and outputs the corresponding test signal to the computer under test through the signal communication module. The key information includes key position information, key mode information, and key duration information. Key position information specifies which key is being pressed; key mode information indicates the meaning of different key positions in the current mode; and key duration information indicates the duration the key is pressed. Different key position information, different key mode information, and different key duration information correspond to different key information, i.e., different test signal information (i.e., whether the level signal is a power-on or restart signal, the number of times the level signal is sent, the high / low level information, the time interval information, the number of times the level signal is sent, and the duration information). The key position information, key mode information, and key duration information correspond one-to-one with the test signal information. The power-on / off states of the computer under test include power-on, power-off, restart, sleep, and hibernation states. Different test signal types (power-on signal or restart signal) correspond to different power-on and power-off states of the computer under test. Specifically, the power-on signal corresponds to the power-on state, power-off state, sleep state, and hibernation state, while the restart signal corresponds to the restart state. Different test signal information (i.e., whether the level signal is a power-on or restart signal, the number of times the level signal is sent, the high / low level information, the time interval information, the number of times the level signal is sent, and the duration of the level signal) represents the test information for the power-on and power-off states under test. This includes the power-on / power-off state type, the number of tests for each power-on / power-off state, whether the power-on / power-off state has been adjusted (adjustment is required under low-level signals), the test time interval for each power-on / power-off state, and the duration of each power-on / power-off state test, among other test configuration information.

[0059] In step S3, after the computer under test receives the test signal sent by the signal communication module, it determines the specific test signal based on its current state:

[0060] The computer under test receives a test signal sent by the signal communication module; the type of test signal is determined based on the correspondence between the test signal received by the computer under test and the power-on / off state of the computer under test.

[0061] If the test signal type is the first signal type (reboot signal), the computer under test will set its power-on / off state to reboot state.

[0062] If the test signal type is the second signal type (power-on signal), the computer under test obtains the current power-on / power-off state and sets its own power-on / power-off state to the corresponding power-on / power-off state according to the current power-on / power-off state and the operating system power management option settings; wherein, the operating system power management option settings include the next power-on / power-off state corresponding to the current power-on / power-off state;

[0063] The power management options in the computer operating system allow you to configure the power button settings (for example, in Windows 10: Start -> Settings -> System -> Power & sleep -> Additional power settings -> Choose what the power buttons do -> When I press the power button -> Select the appropriate function). In these settings, you can configure the next power on / off state corresponding to the current power on / off state. Specifically, if the computer under test is currently powered on, the next power on / off state can be powered off, sleep, hibernation, or standby. These settings can be flexibly configured according to the specific situation to test different power on / off states. If the computer under test is currently powered off, the next power on / off state can be powered on. If the computer under test is currently powered off, the next power on / off state can be powered on. Similarly, if the computer is currently powered off, the next power on / off state can be powered off. This allows you to control the computer's power on / off, standby, hibernation, and wake-up states.

[0064] If the test signal type is the third signal type (forced shutdown signal, in the power-on state, the test level signal is the power-on signal, and the test level signal is kept at a low level for more than 3 seconds, which can realize the forced shutdown of the computer), then the computer under test will set its own power-on state to forced shutdown state.

[0065] Furthermore, such as Figure 3 As shown, the present invention also provides a method for testing the power-on / off state of a computer, which further includes:

[0066] S4, the computer under test obtains the current power-on / off status information of the computer under test through the debugging signal interface and sends it to the control module through the connector module and signal communication module;

[0067] S5, the control module compares the current power-on / off status sent by the computer under test with the current power-on / off status corresponding to the key information entered by the user through the key module, and determines whether the current power-on / off status sent by the computer under test is consistent with the current power-on / off status corresponding to the key information entered by the user through the key module. If the determination result is yes, then proceed to step S6; if the determination result is no, then proceed to step S7.

[0068] S6, then the actual power-on / off state of the computer under test matches the preset power-on / off state;

[0069] S7 indicates that the actual power-on / off state of the computer under test does not match the preset power-on / off state.

[0070] In this invention, the control module acquires key information input by the user through the key module and outputs corresponding test signals to the status test interface of the computer under test based on the input key information. After receiving the test signals sent by the signal communication module, the computer under test executes corresponding test operations based on its current status and the test signals. The test signals include high / low level information, time interval information, number of times the level signals are sent, and duration information, which can achieve control over different number of tests and different test times. This solves the problem of low test reliability caused by existing technology using software scripts for power-on / off status testing, and effectively improves the reliability of computer power-on / off status testing.

[0071] The test interface of the computer under test in the technical solution of the present invention includes a debugging signal interface, which can send the current power-on / off status information of the computer under test to the control module through the connector module and the signal communication module, so as to facilitate the determination of whether the current power-on / off status sent by the computer under test is consistent with the current power-on / off status corresponding to the key information input by the user through the key module.

[0072] The key information in the technical solution of this invention includes key position information, key mode information, and key duration information; correspondingly, the power-on / off state of the computer under test includes power-on state, power-off state, restart state, sleep state, and hibernation state, which can realize the test control of different power-on / off states.

[0073] The computer power-on / off status testing device in the technical solution of the present invention also includes a display module, which can display test signal information and power-on / off status information of the computer under test in real time.

[0074] While the specific embodiments of the present invention have been described above in conjunction with the accompanying drawings, this is not intended to limit the scope of protection of the present invention. Those skilled in the art should understand that various modifications or variations that can be made by those skilled in the art without creative effort based on the technical solutions of the present invention are still within the scope of protection of the present invention.

Claims

1. A computer power-on / off status testing device, characterized in that, The system communicates with the status test interface of the computer under test (DUT), including a button module, a control module, and a signal communication module. The control module acquires button information input by the user through the button module and outputs corresponding test signals to the signal communication module based on the input button information. The signal communication module sends the test signals output by the control module to the DUT's status test interface. Upon receiving the test signals from the signal communication module, the DUT executes corresponding test operations based on its current status and the test signals. The test signals include high / low level information, time interval information, number of times the level signals are sent, and duration information. Different test signal information represents the test information of the DUT's power-on / off state, including the power-on / off state type, the number of times the power-on / off state is tested, and the power-on / off status information. The test module considers factors such as whether the power-on / off state is adjusted, the test interval for power-on / off states, and the duration of each power-on / off state test. The power-on / off states of the computer under test include power-on, power-off, restart, sleep, and hibernation states. The control module compares the current power-on / off state sent by the computer under test with the current power-on / off state corresponding to the key input information from the user via the key module. If the current power-on / off state sent by the computer under test matches the current power-on / off state corresponding to the key input information from the user via the key module, then the actual power-on / off state of the computer under test matches the preset power-on / off state. If the current power-on / off state sent by the computer under test does not match the current power-on / off state corresponding to the key input information from the user via the key module, then the actual power-on / off state of the computer under test does not match the preset power-on / off state.

2. The computer power-on / off status testing device according to claim 1, characterized in that, The computer power-on / off status testing device also includes a connector module. One end of the connector module is communicatively connected to the test interface of the computer under test, and the other end of the connector module is communicatively connected to the signal communication module.

3. The computer power-on / off status testing device according to claim 1, characterized in that, The test interface of the computer under test includes a power-on signal interface and a restart signal interface. The power-on signal interface is connected to the first signal output terminal of the signal communication module through a connector module, and the first signal input terminal of the signal communication module is connected to the first signal output terminal of the control module. The restart signal interface is connected to the second signal output terminal of the signal communication module through a connector module, and the second signal input terminal of the signal communication module is connected to the second signal output terminal of the control module.

4. The computer power-on / off status testing device according to claim 3, characterized in that, The test interface of the computer under test includes a debug signal interface, which is connected to the third signal input terminal of the signal communication module through a connector module. The third signal output terminal of the signal communication module is connected to the third signal output terminal of the control module, and is used to send the current power-on / off status information of the computer under test to the control module through the connector module and the signal communication module.

5. The computer power-on / off status testing device according to claim 1, characterized in that, The control module acquires the key information input by the user through the key module, determines the corresponding test signal according to the preset correspondence between key information and test signal, and outputs the corresponding test signal to the computer under test through the signal communication module; wherein, the key information includes key position information, key mode information, and key duration information.

6. The computer power-on / off status testing device according to claim 1, characterized in that, After the computer under test receives the test signal sent by the signal communication module, it determines the test signal based on its current state and the specific nature of the test signal: The computer under test receives a test signal sent by the signal communication module; the type of test signal is determined based on the correspondence between the test signal received by the computer under test and the power-on / off state of the computer under test. If the test signal type is the first signal type, the computer under test will set its power-on / off state to the restart state; If the test signal type is the second signal type, the computer under test obtains the current power-on / off state and sets its own power-on / off state to the corresponding power-on / off state according to the current power-on / off state and the operating system power management option settings; wherein, the operating system power management option settings include the next power-on / off state corresponding to the current power-on / off state; If the test signal type is the third signal type, the computer under test will set its power-on / off state to forced shutdown.

7. A computer power-on / off status testing device according to any one of claims 1-6, characterized in that, The computer power-on / off status testing device also includes a display module. The data input terminal of the display module is communicatively connected to the data output terminal of the control module, and is used to display test signal information and power-on / off status information of the computer under test.

8. A method for testing the power-on / off state of a computer, characterized in that, Based on the computer power-on / off state testing device according to any one of claims 1-7, it includes: The control module acquires the key information input by the user through the key module, and outputs the corresponding test signal to the signal communication module according to the input key information; The signal communication module receives the test signal output by the control module and sends the received test signal output by the control module to the status test interface of the computer under test. After receiving the test signal sent by the signal communication module, the computer under test performs the corresponding test operation according to the current state and the test signal to realize the power-on / off state test of the computer; wherein, the test signal includes the high / low level information of the level signal, the time interval information of the level signal, the number of times the level signal is sent, and the duration information of the level signal.

9. A method for testing the power-on / off state of a computer according to claim 8, characterized in that, it further includes... include: The computer under test (BUT) obtains the current power-on / off status information of the BUT through the debugging signal interface and sends it to the control module via the connector module and signal communication module. The control module compares the current power-on / off state sent by the computer under test with the current power-on / off state corresponding to the key input information by the user through the key module. If they match, the actual power-on / off state of the computer under test matches the preset power-on / off state; otherwise, the actual power-on / off state of the computer under test does not match the preset power-on / off state.