A Receive Antenna Switcher With An Espressif Brain

It’s not uncommon for a radio enthusiast to have multiple antennas for the same radio, so as you might expect it’s also entirely usual to have a bunch of coaxial cables dangling down for fumbling around the back of the rig to swap over.  If that describes your radio experience than you might be interested in the antenna switcher built by [g3gg0], which uses solid-state RF switches controlled by an ESP32 module.

At its heart is the MXD8625C RF switch, a tiny device designed for cellular phone applications that delivers only a fraction of a dB insertion loss and somehow negates the need for any blocking capacitors. It’s controlled by a GPIO line, and he’s hooked up a brace of them to allow the distribution of three antennas to a couple of radios with the handy option of switching in a preamplifier if required. Of even more interest we note that the device is suitable for transmitter switching too, with a maximum 36.5 dBm throughput that we calculate to be about 4.5 W. This board is fairly obviously for receive use, but perhaps the chip is of interest to anyone considering a transceiver project. Meanwhile the software is a relatively simple web-based control linking on-screen controls to GPIOs.

If you are interested in solid state RF switches, it’s always worth remembering that at lower frequencies they can be very simple indeed.

OpenCV Running On A Tiny Microcontroller

At first blush, it might seem like projects that make extensive use of computer vision or machine learning would need to be based on powerful computing platforms with plenty of clock cycles and memory to handle this type of application. While there is some truth to this, as the field progresses it becomes possible to experiment with these tools on low-power devices as well. Take this OpenCV project which is built entirely on an ESP32 for example.

With that being said, there are some modifications that need to be made to the ESP32 in order to use OpenCV in any meaningful way. The most important of these is the use of the ESP32-DOWDQ6 module which increases the available memory of the ESP32 to allow it to make better use of camera functions. Even then, the ESP32 can’t run the entire OpenCV application, so a shrunken version of OpenCV is required before the device can run it natively. Once those two obstacles are out of the way, though, doing things like edge detection, as this project demonstrates, are well in the realm of possibility.

If running OpenCV on something as small as an ESP32 is possible, it is even easier to run on something orders of magnitude more powerful and yet still inexpensive, such as the Raspberry Pi. While the project’s code is available on its GitHub page for those interested, there are plenty of other OpenCV projects that we have featured on more powerful platforms as well, like this clock which falls off of the wall whenever someone looks at it.

Continue reading “OpenCV Running On A Tiny Microcontroller”

Network Time Protocol On The ESP32

Network Time Protocol (NTP) is one of the best ways to keep networked computers synchronized to the same time. It’s simple, lightweight, and not only allows computers to maintain a time standard together, but it also allows some computer manufacturers to save some money on hardware costs. The Raspberry Pi is perhaps the most well-known example of a low-cost computer without the extra expense of a real-time clock (RTC). While the Pi sets up NTP essentially automatically, other microcontrollers like the ESP32 don’t, but it is possible to configure them to use this time standard with some work.

For this project the MicroPython implementation for the ESP32 is required. MicroPython is a way of running Python code on microcontrollers or other embedded systems without all of the overhead that Python would normally require. Luckily enough, the NTP libraries are built right in so once MicroPython is running on the ESP32 it’s nearly as easy as calling the library. Of course you will have to make sure there is an internet connection, and then grab the time, sync it to the machine, and then set the timezone.

For a bonus exercise, the project’s creator [Bhavesh] suggests attempting to configure Daylight Savings Time, although this can be a surprisingly difficult problem to solve. In the meantime, there are a few other ways of installing a clock on a microcontroller like this one. An RTC module is an obvious choice, but you can also get incredibly accurate time by using a GPS module as well.

APPLE2IDIOT Expansion Card Lets Your Apple II (Sort Of) Access The Internet

[Nathanial Hendler]’s Apple2Idiot expansion card for the Apple II family of computers is a nifty mix of modern and vintage, and provides a clever means of allowing the host computer to (indirectly) access the internet over WiFi while keeping things simple from the host computer’s perspective.

The PCB has plenty of space on which to silkscreen reference data. Click to enlarge.

