Gawking Text Files

Some tools in a toolbox are versatile. You can use a screwdriver as a pry bar to open a paint can, for example. I’ve even hammered a tack in with a screwdriver handle even though you probably shouldn’t. But a chainsaw isn’t that versatile. It only cuts. But man does it cut!

aukAWK is a chainsaw for processing text files line-by-line (and the GNU version is known as GAWK). That’s a pretty common case. It is even more common if you produce a text file from a spreadsheet or work with other kinds of text files. AWK has some serious limitations, but so do chainsaws. They are still super useful. Although AWK sounds like a penguin-like bird (see right), that’s an auk. Sounds the same, but spelled differently. AWK is actually an acronym of the original author’s names.

If you know C and you grok regular expressions, then you can learn AWK in about 5 minutes. If you only know C, go read up on regular expressions and come back. Five minutes later you will know AWK. If you are running Linux, you probably already have GAWK installed and can run it using the alias awk. If you are running Windows, you might consider installing Cygwin, although there are pure Windows versions available. If you just want to play in a browser, try webawk.

Continue reading “Gawking Text Files”

Espressif Releases ESP8266-Killer!

It’s no secret that we love the ESP8266 chip, and the community of hackers that have contributed to making it useful. We often joke about this or that new WiFi-enabler being an ESP8266 killer, but so far none have stepped up. Here we go again!

Espressif has released a chip that’s going to be an ESP8266 killer, and no, it’s not the ESP32. The ESP8285 went into mass production in March, and should start to appear in the usual outlets fairly soon.

What makes it an ESP8266 killer? It’s an ESP8266, but with the flash memory onboard. Nothing more, but also nothing less. What does this mean? Tiny, tiny designs are possible. And, if the street price ends up being right, there’s no reason you wouldn’t opt for built-in flash. (Unless you were planning on doing some ROM hacking.)

Continue reading “Espressif Releases ESP8266-Killer!”

Capacitors Made Easy The Hackaday Way

If you build electronic circuits on a regular basis the chances are you will have used capacitors many times. They are a standard component along with the resistor whose values are lifted off the shelf without a second thought. We use them for power supply smoothing and decoupling, DC blocking, timing circuits, and many more applications.

Different capacitor applications. By Elcap (Own work) [CC0], via Wikimedia Commons
Different capacitor applications. By Elcap (Own work) [CC0], via Wikimedia Commons
A capacitor though is not simply a blob with two wires emerging from it and a couple of parameters: working voltage and capacitance. There is a huge array of capacitor technologies and materials with different properties. And while almost any capacitor with the right value can do the job in most cases, you’ll find that knowing more about these different devices can help you make something that doesn’t just do the job, but does the best possible job. If you’ve ever had to chase a thermal stability problem or seek out the source of those extra dBs of noise for example you will appreciate this.

Continue reading “Capacitors Made Easy The Hackaday Way”

FCC To Investigate Raised RF Noise Floor

If you stand outside on a clear night, can you see the Milky Way? If you live too close to a conurbation the chances are all you’ll see are a few of the brighter stars, the full picture is only seen by those who live in isolated places. The problem is light pollution, scattered light from street lighting and other sources hiding the stars.

The view of the Milky Way is a good analogy for the state of the radio spectrum. If you turn on a radio receiver and tune to a spot between stations, you’ll find a huge amount more noise in areas of human habitation than you will if you do the same thing in the middle of the countryside. The RF noise emitted by a significant amount of cheaper modern electronics is blanketing the airwaves and is in danger of rendering some frequencies unusable.

Can these logos really be trusted? By Moppet65535 (Own work) [CC BY-SA 3.0], via Wikimedia Commons
Can these logos really be trusted? By Moppet65535 (Own work) [CC BY-SA 3.0], via Wikimedia Commons
If you have ever designed a piece of electronics to comply with regulations for sale you might now point out that the requirements for RF interference imposed by codes from the FCC, CE mark etc. are very stringent, and therefore this should not be a significant problem. The unfortunate truth is though that a huge amount of equipment is finding its way into the hands of consumers which may bear an FCC logo or a CE mark but which has plainly had its bill-of-materials cost cut to the point at which its compliance with those rules is only notional. Next to the computer on which this is being written for example is a digital TV box from a well-known online retailer which has all the appropriate marks, but blankets tens of megahertz of spectrum with RF when it is in operation. It’s not faulty but badly designed, and if you pause to imagine hundreds or thousands of such devices across your city you may begin to see the scale of the problem.

