Photoelectric keyboard

By introducing pull-up circuits and pull-up transistors into the photoelectric keyboard, the problem of long pull-up time of photoelectric keyboard detection components is solved, significantly increasing the number of clicks per second, suitable for high-frequency click scenarios.

CN119181611APending Publication Date: 2024-12-24HUAIAN DARFON ELECTRONICS +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310738492.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-06-21
Publication Date
2024-12-24

AI Technical Summary

Technical Problem

Due to the long pull-up time of the detection element, the scanning frequency cannot be increased, which limits its application in scenarios with high clicks per second, such as e-sports competitions.

Method used

The photoelectric keyboard design is adopted that includes a microcontroller, a plurality of infrared generators, detection elements and pull-up circuits, wherein the pull-up circuit includes a first inverter, a second inverter, and a plurality of pull-up transistors, through which the pull-up circuit includes a first inverter, a second inverter, and a plurality of pull-up transistors are passed. The function of pulling transistors reduces the button reaction time and increases the number of clicks per second.

Benefits of technology

Through the pull-up transistor function of the pull-up circuit, the key response time of the photoelectric keyboard is greatly reduced, and the number of clicks per second is significantly increased, making it suitable for high-demand applications such as e-sports competitions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119181611A_ABST
    Figure CN119181611A_ABST
Patent Text Reader

Abstract

The invention discloses a photoelectric keyboard which comprises a microcontroller, a plurality of infrared generators, a plurality of detecting elements and a pull-up circuit. The microcontroller is used for generating M scanning signals. The plurality of infrared generators are arranged in M columns, the plurality of detection elements are arranged in N rows, and both M and N are integers greater than 1. Each detection element corresponds to one infrared generator. The pull-up circuit includes a first inverter, a second inverter and N pull-up transistors. The input end of the first inverter is used for receiving M scanning signals. The input end of the second inverter is coupled to the output end of the first inverter. Each pull-up transistor includes a first terminal coupled to a first voltage source, a second terminal coupled to one of the N rows of detection elements, and a control terminal coupled to an output terminal of the second inverter. By means of the pull-up transistor of the pull-up circuit, the response time of the keys can be greatly shortened, and the number of clicks per second of the photoelectric keyboard can be greatly increased.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to a photoelectric keyboard, and more particularly to a photoelectric keyboard capable of achieving high clicks per second (CPS). Background Art

[0002] Photoelectric keyboards (or optical axis keyboards) operate using infrared rays generated by an infrared generator and a corresponding detection element (e.g., phototransistor (PT)) that senses infrared rays. However, due to the characteristics of the detection element, the pull-up time required for the process of switching from a low potential to a high potential is very long, and the detection element must wait for the long pull-up time to end before it can detect infrared rays again, which results in the inability to effectively increase the scanning frequency of the photoelectric keyboard. As a result, the application of the photoelectric keyboard will be limited, and it cannot be used in scenarios that require high clicks per second (CPS) (e.g., e-sports competitions). Summary of the invention

[0003] The purpose of the present invention is to provide a photoelectric keyboard to solve the problems in the prior art.

[0004] In order to achieve the above-mentioned object, the present invention proposes a photoelectric keyboard, which includes a microcontroller, a plurality of infrared generators, a plurality of detection elements and a pull-up circuit. The microcontroller is used to generate M scan signals, M is an integer greater than 1; the plurality of infrared generators are arranged in M ​​rows, and each row of infrared generators receives a corresponding scan signal from the microcontroller; the plurality of detection elements are arranged in N columns, and each detection element corresponds to one of the plurality of infrared generators, and N is an integer greater than 1; the pull-up circuit includes a first inverter, a second inverter and N pull-up transistors. The first inverter includes a first input terminal and a first output terminal, and the first input terminal is used to receive the M scan signals. The second inverter includes a second input terminal and a second output terminal, and the second input terminal is coupled to the first output terminal of the first inverter. Each pull-up transistor includes a first terminal, a second terminal and a control terminal. The first end is coupled to a first voltage source; the second end is coupled to one column of the N columns of detection elements; and the control end is coupled to the second output end of the second inverter.

[0005] As an optional technical solution, at most only one of the M scan signals is at a high level at any one time.

[0006] As an optional technical solution, the photoelectric keyboard further includes N first resistors, wherein each first resistor includes:

[0007] A third terminal is coupled to the first voltage source; and

[0008] The fourth end is coupled to one column of the N columns of detection elements.

[0009] As an optional technical solution, the pull-up circuit further includes N second resistors, wherein each second resistor includes:

[0010] a fifth terminal coupled to the second terminal of a corresponding pull-up transistor among the N pull-up transistors; and

[0011] The sixth end is coupled to one column of the N columns of detection elements.

[0012] As an optional technical solution, the photoelectric keyboard further includes M diodes, wherein the anode of each diode is coupled to one of the M rows of infrared generators, and the cathode of each diode is coupled to the first input end of the first inverter.

[0013] As an optional technical solution, each infrared generator includes an infrared light emitting diode.

[0014] As an optional technical solution, each detection element is a phototransistor.

[0015] As an optional technical solution, the first inverter and the second inverter respectively include NPN bipolar transistors.

[0016] As an optional technical solution, each pull-up transistor is a PNP bipolar transistor.

[0017] As an optional technical solution, each pull-up transistor is a P-type metal oxide semi-conductor field effect transistor.

[0018] As an optional technical solution, the pull-up circuit further includes a voltage divider circuit, and the base of the NPN bipolar transistor of the first inverter is connected to the voltage divider circuit.

[0019] The photoelectric keyboard of the present invention can greatly reduce the reaction time of the keys of the photoelectric keyboard by the pull-up transistor of the pull-up circuit, thereby greatly increasing the number of clicks per second that the photoelectric keyboard can achieve. Therefore, the photoelectric keyboard of the present invention can be used in more occasions that require a high number of clicks per second (for example, e-sports competitions). BRIEF DESCRIPTION OF THE DRAWINGS

[0020] The specific implementation modes of the present invention are further described in detail below in conjunction with the accompanying drawings.

[0021] Figure 1 FIG. 4 is a circuit diagram of a photoelectric keyboard according to an embodiment of the present invention.

[0022] Figure 2 for Figure 1 Signal timing diagram of the photoelectric keyboard.

[0023] Figure 3 for Figure 1 Circuit diagram of the pull-up transistor, infrared generator and detection element of the photoelectric keyboard.

[0024] Figure 4 is an analog detection element voltage and Figure 3 The timing diagram of the scanning signal and the detection element voltage.

[0025] Figure 5 FIG. 4 is a circuit diagram of a photoelectric keyboard according to another embodiment of the present invention. DETAILED DESCRIPTION

[0026] In order to more clearly illustrate the present invention, the present invention is further described below in conjunction with preferred embodiments and accompanying drawings. Similar components in the accompanying drawings are represented by the same reference numerals. It should be understood by those skilled in the art that the content specifically described below is illustrative rather than restrictive, and should not be used to limit the scope of protection of the present invention.

[0027] Please refer to Figure 1 , Figure 1 The circuit diagram of the photoelectric keyboard 10 of one embodiment of the present invention. The photoelectric keyboard 10 includes a microcontroller unit (MCU) 20, a photoelectric circuit 30 and a pull-up circuit 40. The microcontroller 20 is used to generate M scanning signals (including scanning signals S1, S2 and S3 in this embodiment) and receive the signal sent back by the photoelectric circuit 30, where M is an integer greater than 1. The photoelectric circuit 30 includes a plurality of infrared generators (including infrared generators IR11 to IR33 in this embodiment) and a plurality of detection elements (including detection elements PT11 to PT33 in this embodiment). The plurality of infrared generators are arranged in M ​​rows, and each row of infrared generators receives a corresponding scanning signal from the microcontroller 20. The plurality of detection elements are arranged in N columns, and each detection element corresponds to one of the plurality of infrared generators, where N is an integer greater than 1.

