Mysterious Files PH

Saturday, November 23, 2024

RFID From First Principles and Saving a Cat

November 23, 2024 0

[Dale Cook] has cats, and as he readily admits, cats are jerks. We’d use stronger language than that, but either way it became a significant impediment to making progress with an RFID-based sensor to allow his cats access to their litterbox. Luckily, though, he was able to salvage the project enough to give a great talk on RFID from first principles and learn about a potentially tragic mistake.

If you don’t have 20 minutes to spare for the video below, the quick summary is that [Dale]’s cats are each chipped with an RFID tag using the FDX-B protocol. He figured he’d be able to build a scanner to open the door to their playpen litterbox, but alas, the read range on the chip and the aforementioned attitude problems foiled that plan. He kept plugging away, though, to better understand RFID and the electronics that make it work.

To that end, [Dale] rolled his own RFID reader pretty much from scratch. He used an Arduino to generate the 134.2-kHz clock signal for the FDX-B chips and to parse the returned data. In between, he built a push-pull driver for the antenna coil and an envelope detector to pull the modulated data off the carrier. He also added a low-pass filter and a comparator to clean up the signal into a nice square wave, which was fed into the Arduino to parse the Differential Manchester-encoded data.

Although he was able to read his cats’ chips with this setup, [Dale] admits it was a long road compared to just buying a Flipper Zero or visiting the vet. But it provided him a look under the covers of RFID, which is worth a lot all by itself. But more importantly, he also discovered that one cat had a chip that returned a code different than what was recorded in the national database. That could have resulted in heartache, and avoiding that is certainly worth the effort too.

Thanks for the tip, [Gustavo].


Forget Pixel Art: Try Subpixels

November 23, 2024 0

[Japhy Riddle] was tired of creating pixel art. He went to subpixel art. The idea is that since each color pixel is composed of three subpixels, your display is actually three times as dense as you think it is. As long as you don’t care about the colors, of course.

Is it practical? No, although it is related to the Bayer filter algorithm and font antialiasing. You can also use subpixel manipulation to hide messages in plain sight.

[Japhy] shows how it all works using Photoshop, but you could do the same steps with anything that can do advanced image manipulation. Of course, you are assuming the subpixel mask is identical is for any given device, but apparently, they are mostly the same these days. You could modify the process to account for different masks.

Of course, since the subpixels are smaller, scaling has to change. In the end, you get a strange-looking image made up of tiny dots. Strange? Yes. Surreal? You bet. Useful? Well, tell us why you did it in the comments!

Pixel art isn’t just for CRTs. However, subpixel art assumes that the pixels can be divided up, which is not always the case.


Close Shave for an Old Oscilloscope Saved with a Sticky Note

November 23, 2024 0

When you tear into an old piece of test equipment, you’re probably going to come up against some surprises. That’s especially true of high-precision gear like oscilloscopes from the time before ASICs and ADCs, which had to accomplish so much with discrete components and a lot of engineering ingenuity.

Unfortunately, though, those clever hacks that made everything work sometimes come back to bite you, as [Void Electronics] learned while bringing this classic Tektronix 466 scope back to life. A previous video revealed that the “Works fine, powers up” eBay listing for this scope wasn’t entirely accurate, as it was DOA. That ended up being a bad op-amp in the power supply, which was easily fixed. Once powered up, though, another, more insidious problem cropped up with the vertical attenuator, which failed with any setting divisible by two.

With this curious symptom in mind, [Void] got to work on the scope. Old analog Tek scopes like this use a bank of attenuator modules switched in and out of the signal path by a complex mechanical system of cams. It seemed like one of the modules, specifically the 4x attenuator, was the culprit. [Void] did the obvious first test and compared the module against the known good 4x module in the other channel of the dual-channel scope, but surprisingly, the module worked fine. That meant the problem had to be on the PCB that the module lives on. Close examination with the help of some magnification revealed the culprit — tin whiskers had formed, stretching out from a pad to chassis ground. The tiny metal threads were shorting the signal to ground whenever the 4x module was switched into the signal path. The solution? A quick flick with a sticky note to remove the whiskers!

This was a great fix and a fantastic lesson in looking past the obvious and being observant. It puts us in the mood for breaking out our old Tek scope and seeing what wonders — and challenges — it holds.


3D Printed Boat Uses Tank Tracks For Amphibious Propulsion

November 23, 2024 0

