Keyboard response test method, system and equipment and storage medium

By combining the test component and the image acquisition component with the lighting component, simulating keyboard key operations and analyzing video frames, the problems of manual operation interference and host response impact in the prior art are solved, and the high accuracy of keyboard response testing is achieved.

CN120256228AActive Publication Date: 2025-07-04SHENZHEN RAPOO TECH
View PDF 9 Cites 0 Cited by

Patent Information

Application Number
CN202510727468.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-06-03
Publication Date
2025-07-04
Estimated Expiration
2045-06-03

AI Technical Summary

Technical Problem

The existing keyboard response testing methods rely on manual operations, resulting in low testing efficiency and susceptible to human factors, affecting the accuracy of the test results, and the response time of the computer host masks the actual delay difference on the keyboard.

Method used

The test components, image acquisition components and lighting components are used to simulate key operations through electromagnets, and the start and end times are identified in combination with video frame analysis, to eliminate manual interference and host response effects, and to accurately determine keyboard delay.

Benefits of technology

Improve the accuracy of keyboard response tests, avoid the impact of manual operation interference and host response time, and ensure the accuracy of the actual response delay data of the keyboard.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120256228A_ABST
    Figure CN120256228A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of computers, in particular to a keyboard response test method, system and device and a storage medium. The method comprises the following steps: testing a to-be-tested keyboard through a test assembly, and performing image acquisition on a test process through an image acquisition assembly; acquiring a video frame sequence acquired by the image acquisition assembly, and identifying a first video frame and a second video frame in the video frame sequence based on the position relationship between the test assembly and the keys in the keyboard to be tested and the light color of the light assembly; a trigger delay is determined based on the first video frame and the second video frame. The starting time and the ending time are recorded through the position relation and the light color, the starting time and the ending time are recognized through the video frame sequence, and the keyboard delay is determined based on the starting time and the ending time, so that interference of manual operation on test accuracy is avoided, the influence of a computer host on response test is eliminated, and the test accuracy is improved. And the accuracy of the actual response delay of the keyboard obtained by the keyboard response test is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and particularly to a keyboard response test method, system, device, and storage medium. Background Art

[0002] As is well known, users can press each key on the keyboard independently, causing the keyboard controller to generate a scan code and send it to the computer host. The computer host converts it into a virtual key code through the system driver and then recognizes it as a letter or a control instruction, and finally outputs it to the output device (such as a computer screen) through the application and displays it to the user.

[0003] As a key device for human-computer interaction, the response speed and accuracy of the keyboard are crucial for the user experience. Especially in the scenario of game operations, the quick response of the keyboard ensures that players can quickly respond to emergencies. In order to ensure the response speed of the keyboard, it is necessary to test the keyboard's response speed before leaving the factory. However, most current tests still rely on manual operations, which not only reduces the test efficiency but also is easily interfered by human factors, thus affecting the accuracy of the test results.

[0004] Therefore, the existing technology still needs to be improved. Summary of the Invention

[0005] The technical problem to be solved by the present application is to provide a keyboard response test method, system, device, and storage medium in view of the deficiencies of the existing technology.

[0006] To solve the above technical problem, in the first aspect of the present application, a keyboard response test method is provided, which is applied to a keyboard response test device. The keyboard response test device includes an image acquisition component, a test component, a lighting component, and an external device. The keyboard response test method specifically includes: Testing the keyboard to be tested through the test component, and collecting images of the test process through the image acquisition component. During the test process, the test component controls the lighting component according to the test progress. Obtaining the video frame sequence collected by the image acquisition component, and identifying the first video frame and the second video frame in the video frame sequence based on the positional relationship between the test component and the keys on the keyboard to be tested and the lighting color of the lighting component. Determining the trigger delay of the keyboard to be tested based on the first video frame and the second video frame.

[0007] In the keyboard response test method, the step of testing the keyboard to be tested through the test component specifically includes: Starting the test component, the image acquisition component, and the lighting component. Perform a pressing operation on the keys in the keyboard to be tested through the test component, and obtain a key trigger signal through the test component; When the test component obtains a key trigger signal, control the lighting component to display a first lighting color.

[0008] The keyboard response test method, wherein the test component includes a relay and an electromagnet, and the electromagnet is placed above the keys in the keyboard to be tested; the performing a pressing operation on the keys in the keyboard to be tested through the test component specifically includes: Control the relay to start, and drive the electromagnet to press the keys in the keyboard to be tested through the relay, so as to perform a pressing operation on the keys in the keyboard to be tested.

[0009] The keyboard response test method, wherein after driving the electromagnet to press the keys in the keyboard to be tested through the relay, the method further includes: When the electromagnet contacts the keys in the keyboard to be tested, control the backlight in the lighting component to turn off.

[0010] The keyboard response test method, wherein the keyboard response test method further includes: When the test component obtains a key trigger signal, or when the test component does not obtain a key trigger signal within a preset time, control the relay to disconnect, so as to control the electromagnet to end the pressing operation on the keys in the keyboard to be tested.

[0011] The keyboard response test method, wherein the performing a pressing operation on the keys in the keyboard to be tested through the test component and obtaining a key trigger signal through the test component specifically includes: Perform a pressing operation on the keys in the keyboard to be tested through the test component, and monitor whether the keyboard to be tested detects a key trigger signal; When the keyboard to be tested detects a key trigger signal, control the lighting component to display a second lighting color, and obtain a key trigger signal through the test component.

[0012] The keyboard response test method, wherein the identifying a first video frame and a second video frame in the video frame sequence based on the positional relationship between the test component and the keys in the keyboard to be tested and the lighting color of the lighting component specifically includes: Based on the positional relationship between the electromagnet in the test component and the keys in the keyboard to be tested, identify a first video frame in the video frame sequence; Identify a second video frame in the video frame sequence where the first lighting color first appears.

