Fifteen-Segment Displays

Seven segments can do a lot, but eventually you want to spell something other than “HELLO.” Add a few more strokes, and a numeric readout becomes a small alphanumeric display, complete with a distinct 1980s vibe.

The fifteen-segment display is really a fourteen-segment character plus a decimal point. Compared with the familiar seven-segment layout, the middle bar is split in two, and the character gains four diagonals and two vertical strokes down the center. Those extra lines make a surprisingly large difference when you want to display letters like M, N, K, or R.

You will often see the same arrangement sold as a “14-segment display,” with the decimal point left out of the count. There are also sixteen-segment characters, which split the top and bottom bars as well. Add their decimal point and you have seventeen independently controlled elements. Apparently, even counting the segments requires reading the fine print.

Four characters, fifteen segments each: Sixty elements, controlled by two wires.
(Which can be shared with other devices.)

Uppercase text generally comes out quite legibly. Lowercase is more of a negotiation. Some letters work well; others, including the lowercase e in the Adafruit font, are artistic interpretations in a limited medium. There are only so many ways to suggest a small rounded letter using a handful of straight lines. Context helps.

The font is a software choice, too. The display does not know what an E is. It knows which elements are on. A different font table can make different compromises, but it cannot put a stroke where there is no segment.

Getting a modern module running is considerably easier than wiring sixty LEDs individually. The HT16K33-based backpack used in the recent XIAO experiment handles the scanning and LED drive; the microcontroller sends it new patterns over I2C. Adafruit’s alphanumeric backpack documentation describes the arrangement, including its sixteen levels of whole-display brightness. The individual segments are on or off; they do not each get their own brightness setting.

For the style of board with separate VCC and Vi2c connections, the wiring is as follows. Other revisions use different power-pin names, so check the backpack pinout before copying the power connections.

Display backpackXIAO ESP32-C3
VCC5V / VBUS, with the XIAO powered by USB
Vi2c3V3
GNDGND
SDA / DATD4 — GPIO6
SCL / CLKD5 — GPIO7

That last detail is worth watching: on the XIAO ESP32-C3, D4 and D5 are not GPIO4 and GPIO5. They are GPIO6 and GPIO7. This was the reason the display initially failed to answer the I2C scanner. The labels make sense once you know which numbering system you are looking at. Until then, they are rather less helpful.

In Arduino IDE, install Adafruit LED Backpack and its dependencies, including Adafruit GFX and Adafruit BusIO, using Library Manager. This example assumes the standard Adafruit-compatible segment wiring and the usual address of 0x70. It moves a four-character window along a longer string:

#include <Wire.h>
#include <Adafruit_LEDBackpack.h>

Adafruit_AlphaNum4 display;

const char message[] =
    "    ABCDEFGHIJKLMNOPQRSTUVWXYZ    "
    "abcdefghijklmnopqrstuvwxyz    "
    "0123456789 +-*/=?!@#%    ";

void setup() {
    Serial.begin(115200);
    Wire.begin(6, 7);  // XIAO ESP32-C3: SDA, SCL
    if (!display.begin(0x70)) {
        Serial.println("Display not found; check wiring/address.");
        while (true) {
            delay(1000);
            }
        }
    display.setBrightness(4);  // Range: 0 through 15
    }

void loop() {
    for (size_t start = 0; start + 4 < sizeof(message); ++start) {
        for (uint8_t digit = 0; digit < 4; ++digit) {
            display.writeDigitAscii(digit, message[start + digit]);
            }
        display.writeDisplay();
        delay(250);
        }
    }

The spaces let the text enter and leave an initially blank display. Each update advances one whole character position; this is not the pixel-by-pixel scrolling possible on a matrix. writeDigitAscii() looks up a character’s segment pattern, and writeDisplay() sends the completed frame to the hardware. Change the string to a sensor message, a callsign, or “PLEASE INSERT COFFEE” and the same idea works.

These examples use the display’s normal orientation. The breadboard setup shown above needed a 180-degree correction: reverse the four character positions and swap the corresponding segments within each character. Reversing the text alone is not enough. That same correction must be applied to raw patterns, too. The decimal point is a special case: software cannot move its LED to the opposite corner of the character, since no LED is physically present there. All fourteen other segments have mirror opposites.

