Fn not pressed:
Hold down Fn (multimedia functionality added in version 0.5):
Although it is the challenge of the lowest cost and simplest circuit, there is still a lower limit:
1. No rollover for all keys
2. Bring lights (I can do without welding, but you can’t do without)
3. And it is a two-color LED light
4. With HUB, it is convenient to plug in a wireless mouse (the distance is close, the signal is stronger and more stable), and a USB flash drive. However, it has been discontinued because EDA is not optimized enough for equal lengths.
(It has been implemented in another version, please stay tuned)
You can see Baidu’s “least io scans the most buttons” (here are just a few representative ones)
Traditional matrix:
Diode coding:
Variants of row and column keyboards:
Of course, all of the above have key collisions, and the most commonly used keyboards on the market are conflict-free keyboards based on the first modification. And I want to find another way and use the third transformation.
This is a partial screenshot of the schematic diagram (ignore the LED pins and only look at the buttons). Here, the three io drivers K1, K2, and K3 scan six buttons. Careful viewers may notice that this is different from the third one above. The scheme is similar. They are all paired with IO, one button on the front and one on the back. The operation process will not be explained here.
In order to answer this question, we open the technical documentation:
This is the volt-ampere characteristic diagram of 4148:
This is the trigger level voltage of CH551:
When the power supply is 5V:
When the power supply is 3.3V:
Assume that the current flowing through the 4148 is 1mA, then the voltage drop is 0.5V.
In this case, if the microcontroller is powered by 5V, both K2 and K3 are low. Obviously this goes against the original intention of full-key rollover.
But under 3.3V power supply, 2*0.5V>0.8V, then K2 is low and K3 is high. It’s done.
( The actual measured 551 is not considered a low level at 0.9V, so a pull-up resistor is needed to provide bias current to the diode and increase the voltage drop, otherwise it will be the same as under 5V power supply )
But I was not satisfied with this. I also wanted to add more buttons. After reading the technical documentation carefully, I found that the RST pin can be used as an input pin, but the technical documentation did not indicate its trigger level. To be on the safe side, I connected an external PNP tube for inversion. device. In this way, with only one CH551 and 16 legs, excluding 3 power supplies and 2 USBs, the remaining 10 IOs plus an RST pin can achieve 100 keys without conflict without considering the lights. You say it's powerful or not. However, the size of the 3D printer is limited and it needs to drive LEDs. It just so happens that it comes with two PWM channels for driving two-color LEDs. The rest can also be used for 64-key rollover. There are 61 keys arranged, and there are 3 more buttons that can be used as side keys. Squeeze this microcontroller dry in all aspects.
PCB front and back:
Solder the typeC port first:
Input filtering:
Power supply voltage stabilizing block:
Microcontroller:
Exclusion resistor and transistor: (I forgot to order the SMD 8550, plug it directly into the top)
Start welding 4148:
Weld one side first to fix it:
All welded:
Close-up: (later I found a 4148 with no tin on one side, just in the picture)
Side buttons:
Start welding shaft 25%
50%
75%
100%
Close-up of solder joints: (4148 without tin is on camera again)
Upper balance bar:
Add keycaps:
Close-up of the sponsor’s logo:
Ver0.1:
Ver0.2:
Ver0.3:
Ver0.4:
Ver0.41:
Ver0.5:
Ver0.51:
Ver0.52:
Ver0.6:
Ver0.7
Lighting effect:
The program has been updated for more than a year, and I think its functions are now very complete.
Therefore, the software version should not have any major functional updates in the future. Of course, if you have good ideas, you can put them forward in the comment area.
[DIY mechanical keyboard kit (51 microcontroller)]
110 yuan without free shipping:
Positioning board + circuit board + bottom plate + foot pad + balance rod + green axis + electronic components
You can calculate the cost a little bit. If you make one or two sets of the remaining salted fish and resell them, you might as well buy my kits, because you will definitely not be able to sell them to me.
It’s a different matter if you make 5 sets to give to friends or if the finished product is resold. It is recommended that you tell them about this website after resale so that they can update the program.
The program update tutorial refers to another open source project on the site (remember not to check the reset pin enable): https://oshwhub.com/TheLight/zi-ding-yi-jian-pan
[Due to the long format, the finished products sold to users are placed in the appearance section]
Related words: charlieplexing
I saw this name recently. The principle is very similar, so I put the name here. If you are interested, you can search it on Baidu.
By reducing one channel of PWM output, there are 9981 keys. The light under the caps lock key can also be used as a capital indicator and maintain the same brightness as other LEDs.
Add HUB to modify the layout to make way for the USB interface
Principle description picture reference link : https://baijiahao.baidu.com/s?id=1621173179116478690&wfr=spider&for=pc # Title #italic
All reference designs on this site are sourced from major semiconductor manufacturers or collected online for learning and research. The copyright belongs to the semiconductor manufacturer or the original author. If you believe that the reference design of this site infringes upon your relevant rights and interests, please send us a rights notice. As a neutral platform service provider, we will take measures to delete the relevant content in accordance with relevant laws after receiving the relevant notice from the rights holder. Please send relevant notifications to email: bbs_service@eeworld.com.cn.
It is your responsibility to test the circuit yourself and determine its suitability for you. EEWorld will not be liable for direct, indirect, special, incidental, consequential or punitive damages arising from any cause or anything connected to any reference design used.
Supported by EEWorld Datasheet