Skip to content

Class daisy::OledDisplay

template <typename DisplayDriver>

ClassList > daisy > OledDisplay

More...

  • #include <oled_display.h>

Inherits the following classes: daisy::OneBitGraphicsDisplayImpl

Classes

Type Name
struct Config

Public Functions

Type Name
virtual void DrawPixel (uint_fast8_t x, uint_fast8_t y, bool on) override
virtual void Fill (bool on) override
virtual uint16_t Height () override const
void Init (Config config)
OledDisplay ()
virtual void Update () override
virtual bool UpdateFinished () override
virtual uint16_t Width () override const
virtual ~OledDisplay ()

Public Functions inherited from daisy::OneBitGraphicsDisplayImpl

See daisy::OneBitGraphicsDisplayImpl

Type Name
virtual void DrawArc (uint_fast8_t x, uint_fast8_t y, uint_fast8_t radius, int_fast16_t start_angle, int_fast16_t sweep, bool on) override
virtual void DrawLine (uint_fast8_t x1, uint_fast8_t y1, uint_fast8_t x2, uint_fast8_t y2, bool on) override
virtual void DrawRect (uint_fast8_t x1, uint_fast8_t y1, uint_fast8_t x2, uint_fast8_t y2, bool on, bool fill=false) override
OneBitGraphicsDisplayImpl ()
virtual char WriteChar (char ch, FontDef font, bool on) override
virtual char WriteString (const char * str, FontDef font, bool on) override
virtual Rectangle WriteStringAligned (const char * str, const FontDef & font, Rectangle boundingBox, Alignment alignment, bool on) override
virtual ~OneBitGraphicsDisplayImpl ()

Public Functions inherited from daisy::OneBitGraphicsDisplay

See daisy::OneBitGraphicsDisplay

Type Name
size_t CurrentX ()
size_t CurrentY ()
virtual void DrawArc (uint_fast8_t x, uint_fast8_t y, uint_fast8_t radius, int_fast16_t start_angle, int_fast16_t sweep, bool on) = 0
void DrawCircle (uint_fast8_t x, uint_fast8_t y, uint_fast8_t radius, bool on)
virtual void DrawLine (uint_fast8_t x1, uint_fast8_t y1, uint_fast8_t x2, uint_fast8_t y2, bool on) = 0
virtual void DrawPixel (uint_fast8_t x, uint_fast8_t y, bool on) = 0
virtual void DrawRect (uint_fast8_t x1, uint_fast8_t y1, uint_fast8_t x2, uint_fast8_t y2, bool on, bool fill=false) = 0
void DrawRect (const Rectangle & rect, bool on, bool fill=false)
virtual void Fill (bool on) = 0
Rectangle GetBounds () const
virtual uint16_t Height () const = 0
OneBitGraphicsDisplay ()
void SetCursor (uint16_t x, uint16_t y)
virtual void Update () = 0
virtual bool UpdateFinished () = 0
virtual uint16_t Width () const = 0
virtual char WriteChar (char ch, FontDef font, bool on) = 0
virtual char WriteString (const char * str, FontDef font, bool on) = 0
virtual Rectangle WriteStringAligned (const char * str, const FontDef & font, Rectangle boundingBox, Alignment alignment, bool on) = 0
virtual ~OneBitGraphicsDisplay ()

Protected Attributes inherited from daisy::OneBitGraphicsDisplay

See daisy::OneBitGraphicsDisplay

Type Name
uint16_t currentX_
uint16_t currentY_

Detailed Description

This class is for drawing to a monochrome OLED display.

Public Functions Documentation

function DrawPixel

inline virtual void daisy::OledDisplay::DrawPixel (
    uint_fast8_t x,
    uint_fast8_t y,
    bool on
) override

Sets the pixel at the specified coordinate to be on/off.

Parameters:

  • x x Coordinate
  • y y coordinate
  • on on or off

Implements daisy::OneBitGraphicsDisplay::DrawPixel


function Fill

inline virtual void daisy::OledDisplay::Fill (
    bool on
) override

Fills the entire display with either on/off.

Parameters:

  • on Sets on or off.

Implements daisy::OneBitGraphicsDisplay::Fill


function Height

inline virtual uint16_t daisy::OledDisplay::Height () override const

Implements daisy::OneBitGraphicsDisplay::Height


function Init

inline void daisy::OledDisplay::Init (
    Config config
) 

function OledDisplay

inline daisy::OledDisplay::OledDisplay () 

function Update

inline virtual void daisy::OledDisplay::Update () override

Writes the current display buffer to the OLED device using SPI or I2C depending on how the object was initialized.

Implements daisy::OneBitGraphicsDisplay::Update


function UpdateFinished

inline virtual bool daisy::OledDisplay::UpdateFinished () override

Returns true if the Update has finished, used for chained DMA transfers

Implements daisy::OneBitGraphicsDisplay::UpdateFinished


function Width

inline virtual uint16_t daisy::OledDisplay::Width () override const

Implements daisy::OneBitGraphicsDisplay::Width


function ~OledDisplay

inline virtual daisy::OledDisplay::~OledDisplay () 


The documentation for this class was generated from the following file external-docs/libDaisy/src/hid/disp/oled_display.h