Boats normally get around with propellers or water jets for propulsion. Occasionally, they use paddles. [Engineering After Hours] claims he is “changing the boat game forever” with his new 3D printed boat design that uses a tank tread for propulsion instead. Forgive him for the hyperbole of the YouTuber. It’s basically a modified paddle design, but it’s also pretty cool.

It works on land, even if it doesn’t steer well!

The basic idea is simple enough—think “floating snowmobile” and you’re in the ballpark. In the water, the chunky tank track provides forward propulsion with its paddle-like treads. It’s not that much different from a paddle wheel steamer. However, where it diverges is that it’s more flexible than a traditional paddle wheel.

The tracked design is actually pretty good at propelling the boat in shallow water without getting stuck. In fact, it works pretty well on dirt, too! The video covers the basic concept, but it also goes into some detail regarding optimizing the design, too. Getting the float and track geometry right is key to performance, after all.

If you’re looking to build an oddball amphibious craft, maybe working with the snowmobile concept is worth your engineering time.


Friday, November 22, 2024

OLED Screen Mounting, Without The Pain

November 22, 2024 0
OLED Screen Mounting, Without The Pain

There was a time when no self-respecting electronics engineer would build a big project without at least one panel meter. They may be a rare part here in 2024, but we find ourselves reminded of them by [24Eng]’s project. It’s a 3D printed housing for one of those common small OLED displays, designed to be mounted on a panel with just a single round hole. Having had exactly this problem in the past trying to create a rectangular hole, we can immediately see the value in this.

It solves the problem by encasing the display in a printed shell, and passing a coarsely threaded hollow cylinder behind it for attachment to the panel and routing wires. This is where we are reminded of panel meters, many of which would have a similar sized protrusion on their rear housing their mechanism.

The result is a neatly made OLED display mounting, with a hole that’s ease itself to create. Perhaps now you’ll not be afraid to make your own panels.


Hack On Self: The Un-Crash Alarm

November 22, 2024 0
Hack On Self: The Un-Crash Alarm

Ever get home, tired after work, sit down on a couch, and spend an hour or two sitting down without even managing to change into your home clothes? It’s a seriously unpleasant in-between state – almost comfortable, but you know you’re not really at rest, likely hungry, and even your phone battery is likely about to die. This kind of tiredness can get self-reinforcing real quick – especially if you’re too tired to cook food, or you’re stuck in an uncomfortable position. It’s like the inverse of the marshmallow test – instead of a desire, you’re dealing with lack thereof.

I’ve been dealing with this problem a lot within the last two years’ time. Day to day, I could lose hours to this kind of tiredness. It gets worse when I’m sick, and, it’s gotten worse on average after a few bouts of COVID. It’s not just tiredness, either – distractability and tiredness go hand in hand, and they play into each other, too.

My conclusion, so far, was pretty simple. When I’m tired, delayed but proper rest is way better than “resting” in a half-alert state, even if that takes effort I might not have yet. So, it’s important that I can get up, even if I’m already in a “crashed” position. Sure, I could use tricks like “do not sit down until I’m ready to rest”, but that only works sometimes – other times, the tiredness is too much to handle.

Audio files and sound playback library in hand, negative reinforcement methods fresh in my mind, I went and cooked together a very simple solution.

Anti-Crash Script

When I noticed myself being tired and in a “crash” state, I would think “oh, no worries, I’m going to get up any minute now”. Of course, it was never just a minute, and I decided to hook into that realization, subsurface but close enough that I could justify some intervention to myself.

Would you be surprised if I told you the solution was to ring a siren into my headphones? The algorithm is simple – every time I’m “crashed” and planning to get up “real soon”, I press a button that starts a five-minute timer, programmed to ring a siren into my headphones. When the seconds stop ticking and the siren triggers, I have a choice – get up and then re-trigger the alarm for five more minutes. There is no second choice, really – I don’t give myself one. The part where I get up before turning the siren off is crucial, of course – though, in case of missing willpower, an accelerometer measuring activity could do as well.

Not that much of my willpower would be required – turned out, it typically would be enough of a shock to realize just how quickly five minutes have passed. Consistently, every time I got tired, time would pass much quicker than I could feel it, and the “oh damn it’s been five minutes already” thought made for a surprisingly powerful reality check.

Initially, the script was a tiny local webserver – I had some Flask examples fresh in my mental toolbox, so I took those and wrote two tiny HTML pages, crash and uncrash. The crash page received a seconds argument, indicating how many seconds to wait before ringing the alarm, and the uncrash page stopped the alarm. Keep the two webpages open, and hit Ctrl+R on the page I need – simple enough.