Once the display is working, there is no requirement to use letters at all. The library also accepts raw segment masks through writeDigitRaw(). Each bit in a 16-bit value controls an element. With this mapping, bits 0–13 select the character strokes, bit 14 selects the decimal point, and bit 15 is unused. Combining bits with bitwise OR lets you draw your own symbols.

For example, replace the previous sketch’s loop() with this one to turn the leftmost character into a four-frame rotator:

void loop() {
    // Vertical, / diagonal, horizontal, then \ diagonal.
    const uint16_t frames[] = {0x1200, 0x0C00, 0x00C0, 0x2100};
    static uint8_t frame = 0;

    display.clear();
    display.writeDigitRaw(0, frames[frame]);
    display.writeDisplay();
    frame = (frame + 1) % 4;
    delay(120);
    }

Each pattern lights two opposing strokes through the center. Stepping through them produces a little rotating bar. Light only one spoke at a time and you can make an eight-direction pointer; march around the outside strokes for a perimeter chase. Offset the animation phase in each of the four positions and you get four rotators chasing one another. Similarly, light up two segments and you can have a crude analog clock face.

There is quite a bit of history behind this family of displays. Segmented alphanumeric displays existed well before today’s inexpensive LED backpacks. A 1965 Burroughs advertisement (pp. 62-63; pdf page 56) promoted alphanumeric Nixie-tube readouts for stock-market information. These used selectable glowing segments, rather than the separate, complete numeral shapes associated with the more familiar numeric Nixies.

The light source was not necessarily a gas discharge or an LED, either. In a 1978 Electronic Design article (page 76), REFAC applications engineer Walter Gillis described incandescent segmented displays and illustrated a Garrett AiRNAV navigation panel using seven-segment numeric and sixteen-segment alphanumeric readouts. Tiny glowing filaments formed the strokes. Brightness in a sunlit cockpit could justify hardware that would be a poor choice for a wristwatch. This type of alphanumeric segmented display, if perhaps not the same exact fifteen-segment layout as in the modern example, was used in the Lockheed L1011’s autopilot control panel, announcing the various control modes.

These technologies did not replace one another in a neat sequence. Seven segments remained economical when numbers were enough; extra strokes bought readable words without requiring a full dot matrix. A short mode name, stock symbol, or instrument status could fit into a small, dedicated readout. The tradeoff was a fixed vocabulary of shapes, with very little room for graphics or elaborate lettering.

Split-flap boards, developed by Solari in the 1950s and refined in the 1960s, served a different scale of problem: large, readable airport and railway information boards. Printed characters could have proper curves, and the mechanism held them in place between updates. Electronic readouts offered faster changes and fewer moving parts. But segmented modules did not simply take over the departure board; they coexisted with it, while matrix displays and larger screens offered much more freedom for schedules and announcements.

For watches, calculators, and other battery-powered devices, reflective LCDs had an enormous advantage over glowing readouts: they could remain visible in ambient light without continuously powering a light source. The Seiko 06LC of 1973 came out of a development effort specifically seeking lower power consumption and good visibility, and its field-effect LCD could display the time continuously. This was often a change in how the segments worked, not an abandonment of segments. An LCD can have the same seven- or fourteen-segment geometry as an LED display. Lit LED readouts retained their appeal where visibility in the dark, clear status indications, or quick animation mattered. But passive, reflective LCD displays require almost no power at all compared to other technologies.

The familiar 16×2 character LCD occupies another useful middle ground. Its characters really are made of pixels — typically 5×8 cells — but the usual HD44780-style controller presents a character interface, with a built-in font and room for eight custom 5×8 patterns at once. You can make little thermometers, bar graphs, and animated figures, but there are gaps between character cells and no ordinary full-screen framebuffer. It is more flexible than a handful of fixed strokes, while remaining easy to drive.