[0013] The keyboard response test method described above, wherein identifying the first video frame in the video frame sequence based on the positional relationship between the electromagnet in the test component and the key in the keyboard to be tested specifically includes: Identifying, in the video frame sequence, the first video frame in which the reflected light between the electromagnet and the key in the keyboard to be tested disappears for the first time, where the disappearance of the reflected light between the electromagnet and the key in the keyboard to be tested is used to indicate that the positional relationship between the electromagnet in the test component and the key in the keyboard to be tested changes from non-contact to contact.

[0014] The keyboard response test method described above, wherein determining the trigger delay of the keyboard to be tested based on the first video frame and the second video frame specifically includes: Obtaining the first number of frames from the first video frame to the second video frame; Determining the trigger delay of the keyboard to be tested based on the first number of frames and the frequency of the image acquisition component.

[0015] The keyboard response test method described above, wherein the method further includes: Identifying, in the video frame sequence, the third video frame in which the reflected light between the electromagnet and the key in the keyboard to be tested disappears for the first time; Obtaining the second number of frames from the first video frame to the third video frame, and determining the key recognition delay of the keyboard to be tested according to the second number of frames and the frequency of the image acquisition component; Obtaining the third number of frames from the third video frame to the second video frame, and determining the key trigger information transmission delay of the keyboard to be tested according to the third number of frames and the frequency of the image acquisition component.

[0016] A second aspect of the present application provides a keyboard response test system, which includes a keyboard response test device and an external device; the keyboard response test device includes a test component, an image acquisition component, a test component, and a lighting component; The image acquisition component is used to acquire images during the test process; The lighting component is used for lighting display; The test component is used to test the keyboard to be tested and control the lighting component according to the test process; The external device is used to obtain the video frame sequence acquired by the image acquisition component, identify the first video frame and the second video frame in the video frame sequence based on the positional relationship between the test component and the key in the keyboard to be tested and the lighting color of the lighting component, and determine the trigger delay of the keyboard to be tested based on the first video frame and the second video frame.

[0017] In a third aspect of the present application, a computer-readable storage medium is provided. The computer-readable storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement the steps in any of the keyboard response test methods described above.

[0018] In a fourth aspect of the present application, a test device is provided, which includes: a processor and a memory; A computer-readable program executable by the processor is stored on the memory; When the processor executes the computer-readable program, the steps in any of the keyboard response test methods described above are implemented.

[0019] Advantageous effects: Compared with the prior art, the present application provides a keyboard response test method, system, device and storage medium. The method includes testing the keyboard to be tested through the test component, and collecting images of the test process through the image acquisition component; obtaining the video frame sequence collected by the image acquisition component, and identifying the first video frame and the second video frame in the video frame sequence based on the positional relationship between the test component and the keys on the keyboard to be tested and the light color of the light component; determining the trigger delay of the keyboard to be tested based on the first video frame and the second video frame. The present application records the start time and the end time based on the positional relationship between the test component and the keys on the keyboard to be tested and the light color of the light component, and identifies the start time and the end time through the video frame sequence, and then determines the keyboard delay based on the start time and the end time. This not only avoids the interference of manual operation on the test accuracy, but also eliminates the influence of the computer host on the response test, and improves the accuracy of the actual response delay data of the keyboard obtained by the keyboard response test. Description of the Drawings

[0020] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings required for the description of the embodiments. Obviously, the following drawings are only some embodiments of the present application. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.

[0021] Figure 1 It is a schematic block diagram of the keyboard response test system provided by the embodiment of the present application.

[0022] Figure 2 It is a specific exemplary module schematic diagram of the keyboard response test system provided by the embodiment of the present application.

[0023] Figure 3 It is a flowchart of the keyboard response test method provided by the embodiment of the present application.

[0024] Figure 4 A flowchart of a test process for testing a keyboard by a test component.

[0025] Figure 5 A block diagram of the principle of the test device provided by the embodiment of the present application. Detailed implementation manners

[0026] The embodiment of the present application provides a keyboard response test method, system, device and storage medium. To make the purpose, technical solution and effect of the present application clearer and more definite, the following further describes the present application in detail with reference to the accompanying drawings and by way of examples. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0027] Those skilled in the art of the present technology can understand that unless specifically stated otherwise, the singular forms "a", "an", "the" and "said" used herein may also include the plural forms. It should be further understood that the term "including" used in the specification of the present application means the presence of the described features, integers, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or their groups. It should be understood that when we say that an element is "connected" or "coupled" to another element, it can be directly connected or coupled to other elements, or there may also be intermediate elements. In addition, the "connection" or "coupling" used herein may include wireless connection or wireless coupling. The phrase "and / or" used herein includes all or any unit and all combinations of one or more related listed items.

[0028] Those skilled in the art of the present technology can understand that unless otherwise defined, all terms (including technical terms and scientific terms) used herein have the same meaning as the general understanding of those of ordinary skill in the art to which the present application belongs. It should also be understood that terms such as those defined in a general dictionary should be understood to have a meaning consistent with the meaning in the context of the prior art, and will not be interpreted with an idealized or overly formal meaning unless specifically defined as here.

[0029] It should be understood that the sequence numbers and magnitudes of the steps in this embodiment do not mean the order of execution. The execution order of each process is determined by its function and internal logic, and should not constitute any limitation to the implementation process of the embodiment of the present application.

[0030] As is well known, users can independently choose to press each key on the keyboard, causing the keyboard controller to generate a scan code and send it to the computer host. The computer host converts it into a virtual key code through the system driver and then recognizes it as a letter or a control instruction, and finally outputs it to the output device (such as a computer screen) through the application for display to the user.

