Fixing Bugs In Ancient BASIC Games

Before everyone learned programming on Stack Exchange, things were much different. Computer magazines had BASIC programs in them, which readers would type out, line by line, and hit RUN. In theory, this is a terrible way to learn programming; it’s simply rote recitation without any insight into what the code is actually doing. Of course, copying and pasting from Stack Exchange is exactly the same thing, so maybe these magazines were ahead of the curve.

[0xA000] recently came across one of his old computer magazines containing the type-in listing for Blindganger, a game where you wander a maze blindly. When [0xA000] typed this game into his C64 back in 1988, the game didn’t work. Thirty years later, he decided to give it another go and ended up fixing bugs in an old computer game.

When [0xA000] typed this game into his computer back in 1988, the map just didn’t work, and the final screen revealed a maze where the walls were where they shouldn’t be. A quick Google turned up a disk image of the same game that had the same problem. This bug was obviously in the section of code that draws the map at the end of the game, so [0xA000] started looking there. The offending typo in the code was an $F4 instead of an $F5, or 244 instead of 255. This shifted the colors of the map by 11 positions, meaning the locations marked as visited in the final screen were wrong. Whether this bug cropped up in development or was just a simple typo when typesetting the magazine doesn’t really matter now; after 29 years, this bug is fixed.

How Do They Synchronize Power Stations With The Grid?

There are probably times in every Hackaday reader’s life at which you see something and realise that the technology behind it is something you have always taken for granted but have never considered quite how it works. Where this is being written there was such a moment at the weekend, an acquaintance on an amateur radio field day posted a picture of three portable gas-powered alternators connected together and running in synchronization. In this case the alternators in question were fancy new ones with automatic electronic synchronization built-in, but it left the question: how do they do that? How do they connect a new power station to the grid, and bring it into synchronization with the line? There followed a casual web search, which in turn led to the video below the break of a bench-top demonstration.

If two AC sources are to be connected together to form a grid, they must match each other exactly in frequency, phase, and voltage. To not do so would be to risk excessive currents between the sources, which could damage them and the grid infrastructure. The video below from [BTCInstrumentation] demonstrates in the simplest form how the frequencies of two alternators can be matched, by measuring the frequency difference between them and adjusting their speed and thus frequency until they can be connected. In the video he uses neon bulbs which flash at the difference frequency between the two alternators, and demonstrates adjusting the speed of one until the bulbs are extinguished. The two alternators can then be connected, and will then act together to keep themselves in synchronization. There are further videos in which he shows us the same process using a strobe light, then demonstrates the alternators keeping themselves synchronized, and phase deviation between them.

Of course, utility employees probably do not spend their time gazing at flashing neon bulbs to sync their power stations. The same measurements are not performed by eye but by electromechanical or electronic systems with automatic control of the contactors, just as they are in the fancy electronic alternator mentioned earlier. But most of us have probably never had to think about synchronizing a set of alternators, so to see it demonstrated in such a simple manner should fill a knowledge gap even if it’s one only of idle curiosity.

Continue reading “How Do They Synchronize Power Stations With The Grid?”

Hackaday Prize Entry: An Internet Doorbell

The Internet of Things will kill us all and is the worst idea anyone has ever had. However, just because something could be labeled an ‘Internet of Things thing’ doesn’t mean it’s a bad idea. The Hackaday Prize’s Internet of Useful Things challenge was all about finding the Internet of Useful things, and one of these projects is so simple yet so elegant, we’re surprised no one has thought of it yet.

[David]’s entry to the Hackaday Prize is effectively an Internet of Things doorbell. You might think an IoT doorbell would just consist of a device sending push notifications to your phone. That’s part of the project, but it gets so much better.

The brilliant part of this build boils down to a simple relay. On command, [David] can turn his doorbell off. This means no ringing doorbell interrupting meals or naps. By sending a command to the ESP32 in this little device, [David] can enable or disable his doorbell. Of course, this doorbell also sends push notifications to his phone, so if the UPS guy throws a package at his front door and manages to hit the doorbell, [David] will still hear it even if he’s upstairs, in the garage, or in the backyard.

This is the simplest and most brilliant Internet of Things device ever created. It solves an obvious problem with surprisingly little hardware. The only data this device collects is the state of a doorbell, and even if this device was completely hacked by balaclava-wearing hackers, they still can’t F5 the doorbell. This is the best the Internet of Things has to offer, and we’re proud to have the Internet of Doorbells make it to the finals of the Hackaday Prize.

Camera Slide Pans And Tilts Camera Mechanically

A camera slider is a popular and simple project — just a linear slide, a stepper, and some sort of controller. Adding tilt and pan axes ups the complexity until you’ve got three motors, a controller, and probably a pretty beefy battery pack to run everything. Why not simplify with an entirely mechanical pan-tilt camera slider and leave all that heavy stuff at home?

