jacdac.seven_segment_display.client

Module Contents

Classes

SevenSegmentDisplayClient

A 7-segment numeric display, with one or more digits.

class jacdac.seven_segment_display.client.SevenSegmentDisplayClient(bus: jacdac.bus.Bus, role: str)

Bases: jacdac.bus.Client

A 7-segment numeric display, with one or more digits. Implements a client for the 7-segment display service.

property digits: bytes | None

Each byte encodes the display status of a digit using, where lowest bit 0 encodes segment A, bit 1 encodes segments B, …, bit 6 encodes segments G, and bit 7 encodes the decimal point (if present). If incoming digits data is smaller than digit_count, the remaining digits will be cleared. Thus, sending an empty digits payload clears the screen.

```text GFEDCBA DP

  • A -

F B | | - G - | | E C _ | | |DP| - D - -

```,

property brightness: float | None

(Optional) Controls the brightness of the LEDs. 0 means off., _: /

property double_dots: bool | None

(Optional) Turn on or off the column LEDs (separating minutes from hours, etc.) in of the segment. If the column LEDs is not supported, the value remains false.,

property digit_count: int | None

The number of digits available on the display.,

property decimal_point: bool | None

(Optional) True if decimal points are available (on all digits).,

set_number(value: float) None

Shows the number on the screen using the decimal dot if available.