[0031] As a key device for human-computer interaction, the response speed and accuracy of the keyboard are crucial for the user experience. Especially in the scenario of game operations, the quick response of the keyboard ensures that players can quickly respond to emergencies. To improve the quick response of the keyboard, during the R & D process, the response speed of the keyboard can be tested, and the keyboard can be optimized accordingly based on the test results. However, most current tests still rely on manual operations, which not only reduces the test efficiency but also is easily interfered by human factors, thus affecting the accuracy of the test results.

[0032] In addition, when performing the keyboard response test, the computer host will respond and determine the start and end times of the test. However, when using the computer host to respond and determine the start and end times. The response time of the computer host itself will occupy a relatively large proportion of the overall response time, which may mask the actual latency differences at the keyboard end, thus affecting the evaluation of the keyboard response accuracy.

[0033] To solve the above problems, in the embodiments of the present application, the test component is used to test the keyboard to be tested, and the image acquisition component is used to collect images during the test process; the video frame sequence collected by the image acquisition component is obtained, and the first video frame and the second video frame are identified in the video frame sequence based on the positional relationship between the test component and the keys on the keyboard to be tested and the lighting color of the lighting component; the trigger latency of the keyboard to be tested is determined based on the first video frame and the second video frame. The present application records the start time and the end time based on the positional relationship between the test component and the keys on the keyboard to be tested and the lighting color of the lighting component, and recognizes the start time and the end time through the video frame sequence, and then determines the keyboard latency based on the start time and the end time. This not only avoids the interference of manual operations on the test accuracy but also eliminates the influence of the computer host on the response test, improving the accuracy of the actual response latency data of the keyboard obtained from the keyboard response test.

[0034] An application environment diagram of the keyboard response test method provided by the embodiments of the present application can be as Figure 1 shown. Refer to Figure 1, the keyboard response test method is used for a keyboard response test system, which includes an external device 10 and a keyboard response test device 20. The keyboard response test device 20 includes an image acquisition component 100, a test component 200, and a lighting component 300. The test component 200 communicates with the image acquisition component 100 and the lighting component 300. The image acquisition component 100 is used to acquire images during the test process. The lighting component 300 is used to change the lighting color according to the test progress. The test component 200 is used to test the keyboard to be tested and control the lighting component according to the test progress, so that the lighting component performs lighting on and off and color display changes, etc. The external device 10 is used to obtain the video frame sequence collected by the image acquisition component, and identify the first video frame and the second video frame in the video frame sequence based on the positional relationship between the test component and the keys on the keyboard to be tested and the lighting color of the lighting component; and determine the trigger delay of the keyboard to be tested based on the first video frame and the second video frame.

[0035] Furthermore, as Figure 2 shown, the test component includes a development board, a relay, an electromagnet, and a power adapter. The power adapter is connected to the development board and the relay respectively, and the relay is connected to the electromagnet. When using the test component to perform a response test on the keyboard keys, the electromagnet is placed above the key to be tested on the keyboard and contacts the key to be tested. The electromagnet can be driven by the relay to simulate the pressing operation of the key to be tested. Specifically, when the relay is activated, the electromagnet is driven by the relay to generate a downward force to simulate the pressing of the keyboard key by the user's finger; when the relay is turned off, the electromagnet loses the driving force of the relay and thus stops simulating the pressing of the keyboard key. By controlling the on / off state of the relay, the pressing and releasing of the electromagnet on the keyboard key can be precisely controlled, thereby simulating the pressing operation of the user on the key. In addition, the main board, as the core control unit of the test component, is responsible for receiving and processing signals from other components, and controlling the operation of the relay and the electromagnet according to the preset test program. In this way, the test component can simulate the pressing operation of the user on the control key and complete the test of the keyboard response according to the signal information formed during each test process in the acquisition test. In addition, for the convenience of keyboard fixation, the test component can also include a test bracket to fix the keyboard.

[0036] The keyboard response test is used to test the keyboard response link. Among them, the keyboard response link includes: 1. The key is pressed to the trigger stroke; 2. Keyboard MCU Button Scanning: When the mechanical travel of a button reaches the trigger point, a button trigger signal is generated. The keyboard MCU detects this button trigger signal through button scanning. The frequency of button scanning is associated with the performance of the MCU. The higher the scanning frequency, the shorter the scanning time, and the faster the button trigger signal can be detected. For example, when the scanning frequency is 1KHz, the time interval for button scanning is 1 millisecond; when the scanning frequency is 4K, the time interval for button scanning is 0.25 milliseconds. If the button trigger signal generated when the pressed button reaches the trigger travel is scanned during button scanning, the button trigger signal is directly obtained; if it is not scanned, it waits for the next button scanning. Therefore, the maximum error time for detecting the button trigger signal is one scanning cycle.

[0037] 3. Keyboard MCU Button Debouncing: When the keyboard MCU obtains the button trigger signal, it will perform button debouncing processing. The mechanical axis (button) judges the signal through the contact of metal contacts. However, when the metal spring sheet contacts deform, there will be jitter, which may cause misjudgments such as double-clicking or multi-clicking of the button. For the mechanical axis (button), over time, the contacts may wear, oxidize, and the metal spring sheet may deform. These factors may cause the trigger signal to become unstable. Therefore, button debouncing is very important.

[0038] 4. Keyboard MCU Button Data Processing: The MCU identifies the pressed button according to the button matrix, assigns a button function to it, and reports the signal.

