An IR Blaster Project, In A Nutshell

The speed that computers have gotten smaller is a bit mind-bending. Most of us now walk around with computers in our pockets that would have rivaled the supercomputers from a few decades ago. And, although it seems like the speed at which things are getting smaller and faster has slowed a bit compared to the rapid pace of the 90s and 00s, some truly minuscule computers are accessible nowadays. So much so that it’s possible to do useful computing inside a walnut shell.

The first step in this build is to crack into a walnut. Most have a natural seam that separates two hemispheres, so splitting it open, enjoying a small snack, and then adding some small neodymium magnets on the inside of that seam to close up the shell is not too difficult. From there, some LEDs were installed at various points in the shell, with an ESP32-C3 installed in the middle to control everything and oriented so that its USB port is still accessible.

Although putting a small microcontroller in a nutshell might seem like a novelty, [JSK-koubou] is actually using the LEDs to perform a useful task. The walnut sits in his living room and connects to a home automation system through the ESP32, and when it receives a command it uses the LEDs to send infrared signals to non-connected devices. Hiding projects in unexpected places is a fun pastime, like this Meshtastic node hidden in a landscape light.

Continue reading “An IR Blaster Project, In A Nutshell” →

Center-Pivot System Modified To Mow Lawn

When flying over the United States, Australia, and a few other vast and relatively empty parts of the world, strange circular formations can be spotted. These are typically center-pivot irrigation systems, an effective way to irrigate crops if efficient use of space is not too big of a priority. Keeping these massive machines in a straight line is an interesting engineering problem, though, and [rctestflight] built a miniature version of his that works on the same principle but mows his lawn instead.

These systems work as semi-independent sections that are flexibly coupled at either end. The control scheme initially used here was to drive the outermost set of wheels at a constant speed, and then use limit switches at each coupling inside of that to drive inner sets of wheels once the outer set passes a setpoint. Eventually a potentiometer-based proportional controller was installed in place of the limit switches. With some other drivetrain issues sorted out it was on to building the mower attachment. This uses a pair of pivoting precision knives mounted to motors that ride along a carriage attached to any one of the linkages of the center-pivot system. Limit switches keep the carriage riding back and forth cutting the lawn as it traverses the grass.

With the system in place, [rctestflight] set out to optimize it mostly out of a desire to tinker with a thing that he had built. The challenge for him is that his location in the Pacific Northwest is generally very damp, so in addition to corrosion and other water damage on various parts, there were also issues of mud complicating the way the wheels navigated the terrain, as well as the plant growth being fairly rapid and often impeding the process of the robot as well. One of the perks, though, was that the circular area was already largely carved out thanks to some of his earlier projects testing the durability of RC cars.

Continue reading “Center-Pivot System Modified To Mow Lawn” →

Reverse Engineering Apple’s Mikey Chip

On the old iPods, generally referred to here in the future as iPod Classic, there lives a tiny, undocumented chip called Mikey. It sits at the headphone output and performs only two functions: powering the Apple wired headset microphone and handling button presses from the three buttons. Despite these headphones and iPods having existed for nearly two decades, no one in the open source community has figured out the protocol Apple used for these buttons until now.

As [Hemant] discovered after finding a single archived blog post from 16 years ago about it, the chip is relatively simple by modern standards. Besides handling microphone bias, it sits on an I2C bus and monitors presses from the three buttons on the headset. Each button has its own resistive load, so a press from any of them drops the voltage on the line to a certain amount which the chip can read. The more involved part is a “chirp” that’s a sort of handshake between headset and iPod, which took a bit of work with a debugger that [Hemant] built into a custom Rockbox firmware.

With the chirp sorted out, [Hemant] built the feature into an existing version of Rockbox, and submitted the update to the Rockbox team for integration in future official builds. It’s a long overdue feature for those still using wired headphones and iPods from the turn of the century, but welcome. Some of those iPods are still working to this day, but only conditionally if they’re very cold.

Basically, Galvanizing Metal Without Acid

As useful as steel and iron are to the modern world, their tendency to rust is a major downside. There’s a spectrum of ways to prevent it, from quickly slapping on a coat of paint to alloying, chromizing, or physical vapor deposition. For a middle ground accessible to the home shop, galvanizing is a go-to method of rust prevention that deposits a layer of zinc onto the metal instead, but even this generally involves the use of strong acids. This method makes galvanizing accessible without any acids. (Spoiler alert: substitute strong bases.)

Although the acids are omitted, the solution is caustic, so similar safety measures are still advised. The first step in the process is to dissolve sodium hydroxide into a container of distilled water. Metallic zinc can then be dissolved in the solution, with a bit of sugar and liquid soap to improve the finished quality of the coating. An electric current is applied to the solution, using a graphite plate at the anode and the part to be electroplated as the cathode. After some time, the part will be uniformly coated in a layer of zinc, which can then be brightened in a solution of only-mildly-acidic citric acid if needed.