Resistance Is Counterproductive

Later on, I beautified the pages a little – adding background colours, so that it’d be easy for me to find the pages in my laptop’s window switcher and not get confused between them. That was my first attempt to make the crash/uncrash “hooks” more accessible – since, unsurprisingly, having to Alt-Tab a couple times before finding the right page required some mental energy, so I would often forget about them altogether, and developing a habit of using these pages was significantly harder. Thinking back to the very first article and principles I outlined in it – reducing resistance to use was a must.

So, the “crash” webpages got turned into keybinds accessible on my laptop globally. Surprisingly, despite the crash endpoint’s arbitrary integer delay, I didn’t need much granularity. Right now, I only use three buttons , “uncrash”, “crash in 300 seconds” (5 minutes), and “crash in 1 second” (immediate). The “immediate crash” button was a surprisingly helpful one, too. See, the “oh, five minutes truly can pass quicker than expected” lesson has stuck with me – so, when I’d notice myself crashing, I knew better than to waste time trusting in the “just a few minutes” notice.

The keybinds got me to use the script more often – which has helped me find more usecases, and use it even when I’m not sick or super tired. Really, most of the trouble nowadays is noticing when I need to press the button – which, generally, is in the mornings, when I am still groggy and a scheduled appointment might not feel as important as it actually is.

One important aspect turned out to be retriggering the alarm instead of turning it off after five minutes. I get up either way, but usually, the crash doesn’t – I might “crash” immediately afterwards, or a minute-two later. Stopping the alarm ended up being a very intentional “crash is over” decision – so, the “stop” button never got into my muscle memory. I’ve indeed had muscle-memory cycle restarts, giving myself five more minutes without realizing – but I’ve never had muscle-memory stops, which is nice, because stopping the script without even realizing it would be a critical failure condition.

Retrospective: It’s Great, Somehow

Anything missing? Definitely! For one, there are some good keybinds I could add, even if maybe they wouldn’t fundamentally impact how the script is functioning. Say I’ve woken up, and I have to get somewhere early – so I use the “crash” script to get up and get with the gravity of my current situation. As I run around the house doing morning chores, five minutes pass and the alarm rings again, even though I’m currently actively doing something around the house.

Now, running back to the laptop and pressing a keybind isn’t a problem. The problem is that I could be pressing the “reset alarm” button in two different states – either I’m doing well, or I’m not, but it’s the same button. Making two different buttons, one “doing good” and one “still crashed”, would help me collect metadata I could use for a good purpose – and, quite likely, add a trigger for some sort of positive reinforcement.

Other than that? This script has eliminated yet another common failure mode from my life – and, once again, helped improve focus. It’s as simple as simple goes, and, it’s gotten me to a more comfortable point – often, making a difference between an evening lost to tiredness, and an evening of recuperation.

One thing you might notice – to actually work properly, this script requires always-on, wireless headphones. In the next article, I’ll talk about the wireless headphone device I’ve built, why I had to build one instead of buying one, and how that device has helped me solved a bunch of other problems I didn’t realize I had.


Enhiker Helps You Decide if its a Good Day to Hike

November 22, 2024 0
Enhiker Helps You Decide if its a Good Day to Hike

Many of us check the weather before heading out for the day — we want to know if we’re dressed (or equipped) properly to handle what Mother Nature has planned for us. This is even more important if you’re going out hiking, because you’re going to be out in a more rugged environment. To aid in this regard, [Mukesh Sankhla] built a tool called Enhiker.

The concept is simple; it’s intended to tell you everything you need to know about current and pending conditions before heading out on a hike. It’s based around Unihiker, a single-board computer which also conveniently features a 2.8-inch touch screen. It’s a quad-core ARM device that runs Debian and has WiFi and Bluetooth built in, too. The device is able to query its GPS/GNSS receiver for location information, and then uses this to get accurate weather data online from OpenWeatherMap. It makes some basic analysis, too. For example, it can tell you if it’s a good time to go out, or if there’s a storm likely rolling in, or if the conditions are hot enough to make heat stroke a concern.

It’s a nifty little gadget, and it’s neat to have all the relevant information displayed on one compact device. We’d love to see it upgraded further with cellular connectivity in addition to WiFi; this would make it more capable when out and about.

We’ve seen some other neat hiking hacks before, too, like this antenna built with a hiking pole. Meanwhile, if you’ve got your own neat hacks for when you’re out on the trail, don’t hesitate to let us know!