The teeny tiny MCU mentioned in the article, merely a blimp on a giant devboard

New Part Day: Smallest ARM MCU Uproots Competition, Needs Research

We’ve been contacted by [Cedric], telling us about the smallest ARM MCU he’s ever seen – Huada HC32L110. For those of us into miniature products, this Cortex-M0+ package packs a punch (PDF datasheet), with low-power, high capabilities and rich peripherals packed into an 1.6mm x 1.4mm piece of solderable silicon.

This is matchstick head scale computing, with way more power than we previously could access at such a scale, waiting to be wrangled. Compared to an 8-bit ATTiny20 also available in WLCSP package, this is a notable increase in specs, with a way more powerful CPU, 16 times as much RAM and 8-16 times the flash! Not to mention that it’s $1 a piece in QTY1, which is about what an ATTiny20 goes for. Being a 0.35mm pitch 16-pin BGA, your typical board house might not be quite happy with you, but once you get a board fabbed and delivered from a fab worth their salt, a bit of stenciling and reflow will get you to a devboard in no time.

Drawbacks? No English datasheet or Arduino port, and the 67-page PDF we found doesn’t have some things like register mappings. LILYGO promised that they will start selling the devboards soon, but we’re sure it wouldn’t be hard for us to develop our own. From there, we’d hope for an ESP8266-like effect – missing information pieced together, translated and made accessible, bit by bit.

When it comes to soldering such small packages, we highly recommend reflow. However, if you decide to go the magnet wire route, we wouldn’t dare object – just make sure to send us pictures. After all, seems like miniature microcontrollers like ATTiny20 are attractive enough of a proposition that people will pick the craziest route possible just to play with one. They say, the madness of the brave is the wisdom of life.

We thank [Cedric] for sharing this with us!

A HVTPI adapter plugged into a USBASP, with a an IDC10 cable plugged into it in turn

HVTPI Primer And Toolkit Equips You For BOM Substitutions

Novel programming interfaces for MCUs might catch us by surprise, but then we inevitably get up to speed with the changes required. Today’s bastion is HVTPI – a “12V reset” addition to the TPI we’ve just started getting used to, and [Sam Ettinger] has shared a simple circuit to teach us all about it, along with PCB files and detailed explanations of how it all works.

HVTPI is an add-on on top of TPI, for which, as Sam explains, you need to hold RST at 12V when TPI would have it be low logic level, and leave it at Vtarget otherwise. For that, he has designed a variety of interposer boards of various complexity and requirements; explaining the choices behind each one and clearing up any misunderstandings that might occur on your way. All of the board files (and the TPI write-up copy) are caringly shared with us in a git repository, too! As a result, if you have an USB-ASP or an Arduino available, now you also have everything to do HVTPI, thanks to Sam’s work and explanations.

We’ve been covering Sam’s exploits before, and can’t help but be grateful for the stop-and-explain detour along the way. HVTPI being used on very small ATTiny parts, we wonder if something new in the vein of his recent FPC board able to fit and function entirely within a Type-C cable end!

With chip shortages, investigating programming interfaces for small and obscure yet in-stock microcontrollers has been, quite literally, paying off, and if you got some projects that need a MCU but won’t consume a whole lot of resources, it could be time to give an ATTiny10 a go. What’s the worst that can happen – you make the smallest chiptunes ever?

ESP32 Virtual Machine Lets You Change Programs On The Fly

Often, reprogramming a microcontroller involves placing it in reset, flashing the code, and letting it fire back up. It usually involves shutting the chip down entirely. However, [bor0] has built a virtual machine that runs on the ESP32, allowing for dynamic program updates to happen.

The code is inspired by the CHIP-8, a relatively ancient interpreter that had some gaming applications. [bor0] had already created a VM simulating the CHIP-8, and repurposed it here, taking out the gaming-related drawing instructions and replacing them with those that control IO pins. Registers have also been changed to 16 bits for added flexibility and headroom.

It’s probably not something with immediate ground-breaking applications for most people, but it’s a different way of working with and programming the ESP32, and that’s pretty neat.

The ESP32 is a powerful chip, too, as we all know – and it makes a great 8-bit emulator to boot. Sound off in the comments with your thoughts on what would make a killer application for the ESP32 VM!

[Thanks to satancete for the tip!]

A mailbox with a solar cell on top

IoT-Enabled Mailbox Lets You Check Your Mail Without Leaving Your House

Whether you live in an apartment downtown or in a detached house in the suburbs, if your mailbox is not built into your home you’ll have to go outside to see if anything’s there. But how do you prevent that dreadful feeling of disappointment when you find your mailbox empty? Well, we’re living in 2022, so today your mailbox is just another Thing to connect to the Internet of Things. And that’s exactly what [fhuable] did when he made a solar powered IoT mailbox.

The basic idea was to equip a mailbox with a camera and have it send over pictures of its contents. An ESP32-Cam module could do just that: with a 1600 x 1200 camera sensor, a 160 MHz CPU and an integrated WiFi adapter, [fhuable] just needed to write an Arduino sketch to have it take a picture every few hours and upload it to an FTP server.

A pile of components making up an IoT Mailbox
The components inside: a solar cell, battery, power controller, LDO and ESP32-Cam module with WiFi antenna

