Foot Pedal Ups Vim Productivity, Brings Ergonomic Benefits

Vim is the greatest or the worst text editor of all time, depending on the tribe you’re in. Either way, members of both camps can appreciate this build from [Chris Price], which uses a foot pedal to ease operations for the user.

The basic concept was to use a pedal to enable switching between normal and insert modes. In Vim’s predecessor, vi, switching modes was easy, with the ESC key located neatly by the Q on the keyboard of the ADM-3A terminal. On modern keyboards, though, it’s a pain, and so a foot pedal is a desirable solution. In the Vim world, it’s referred to as a “Vim clutch.”

The build used a cheap pedal switch sourced from eBay, into which a Raspberry Pi Pico was installed. The Pico was hooked up to the switch contacts, and programmed to act as a USB HID device. When the pedal is pressed down, the Pico sends an “i” keypress to enter Vim’s insert mode. Releasing the pedal has the Pico send a “ESC” keypress to return to normal mode.

Those that use Vim on a regular basis would likely appreciate the productivity improvements of such a device. Plus, there’s some ergonomic benefits to not having to strain one’s hand over to reach the ESC key. Of course, it’s an old-school solution, but there’s still something so compelling and next-level about having a foot pedal hooked up to one’s dev rig.

Battery Engineering Hack Chat Gets Charged Up

Turn the clock back a couple of decades, and the only time the average person would have given much thought to batteries was when the power would go out, and they suddenly needed to juice up their flashlight or portable radio.  But today, high-capacity batteries have become part and parcel to our increasingly digital lifestyle. In fact, there’s an excellent chance the device your reading this on is currently running on battery power, or at least, is capable of it.

So let’s get to know batteries better. What’s the chemical process that allows them to work? For that matter, what even is a battery in the first place?

It’s these questions, and more, that made up this week’s Battery Engineering Hack Chat with Dave Sopchak. Our last Hack Chat of 2022 ended up being one of the longest in recent memory, with the conversation starting over an hour before the scheduled kickoff and running another half hour beyond when emcee Dan Maloney officially made his closing remarks. Not bad for a topic that so often gets taken for granted.

Continue reading “Battery Engineering Hack Chat Gets Charged Up”

Hackaday Podcast 197: Decoding VHS, Engineering The TV Guardian, And Gitting Code Into Your ESP32s

This week, Editor-in-Chief Elliot Williams and Assignments Editor Kristina Panos delighted in the aural qualities of Kristina’s brand new, real (read: XLR) microphone before embarking on creating a podcast highlighting the best of the previous week’s hacks.

This week in the news, NASA returned to the Moon with Artemis I, and this time, there are CubeSats involved. After that, it’s on to the What’s That Sound results show, marred by Kristina’s cheating scandal (listening ahead of time) and Elliot’s reading the filename aloud before we started recording. Finally, we move on to the hacks — they start with a trip to the 90s both sonically and visually, and end with a really nice alarm clock that’s decidedly 70s, and definitely Hackaday.

Check out the links below if you want to follow along, and as always, tell us what you think about this episode in the comments!

And/or download it and listen offline.

Continue reading “Hackaday Podcast 197: Decoding VHS, Engineering The TV Guardian, And Gitting Code Into Your ESP32s”

Motion-Activated Clock Only Lights Up On Command

While some of us can fall asleep anywhere from a noisy auditorium to a brightly lit train station, others are more fussy, requiring quiet and dark to nod off. [Craig Lindley] likes to minimize light when he’s trying to sleep, and decided to build himself a simple clock that wouldn’t disturb his rest.

The basic concept was to build a clock that would only display the time on command. In this case, that command would be a wave of a hand in front of the clock. The build is based around a Lilygo ESP32 T-Display unit, which combines the ESP32 with an LCD display and a battery management system. The ESP32’s WiFi connection provides accurate time via querying an NTP server. A passive infrared motion sensor is used to detect the motion of the user’s hand in front of the clock.

While all kinds of clocks and clock radios are available out there, few are motion activated. [Craig]’s work is a great demonstration of building your own solutions to your problems. We’ve seen some other neat motion-sensing convenience hacks before, too!

This Week In Security: Scamming The FBI, In The Wild, And AI Security

If you’re part of a government alphabet agency, particularly running a program to share information to fight cybercrime, make sure to properly verify the identity of new members before admission. Oh, and make sure the API is rate-limited so a malicious member can’t scrape the entire user database and sell it on a dark web forum.