[0028] In this embodiment, infrared generators IR11 to IR33 are arranged in three rows, and each row of infrared generators receives a corresponding scan signal among the scan signals S1, S2 and S3 from the microcontroller 20. For example, the infrared generators IR11, IR12 and IR13 in the first row receive the scan signal S1 from the microcontroller 20, the infrared generators IR21, IR22 and IR23 in the second row receive the scan signal S2 from the microcontroller 20, and the infrared generators IR31, IR32 and IR33 in the third row receive the scan signal S3 from the microcontroller 20. The detection elements PT11 to PT33 are arranged in three columns, and each detection element corresponds to an infrared generator. Although in Figure 1In the embodiment, the photoelectric circuit 30 includes nine infrared generators IR11 to IR33 arranged in three rows and nine detection elements PT11 to PT33 arranged in three columns, but the present invention is not limited thereto. The photoelectric circuit 30 may include other numbers of multiple infrared generators and multiple detection elements. The multiple infrared generators may be arranged in two rows, four rows or more rows, and the multiple detection elements may be arranged in two columns, four columns or more columns. The number of scanning signals generated by the microcontroller 20 will be equal to the number of rows of the infrared generators. Therefore, when the multiple infrared generators are arranged in M ​​rows, the number of scanning signals generated by the microcontroller 20 will be equal to M, and the infrared generators in each row will receive one scanning signal from the microcontroller 20 among the M scanning signals, where M is an integer greater than 1.

[0029] In addition, the photoelectric keyboard 10 may further include M diodes, and the M scanning signals generated by the microcontroller 20 are transmitted to the pull-up circuit 40 after passing through the M diodes. The M diodes correspond to the M scanning signals one by one, and the M scanning signals are transmitted to the pull-up circuit 40 after passing through the corresponding diodes. Figure 1 For example, the photoelectric keyboard 10 includes three diodes D1, D2 and D3, and the scanning signals S1, S2 and S3 are respectively transmitted to the pull-up circuit 40 through the corresponding diodes D1, D2 and D3. The anode of each diode D1, D2, D3 is coupled to the microcontroller 20 to transmit the aforementioned scanning signals S1, S2, S3. It can also be considered that the anode of each diode D1, D2, D3 is coupled to one of the M rows of infrared generators (in this embodiment, one of the infrared generators IR11 to IR33 is coupled), and the cathode of each diode D1, D2, D3 is coupled to the pull-up circuit 40.

[0030] The pull-up circuit 40 includes a first inverter 41, a second inverter 42, and a plurality of pull-up transistors Q1 to Q3. The first inverter 41 includes a first input terminal and a first output terminal, and the second inverter 42 includes a second input terminal and a second output terminal. The first input terminal of the first inverter 41 is used to receive M scanning signals (scanning signals S1, S2, and S3 in this embodiment) generated by the microcontroller 20, and the second input terminal of the second inverter 42 is coupled to the first output terminal of the first inverter 41. As mentioned above, the anode of each diode D1, D2, and D3 is coupled to a row of infrared generators IR11 to IR33, and the cathode of each diode D1, D2, and D3 is coupled to the pull-up circuit 40. In this embodiment, the cathode of each diode D1, D2, and D3 is coupled to the first input terminal of the first inverter 41. Therefore, the first inverter 41 receives the scanning signals S1, S2, and S3 generated by the microcontroller 20 through each diode D1, D2, and D3.

[0031] The first inverter 41 may include a voltage divider circuit formed by resistors Rx and Ry, an NPN bipolar junction transistor (NPN BJT) Qa, and a resistor Ra. The base of the NPN bipolar transistor Qa is connected to the resistors Rx and Ry to receive a mixed signal S4 obtained by mixing the scan signals S1, S2, and S3. The emitter of the NPN bipolar transistor Qa is connected to the voltage source GND, the collector of the NPN bipolar transistor Qa is connected to one end of the resistor Ra, and the other end of the resistor Ra is connected to the voltage source VCC. The voltage of the voltage source VCC is higher than the voltage of the voltage source GND. For example, the voltage of the voltage source VCC can be equal to 3.3 volts, and the voltage of the voltage source GND can be equal to zero volts. The second inverter 42 includes an NPN bipolar junction transistor (NPN BJT) Qb and a resistor Rb. One end of the resistor Rb is connected to the voltage source VCC, the collector of the NPN bipolar transistor Qb is connected to the other end of the resistor Rb and is used to output the control signal S5, the base of the NPN bipolar transistor Qb is connected to the collector of the NPN bipolar transistor Qa, and the emitter of the NPN bipolar transistor Qb is connected to the voltage source GND. In another embodiment of the present invention, the first inverter 41 may not necessarily include the resistors Rx and Ry. In this case, the base of the NPN bipolar transistor Qa is directly connected to each diode D1, D2 and D3 (specifically, it can be connected to the cathode of each diode D1, D2, D3), and is not connected to the voltage source GND to receive the scanning signals S1, S2 and S3.