[0039] 5. Signal Transmission: Signal transmission can be carried out in two ways: wired and wireless. The host will obtain data from the keyboard every once in a while. If the keyboard MCU completes button data processing and reports when the host obtains data from the keyboard, the host obtains the data reported by the keyboard MCU within the current acquisition cycle. If the keyboard MCU does not report data, it will obtain the data reported by the keyboard MCU in the next acquisition cycle. Therefore, the maximum error time for signal transmission is one scanning cycle.

[0040] 6. Host Response: When the signal enters the host, the host will respond to the signal so that the user can perceive it.

[0041] For this reason, the keyboard response process may include the key being pressed until the trigger stroke, the keyboard MCU key scan, the keyboard MCU key debounce, the keyboard MCU key data processing, signal transmission, and host response. That is, all test processes of the keyboard response test can be implemented through the test component, and the lighting component can be controlled according to the test process, so that the lighting component can display the test process through different lighting colors. Among them, the lighting component may include test process indicator lights, and the test process indicator lights can display different colors when in different test processes. For example, the lighting component includes a key trigger indicator light (green) and a key scan indicator light (blue), etc.

[0042] It should be noted that a lighting color can be configured for each test process, or a lighting color can be configured for multiple consecutive test detections. Specifically, it can be set according to actual test requirements. At the same time, the test process can be displayed through the color change of a test process indicator light, or through the lighting and extinguishing of multiple test process indicator lights configured with different lighting colors, etc. As long as the test process can be displayed through the lighting color change, any method is acceptable.

[0043] The image acquisition component is applicable to devices such as cameras or cameras, and is used to capture images of the entire test process. For example, Figure 2 as shown, the image acquisition component uses a high-speed camera. The image acquisition component can be installed directly in front of the keyboard on the same horizontal plane, and can capture the pictures of the electromagnet, the keyboard keys to be tested, and the lighting component. Through the image acquisition component, the actions of the keyboard responding to the user's pressing and releasing actions simulated by the electromagnet during the test process, as well as the entire process of the color change of the lighting component during the test, can be recorded.

[0044] Based on the above keyboard response test system, an embodiment of the present application provides a keyboard response test method. The following further describes the keyboard response test method provided by the embodiment of the present application with reference to the accompanying drawings through the description of the embodiments.

[0045] As Figure 3 shown, a keyboard response test method provided by this embodiment specifically includes: S10. Test the keyboard to be tested through the test component, and collect images of the test process through the image acquisition component.

[0046] Specifically, the testing of the keyboard under test by the testing component refers to the testing component performing a keyboard response link test on the keyboard under test. Moreover, during the testing process of the keyboard under test, the testing component controls the lighting component, causing the lighting component to turn on and off during the testing process, or to turn on and off and display different colors when the light is on, etc. That is to say, during the testing process, the testing component controls the lighting component according to the testing progress to display each testing process through the lighting component.

[0047] Furthermore, as can be seen from the above description of the keyboard response testing system, the keyboard response link includes the key being pressed to the trigger stroke, the keyboard MCU key scan, the keyboard MCU key debounce, the keyboard MCU key data processing, signal transmission, and host response. Therefore, when testing the keyboard under test through the testing component, the test can be carried out according to the entire keyboard response link. Correspondingly, as Figure 4 shown, the testing of the keyboard under test through the testing component specifically includes: S11. Start the testing component, the image acquisition component, and the lighting component; S12. Perform a pressing operation on the keys in the keyboard under test through the testing component, and obtain a key trigger signal through the testing component; S13. When the testing component obtains a key trigger signal, control the lighting component to display the first lighting color.

[0048] In step S11, the testing component, the image acquisition component, and the lighting component can be started synchronously. For example, the user simultaneously turns on the testing component, the image acquisition component, and the lighting component, etc. Of course, the testing component, the image acquisition component, and the lighting component can also be started separately. For example, based on the user's operation, the testing component is started. The testing component forms a test start instruction and controls the image acquisition component and the lighting component to start through this test start instruction. Or, based on the user's operation, the testing component and the image acquisition component are started. The testing component forms a test start instruction and controls the lighting component to start through this test start instruction, etc.

[0049] In addition, before starting the testing component, the image acquisition component, and the lighting component, preparatory work can be carried out first. The preparatory work can include placing the keyboard under test flat on the test stand and adjusting and fixing the angle; connecting the keyboard under test to the development board in the testing component, turning on the keyboard, and selecting the corresponding working mode (such as wired, 2.4G, etc.). Adjust the position of the image acquisition component (such as distance, height, etc.); connect the power adapter to the power supply and adjust the position of the keyboard and the electromagnet. In addition, an auxiliary shooting light can also be configured for the image acquisition component.

[0050] In step S12, the pressing operation is a pressing operation of the user on the keyboard simulated by the test component, and this pressing operation starts after both the test component and the image acquisition component are started. That is to say, before the test component performs a pressing operation on the keys in the keyboard to be tested, the test component can first obtain the startup state of the image acquisition component. When the startup state of the image acquisition component is startup, the test component performs a pressing operation on the keys in the keyboard to be tested. If the startup state of the image acquisition component is not startup, the startup state of the image acquisition component continues to be monitored until the startup state becomes startup, or the monitoring duration reaches a preset duration, and when the monitoring duration reaches the preset duration, it is prompted that the image acquisition component fails to start. This can ensure that the image acquisition component can capture the entire process of the keyboard response test, avoiding the problem of inaccurate trigger delay caused by the image acquisition component missing images. Of course, in practical applications, it can also be that after the test component controls the image acquisition component to start, after a preset delay, the test component directly performs a pressing operation on the keys in the keyboard to be tested, etc.

[0051] In one implementation, the test component includes a relay and an electromagnet, and the relay is used to drive the electromagnet to simulate a human hand to press the keys in the keyboard to be tested. Correspondingly, the specific operation of the test component performing a pressing operation on the keys in the keyboard to be tested includes: Controlling the relay to start, and driving the electromagnet through the relay to press the keys in the keyboard to be tested, so as to perform a pressing operation on the keys in the keyboard to be tested.

