Ask Hackaday: What’s Your “Tactical Tool” Threshold?

With few exceptions, every field has a pretty modest set of tools that would be considered the minimum for getting most jobs done. A carpenter can make do with tools that would fit in a smallish bag, while a mechanic can handle quite a few repairs with a simple set of socket wrenches and other tools. Even in electronics, a lot of repairs and projects can be tackled with little more than a couple of pairs of pliers, some cutters, and a cheap soldering iron.

But while the basic kit of tools for any job may be enough, there will always be those jobs that need more tools. Oh sure, sometimes you can — and should — make do with what you’ve got; I can’t count the number of times I’ve used an elastic band wrapped around the handles of a pair of needlenose pliers as an impromptu circuit board vise. But eventually, you’re going to come upon a situation where only the “real” tool will do, and substitutes need not apply.

As I look around my shop and my garage, I realize that I may have a problem with these “tactical tool” purchases. I’ve bought so many tools that I’ve used far fewer times than I thought I would, or perhaps even never used, that I’m beginning to wonder if I tackle projects just as an excuse to buy tools. Then again, some of my tactical purchases have ended up being far more useful than I ever intended, which has only reinforced my tendency toward tool collecting. So I thought I’d share a few of my experiences with tactical tools, and see how the community justifies tactical tool acquisitions.

Continue reading “Ask Hackaday: What’s Your “Tactical Tool” Threshold?”

All Your Robots Are Belong To Us: You Just Rent Them

Monthly bills. Everyone has them. Except if you go far enough back, not everyone had them. After all, you might live in a home your family has owned for generations. You might be able to produce all the basic necessities using your homestead: food from a garden, water from a well, textiles, soap, and candles. You might have to buy the occasional animal, but your recurring bills could be modest outside of the ever-present tax burden.

But as people moved to cities, they had to pay rent. Buy gas or coal and, eventually, electricity. Water and trash collection are pretty essential, too. But at some point, everyone realized that being in a position to bill you monthly is a good idea. Now we pay for the internet, movie subscriptions, meal plans, alarm monitoring, shopping clubs, cell phones, spa memberships. Soon we might be paying a monthly fee for our robots, too.

Rent To (Not) Own

In industry, this is a common occurrence. You often don’t buy a robot arm or similar device. That, after all, is a capital expense, and most tax codes require you to count it as an asset that slowly depreciates. Instead, you hire a robot from a service provider. Not only does that make it a pure expense, but the provider worries about software, repairs, and all that.

But at home, it is different. There’s no tax advantage in most places between owning a car and leasing it. Yet vendors want to adopt a rent-a-robot strategy. Case in point: a startup named Matician wants you to sign up for a robotic vacuum. For $125 a month, you get a super smart robot vacuum. You could, of course, buy a Roomba, but — according to Matician — the Matic robot uses computer vision to map your house and automatically finds messes. You can also voice command it to clean up areas. It also avoids wire and furniture. They didn’t mention if it can avoid presents left by your pets or not. It will avoid pets and kids, though.

Continue reading “All Your Robots Are Belong To Us: You Just Rent Them”

Hack Simple

Here at Hackaday, we definitely love to celebrate the hard hacks: the insane feats of reverse engineering, the physics-defying flights of fancy, or the abuse of cutting edge technology. But today I’d like to raise a rhetorical glass in tribute of the simple hacks. Because, to be perfectly honest, the vast majority of my hacks are simple hacks, and it’s probably the same for you too. And these often go unsung because, well, they’re simple. But that doesn’t mean that something simple can’t be helpful.

Case in point: an ESP8266 press-buttons device that we featured this week. It doesn’t do much. It’s main feature is that it connects to a home automation network over WiFi and enables you to flip three relays. Wires coming off the board are to be soldered to the not-yet-smart device in question, simply connected to each side of the button you’d like to press. In the example, a coffee machine was turned on and the “go” button pressed, automating one of the most essential kitchen rituals. While recording the podcast, I realized that I’ve built essentially this device and have it controlling our house’s heating furnace.

For the experienced hacker, there’s not much here. It’s a simple board design, the software heavily leverages ESPHome, so there’s not much work on that front either. But imagine that you lacked any of the wide-ranging skills that it takes to make such a device: PCB layout, ESP8266 software wrangling, or the nuances of designing with relays. You could just as easily build this device wrong as right. The startup costs are non-trivial.

Making a simple design like this available to the public isn’t a technical flex, and it’s not contributing to the cutting edge. But it just might be giving someone their first taste of DIY home automation, and a sweet taste of success. There’s not much easier than finding a switch and soldering on two wires, but if that’s the spark that pushes them on their path to greater hacks, that’s awesome. And even if it doesn’t, at least it’s another appliance under user control, connected to a private WiFi network rather than spying you out and phoning home to Big Toaster.

So here’s to the simple hacks!

Dear Ubuntu…

Dear Ubuntu,

I hope this letter finds you well. I want to start by saying that our time together has been one of creativity and entertainment, a time in which you gave me the tools to develop a new career, to run a small electronics business, make fun things, and to write several thousand articles for Hackaday and other publications, but for all that it’s sadly time for our ways to part. The magic that once brought us together has faded, and what remains is in danger of becoming a frustration.

In our early days as an item you gave me for the first time a Linux distro that was complete, fast, and easy to use without spending too much time at the CLI or editing config files to make things happen; you gave me a desktop that was smooth and uncluttered, and you freed me from all those little utilities that were required to make Windows usable. You replaced the other distros I’d been using, you dual-booted with my Windows machines, and pretty soon you supplanted the Microsoft operating system entirely.

Ubuntu and me and a trusty Dell laptop, Oxford Hackspace, 2017.
Me and Ubuntu in 2017, good times.