It does this by embedding an ESP32 module and a dual-port RAM chip onto an expansion card. The Apple2Idiot, when installed into a host machine, presents as a memory location which the host machine can access. The ESP32 then takes care of all the WiFi communications and tasks requiring internet access, and the host computer directs these tasks (and reads their output) via PEEK and POKE commands.

This means that there are two pieces of software for any given task: one running on the ESP32 doing the actual work, and one running on the Apple II that communicates with the ESP32 on the card by reading and writing to memory. It’s a simple system, and one that [Nathanial] thinks works quite well for specific tasks.

Example programs include things like scanning and selecting a WiFi network, fetching weather data, and sending a message to Slack. Making new applications does mean having to write software on two ends, but the simplicity of the system also means flexibility, because anything the ESP32 does can have its complexity abstracted away by the time its data is presented to the host machine. Not that the Apple II is incapable of dealing with the modern internet more directly; we’ve seen a basic Apple II web server written in BASIC.

TWANG32 Brings LED Strip Gaming To The ESP32

Under the Hackaday TV is a modern game console, it’s a well-known model that many of you also probably have, and its main feature is a 3D accelerator which allows it to create the beautifully rendered worlds we’ve all come to know and love. [Mircemk] eschews such fripperies with the Twang project, because it’s a game that’s not 3D, nor 2D, but 1D. The display, indeed the entire gaming surface, is a single strip of addressable LEDs which can be seen int he video below the break.

Behind it all is an ESP32, and a unique one-dimensional joystick using an accelerometer. There’s an audio channel with a little piezoelectric speaker too, and the LED strip is a particularly high-density one from DFRobot. Because this is an ESP32-driven device it has WiFi, upon which is exposed an access point for a network over which is served the game stats as a web page. It may not displace that modern console, but it’s certainly inventive.

Long-time Hackaday readers will be aware that this is only the latest of a long line of one-dimensional games, including a 1D take on the famous PONG.

Continue reading TWANG32 Brings LED Strip Gaming To The ESP32″

All-In-One Automated Plant Care

Caring for a few plants, or even an entire farm, can be quite a rewarding experience. Watching something grow under and then (optionally) produce food is a great hobby or career, but it can end up being complicated. Thanks to modern technology we can get a considerable amount of help growing plants, even if it’s just one plant in a single pot.

Plant Bot from [YJ] takes what would normally be a wide array of sensors and controllers and combines them all into a single device. To start, there is a moisture sensor integrated into the housing so that when the entire device is placed in soil it’s instantly ready to gather moisture data. Plant Bot also has the capability to control LED lighting if the plant is indoors.  It can control the water supply to the plant, and it can also communicate information over WiFi or Bluetooth.

The entire build is based around an ESP32 which is integrated into the PCB along with all of the other sensors and components needed to monitor a single plant. Plant Bot is an excellent all-in-one solution for caring for a plant automatically. If you need to take care of more than one at a time take a look at this fully automated hydroponic mini-farm.

Mini MIDI Synth Uses Minimum Number Of Parts

The 80s were the golden age of synthesizers in pop music. Hugely complicated setups that spared no expense were the norm, with synths capable of recreating anything from pianos and guitars to percussion, strings, and brass. These types of setups aren’t strictly necessary if you’re looking to make music, though, especially in the modern age of accessible microcontrollers. This synthesizer from [Folkert] with MIDI capabilities, for example, creates catchy tunes with only a handful of parts.

This tiny synth is built around an ESP32 and works by generating PWM signals normally meant for LEDs. In this case, the PWM signals are sent through a rudimentary amplifier and then on to an audio output device.  That could be a small speaker, an audio jack to another amplifier, or a capture device.

The synth’s eight channels use up most of the ESP32’s I/O and provide a sound that’s reminiscent of the eight-bit video game era. The total parts count for this build is shockingly small with only a handful of resistors, the ESP, an optocoupler, and a few jacks.

For those wishing to experiment with synthesizers, a build like this is attractive because it’s likely that all the parts needed are already sitting around in a drawer somewhere with possibly the exception of the 5 pin DIN jacks needed for MIDI capabilities. Either way, [Folkert] has made all of the schematics available on the project page along with some sample mp3 files. For those looking to use parts from old video game systems sitting in their parts drawer, though, take a look at this synthesizer built out of a Sega Genesis.