[0052] Specifically, the electromagnet is located above the keys in the keyboard to be tested. In this way, under the drive of the relay, the electromagnet will generate a downward pressure on the keys, pushing the keys towards the trigger point to simulate the pressing operation of the user pressing the keys, so as to press the keys in the keyboard to be tested to the process of the trigger stroke. In addition, during the process of simulating the pressing operation by the electromagnet, the pressure of the electromagnet can be adjusted by controlling the current of the relay, so as to achieve precise control of the pressing force and pressing speed of the keys.

[0053] Further, the electromagnet is placed above a key in the keyboard to be tested, and there is a certain distance between the electromagnet and the key. When starting the test, the backlight panel in the test component is lit. The backlight panel is along the moving direction of the electromagnet, and when the electromagnet moves to the maximum stroke, the bottom end of the electromagnet is flush with or higher than the bottom end of the backlight panel. When the electromagnet contacts the key, the reflected light between the electromagnet and the key in the keyboard to be tested disappears, so as to record the contact moment when the electromagnet contacts the key. For this purpose, when starting the test component, the image acquisition component and the lighting component, the backlight panel is lit. Then, in the process of driving the electromagnet to press the key in the keyboard to be tested through the relay, when the electromagnet contacts the key in the keyboard to be tested, the gap between the electromagnet and the key disappears, and the light reflected through the gap is blocked, so that the reflected light between the electromagnet and the key in the keyboard to be tested disappears.

[0054] It should be noted that the embodiments of the present application do not specifically limit which color of the backlight panel is used to record the contact moment when the electromagnet contacts the key, as long as the contact moment when the electromagnet contacts the key can be recorded by the disappearance of the reflected light between the electromagnet and the key in the keyboard to be tested.

[0055] Further, after performing a pressing operation on the key, the response end time of the keyboard to be tested will be monitored. From the response link of the upper keyboard, it can be seen that after the keyboard to be detected transmits the signal to the host (i.e., signal transmission), the host will respond to the signal (i.e., host response), and the host response is the time spent by the host to process the signal. Optimizing the keyboard does not affect the host response time. For this purpose, the embodiments of the present application use the completion time of signal transmission as the response end time, that is, the time when the test component obtains the key trigger signal is used as the response end time. Correspondingly, after performing a pressing operation on the key, the test component will obtain the key trigger signal to detect whether the keyboard to be tested has responded.

[0056] In step S13, when the test component obtains the key trigger signal, it indicates that the test component has received the key information, that is, the keyboard has completed the key response. The lighting component can be controlled to display the first lighting color to indicate that the keyboard has completed the key response. At the same time, after the keyboard has completed the key response, the pressing operation on the key in the keyboard to be tested will be ended. For this purpose, the relay will be controlled to disconnect to control the electromagnet to end the pressing operation on the key in the keyboard to be tested. In addition, to avoid the electromagnet pressing the key for a long time due to the loss of the key trigger signal, when the test component does not obtain the key trigger signal within the preset time, the relay will also be controlled to disconnect to control the electromagnet to end the pressing operation on the key in the keyboard to be tested. At the same time, the image acquisition component and the lighting component will also be turned off.

[0057] In one implementation, the response chain of the keyboard to be tested can be divided into a key recognition process and a key trigger signal transmission process. The key recognition process includes the key being pressed to the trigger stroke, the keyboard MCU key scan, and the keyboard MCU key debounce. The key trigger signal transmission process includes signal transmission. When optimizing the keyboard, more detailed research and improvement can be done on the keyboard response process based on the response times of these two processes. To this end, performing a pressing operation on the keys in the keyboard to be tested through the test component and obtaining the key trigger signal through the test component specifically includes: S121. Performing a pressing operation on the keys in the keyboard to be tested through the test component, and monitoring whether the keyboard to be tested detects a key trigger signal; S122. When the keyboard to be tested detects a key trigger signal, controlling the lighting component to display a second lighting color, and obtaining the key trigger signal through the test component.

[0058] Specifically, after performing a pressing operation on the keys in the keyboard to be tested, the keyboard to be tested will obtain the key trigger information formed by the key operation through key scanning, and perform debouncing on the key trigger information. To this end, it can be determined whether the keyboard to be tested detects a key trigger signal by monitoring whether the keyboard to be detected has completed the jitter operation on the key trigger signal. When the keyboard to be tested detects a key trigger signal, controlling the lighting component to display a second lighting color, and recording the completion time of the keyboard MCU key debounce (i.e., the end time of the key recognition process) through the second lighting color.

[0059] In the embodiment of the present application, a relay is used to drive an electromagnet to simulate a key operation, which can avoid the interference of manual operation on the test accuracy. During the test process, based on the keyboard detecting a key trigger signal, the lighting component is controlled to display a second lighting color to record the time point after the keyboard scans the key trigger signal and debounces the key trigger signal through the second lighting color, and based on the test component obtaining the key trigger signal, the lighting component is controlled to display a first lighting color to record the time point when the keyboard completes the key response through the first lighting color. This can eliminate the influence of the computer host response on the keyboard response test, thereby improving the accuracy of the keyboard response test. At the same time, in the present application, the test component directly receives the signal uploaded by the keyboard, and the test component can make a quick response based on this signal (controlling the lighting component to display a first lighting color), which can also eliminate the test data differences caused by different computer hosts (performance differences), further improving the accuracy of the keyboard response test.