This situation has prompted the FCC Technological Advisory Council to investigate any changes to the radio noise floor to determine the scale of the problem. To this end they have posted a public notice (PDF) in which they have invited interested parties to respond with any evidence they may have.

We hope that quantifying the scale of the RF noise problem will result in some action to reduce its ill-effects. It is also to be hoped though that the response will not be an ever-tighter set of regulations but greater enforcement of those that already exist. It has become too easy to make, import, or sell equipment made with scant regard to RF emissions, and simply making the requirements tougher for those designers who make the effort to comply will not change anything.

This is the first time we’ve raised the problem of the ever-rising radio noise floor here at Hackaday. We have covered a possible solution though, if stray RF is really getting to you perhaps you’d like to move to the National Radio Quiet Zone.

[via Southgate amateur radio news]

Brutal Water Cannon Defeats Summer Heat; Kills It On Documentation

There’s a war on, and while this over-the-top water blaster is certainly an escalation in the Water Wars arms race, that’s not the war we’re referring to. We’re talking about the Documentation War. Hackers, you’re on notice.

Gj3YAOLIf you want to see how a project should be documented, look no further than [Tim]’s forum posts over at WaterWar.net. From the insanely detailed BOM with catalog numbers and links to supplier websites, to scads of build photos with part number callouts, to the finely detailed build instructions, [Tim] has raised the stakes for anyone that documents any kind of build.

And that’s not even touching on the merits of the blaster itself, which has air and water tanks plumbed with every conceivable valve and fitting. There’s even an inline stream straightener made of bundled soda straws to keep the flow as laminar as possible. It looks like [Tim] and his colleagues are obsessed with launching streams of water as far as possible, and although bad weather has prevented an official measurement so far, from the video below it sure looks like he’s covering a huge distance with a stream that stays mostly intact to deliver the full blast to its intended target without losing a drop.

For as much fun as amped-up water guns appear to be, we haven’t seen too many grace these pages before. Going way back we covered a DIY super-soaker. For something much less involved than [Tim’s] masterpiece, you can pull together this pressurized water pistol in an afternoon.

Continue reading “Brutal Water Cannon Defeats Summer Heat; Kills It On Documentation”

Hackaday Prize Entry: DIY Automatic Tool Changer

Choosing between manually changing endmill bits on a CNC machine and investing in an expensive automated solution? Not for [Frank Herrmann], who invented the XATC, an eXtremely simple Automated Tool Changer. [Frank’s] ingenious hack achieves the same functionality as an industrial tool changer using only cheap standard hardware you might have lying around the workshop.

xatc_carouselLike many ATCs, this one features a tool carousel. The carousel, which is not motorized, stores each milling bit in the center bore of a Gator Grip wrench tool. To change a tool, a fork wrench, actuated by an RC servo, blocks the spindle shaft, just like you would do it to manually change a tool. The machine then positions the current bit in an empty Gator Grip on the carousel and loosens the collet by performing a circular “magic move” around the carousel. This move utilizes the carousel as a wrench to unscrew the collet. A short reverse spin of the spindle takes care of the rest. It then picks another tool from the carousel and does the whole trick in reverse.

The servo is controlled via a WiFi connected NodeMCU board, which accepts commands from his CNC controller over HTTP. The custom tool change sequences are provided by a few JavaScript macros written for the TinyG workspace on chilipeppr.com, a browser-based G-code host. Enjoy the video of [Frank Herrmann] explaining his build!

Thanks to Smoothieboard creator [Arthur Wolf], who is currently working on a similar project, for the tip!

The HackadayPrize2016 is Sponsored by:

Add USB OTG To A USB Thumb Drive

Every hacker has a USB thumb drive on their keyring, filled with backup files and a way to boot up a broken computer. One feature that most are missing though is USB On The Go (OTG) support, which allows a USB device to act as a USB host, connecting to devices like cell phones and tablets.

That can be added with the addition of a USB OTG adapter, though, and [usbdevice] has produced a nice how-to on soldering one of these permanently into a USB thumb drive to create a more flexible device. It’s a simple solder-something-on-something-else hack, but it could be handy.

There are a few caveats, though: it needs a USB thumb drive with solderable headers, which most of the smallest drives that have connectors right on the PCB won’t have. Most of the larger drives will have these, though, and they are cheap, so finding a suitable victim isn’t hard.