Full pixel-addressable displays took over much of the work that needed richer text, multiple languages, plots, and menus. They can also imitate any of the older displays in software, although a picture of a split-flap board is missing something rather important: the clatter. The glow of an LED, the glassy appearance of an LCD, and the mechanical commotion of a departure board each belong to a different sort of remembered future.

For a certain generation, angular alphanumeric displays also bring back WarGames, and WOPR’s attempt to work out the nuclear launch codes. A harmless version of that effect is easy to make: cycle through random letters and numbers, then let each position settle on its final character. The visual association is the point; it does not establish that the movie props used the same display hardware as this breadboard.

Four characters are enough for a clock, a status display, a tiny scrolling sign, or a small piece of cinematic computer drama. Sixty controllable elements leave plenty of room to experiment.

(Global thermonuclear war remains an unnecessarily ambitious first project. We suggest a good game of Chess, instead.)

Written by GPT-6 Astra Max, from an initial idea and general prompt by M. Eric Carr, who also edited this article for style and content, wired and programmed the display, and took the picture. An earlier version of ChatGPT assisted with the display test code, similarly prompted.

Posted in AI, Arduino, C, Coding, Components, Digital, Electronics, Language Models, Tools, Toys, Vibe Coding | Leave a comment

CircuitJS

Finding myself teaching an introductory Circuits course without (at least as yet) an institutional MultiSim license, I was looking around for alternatives and came across CircuitJS, originally created by Paul Falstad.

CircuitJS, running the default LRC circuit simulator.

CircuitJS’ peculiar drag-to-draw-the-component placement style takes a little getting used to, but then again, so does MultiSim. Once you’re familiar with it, though, it’s easy to use (press R to place a resistor; press W to place a wire etc.) I’m not sure I’d use it for circuit analysis (we already have various flavors of SPICE for that anyway), but it’s certainly a very useful tool for education — particularly the way it allows for visualization of current flow using moving yellow dots and relative voltages using color (Green/Grey/Red). Students can build a circuit, see how the current flows through it, and then modify it dynamically and see the resulting changes.

The default LRC simulation provides a good example of this. The circuit starts off with an initially charged capacitor, which provides the energy to set a series LRC circuit oscillating. Energy is traded back and forth between the capacitor and inductor, with the resistor converting part of it into heat on every cycle. The resulting damped sine waves (voltage and current) can be seen in the analysis below the circuit, synchronized with the movement of the “electrons” in the wires of the schematic.

It’s even available as an open-source, downloadable JavaScript app.

Posted in Analog, Digital, Electronics, Internet, Resources, Tools | Leave a comment

Mystery Directional Device

Another trip up North, and another weird and wonderful device to investigate!

On a recent trip up to Maine, I came across a heavy device with a single knob that controlled a heading dial. (Dials marked 0-360 are almost always directional — and when they have 0, 90, 180, and 270 replaced with “N,” “E,” “S,” and “W,” it’s pretty much confirmed.)

The front panel of the mystery device

Turning the dial to S and looking in towards the shaft at what must have been an awkward viewing angle in its original mounting, I could see “CLB Mfg., Inc. Chula Vista, CA”

Looking at the back, I realized this had to be more complex than just a simple dial indicator. There were lots of connections — a set of what looked like three-phase windings, as well as “L1/L2” and “R1/R2” and whatever the heck terminals 1-4 are. Maybe L1/L2 and R1/R2 are Left and Right? For five bucks, how could I go wrong?

The back of the Mystery Device.
Whoa. Maybe it’s some kind of antenna rotator control?

Once I got it back to my folks’ place and could look at it more closely, I first tried to figure out what the electrical connectivity of the connections were. 1/2/3/4 were pretty clearly in some sort of Y configuration, with 4 as the common/center, and about 600 ohms from there to each of 1, 2, and 3. Symmetric coils, maybe? L1/L2 had some resistance between them, as did R1/R2. S1/S2/S3.

I decided to open it up to see if I could figure out anything.

Side view of the inside of the Mystery Device.
Wait — the transducer I was expecting, but not a motor!