[0060] In addition, in the embodiments of the present application, the start time of pressing the key in the keyboard to be detected is recorded through the backlight of the keyboard to be tested, and the end time when the test component obtains the key trigger signal is recorded through the lighting component. The movement time of the test component controlling the relay to drive the electromagnet to press the key in the keyboard to be tested and the time for the test component to respond to the key trigger information are removed, avoiding the influence of the distance between the electromagnet and the key and the response speed of the test component itself on the keyboard response time, and further improving the accuracy of the keyboard response test.

[0061] Of course, in practical applications, the time for the test component to control the relay to supply power to the electromagnet, the time for the electromagnet to press the key, and one or more of the times for the test component to respond to the key trigger information can also be added to the keyboard response time, and other light colors can be used to record each time point. For example, when the electromagnet starts to press the key, the lighting component can be controlled to display the third light color, etc. In addition, the keyboard can be tested multiple times. Each time, based on the two time points provided in the embodiments of the present application, the time for the test component to control the relay to supply power to the electromagnet, the time for the electromagnet to press the key, and one or more of the times for the test component to respond to the key trigger information are added, and the key delays obtained from multiple tests are comprehensively analyzed to obtain the keyboard delay, such as calculating the average value of multiple times, or calculating the average value of the time interval between the first time point and the second time point in this embodiment for each test, etc.

[0062] S20. Obtain the video frame sequence collected by the image acquisition component, and identify the first video frame and the second video frame in the video frame sequence based on the positional relationship between the test component and the key in the keyboard to be tested and the light color of the lighting component.

[0063] Specifically, the video frame sequence includes all the video frames collected during the test process, that is, the video frame sequence collected by the image acquisition component is obtained after the keyboard response test is completed. For example, after controlling the electromagnet to end the pressing operation on the key in the keyboard to be tested, the video frame sequence collected by the image acquisition component is obtained; or after controlling the electromagnet to end the pressing operation on the key in the keyboard to be tested, the image acquisition component is controlled to close, and then the video frame sequence collected by the image acquisition component is obtained; or the video frame sequence collected by the image acquisition component is obtained after a preset time after controlling the image acquisition component to close, etc.

[0064] It should be noted that in order to test the influence of the test parameters in the test component on the recognition process of the first video frame and the second video frame and the calculation process of the delay time, the recognition process of the first video frame and the second video frame and the calculation process of the delay time can be calculated by an external device independent of the test component. Among them, the external device can be a personal computer such as a tablet computer, a notebook computer, or a desktop computer, an independent server, or a server cluster composed of multiple servers, etc.

[0065] Exemplarily, the recognition of the first video frame and the second video frame in the video frame sequence based on the positional relationship between the test component and the keys in the keyboard to be tested and the light color of the lighting component specifically includes: Based on the positional relationship between the electromagnet in the test component and the keys in the keyboard to be tested, the first video frame is recognized in the video frame sequence; The second video frame in which the first light color first appears is recognized in the video frame sequence.

[0066] Specifically, the first video frame is the video frame when the electromagnet starts to press the keys in the keyboard to be tested. That is to say, the first video frame is the video frame in the video frame sequence where the positional relationship between the electromagnet and the keys in the keyboard to be tested first appears as contact. The positional relationship between the electromagnet and the keys in the keyboard to be tested can be determined by recognizing the reflected light between the electromagnet and the keyboard to be tested. That is to say, based on the positional relationship between the electromagnet in the test component and the keys in the keyboard to be tested, the recognition of the first video frame in the video frame sequence can specifically be: The first video frame in which the reflected light between the electromagnet and the keys in the keyboard to be tested first disappears is selected in the video frame sequence.

[0067] Specifically, the disappearance of the reflected light between the electromagnet and the keys in the keyboard to be tested is used to indicate that the positional relationship between the electromagnet in the test component and the keys in the keyboard to be tested changes from non-contact to contact. Then, the first video frame in which the reflected light between the electromagnet and the keys in the keyboard to be tested first disappears can be the contact moment when the electromagnet contacts the keys, so that the starting time of the keyboard response can be determined through the first video frame.

[0068] In practical applications, in addition to identifying the first video frame by the disappearance of the reflected light between the electromagnet and the key on the keyboard to be tested for the first time, other methods can also be used to identify the first video frame. For example, the first video frame can be identified according to the distance between the electromagnet and the key on the keyboard to be tested, that is, the video frame when the distance between the electromagnet and the key on the keyboard to be tested reaches a preset distance threshold is identified, and this video frame is used as the first video frame. In addition, the method of combining the disappearance of the reflected light between the electromagnet and the key on the keyboard to be tested for the first time and the distance between the electromagnet and the key on the keyboard to be tested can also be used. Specifically, the video frame when the reflected light between the electromagnet and the key on the keyboard to be tested disappears for the first time can be identified first. If it is identified, this video frame is directly used as the first video frame. If it is not identified (such as the backlight fault light, the initial position relationship between the electromagnet and the key is contact, etc.), the video frame when the distance between the electromagnet and the key on the keyboard to be tested reaches a preset distance threshold is identified, and this video frame is used as the first video frame, etc. Correspondingly, when preparing for the test, in addition to keeping a certain distance between the electromagnet and the key, the electromagnet and the key can also be directly contacted.

[0069] It should be noted that the identification process of the first video frame and the second video frame can adopt traditional image recognition methods, or can adopt deep learning models or large models, etc. For example, a large model can be pre-trained first, and then the video frame sequence and the identification basis are input into the large model to identify the image frame through the large model. Among them, when the identification basis is the first appearance of the first light color, the large model can output the second video frame or the frame number of the second video frame, etc. When the identification basis is the first disappearance of the reflected light between the electromagnet and the key on the keyboard to be tested, the large model can output the first video frame or the frame number of the first video frame, etc.

