8/9/2023 0 Comments Diy osu keypadThe rgb LEDs are APA102 leds which are individually addressable using a clock and data line. If you measure a different debounce time on your switch you can calculate your resistor and capacitor values. The voltage of the capacitor at any time in its discharge is Vcc * e^(-t/RC). The Atmaga32U4 reads a digital low at 0.2Vcc - 0.1V = 0.9 volt. Don't worry about it falling to slow for the next real press because it will. The signal to the Arduino won't be able to change as fast as the bouncing occurs so it will be read as one press. This debounce circuit will slow down the falling edge of the signal. The program will send a key press or release every time a high or low is read so with every press your computer will receive multiple key presses. An Arduino is really fast and reads every high and low in this short time. When you press or release a switch it bounces and your signal alternates between high and low a couple of times for a few milliseconds. To know what debouncing is you need to understand switch bouncing and it's not hard to understand.įirst look at this simulation to paint a first picture (click the switch fast and look at the signal below) This circuit is used to debounce the switch. On the left side of the schematic is a circuit that is copied 3 times. This is further explained in the code section. The switches are connected to Arduino pins 0, 2 and 3 because those pins can be used as external interrupts. The schematic for this project is rather simple, but I want to explain the components for the people who are interested and don't know this implementation. If you have a 3D printer go ahead and print it, but please don't go out of your way to print this flawed case if you dont and just use some kind of project box. In the future a new housing may be added. Modifications are needed to fit bolts, the openings for the leds are not optimal, the arduino is exposed and a part needs to be cut out for the USB to fit. I do provide a housing in this project, but it is at this moment flawed. Even for SMD on a PCB "advanced" soldering skills are equired. I would also not recommend to use wires on SMD packages unless you are Very confident in your soldering skills. Unfortunately the leds used are not available in trough hole packages. Not much to explain about them in this chapter, but if you dont use the PCB I would recomend just normal trough hole components for soldering ease. If you choose to use the PCB you'll need Kailh BOX switches. I used the Kailh switches because they were cheap on Ailexpress. Linear, tactile or clicky from Kailh or Cherry MX. There are many mechanical switches you can use. Those boards use an external chip to make USB communication possible whereas the Arduino pro micro (Atmega32U4) has it built in. Yes you can program them over USB very easily and I think there are workarounds, but I like to keep it simple when it comes to USB communication and I don't know if the workarounds are as responsive. Most arduino boards like the Uno (Atmega328) don't have native support for USB communication. If you have the time and want to save mony, order form aliexpress and don't order the PCB.ġ Printed circuit board (PCB) provided in this projectġ 3D printed case provided in this project It currently doesn't have led functionality but it should be the best performing one.ĭepending on how you make your project you may need different components, but these components are te ones I used. I'll leave all code online but I recommend you use the last version. Note 2: I have updated the code multiple times and im up to version 3ish now. maybe an easy to solder version will be added but these leds don't come in trough hole package Note 1: SMD components (small electronics) are used so if you replicate this project soldering skills are required. If you can handle it I would encourege you to customize your project. Some components are chosen almost purely because i had them lying around. If you want to replicate this project exactly to the last instruction then be my guest, but some of the desicions I made are not based on lowest price or best quality. Not long after that I decided it would be a good idea to put it on instructables as my first project. I recently started playing a rhythm game called osu! and after seeing a video of a commercial mini keyboard I thought it would be a fun project to design one myself.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |