Keypad Interface Module Reverse Engineers Pinouts So You Don’t Have To

If you’ve scavenged some random keypads and want to reuse them in a project without the hassle of figuring out the pinouts, then [Cliff Biffle] has an interface module for you. The Keypad Go connects to the mystery keypad via an 8-pin 0.1 inch header, and talks to your own project using I2C and/or serial.

You could categorize the mechanism at work as machine learning of a sort, though it’s stretching definitions a bit, as there is no ChatGPT or GitHub Copilot wizardry going on here. But you must teach the module during an initial calibration sequence, assigning a 7-bit ASCII character to each key as you press it. Once trained, it responds to key presses by sending the pre-assigned character over the interface. Likewise, key releases send the same character but with the 8th bit set.

The heart of the board is either an STM32G030 or STM32C011/31, depending on parts availability we presume. I2C connectivity is over a four-pin STEMMA connector, and logic-level serial UART data is over a four-pin 0.1 inch pin header. [Cliff] plans to release the firmware and schematics as open source soon, after cleaning up the code a bit. The device is also for sale on Tindie, though it looks like they won’t be back in stock until later on in the month.

Longtime readers might recognize [Cliff] from his impressive m4vga project which we covered back in 2015, where he manages to generate 800×600 VGA signals at 60 Hz from an STM32F4-family microcontroller.

Continue reading “Keypad Interface Module Reverse Engineers Pinouts So You Don’t Have To”

Bridging A Gap Between LLMs And Programming With TypeChat

By now, large language models (LLMs) like OpenAI’s ChatGPT are old news. While not perfect, they can assist with all kinds of tasks like creating efficient Excel spreadsheets, writing cover letters, asking for music references, and putting together functional computer programs in a variety of languages. One thing these LLMs don’t do yet though is integrate well with existing app interfaces. However, that’s where the TypeChat library comes in, bridging the gap between LLMs and programming.

TypeChat is an experimental MIT-licensed library from Microsoft which sits in between a user and a LLM and formats responses from the AI that are type-safe so that they can easily be plugged back in to the original interface. It does this by generating JSON responses based on user input, making it easier to take the user input directly, run it through the LLM, and then use the output directly in another piece of code. It can be used for things like prototyping prompts, validating responses, and handling errors. It’s also not limited to a single LLM and can be fairly easily modified to work with many of the existing models.

The software is still in its infancy but does hope to make it somewhat easier to work between user inputs within existing pieces of software and LLMs which have quickly become all the rage in the computer science world. We expect to see plenty more tools like this become available as more people take up using these new tools, which have plenty of applications beyond just writing code.

Transform An Original Xbox Controller To A 360 Controller

If you’re looking for a controller for your computer or mobile device, you could certainly do worse than one of the latest iterations of the Xbox pad. They might not be perfect, but they’re fairly well-made, not particularly expensive, use standard USB and Bluetooth interfaces, and even have decent support in the open-source community. So if you’re gaming on Linux or working on any other kind of retro gaming rig it’ll likely be plug-and-play.

This wasn’t the case with the first generation Xbox controller, though, and although its proprietary connector was actually using USB, the controller scheme wasn’t as open. This is [Tom]’s effort of upcycling his original Xbox controller to work indistinguishably from a stock Xbox 360 controller.

For those asking why anyone would want to do this, [Tom] is actually one of the few who enjoyed the original bulky Xbox “Duke” controller that released with the console in 2001. It wasn’t a popular choice in the larger gaming community and a year later Microsoft released a smaller version, but we all have our quirks. A Teensy 4.1 is attached to the end of the controller cable and acts as an intermediary to intercept the proprietary signalling coming from this controller and convert it into something usable. Since the controller doesn’t even show up as a standard USB HID device it took a little more sniffing of the protocol to decipher what was going on at all, but eventually some help was found within this other driver that gave [Tom] the clues he needed to get it working.

There were some other headaches to this project as well, especially since USB debugging USB connections while using USB isn’t exactly a streamlined process, but after a couple of breakthroughs the Teensy pass-through interface began working and [Tom] can use his controller of choice across multiple platforms now. If you’re looking to upgrade in other ways take a look at this build which seeks to recalibrate, rather than replace, an older Xbox controller experiencing drift on its analog control sticks.

Continue reading “Transform An Original Xbox Controller To A 360 Controller”

A Dedicated GPU For Your Favorite SBC