[0032] In the present invention, each pull-up transistor includes a first terminal, a second terminal and a control terminal, the first terminal is coupled to the first voltage source VCC, the second terminal is coupled to one of the N columns of detection elements, and the control terminal is coupled to the second output terminal of the second inverter 42. In this embodiment, each pull-up transistor Q1, Q2 and Q3 is a PNP bipolar transistor, the first terminal is the emitter of each PNP bipolar transistor, the second terminal is the collector of each PNP bipolar transistor, and the control terminal is the base of each PNP bipolar transistor. Figure 1 As shown, in this embodiment, the bases of the pull-up transistors Q1, Q2 and Q3 are coupled to the second output terminal of the second inverter 42 through the resistors R11, R21 and R31, respectively, to receive the control signal S5 output by the second inverter 42. Specifically, one end of each of the resistors R11, R21 and R31 is coupled to the output terminal of the second inverter 42, the other end of the resistor R11 is coupled to the base of the pull-up transistor Q1, the other end of the resistor R21 is coupled to the base of the pull-up transistor Q2, and the other end of the resistor R31 is coupled to the base of the pull-up transistor Q3.

[0033] In addition, the pull-up circuit 40 further includes N first resistors R13, R23 and R33. Each of the N first resistors R13, R23 and R33 includes a third end and a fourth end, the third end is coupled to the first voltage source VCC, and the fourth end is coupled to one of the N columns of detection elements. In the present embodiment, the third end of the first resistor R13 is coupled to the first voltage source VCC, and the fourth end of the first resistor R13 is coupled to the detection elements PT11, PT21 and PT31 of the first column; the third end of the first resistor R23 is coupled to the first voltage source VCC, and the fourth end of the first resistor R23 is coupled to the detection elements PT12, PT22 and PT32 of the second column; the third end of the first resistor R33 is coupled to the first voltage source VCC, and the fourth end of the first resistor R33 is coupled to the detection elements PT13, PT23 and PT33 of the third column.

[0034] In addition, the pull-up circuit 40 further includes N second resistors, each of which includes a fifth end and a sixth end, the fifth end being coupled to the second end (collector) of the corresponding pull-up transistor among the N pull-up transistors, and the sixth end being coupled to one of the N columns of detection elements. Thus, the collectors of the pull-up transistors Q1, Q2, and Q3 are connected to the detection elements of a corresponding column through the second resistors R12, R22, and R32, respectively. For example, the collector of the pull-up transistor Q1 is connected to the detection elements PT11, PT21, and PT31 of the first column, the collector of the pull-up transistor Q2 is connected to the detection elements PT12, PT22, and PT32 of the second column, and the collector of the pull-up transistor Q3 is connected to the detection elements PT13, PT23, and PT33 of the third column. The emitters of the pull-up transistors Q1, Q2, and Q3 are connected to the voltage source VCC.

[0035] Please refer to Figure 2 , Figure 2 for Figure 1 The signal timing diagram of the photoelectric keyboard 10 is shown in FIG. SC , Vr and Vc represent the scan voltage, the voltage division and the system voltage provided by the voltage source VCC respectively. In this embodiment, the voltage of the scan signals S1 to S3 is between the scan voltage V SC and zero volts. The voltage divider Vr is then equal to (V SC ×(ry / rx+ry)), where rx is the resistance value of resistor Rx, and ry is the resistance value of resistor Ry. The system voltage Vc can be equal to 3.3 volts. Figure 2 As shown, at any time, only one scanning signal of the scanning signals S1 to S3 is at a high potential (i.e., the scanning voltage V SC ), that is, the microcontroller 20 will only scan one row of infrared generators at most at any time. In detail, when the scanning signal S1 is equal to the scanning voltage V SC, the infrared generators IR11, IR12 and IR13 in the first row will be activated to generate infrared rays, while the infrared generators in other rows will not be activated; when the scanning signal S2 is equal to the scanning voltage V SC , the infrared generators IR21, IR22 and IR23 in the second row will be activated to generate infrared rays, while the infrared generators in other rows will not be activated; when the scanning signal S3 is equal to the scanning voltage V SC When the infrared generators IR31, IR32 and IR33 in the third row are activated to generate infrared rays, while the infrared generators in other rows are not activated.

[0036] To further explain the operation of the infrared generators IR11 to IR33, the detection elements PT11 to PT33, and the pull-up transistors Q1, Q2, and Q3, the operation of the infrared generator IR11, the detection element PT11, and the pull-up transistor Q1 will be described below. Figure 3 and Figure 4 , Figure 3 for Figure 1 The circuit diagram of the pull-up transistor Q1, infrared generator IR11 and detection element PT11 of the photoelectric keyboard 10 is shown in FIG. Figure 4 is an analog detection element voltage V” PT and Figure 3 The scanning signal S1 and the detection element voltage V PT The timing diagram of the detection element voltage V PT The voltage of the detection element PT11 coupled to one end of the resistor R13; the analog detection element voltage V" PT Through software simulation Figure 3 After the pull-up transistor Q1 and the resistors R11 and R12 are removed, the voltage of the detection element PT11 coupled to one end of the resistor R13 is detected. By comparing the detection element voltage V PT and the analog detection element voltage V” PT , that is, it can be understood that the pull-up transistor Q1 increases the detection element voltage V PT impact.

[0037] The infrared generator IR11 includes a resistor R IR and an infrared light emitting diode (IR LED) D, and the detection element PT11 is a phototransistor (PT). IR One end of the resistor R is used to receive the scanning signal S1. IRThe other end of is coupled to one end of the infrared light emitting diode D, and the other end of the infrared light emitting diode D is coupled to the voltage source GND. One end of the detection element PT11 is coupled to the resistors R12 and R13, and the other end of the detection element PT11 is coupled to the voltage source GND. The structures and connection methods of the other infrared generators IR12 to IR33 and other detection elements PT12 to PT33 are similar to those of the infrared generator IR11 and the detection element PT11, and will not be repeated here.

[0038] The infrared generator IR11 and the detection element PT11 are used for a key in the photoelectric keyboard 10. When the user presses the key, the infrared generated by the infrared generator IR11 can irradiate the detection element PT11, causing the detection element voltage V PT When the user does not press this button, the infrared light generated by the infrared generator IR11 will not irradiate the detection element PT11, causing the detection element voltage V PT Remain unchanged. Figure 1 The microcontroller 20 detects the device voltage V PT The change of can determine whether the key corresponding to the infrared generator IR11 and the detection element PT11 is pressed. Figure 2 , Figure 3 and Figure 4 , when the scan signal S1 is pulled up from zero volts to the scan voltage V SC When the infrared ray generated by the infrared ray generator IR11 irradiates the detection element PT11, the detection element PT11 gradually turns on, thereby making the detection element voltage V PT The system voltage Vc is gradually reduced to zero volts. When the scanning signal S1 changes from the scanning voltage V SC When the control signal S5 drops to zero volt, the control signal S5 will drop from the system voltage Vc to zero volt, and the infrared generator IR11 will stop generating infrared rays, causing the detection element PT11 to change from a conducting state to a non-conducting state. Since the control signal S5 drops to zero volt, the pull-up transistor Q1 will turn on, causing the detection element voltage V PT Rapidly raised from zero volts to the system voltage Vc.

[0039] Please refer to Figure 4 As mentioned above, the analog detection element voltage V” PT It is simulated by software. Figure 3 After the pull-up transistor Q1 and the resistors R11 and R12 are removed, the voltage of the detection element PT11 coupled to one end of the resistor R13 is detected. By comparing the detection element voltage V PTand the analog detection element voltage V” PT , that is, it can be understood that the pull-up transistor Q1 increases the detection element voltage V PT When the scanning signal S1 changes from the scanning voltage V SC After dropping to zero volts, the detection element voltage V PT The response time required to increase from zero volt to (0.9×Vc) is ΔT1. In contrast, the analog detection element voltage V” PT The reaction time required to increase from zero volt to (0.9×Vc) is ΔT2, and the reaction time ΔT2 is much longer than the reaction time ΔT1. Therefore, due to the function of the pull-up transistor Q1 of the pull-up circuit 40, the reaction time of the key of the photoelectric keyboard 10 can be greatly reduced, thereby greatly increasing the number of clicks per second (CPS) that the photoelectric keyboard 10 can achieve.