One of the benefits of using a strong base to galvanize a metal part, beyond the preference of avoiding strong acids, is that this process can be better at plating parts that are non-uniform in shape, so things with deep crevices or other odd shapes that might coat unevenly in acid. If there’s a preference for electroplating with acid, there are some ways of producing one’s own using various methods.

Continue reading “Basically, Galvanizing Metal Without Acid” →

A Modular Macro Keypad

The introduction of the ATmega32U4 microcontroller, with its integrated USB controller, made a lot of hardware tasks much simpler than they were before. One of the arenas it revolutionized was custom keyboards, making it much easier to build not only standard mechanical keyboards, but keyboards of all kinds of shapes and layouts and custom macro keyboards as well. This trend has continued on for the better part of the past decade with other microcontrollers beyond the 32U4 now available as well, but this modular macro keypad takes it to a new level by keeping that simplicity but also keeping costs down.

The suutari20, as it is called by its creator [Squalius] is able to achieve these aims by using 3.5 mm jacks commonly found in audio equipment. Each jack can support up to three keys, with the hub ultimately able to support 18 different keys. Those can include analog devices as well, such as volume knobs or jog controllers. The macro pad is powered by an RP2040 microcontroller from a Raspberry Pi Pico and uses QMK firmware, so those already familiar with custom keyboard programming will have no problem getting started.

From there, all that’s needed is a case, in this example a 3D printed one, and the commodity audio hardware to plug everything in to. It enables whatever functions can be thought of in a macro pad, and although the design focuses on simplicity and cost, this macro pad takes the concept to the extreme with modular keys that each have their own microcontroller built-in.

Continue reading “A Modular Macro Keypad” →

Abusing SQL To Play DOOM

Most laypeople who encounter SQL think of it purely as a tool for managing large datasets. While that is certainly what it was designed for, SQL is still a programming language at its core. It includes many of the features found in general-purpose languages like C or Python, and although it wasn’t built for general-purpose work, it can handle a surprising range of tasks that programmers might not expect to use it for. To demonstrate its capabilities, and perhaps to show off their skills with SQL, a group at CedarDB ported the original DOOM to this language.

The project stores the WAD data (essentially everything except the engine) in a series of tables, which was fairly straightforward compared to the rest of the project. Where it gets more complicated is managing the timing that ties the game to 35 fps, and of course rendering the images. Their rendering process takes up 1300 lines of SQL across 89 common table expressions (CTEs) which is certainly advanced for this language. The rest of the project is another 4000 lines of SQL, with a bit of Python to handle the keyboard inputs, timing, and display of the generated bitmap.

Perhaps counterintuitively, DOOM might be the perfect game to run on SQL. It was built in an era before dedicated graphics cards and isn’t truly 3D, meaning that the programmers had to do a lot of tricks to get it to look as if it is 3D. This results in a lot of data transformations uniquely suited to SQL. It’s almost like DOOM‘s original renderer was built by someone with extensive SQL knowledge in the first place. For those looking to try this out, the source code for the project is available on a GitHub page, and for some other unique implementations of DOOM there’s also this version built in regular expressions and this one in Microsoft Word.

Myst On The Atari 2600

Although the Atari 2600 was a hugely popular game console in the late 70s, its hardware specs were limited, to say the least. For a dedicated game console of the era this isn’t too surprising, but things like 128 bytes of RAM meant programmers had to work hard to make games that were fun and playable (and they didn’t always succeed). Programming on this system even now is difficult, but nonetheless [Vince] wanted to get a version of Myst running on this system.

Obviously a PC game from the 90s is much to large, in many ways, to fit into an Atari cartridge or play on the 70s-era hardware. For that, there is a “demake” of Myst, a recreation of the game purposely built to run on older hardware it was never meant for. Even so, the game is running on a specialized cartridge built by [Vince] using parts from the real Atari game cartridge BurgerTime which had a bit more memory than normal. It wasn’t quite as straightforward as flashing the new game file to an old EEPROM though; [Vince] came across all kinds of timing issues and other miscellaneous problems that stretched this project out to around a three-year endeavor.

At the end of everything, though, he has a cartridge that will run Myst on the Atari, using the E7 bank switching scheme which afforded this system more memory within the cartridge. For [Vince], who is a fan of the demo scene for consoles like this, this was an interesting experiment to push original hardware to its limits. And, if you want to try this on an Atari 2600 handheld which also uses original hardware, we’d recommend using one of these.