[0070] S30. Determine the trigger delay of the keyboard to be tested based on the first video frame and the second video frame.

[0071] Specifically, the trigger delay is used to reflect the keyboard response delay, and the trigger delay is the time difference between the shooting time of the first video frame and the shooting time of the second video frame. For this reason, when both the first video frame and the second video frame carry time stamps, the trigger delay can be calculated according to the time stamps carried by the first video frame and the second video frame respectively. When the first video frame and the second video frame do not carry time stamps, the trigger delay can be calculated according to the number of video frames from the first video frame to the second video frame.

[0072] In one implementation manner, the determining the trigger delay of the keyboard to be tested based on the first video frame and the second video frame specifically includes: Obtain the number of video frames from the first video frame to the second video frame; Determine the trigger delay of the keyboard to be tested based on the number of video frames and the frequency of the image acquisition component.

[0073] Specifically, the number of video frames refers to the number of video frames acquired from the acquisition of the first video frame to the acquisition of the second video frame. The number of video frames can be calculated based on the frame sequence numbers of the first video frame and the second video frame. That is, the number of video frames = the frame sequence number of the second video frame - the frame sequence number of the first video frame. The trigger delay is calculated by the number of video frames and the frequency of the image acquisition component. Among them, the trigger delay can be expressed as: , Where, represents the trigger delay, represents the number of video frames, represents the frequency of the image acquisition component.

[0074] For example, assuming that the frequency of the image acquisition component is 1K FPS, which means 1000 video frames are played in one second, and the number of video frames is 100, then the trigger delay = 0.1 seconds.

[0075] In one implementation, in order to analyze the keyboard response time more carefully, in addition to obtaining the overall trigger delay of the keyboard response, the key recognition delay during the key recognition process and the key trigger information transmission delay during the key trigger information transmission process can also be obtained. Correspondingly, the keyboard response test method may further include: Identify the third video frame in which the second light color first appears in the video frame sequence; Obtain the second number of frames from the first video frame to the third video frame, and determine the key recognition delay of the keyboard to be tested according to the second number of frames and the frequency of the image acquisition component; Obtain the third number of frames from the third video frame to the second video frame, and determine the key trigger information transmission delay of the keyboard to be tested according to the third number of frames and the frequency of the image acquisition component.

[0076] Specifically, the second light color appears for the first time to indicate that the key debouncing of the keyboard MCU is completed. That is, the time between the third video frame and the first video frame is the time required for the key recognition process, and the time between the second video frame and the third video frame is the time required for the signal transmission process. Thus, after obtaining the third video frame, the key recognition delay can be calculated based on the number of frames of the second from the first video frame to the third video frame, and the key trigger information transmission delay can be calculated based on the number of frames of the third from the third video frame to the second video frame. Among them, the calculation processes of the key recognition delay and the key trigger information transmission delay are the same as the calculation process of the above trigger delay, and the recognition process of the third video frame is the same as the recognition process of the second video frame, which will not be elaborated here.

[0077] In summary, this embodiment provides a keyboard response test method, which includes testing the keyboard to be tested through the test component and collecting images of the test process through the image acquisition component; obtaining the video frame sequence collected by the image acquisition component, and identifying the first video frame and the second video frame in the video frame sequence based on the positional relationship between the test component and the keys in the keyboard to be tested and the light color of the light component; and determining the trigger delay of the keyboard to be tested based on the first video frame and the second video frame. In this application, the start time and the end time are recorded by using lights, and the start time and the end time are identified by recording the video frame sequence of the lights, which not only avoids the interference of manual operation on the test accuracy, but also eliminates the influence of the computer host on the response test, thereby improving the accuracy of the keyboard response test.

[0078] Based on the above keyboard response test method, this embodiment provides a keyboard response test system, as Figure 1 shown. The keyboard response test system includes an external device 10 and a keyboard response test device 20. The keyboard response test device 20 includes an image acquisition component 100, a test component 200, and a light component 300; The image acquisition component is used to collect images of the test process; The light component is used for light display; The test component is used to test the keyboard to be tested and control the light component according to the test process; The external device is used to obtain the video frame sequence collected by the image acquisition component, identify the first video frame and the second video frame in the video frame sequence based on the positional relationship between the test component and the keys in the keyboard to be tested and the light color of the light component, and determine the trigger delay of the keyboard to be tested based on the first video frame and the second video frame.

[0079] Based on the above keyboard response test method, this embodiment provides a computer-readable storage medium storing one or more programs, which can be executed by one or more processors to implement the steps in the keyboard response test method as described in the above embodiment.

[0080] Based on the above keyboard response test method, the present application also provides a test device, as Figure 5 shown, which includes at least one processor 25; a display screen 21; and a memory 22. It may further include a communication interface 23 and a bus 24. Among them, the processor 25, the display screen 21, the memory 22, and the communication interface 23 can communicate with each other through the bus 24. The display screen 21 is set to display a user guidance interface preset in the initial setting mode. The communication interface 23 can transmit information. The processor 25 can call the logical instructions in the memory 22 to execute the method in the above embodiment.

[0081] In addition, when the logical instructions in the above-mentioned memory 22 are implemented in the form of a software functional unit and sold or used as an independent product, they can be stored in a computer-readable storage medium.

[0082] The memory 22, as a computer-readable storage medium, can be set to store software programs and computer-executable programs, such as the program instructions or modules corresponding to the method in the embodiments of the present disclosure. The processor 25 executes functional applications and data processing by running the software programs, instructions, or modules stored in the memory 22, that is, to implement the method in the above embodiment.

[0083] The memory 22 may include a program storage area and a data storage area. Among them, the program storage area can store an operating system and application programs required for at least one function; the data storage area can store data created according to the use of the test device, etc. In addition, the memory 22 may include a high-speed random access memory and may also include a non-volatile memory. For example, various media such as USB flash drives, external hard drives, random access memories (RAM), magnetic disks, or optical discs that can store program codes can also be transient storage media.

[0084] In addition, the specific processes of loading and executing multiple instructions by the instruction processor in the above storage medium and test device have been described in detail in the above method, and will not be repeated here one by one.

[0085] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them; although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions described in the foregoing embodiments, or perform equivalent replacements for some of the technical features; and these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present application.

Claims

1. A keyboard response test method, characterized in that, An application keyboard response testing device, the application keyboard response testing device includes an image acquisition component, a testing component, a lighting component, and an external device; the specific steps of the keyboard response testing method include: The testing component tests the keyboard to be tested, and the image acquisition component acquires images during the testing process. During the testing process, the testing component controls the lighting component according to the testing progress; Obtain the video frame sequence acquired by the image acquisition component, and identify the first video frame and the second video frame in the video frame sequence based on the positional relationship between the testing component and the keys on the keyboard to be tested and the lighting color of the lighting component; Determine the trigger delay of the keyboard to be tested based on the first video frame and the second video frame.

2. The keyboard response test method according to claim 1, wherein The step of testing the keyboard to be tested by the testing component specifically includes: Start the testing component, the image acquisition component, and the lighting component; The testing component performs a pressing operation on the keys of the keyboard to be tested, and the testing component obtains a key trigger signal; When the testing component obtains a key trigger signal, control the lighting component to display the first lighting color.

3. The keyboard response test method according to claim 2, wherein The testing component includes a relay and an electromagnet. The electromagnet is placed above the key of the keyboard to be tested; the step of performing a pressing operation on the key of the keyboard to be tested by the testing component specifically includes: Control the relay to start, and drive the electromagnet to press the key of the keyboard to be tested through the relay, so as to perform a pressing operation on the key of the keyboard to be tested.

4. The keyboard response test method according to claim 3, wherein The keyboard response testing method further includes: When the testing component obtains a key trigger signal, or when the testing component does not obtain a key trigger signal within a preset time, control the relay to disconnect, so as to control the electromagnet to end the pressing operation on the key of the keyboard to be tested.

5. The keyboard response test method according to claim 2, wherein The step of performing a pressing operation on the key of the keyboard to be tested by the testing component and obtaining a key trigger signal by the testing component specifically includes: The testing component performs a pressing operation on the key of the keyboard to be tested, and monitors whether the keyboard to be tested detects a key trigger signal; When the keyboard to be tested detects a key trigger signal, control the lighting component to display the second lighting color, and obtain the key trigger signal by the testing component.

6. The keyboard response test method according to claim 2, wherein The step of identifying the first video frame and the second video frame in the video frame sequence based on the positional relationship between the testing component and the keys on the keyboard to be tested and the lighting color of the lighting component specifically includes: Based on the positional relationship between the electromagnet in the testing component and the key on the keyboard to be tested, identify the first video frame in the video frame sequence; Identify the second video frame in which the first lighting color first appears in the video frame sequence.

7. The keyboard response test method according to claim 6, characterized in that The step of identifying the first video frame in the video frame sequence based on the positional relationship between the electromagnet in the testing component and the key on the keyboard to be tested specifically includes: Identify a first video frame in the video frame sequence where the reflected light between the electromagnet and the key in the keyboard under test first disappears, where the disappearance of the reflected light between the electromagnet and the key in the keyboard under test is used to indicate that the positional relationship between the electromagnet in the test component and the key in the keyboard under test changes from non-contact to contact.

8. The keyboard response test method according to claim 1, wherein, The determining of the trigger delay of the keyboard under test based on the first video frame and the second video frame specifically includes: Obtain a first number of frames from the first video frame to the second video frame; Based on the first number of frames and the frequency of the image acquisition component, determine the trigger delay of the keyboard under test.

9. The keyboard response test method according to claim 1 or 8, characterized in that The method further includes: Identify a third video frame in the video frame sequence where the reflected light between the electromagnet and the key in the keyboard under test first disappears; Obtain a second number of frames from the first video frame to the third video frame, and based on the second number of frames and the frequency of the image acquisition component, determine the key recognition delay of the keyboard under test; Obtain a third number of frames from the third video frame to the second video frame, and based on the third number of frames and the frequency of the image acquisition component, determine the key trigger information transmission delay of the keyboard under test.

10. A keyboard response test system, characterized in that, The keyboard response test system includes a keyboard response test device and an external device; the keyboard response test device includes a test component, an image acquisition component, a test component, and a lighting component; The image acquisition component is used to acquire images during the test process; The lighting component is used for lighting display; The test component is used to test the keyboard under test and control the lighting component according to the test progress; The external device is used to obtain the video frame sequence acquired by the image acquisition component, identify a first video frame and a second video frame in the video frame sequence based on the positional relationship between the test component and the key in the keyboard under test and the lighting color of the lighting component, and determine the trigger delay of the keyboard under test based on the first video frame and the second video frame.

11. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement the steps in the keyboard response test method according to any one of claims 1-9.

12. A testing device, characterized in that, Including: A processor and a memory; The memory stores a computer-readable program executable by the processor; When the processor executes the computer-readable program, it implements the steps in the keyboard response test method according to any one of claims 1-9.

Citation Information

Patent Citations

  • Method, device and system for measuring response delay of interaction service based on video

    CN101516020A

  • Method and system for testing virtual reality equipment delay

    CN105807602A

  • Video response speed detection method and system

    CN106982368A

  • Screen projection time delay test method and device and storage medium

    CN115767078A

  • Screen click response time testing method and system

    CN117743051A