Putting snark aside, this is exactly what has happened to the FBI’s InfraGuard program. A clever user applied to the program using a CEO’s name and phone number, and a convincing-looking email address. The program administrators didn’t do much due diligence, and approved the application. Awkward.

BSD Ping

First off, the good folks at FreeBSD have published some errata about the ping problem we talked about last week. First off, note that while ping does elevate to root privileges via setuid, those privileges are dropped before any data handling occurs. And ping on FreeBSD runs inside a Capsicum sandbox, a huge obstacle to system compromise from within ping. And finally, further examination of the bug in a real-world context casts doubt on the idea that Remote Code Execution (RCE) is actually possible due to stack layouts.

If someone messes up somewhere, go look if you messed up in the same or similar way somewhere else.

Sage advice from [Florian Obser], OpenBSD developer. So seeing the ping problem in FreeBSD, he set about checking the OpenBSD ping implementation for identical or similar problems. The vulnerable code isn’t shared between the versions, so he reached for afl++, a fuzzing tool with an impressive list of finds. Connect afl++ to the function in ping that handles incoming data, and see what shakes out. The conclusion? No crashes found in this particular effort, but several hangs were identified and fixed. And that is a win. Continue reading “This Week In Security: Scamming The FBI, In The Wild, And AI Security”

Mazda Patents Spinning Dorito To Extend EV Range

OK, so a Wankel engine doesn’t really use a Dorito as its cylinders, but it sure looks like one. The company has announced it will offer a range extender rotary engine for the MX-30 electric “crossover” vehicle, but [CarBuzz] dug into the patent papers to find out that it has some interesting twists.

The MX-30 is an EV with a relatively small 35.5 kWh battery. Like a hybrid vehicle, the car includes a small internal combustion engine that can charge the battery. It does not, however, directly drive the wheels at any time. The Wankel has several improvements, including a secondary port that allows more air into the combustion chamber when the engine has to produce high power. But there’s a problem…

The secondary port is great when you are pushing hard, but at low speed, it produces inefficiency. To combat that, Mazda includes a valve to seal off the second port when it doesn’t make sense to open it. But that’s not the strange part. The strange part is that the engine also has its own electric assist motor that runs off the main battery.  That’s right. The battery you are charging provides some energy to operate the electric assist motor to help the engine that is charging the battery. If that makes your head spin like the Wankel’s rotor, you aren’t alone.

The assist motor can assist or retard the output shaft during the intake stroke. This can optimize the intake to the combustion chamber. Of course, this will cause odd movement in the engine’s output, but since it doesn’t drive the car, who cares? The battery isn’t going to mind if the output isn’t smooth.

The Wankel shows up in a lot of odd places. We’ve seen Wankel air compressors. Despite detractors, there have been many improvements in the design over the years.

Two-Thirds Keyboard Is Inspired By The Typesetting Era

We see all kinds of custom keyboard builds around here. Most of them are intended to optimize typing to the user’s desires. This glorious build from [Attoparsec] isn’t one of those, and is instead part of the growing joke keyboard genre. The so-called Two-Thirds Keyboard is inspired by the long-gone typesetting era.

The build is based on the typecases used in the era when type was assembled by hand. Typesetters would grab “majuscule” letters from the upper case of type, and “miniscule” letters from the lower case of type, when setting a page, which would go on to influence how we refer to those letters today. Letters that came up more often, like e and s, would get larger compartments in the type cases, while rarer letters like z and q would get smaller compartments. The Two-Thirds keyboard replicates this by giving the most common letters the biggest keys, while rarer letters and upper-case majuscule letters get smaller keys. The overall layout matches that of the popular Two-Thirds California Case of type that grew popular in the US in the typesetting era.

There were some engineering issues in building the keyboard. While stabilizers are available for wide keys like Enter and Space in regular keyboard designs, stabilizing keys that are wide and high is fussy. The build relies on multiple switches to enable them to move cleanly. Nor were 2×2 and 2×3-sized custom keycaps readily available. In the end, resin printing was key to producing all the necessary components.

Typing on the keyboard is not quick, but lower speeds were probably acceptable in the typesetting era. Regardless, [Attoparsec] used it for a full week to do it justice, going from around 10  wpm to 22 wpm by the end of the test.

It’s a fun build, but by no means the slowest keyboard we’ve ever seen.

Continue reading “Two-Thirds Keyboard Is Inspired By The Typesetting Era”