Skip to content

File DrumDisplay.h

FileList > DrumDisplay > DrumDisplay.h

Go to the source code of this file

Rolling mechanical-drum OLED readout output for OpenSkyhawk __PanelGroup nodes.More...

  • #include <PanelGroup.h>
  • #include <U8g2lib.h>
  • #include <Helpers/I2cMux/I2cMux.h>
  • #include <Helpers/I2cHealth/I2cHealth.h>

Namespaces

Type Name
namespace OpenSkyhawk

Classes

Type Name
class DrumDisplay
Rolling-drum OLED readout. One instance == one OLED panel.
struct DrumFlag
Optional 2-state (or N-state) flag tape — hemisphere N/S · E/W, or a mode letter.
struct DrumGlyph
A fixed (non-rolling) glyph painted between digit columns — '.', ' ', ':' etc.
struct DrumReadout
Complete description of one rolling readout: its sources, geometry, glyphs, flag.
struct DrumSource
One DCS-BIOS digit source feeding a DrumReadout .

Detailed Description

One DrumDisplay instance drives ONE OLED panel through a caller-owned U8G2 object. It renders a row of digit "tapes" that ease toward their target value with a mechanical-drum cascade (units rolls continuously; higher places dwell and roll only on carry), optionally followed by a 2-state hemisphere/mode flag tape. Multi-digit DCS-BIOS readouts (APN-153 SPEED, NAV LAT/LON, MAGVAR, ARC-51 frequency, BDHI range) are reconstructed from their per-digit DCS-BIOS output addresses via a DrumReadout descriptor.

Renderer ported from the bench-verified SH1106 prototype (Tests/DrumDisplay roll_reference): per-cell setClipWindow + drawTape/drawFlag + per-place ease. Adds snap-then-settle, DCS-BIOS address→digit decode, and descriptor-driven geometry auto-fit.

Ownership: the sketch constructs the concrete U8G2 type (it knows the panel — SH1106 vs SSD1306, size, rotation), calls Wire.begin() and oled.begin(), and passes the U8G2 by reference. DrumDisplay calls only base-class U8G2 methods. For N panels on one TCA9548A, construct N DrumDisplay instances sharing one I2cMux, each with its own channel; the class re-selects its channel before every buffer send.

Version:

0.1.0

Copyright:

GPL-2.0-only — see Firmware/LICENSE


The documentation for this class was generated from the following file Firmware/Libraries/DrumDisplay/DrumDisplay.h