We’ve been together for close to two decades now, and in that time we’ve looked each other in the eye across a variety of desktop and laptop computers. My trusty Dell Inspiron 640 ran you for over a decade through several RAM, HDD, and SSD upgrades, and provided Hackaday readers with the first few years of my writing. Even the Unity desktop couldn’t break our relationship, those Linux Mint people weren’t going to tear us asunder! You captured my text, edited my videos and images, created my PCBs and CAD projects, and did countless more computing tasks. Together we made a lot of people happy, and for that I will always be grateful. Continue reading “Dear Ubuntu…”

How Far Can An EULA Go?

We read this news with mixed glee and horror: a company called Telly is giving TVs away, for the low price of having to live with an always-on advertisement bar and some pretty stringent terms and conditions. Break the terms, and they’ll repossess your TV. If you don’t give them the TV, they have your credit card on record and they think the set is worth $1,000.

The hacker in me sees free hardware, so I checked out the terms and conditions, and it doesn’t look good. They’ve explicitly ruled out opening up or physically modifying the device, and it has to continually have WiFi – for which you pay, naturally. It sounds like it could easily tell if you try to tamper with it. My next thought was, perhaps too cynically, to get one, put it in the closet, and wait for the company to go bankrupt. Because you know that business model isn’t going to last.

But it’s clear that they’ve seen through me. The most bizarre clause is that you have to “Use the Product as the primary television in Your household”. Now, we’re not lawyers, but it seems like an amazing stretch that they can tell you how intensively you are to use the product. Can you imagine a license with a keyboard that demanded that you only use it to write sci-fi novels, or that you have to use it more than any other keyboard?

Nope. Too many hoops to jump through for a silly free TV. You can keep your dystopian future.

Tools Of The Trade: Dirt Cheap Or Too Dirty?

We’ve recently seen a couple reviews of a particularly cheap oscilloscope that, among other things, doesn’t meet its advertised specs. Actually, it’s not even close. It claims to be a 100 MHz scope, and it’s got around 30 MHz of bandwidth instead. If you bought it for higher frequency work, you’d have every right to be angry. But it’s also cheap enough that, if you were on a very tight budget, and you knew its limitations beforehand, you might be tempted to buy it anyway. Or so goes one rationale.

In principle, I’m of the “buy cheap, buy twice” mindset. Some tools, especially ones that you’re liable to use a lot, make it worth your while to save up for the good stuff. (And for myself, I would absolutely put an oscilloscope in that category.) The chances that you’ll outgrow or outlive the cheaper tool and end up buying the better one eventually makes the money spent on the cheaper tool simply wasted.

But that’s not always the case either, and that’s where you have to know yourself. If you’re only going to use it a couple times, and it’s not super critical, maybe it’s fine to get the cheap stuff. Or if you know you’re going to break it in the process of learning anyway, maybe it’s a shame to put the gold-plated version into your noob hands. Or maybe you simply don’t know if an oscilloscope is for you. It’s possible!

And you can mix and match. I just recently bought tools for changing our car’s tires. It included a dirt-cheap pneumatic jack and an expensive torque wrench. My logic? The jack is relatively easy to make functional, and the specs are so wildly in excess of what I need that even if it’s all lies, it’ll probably suffice. The torque wrench, on the other hand, is a bit of a precision instrument, and it’s pretty important that the bolts are socked up tight enough. I don’t want the wheels rolling off as I drive down the road.

Point is, I can see both sides of the argument. And in the specific case of the ’scope, the cheapo one can also be battery powered, which gives it a bit of a niche functionality when probing live-ground circuits. Still, if you’re marginally ’scope-curious, I’d say save up your pennies for something at least mid-market. (Rigol? Used Agilent or Tek?)

But isn’t it cool that we have so many choices? Where do you buy cheap? Where won’t you?

A Literate Assembly Language

A recent edition of [Babbage’s] The Chip Letter discusses the obscurity of assembly language. He points out, and I think correctly, that assembly language is more often read than written, yet nearly all of them are hampered by obscurity left over from the days when punched cards had 80 columns and a six-letter symbol was all you could manage in the limited memory space of the computer. For example,  without looking it up, what does the ARM instruction FJCVTZS do? The instruction’s full name is Floating-point Javascript Convert to Signed Fixed-point Rounding Towards Zero. Not super helpful.

But it did occur to me that nothing is stopping you from writing a literate assembler that is made to be easier to read. First, most C compilers will accept some sort of asm statement, and you could probably manage that with compile-time string construction and macros. However, I think there is a better possibility.

Reuse, Recycle

Since I sometimes develop new CPU architectures, I have a universal cross assembler that is, honestly, an ugly hack, but it works quite well. I’ve talked about it before, but if you don’t want to read the whole post about it, it uses some simple tricks to convert standard-looking assembly language formats into C code that is then compiled. Executing the resulting program outputs the desired machine language into a desired file format. It is very easy to set up, and in the middle, there’s a nice C program that emits machine code. It is not much more readable than the raw assembly, but you shouldn’t have to see it. But what if we started the process there and made the format readable?

At the heart of the system is a C program that lives in soloasm.c. It handles command line options and output file generation. It calls an external function, genasm with a single integer argument. When that argument is set to 1, it indicates the assembler is in its first pass, and you only need to fill in label values with real numbers. If the pass is a 2, it means actually fill in the array that holds the code.

That array is defined in the __solo_info instruction (soloasm.h). It includes the size of the memory, a pointer to the code, the processor’s word size, the beginning and end addresses, and an error flag. Normally, the system converts your assembly language input into a bunch of function calls it writes inside the genasm function. But in this case, I want to reuse soloasm.c to create a literate assembly language. Continue reading “A Literate Assembly Language”