Converting Morse Code to Text with Arduino

Morse code used to be widely used around the globe. Before voice transmissions were possible over radio, Morse code was all the rage. Nowadays, it’s been replaced with more sophisticated technologies that allow us to transmit voice, or data much faster and more efficiently. You don’t even need to know Morse code to get an amateur radio license any more. That doesn’t mean that Morse code is dead, though. There are still plenty of hobbyists out there practicing for the fun of it.

[Dan] decided to take a shortcut and use some modern technology to make it easier to translate Morse code back into readable text. His project log is a good example of the natural progression we all make when we are learning something new. He started out with an Arduino and a simple microphone. He wrote a basic sketch to read the input from the microphone and output the perceived volume over a Serial monitor as a series of asterisks. The more asterisks, the louder the signal. He calibrated the system so that a quiet room would read zero.

He found that while this worked, the Arduino was so fast that it detected very short pulses that the human ear could not detect. This would throw off his readings and needed to be smoothed out. If you are familiar with button debouncing then you get the idea. He ended up just averaging a few samples at a time, which worked out nicely.

The next iteration of the software added the ability to detect each legitimate beep from the Morse code signal. He cleared away anything too short. The result was a series of long and short chains of asterisks, representing long or short beeps. The third iteration translated these chains into dots and dashes. This version could also detect longer pauses between words to make things more readable.

Finally, [Dan] added a sort of lookup table to translate the dots and dashes back into ASCII characters. Now he can rest easy while the Arduino does all of the hard work. If you’re wondering why anyone would want to learn Morse code these days, it’s still a very simple way for humans to communicate long distances without the aid of a computer.

Get Serious with Amateur Radio; Design & Build a Single-Sideband Transceiver from Scratch Part 1

Amateur radio is the only hobby that offers its licensed operators the chance to legally design, build, and operate high power radio transceivers connected to unlimited antenna arrays for the purpose of communicating anywhere in the world. The most complicated part of this communication system is the single-sideband (SSB) high frequency (HF) transceiver. In reality, due to the proliferation of low-cost amateur equipment, there only exists a very small group of die-hards who actually design, build from scratch, and operate their own SSB transceivers. I am one of those die-hards, and in this post I will show you how to get started.

Continue reading “Get Serious with Amateur Radio; Design & Build a Single-Sideband Transceiver from Scratch Part 1″

Demodulating BPSK31 With OpAmps and 555s

BPSK31 is an extremely popular mode for amateur radio operators; it’s efficient and has a narrow bandwidth and can be implemented with a computer sound card or an Arduino. Just like it says on the tin, it’s phase shift keying, and a proper implementation uses a phase detection circuit or something similar. [Craig] thought it would be fun to build an analog BPSK31 demodulator and hit upon the idea of doing this with amplitude demodulation. No, this isn’t the way you’re supposed to do it, but it works.

Data is transmitted via BPSK31 with a phase shift of 180 degrees being a binary 0, and no phase shift being a binary 1. [Craig]’s circuit uses an op-amp and a pair of diodes to do a full wave rectification of the signal, which basically makes a binary 1 logic high, and binary 0 logic low.

This rectified signal is then fed into a comparator, making the output go high when the signal is above 2V, and low when the signal is below 1V. That’s all you need to do to get bits out of the signal, all [Craig] had to do after that was figure out a way to sample it.

A 555 set up in astable mode running at 31.25 Hz provides the clock, synchronized with the signal by connecting the comparator’s output to the 555 trigger input. The timer clock ends up being slightly slower, but thanks to the varicode character set, the maximum number of binary ones the circuit will see is nine; every time the trigger sees a zero, the timer’s trigger is reset, re-synchronizing the receiver’s clock.

Yes, it’s a hack, and no, this isn’t how you’re supposed to receive PSK. It does, however, work, and you can thank [Craig] for that.


‘Gibson Girl’ emergency beacon built from a Wind-Up Flashlight

Batteries flat and no cellphone coverage and you need to communicate hundreds of miles?  No problem. [Peter Parker VK3YE] has created a wind-up ham radio transmitter built into a discount store crank-handle flashlight (or torch). No batteries – all power comes from you turning the hand crank. This design was inspired by the ‘Gibson Girl’ emergency beacon transmitter used during Second World War. But what used to be an very large, full body cranking box is now tiny and simple to crank. Let’s take a look at he video and the build details after the break.

Continue reading “‘Gibson Girl’ emergency beacon built from a Wind-Up Flashlight”

Hacklet 19 – Ham Radio


Amateur, or ham radio operators have always been hackers. For much of the early 1900’s, buying a radio was expensive or impossible. Hams would build their own rigs, learning electronics and radio theory along the way. Time moves on, but hams keep hacking. Today we’re highlighting some of the best ham radio projects on!


