Seven segment display
Common anode or cathode, with the decimal point.
- 10 pins
- 2 settings
- In 4 projects
- In 4 lessons
The Seven segment display in brief
What it is, and every setting the properties panel gives it.
A seven-segment display is not a smart part: it is eight ordinary LEDs in one black package, sharing one internal node that is brought out on two legs so the footprint stays symmetric. There is no decoder, no latch and no multiplexing inside it, exactly like the real thing. Each segment is the same diode model the plain LED uses, so a segment left with no series resistor still lights, at a current the probe will happily report as unrealistic rather than refusing to show it. The common leg’s polarity is the detail that catches people: a common-cathode part sinks the combined current of every lit segment through its grounded common leg, and wiring a common-anode part the common-cathode way lights nothing at all, which is precisely the mistake a real seven-segment display lets you make on a real breadboard too. Driving all eight lines from a microcontroller with pins to spare is the usual reason to reach for a 74HC595 alongside it.
- Family
- Displays
- Pins
- 10
- common
- cathode (or anode)
- cathode or anode.
- color
- red (or green, blue, yellow, white)
- the LED color, which also sets the forward drop per segment.
A circuit built around it, running and explained: the 7 segment display simulator.
10 pins
Named as the editor names them, so a wire lands where you expect it.
How to wire a 7-segment display to an Arduino
A single-digit display is eight LEDs in one package, the segments a to g and the decimal point, with all their cathodes joined (common cathode) or all their anodes joined (common anode). On a common cathode display, each segment pin goes to an Arduino pin and the common pin to GND; a segment lights when its pin goes HIGH.
The circuit here is an electronic dice: segments a to g on pins 2 to 8, the common cathode through one 220 ohm resistor to GND, and a button on pin 9. One shared resistor is the cheap way and the more segments are lit, the dimmer each one is; a resistor per segment is the right way.
For four digits with only two pins, the TM1637 module does the multiplexing itself; its pages under the boards list show the wiring for each board.
const int SEG_PINS[] = {2, 3, 4, 5, 6, 7, 8};
void show(uint8_t mask) { // 0x06 is a 1, 0x7D a 6
for (int i = 0; i < 7; i++) {
digitalWrite(SEG_PINS[i], (mask >> i) & 1 ? HIGH : LOW);
}
}What is true about the Seven segment display, here
In its help article’s own words: what the simulation gets right, and where it stops.
Modeled
Each segment is the same diode model the LED uses, literally the same forward drop and dynamic resistance, by color. Seen from a segment leg the part is the common node plus one diode; seen from a common leg it is every lit segment in parallel. A common-cathode digit with its common grounded sinks the sum of the segment currents, exactly as it does on a real board.
Not modeled
No decoder, no BCD input, no built-in current limiting.
Each segment is the same Shockley diode the LED is, so the same caveats apply: one curve per color, no dice-to-dice variation, no junction capacitance and no temperature. The probe calls a segment lit above 1 mA, which is a threshold rather than a brightness. The bitmask is on or off per segment, so a multiplexed digit at a tenth of full current reads exactly as bright as a steady one. There is no per-segment brightness, no persistence-of-vision averaging (unlike the plain LED), no digit multiplexing and no current or power rating.
LEDs, seven-segment dies and RGB LEDs (`led`)
| model | what sets it |
|---|---|
the same equation, with N = 2 and 12 ohm of bulk | the color's drop at 20 mA: red 1.8 V, yellow 2.0, green 3.0, blue 3.0, white 3.1 |
From Seven-segment display, in full.
See the Seven segment display in a project
4 built-in projects use it. Each opens in the editor, already wired.
Where it turns up in a lesson
4 lessons place it in their own circuits.
The boards it is shown on
Each of these 2 boards has a built-in project with the Seven segment display in it.
The Seven segment display on each board
The pins, the voltage and the code change from board to board. Each page has that board’s wiring and a circuit you can run.
The rest of the bench
Every one of these is drawn and simulated the same way.
Wire up the Seven segment display
Open the editor and push it into the breadboard. It is free, and it runs on your own machine.