There’s more than one way to program motion control, and [Enza3D]’s design uses adjustable rails to move the gimballed pan-tilt head through two axes of motion. One rail adjusts vertically to control tilt, while the other adjusts in and out relative to the slider to control pan. Arms ride on each rail and connect to the gimbals to swivel the camera in both dimensions while it travels down the manually cranked slide. It’s pretty clever and results in some clean, dynamic shots as in the video below.

Our quibble is that the “program” is only linear since the control rails are straight lengths of aluminum extrusion; seems to us that some sort of flexible control rails might make for more interesting shots. [Enza3D] has amply documented the build and is looking for feedback, so comment away. And if you don’t have a 3D printer to make the parts, wood works for a slider too.

Continue reading “Camera Slide Pans And Tilts Camera Mechanically”

A Virtual Machine, In Google Sheets

In the last couple of decades we have become used to the browser taking over so many of the desktop functions for which we used to rely on stand-alone software. Email clients, calendars, office suites and much more can now be found in the cloud, courtesy of the usual technology companies.

Sometimes these cloud-based alternatives to desktop software can be a little sketchy, but often they have features that might surprise you as they edge towards parity with the packages they seek to replace. Google Docs, for instance has a full-featured built-in scripting language called Apps Script, that gives your full control of a document or spreadsheet with the help of a bit of Javascript. When [Brian Steffens] saw this it piqued his interest, so of course he had to in his words “do something weird with it”. The result of his efforts is the Google Sheets Virtual Machine, a virtual computer in software using spreadsheet cells as memory, stack, and registers.

With only a 100-cell memory and dependent entirely upon the processing power available to the host browser, this machine is not likely to set the world on fire. He gives full instruction set details, there are a couple of demo programs, a Fibronacci sequence generator and a factorial generator, but its general lack of power is not really the point. Instead its value lies in an elegant demonstration for its own sake that a virtual computer can be built in the unlikeliest of places, and for those interested enough to peer into its code, some idea how that might be achieved.

[via Hacker News]

Book Review: The Art Of The Patent

In bringing suitable illustrations to our articles, we Hackaday scribes use a variety of sources that offer images featuring permissive licences. Among the usual free image libraries there is one particularly rich source, the line drawings contained within the huge archives of patents granted by the various countries around the world. These are the illustrations used as part of the patent itself to describe the working of the patent being claimed. We use them because though the items they depict are legally protected from copying by the patents they are part of, they as part of the patents themselves are in the public domain. Thus we can easily find detailed hand drawn pictures of all kinds of technical innovations from the last couple of hundred years or so, and from time to time you as our readers reap the benefit.

The beauty in hand-rendered fonts from patent artwork, collected within the book.
The beauty in hand-rendered fonts from patent artwork, collected within the book.

If you spend a while browsing old patents through a search engine such as Google Patents, you can quickly become engrossed in these beautiful images of inventions past. Though their purpose is a functional one to convey the workings of an invention, the anonymous artists have often poured all of their skill into rendering them as considerably more than mere draughtsmanship. In those dusty Government archives lurk masterpieces, just waiting to be found.

It seems we here at Hackaday are not alone in sharing a fascination with these images, for a US patent agent, [Kevin Prince], wrote a fascinating exploration of the medium in his book, The Art of the Patent. Continue reading “Book Review: The Art Of The Patent”

Friday Hack Chat: A Design Slam Challenge

Every Friday, the Hackaday.io community gathers ’round the fireplace and discusses the challenges facing the world. This is the Hack Chat, and in previous incarnations, we’ve talked about custom silicon, Arduinos, PCB fabrication, old technologies, and hardware manufacturing.

For this week’s Hack Chat, we’re opening up a design challenge. We’re asking the community for help on developing a wireless position sensor. This is a Design Slam Hack Chat, and we’re looking for contributors.

Our guest for this week’s Hack Chat will be [Naveen Nair], technology leader for GE Fuse. We’ll be discussing position sensors during this Hack Chat. If you’ve ever used a mouse, you’re using a position sensor, but for this Hack Chat we’re designing something a little more challenging. The Fuse group is attempting to build a low-cost, wireless position sensor with hand-held ultrasonic inspection units. Why is GE interested in this technology? Our guess is inspecting jet turbines, or something like that. That doesn’t mean low-cost wireless position sensors wouldn’t have other applications, though. Just imagine what a quadcopter could do if it could sense its position with 1mm resolution.

Won’t be able to make the Hack Chat? Don’t worry, we’ll be putting a transcript up here sometime after the event.

Here’s How To Take Part:

join-hack-chatOur Hack Chats are live community events on the Hackaday.io Hack Chat group messaging. This Hack Chat will take place at noon Pacific time on Friday, July 7th. Confused about where and when ‘noon’ is? Here’s a time and date converter!

Log into Hackaday.io, visit that page, and look for the ‘Join this Project’ Button. Once you’re part of the project, the button will change to ‘Team Messaging’, which takes you directly to the Hack Chat.

You don’t have to wait until Friday; join whenever you want and you can see what the community is talking about.