We start with [DainBramage1991] and his very practical RTL-SDR With Upconverter and Case. [DainBramage1991] fell in love with his low-cost RTL software defined radio dongle. He even added a Ham-It-Up upconverter to cover HF bands. The only problem was RF noise. the Realtek USB sticks tend to have little or no filtering, which means they are very susceptible to noise. [DainBramage1991] used the time-honored technique of insulating with copper clad board. Bits of PCB hold the RTL-SDR and upconverter in place. More PCB separates the two boards. Everything goes into a steel enclosure which keeps that unwanted RF at bay.

foxhunt-attenNext up is [Ryan Miller’s aka KG7HZQ]’s  ham radio fox hunt attenuator. Ham radio fox hunt’s don’t involve baying dogs or horses. In this case a fox hunt is a contest to find hidden low power transmitters. If you’ve never tried one, it’s a heck of a lot of fun. One of the challenges with a fox hunt is to find the direction to the transmitter when you’re very close. Even with directional antennas, reflections and swamped receivers make it hard to figure out just where the transmitter is. The solution is an attenuator, which simply reduces the signal to a more reasonable value. [Ryan] also used copper clad PCB for his circuit. Since the attenuator parts are soldered directly to the PCB, this is more of a Manhattan style design. Two ceramic 1k pots help him achieve his goal of near perfect linear attenuation. We’re betting this attenuator will help [Ryan] win some contests!

psdrWho says amateur radio won’t take you places? It may well be taking [Michael R Colton] to space! [Michael’s] project PortableSDR is one of the five finalists in The Hackaday Prize. We covered Michael earlier in the contest. PortableSDR started as a ham radio project: a radio system which would be easy for hams to take with them on backpacking trips. It’s grown into so much more now, with software defined radio reception and transmission, vector network analysis, antenna analysis, GPS, and a host of other features. We seriously love how [Michael] optimized a small LCD for waterfall display, tuning, and bandpass filter adjustment.

e2ra[W5VO] is working on an Ethernet to Radio Adapter. Every foot of coax in a radio system loses signal. Connections are even worse. It can all add up to several dB loss. [W5VO] wants to put an SDR at the antenna feed-point. With the signal path minimized, more watts make it out when transmitting, and more signal gets back to the receiver when listening. The interface between the SDR and host computer will be all digital; Ethernet to be precise. [W5VO] isn’t the first person to do something like this, microwave systems have had the transmitter and LNB at the antenna for years. That doesn’t take away from [W5VO’s] design at all  He’s been quiet for a while, but we’re hoping he continues on his design!

Where is everyone else? We’re a bit light on projects this week, but we have a good reason. There just aren’t enough ham radio projects on! We’re hoping to change that though. Are you an amateur radio enthusiast? Document your project on the site. Get input from other hams and push the envelope! You might even find yourself on the Ham Radio List!

That’s all for this episode of The Hacklet. As always, QRX is next week. Same hack time, same hack channel, bringing you the best of! 73’s!

Digital “Crystal” Breathes New Life into Old Radio

[Bill Meara] of the Soldersmoke Podcast has a nice old Drake 2B radio, and wanted to use it for the 12 meter amateur band. These old radios normally make switching tuning bands easy — you just swap out one frequency crystal for another and you’re set.

Only [Bill] didn’t have the 21 MHz crystal that he needed. No problem, because he had a junk crystal, a hacksaw, and a modern direct-digital synthesis (DDS) chip sitting around. So he takes the donor crystal, cuts it open, and solders the two wires directly from the DDS to the crystal’s pins. Now he’s got a plug-in replacement digital oscillator that doesn’t require modifying the nice old Drake receiver at all. A sweet little trick.

The video’s a little bit long, but the money shot comes in around 5:00.

Now, one might worry about simply plugging a powered circuit (the DDS) in place of a passive element (the crystal), but it seems to work and the proof of the pudding is in the tasting. We wonder how far this digitally-controlled-analog-receiver idea could be extended.

A Mobile Radio Power Controller

[Pete], a.k.a. [KD8TBW] wanted to install his Yaesu radio in his car. From experience, he knew that having a radio in a car inevitable led to leaving it on once in a while, and this time, he wanted a device that would turn his rig on and off when the key was in the ignition. He ended up building a mobile radio power converter. It takes the 12V from the car when the alternator is running, and shuts everything off when the engine has stopped.

The Yaesu radio in question – an FT-8800 does have an automatic power off feature, but this is a terrible way of doing things. There is no way to turn the radio back on, and the radio must be left in a non-scanning mode.

In what he hopes to be his last design in EagleCAD, [Pete] whipped up a board featuring an ATtiny85 that measures the voltage in the car; when it’s ~14V, the alternator is working, and the radio can be switched on. When it drops to ~12V, it’s time to turn the radio off. It’s a great project, and with the 3D printed case, it can easily be shoved inside the console. Video below.

Continue reading “A Mobile Radio Power Controller”