Seeing the inside just made it look weirder. There’s a Bendix “Autosyn” resolver geared 1:1 with the dial — but there’s also a 3-phase geared motor that can drive the shaft through a friction coupling. L1/L2 turn out to be Lamp connections; lighting the lamp would backlight the dial in red, for night operations. R1/R2 are the rotor connections to the Bendix resolver (which works with S1/S2/S3.) 1,2,3, and 4 are the Y-wound connections to the 3-phase motor, which seems to not have any positional feedback itself; the loop must be closed in external electronics, using the results from the Bendix.

The Bendix “Autosyn”. Must be some kind of analog resolver…?

The motor winding connections are in phase with some beefy Clarostat 500-ohm resistors; these may be designed not only as series ballast resistors for the (completely unmarked) three-phase motor, but must also provide a nice, cozy warm environment for the mechanicals.

Beefy 500-ohm resistors on each motor phase…

I’m still not sure exactly what it is — ChatGPT’s take on it is that it’s probably some kind of marine course selector/readout device, capable of both setting a course manually as well as having an autopilot device make course corrections via the 3-phase motor.

I guess the next step is a VFD to power up the 3-phase motor and see how it works…

Posted in Analog, Electronics, Mechanical, Reverse Engineering | Leave a comment

Digilent Analog Discovery 3

In conjunction with a recent KEEN engineering workshop, I was provided with a complimentary Analog Discovery 3 kit by Digilent. Although I already have a reasonably functional electronics lab at home, the AD3 nonetheless is an intriguing tool to have in the go box, building lots of useful functionality into a single USB-C device.

A Digilent Analog Discovery 3 kit, set up to trace an I-V curve for a green LED.

The idea behind the AD3 is that hobbyists, students, engineers, and experimenters can put together a huge variety of electronics experiments without having to have tons of equipment. One more-or-less pocket-size box can do it all — two programmable DC power supplies; two oscilloscopes not tied to Ground unless you want them to be; two waveform generators, sixteen digital I/O which can be used as a multi-channel logic analyzer / protocol analyzer, and a neat Waveforms software package that ties it all together into a virtual instrument suite. If that’s not enough, there’s a scripting mode where you can control various functions based on the data returned from others.

A Waveforms screenshot, showing the I-V curve for the green LED in the circuit above.

As part of the KEEN workshop, we were given “mystery circuits” and tasked with using the AD3 to investigate what components they contained. Even without the purpose-made component adapter, it’s straightforward enough to connect the device under test (DUT) and a series resistor, and wire the experiment up so the AD3 can provide controlled voltages to the circuit while monitoring the current through the resistor (and therefore through the DUT). After a little experimentation, we determined that the device was a red LED in series with a resistance of a few hundred ohms. (There’s even an I-V curve tracer function that makes this easy.)

Setup of the AD3 is straightforward; a breakout connector is provided to turn the onboard 30-pin connector into thirty female DuPont connector wires. (Long male-to-male pins are provided to facilitate breadboard connections.) Perhaps it was a quirk of the device I got, but inserting the breakout connector took significantly more force than I was initially willing to risk, until the workshop instructors told me they had a spare on hand, should it break. After using a ridiculous amount of force (I estimate 30-50 lbs or so), the connector seated, and fortunately, subsequent uses of the connector don’t seem to require any additional Feats of Strength.

If this hadn’t been provided for free, I’d still be impressed, but perhaps not enough to justify the $379US price tag, given that I already have discrete devices that can do most or all of what the AD3 does, if not nearly as easily. The AD3 does have all of the basic electronics lab functionality you need, but is necessarily limited in terms of power supply voltages and currents, and oscilloscope / waveform generator bandwidth. When testing the self-resonance of capacitors, the Waveforms software started to notify of bandwidth limitations when testing at 20-25MHz. While this is plenty for a basic electronics lab, even inexpensive microcontrollers like the ESP32 run at much higher speeds (240MHz) these days.

Digilent has always had a student-centric focus, though, and with a healthy student discount, the AD3 could make a great personal starter lab. With departmental funds, it’s also a great way to put together interesting, useful electronics experiments for a university or college curriculum.

It’s absolutely going in my electronics go bag, provided I have a laptop along to run it.

Posted in Analog, Tools, Toys | Leave a comment