But since running a long cable all the way from the house was not an attractive option, the whole module had to be completely wireless. [fhuable] decided to power it using a single 18650 lithium ion cell, which gets topped up continuously thanks to a 1.5 W solar panel mounted on the roof of the mailbox. The other parts are housed in a 3D-printed enclosure that’s completely sealed to keep out moisture.

The enclosure had to be made from a material that does not degrade in direct sunlight, which is why [fhuable] decided to try ASA filament; this should be very resistant against UV rays, but proved tricky to process. It warped so much during cooling that the only way to get a solid piece out of the printer was to enclose the entire machine in a cardboard box to keep it warm inside.

The end result was worth it though: a neat little extension on the back of the mailbox that should keep sending photos of its insides for as long as the Sun keeps shining. The camera should also give a good indication as to the contents of the mailbox, allowing the user to ignore any junk mail; this is a useful improvement over previous IoT-enabled mailboxes that use proximity sensors, microswitches or optical sensors.

Continue reading “IoT-Enabled Mailbox Lets You Check Your Mail Without Leaving Your House”

An “unbusy” USB-C Port Doubles-up For JTAG Programming

Board space is a premium on small circuit board designs, and [Alvaro] knows it. So instead of adding a separate programming port, he’s found a niche USB-C feature that lets him use the port that he’s already added both for its primary application and for programming the target microcontroller over JTAG. The result is that he no longer needs to worry about spending precious board space for a tiny programming port; the USB-C port timeshares for both!

In a Twitter thread (Unrolled Link), [Alvaro] walks us through his discovery and progress towards an encapsulated solution. It turns out that the USB-C spec supports a “Debug-Accessory Mode” specification, where some pins are allowed to be repurposed if pins CC1 and CC2 are pulled up to Logic-1. Under these circumstances, the pin functions are released, and a JTAG programmer can step in to borrow them. To expose the port to a programmer, [Alvaro] cooked up a small breakout board with a USB-C plug and separate microcontroller populated on it.

This board also handles a small quirk. Since [Alvaro’s] choice of programming pins aren’t reversible, the USB-C plug will only work one of the two ways it can be plugged in. To keep the user informed, this breakout board sports a red LED for incorrect orientation and a green LED for correct orientation–nifty. While this design quirk sacrifices reversibility, it preserves the USB 2.0 D+ and D- pins while also handling some edge cases with regard to the negotiating for access to the port.

Stick through [Alvaro]’s Twitter thread for progress pics and more details on his rationale behind his pin choices. Who knows? With more eyes on the USB-C feature, maybe we’ll see this sort of programming interface become the norm?

[Alvaro] is no stranger to Hackaday. In fact, take a tour back to our very first Supercon to see him chat about shooting lasers at moving targets to score points on a DEFCON challenge in the past

Bend It Like (Sonar) Beacon With A Phased Array

Ultrasonic transducers are incredible, with them you can detect distances, as well as levitate and peer through objects. They can emit and receive ultrasonic soundwaves (typically above 18khz) and just like all waves, they can be steered via a phased array. [Bitluni] was trying to accurately measure distances but found the large field of view of the sensor was just too imprecise, so he made a phased array of transducers.

The inspiration came from a Hackaday Supercon talk from 2019 about phased arrays. [Bitluni] walks through an excellent explanation of how the array works with a bucket of water and his finger, as well as a separate simulation. By changing the phase offset of the different array members, the beam can effectively be steered as interference muffs the undesired waves. Using a set of solenoids, he created a test bench to validate his idea in a medium he could see; water. The solenoids fire a single pulse into the water creating a wave. You can see the wave move in the correct direction in the water, which validates the concept. A simple PCB sent off to a fab house with a stencil offers a surface to solder the transducers and drivers onto. An ESP32 drives the 8 PWM signals that go to the transmitters and reads in the single receiver via a small amplifier. Still not content to let the idea be unproven, he sets up the receiver on his CNC gantry and plots the signal strength at different points, yielding beautiful “heat maps.”
bitluni's heatmap for his sonar array

It sweeps a 60-degree field in front of it at around 1-3 frames per second. As you might imagine, turning sound wave reflections into distance fields is a somewhat noisy affair. He projects the sonar display on top of what we can see in the camera and it is fun to see the blobs line up in the correct spot.

We noticed he built quite a few boards, perhaps in the future, he will scale it up like this 100 transducer array? Video after the break.

Continue reading “Bend It Like (Sonar) Beacon With A Phased Array”

Backpack Board For OLEDs Boasts Fancy Features

Back when LCD character displays based on the HD44780 controller were the bee’s knees, a way to make them easier to work with came in the form of “backpack” PCBs, which provided an accessible serial interface and superior display handling at the same time. [Barbouri] has updated that idea with a backpack board that mounts to OLED displays using the US2066 display driver, and provides an I2C interface with powerful and convenient high-level functions that make the display simple to use.

On the software side, the backpack uses this I2cCharDisplay driver project which provides functions like cursor control, fading, display shifting, and of course writing characters or strings. While [Barbouri] designed the board specifically to accommodate Newhaven Slim Character OLED displays, it should in theory work with any US2066-based OLED character display. [Barbouri]’s design files for the Slim-OLED Display backpack board are available for download directly from the project page (link is near the bottom), or boards can be purchased directly from OSH Park.

OLED technology is nifty as heck; we’ve seen some neat tricks done by stacking transparent OLED displays, and even seen OLEDs made in the home lab.