The Raspberry Pi is famous for its low cost, versatile and open Linux environment, and plentiful I/O, making it a perfect device not only for its originally-intended educational purposes but for basically every hobbyist from gardeners to roboticists to amateur radio operators. Most builds tend to make use of the GPIO pins which allow easy connections to various peripherals and sensors, but the Pi also supports PCI devices which means that, in theory, it could use a GPU in much the same way that a modern computer would. After plenty of testing and development, [Jeff Geerling] brings us this custom graphics card interface for the Raspberry Pi.

The testing for all of these graphics cards has been done with a Pi Compute Module 4 and the end result is an interface device which looks much like a graphics card itself. It splits the PCI bus out onto a more familiar x16 slot connector and adds physical connections for power, USB, and Ethernet. When plugged into the carrier board, the Compute Module can be attached to any of a number of graphics cards, including the latest and highest-end of Nvidia and AMD offerings.

Perhaps unsurprisingly, though, the 4090 and 7900 cards don’t work with the Raspberry Pi. This is partially due to the 32-bit limitations of the Pi and other memory mapping issues, but even after attempting some workarounds Nvidia’s cards aren’t open-source enough to test properly (although the card is recognized by the Pi) and AMD’s drivers crash the system even after compiling a custom kernel. [Jeff] did find an Nvidia card that worked, although it requires using the USB interface and second-hand cards are selling for around $3000 USD. For a more economical choice there are some other graphics cards that he was eventually able to get working, albeit not with perfect performance, including some of the ones we’ve seen him test already.

Continue reading “A Dedicated GPU For Your Favorite SBC”

Beat Backing Box For Bassists

The soul of a rock band is its rhythm section, usually consisting of a drummer and bass player. If you don’t believe that, try listening to a band where these two can’t keep proper time. Bands can often get away with sloppy guitars and vocals (this is how punk became a genre), but without that foundation you’ll be hard pressed to score any gigs at all. Unfortunately drums are bulky and expensive, and good drummers hard to find, so if you’re an aspiring bassist looking to practice laying down a solid groove on your own check out this drum machine designed by [Duncan McIntyre].

The drum machine is designed to be as user-friendly as possible for someone who is actively playing another instrument, which means all tactile inputs and no touch screens. Several rows of buttons across the top select the drum sounds for the sequencer and each column corresponds to the various beats, allowing custom patterns to be selected and changed rapidly. There are several other controls for volume and tempo, and since it’s based on MIDI using the VS1053 chip and uses an STM32 microcontroller it’s easily configurable and can be quickly interfaced with other machines as well.

For anyone who wants to build their own, all of the circuit schematics and code are available on GitHub. If you have an aversion to digital equipment, though, take a look at this drum machine that produces its rhythms using circuits that are completely analog.

Continue reading “Beat Backing Box For Bassists”

Python Your Keyboard Hack Chat With Adafruit

Join us on Wednesday, July 21 at noon Pacific for the Python Your Keyboard Hack Chat with the Adafruit crew!

Especially over the last year and a half, most of us have gotten the feeling that there’s precious little distinction between our computers and ourselves. We seem welded together, inseparable even, attached as we are day and night to our machines as work life and home life blend into one gray, featureless landscape where time passes unmarked except by the accumulation of food wrappers and drink cans around our work areas. Or maybe it just seems that way.

Regardless, there actually is a fine line between machine and operator, and in most instances it’s that electromechanical accessory that we all love to hate: the keyboard. If you buy off the shelf, it’s never quite right — too clicky, not clicky enough, wrong spacing, bad ergonomics, or just plain ugly design. The only real way around these limitations is to join the DIY keyboard crowd and roll your own, specifically customized to your fingers and your needs — at least until you realize that it’s not quite perfect, and need to modify it again.

Hitting this moving target is often as much a software problem as it is a hardware issue, but as is increasingly the case these days, Python is ready to help. To go into depth on how Python can be leveraged for the custom keyboard builder, our good friends at Adafruit, including Limor “Ladyada” Fried, Phillip Torrone, Dan HalbertKattni Rembor, and Scott Shawcroft will stop by the Hack Chat. We suspect they’ll have some cool stuff to show off, in addition to sharing their tips and tricks for making DIY keyboards just right. If you’re building custom keebs, or even if you’re just “keyboard curious”, you won’t want to miss this one.

join-hack-chatOur Hack Chats are live community events in the Hackaday.io Hack Chat group messaging. This week we’ll be sitting down on Wednesday, July 21 at 12:00 PM Pacific time. If time zones have you tied up, we have a handy time zone converter.