[0040] Please refer to Figure 5 , Figure 5 FIG. 5 is a circuit diagram of a photoelectric keyboard 50 according to another embodiment of the present invention. Figure 1 The difference between the optical keyboard 10 and the optical keyboard 50 is that the pull-up transistors Q1, Q2 and Q3 in the pull-up circuit 40 of the optical keyboard 50 are replaced by P-type metal-oxide-semiconductor (PMOS) instead of the original PNP bipolar transistors. In addition, the other components and operation methods of the optical keyboard 50 are the same as those of the optical keyboard 10, and will not be repeated here.

[0041] According to the description of the above embodiments, the present invention can significantly reduce the reaction time of the keys of the photoelectric keyboard through the function of the pull-up transistor of the pull-up circuit, thereby significantly increasing the number of clicks per second that the photoelectric keyboard can achieve. Therefore, the photoelectric keyboard of the present invention can be used in more occasions that require a high number of clicks per second (for example, e-sports competitions).

[0042] Obviously, the above embodiments of the present invention are merely examples for clearly illustrating the present invention, and are not limitations on the implementation methods of the present invention. For ordinary technicians in the relevant field, other different forms of changes or modifications can be made based on the above description. It is impossible to list all the implementation methods here. All obvious changes or modifications derived from the technical solution of the present invention are still within the protection scope of the present invention.

Claims

1. A photoelectric keyboard, characterized in that Include: A microcontroller, used for generating M scanning signals, where M is an integer greater than 1; A plurality of infrared generators are arranged in M ​​rows, and each row of infrared generators receives a corresponding scanning signal among the M scanning signals from the microcontroller; A plurality of detection elements are arranged in N rows, each detection element corresponds to an infrared generator of the plurality of infrared generators, and N is an integer greater than 1; as well as Pull-up circuit, including: The first inverter comprises: A first input terminal, for receiving the M scanning signals; and a first output terminal; The second inverter comprises: A second input terminal coupled to the first output terminal of the first inverter; and A second output terminal; as well as N pull-up transistors, each pull-up transistor comprising: A first terminal coupled to a first voltage source; The second end is coupled to one column of the N columns of detection elements; as well as The control end is coupled to the second output end of the second inverter.

2. The photoelectric keyboard according to claim 1, characterized in that: Among the M scan signals, at most only one scan signal is at a high level at any one time.

3. The photoelectric keyboard according to claim 1, characterized in that: The photoelectric keyboard further comprises N first resistors, wherein each first resistor comprises: A third terminal is coupled to the first voltage source; and The fourth end is coupled to one column of the N columns of detection elements.

4. The photoelectric keyboard according to claim 3, characterized in that: The pull-up circuit further includes N second resistors, wherein each second resistor includes: a fifth terminal coupled to the second terminal of a corresponding pull-up transistor among the N pull-up transistors; and The sixth end is coupled to one column of the N columns of detection elements.

5. The photoelectric keyboard according to claim 1, characterized in that: The photoelectric keyboard further comprises M diodes, wherein the anode of each diode is coupled to one of the M rows of infrared generators, and the cathode of each diode is coupled to the first input end of the first inverter.

6. The photoelectric keyboard according to claim 1, characterized in that: Each infrared generator includes an infrared light emitting diode.

7. The photoelectric keyboard according to claim 1, characterized in that: Each detection element is a phototransistor.

8. The photoelectric keyboard according to claim 1, characterized in that: The first inverter and the second inverter respectively include NPN bipolar transistors.

9. The photoelectric keyboard according to claim 1, characterized in that: Each pull-up transistor is a PNP bipolar transistor or a P-type metal oxide semi-conductor field effect transistor.

10. The photoelectric keyboard according to claim 8, characterized in that: The pull-up circuit further comprises a voltage divider circuit, and the base of the NPN bipolar transistor of the first inverter is connected to the voltage divider circuit.