A kind of electronic switch that can be turned on by gently pressing the switch button. The internal structure of the switch is realized by the spring of metal spring under force. Due to its small size and light weight, light touch switch is widely used in household appliances, such as audio-visual products, digital products, remote controls, communication products, household appliances, security products, toys, computer products, etc.
1、 The main specifications of touch switch are as follows:
Environmental friendly and high temperature resistant plug-in side plug-in large / medium / small turtle type light touch switch 2 * 4 light touch switch 3 * 3 light touch switch 3.7 * 3.7 * 0.35 imported light switch 4 * 4 * 1.5 / 1.6/17mm light touch switch 3 * 6 * 4.3 / 5.0mm car touch switch 4 * 6 * 2.6 touch switch 4.5 * 4.5 * 3.8 / 4.8 / 5 / 0 / 6 / 7 / 8 / 9 patch touch switch 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 2 * 2 * 2.5 / 2.7 / 3.1 / 3.4 light switch 12 * 12 * 12 * 4 * 4 * 4.3 / 5.0 / 5.5 / 6 / 7 / 7 / 3.1 / 3.4 light switch 12 * 12 * 12 * 12 * 4 * 4 * 4.3 / 5.0 / 5.5 / 5 / 6 / 7 / 7 / 8 / 9 / 10 / 11 / 12 / 12 / 13 / 14 / 15 / 15 / 16 / 17 / 18 / 19 / 20 / 22 / 22 / 23mm light switch 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 * 6 series waterproof touch switch 8 * 8 series waterproof touch switch 10 * 10 series waterproof touch switch 12 * 12 series waterproof light touch switch.
2、 Recognition of key signal
The recognition of key signal is to judge whether the key is pressed or not. It is an independent keyboard composed of 4 keys. One end of the key is grounded, and the I / O pins of pb0, PB1, PB2 and PB3 bits of single chip microcomputer are grounded. When a key is pressed, the level state of I / O pin of single chip microcomputer is low level, and it is high level when it is not pressed. By detecting the state of I / O pin of single chip microcomputer, we can judge whether the key is pressed or not.
Because the key is a mechanical switch, when the key is pressed or released, the button will shake, which will interfere with the recognition of the key. There are two methods to remove jitter, hardware and software. In general, software is used to remove jitter. The implementation method is to judge that the key is pressed, and add a 10 ms delay. After the key is stable, detect the key again. The key is still in the pressed state, and confirm that there is a key pressed.
3、 Key matrix (touch switch circuit)
When a system needs more buttons, the use of the above independent keys will occupy a large number of I / O ports. The I / O ports of MCU are limited resources. The matrix keyboard is usually used when more keys are needed. As shown in the figure below, 16 key matrixes with 4 rows and 4 columns are used.