This repository has been archived on 2024-12-15. You can view files and clone it, but cannot push or open issues or pull requests.
DeviceLib/Lcd.h

38 lines
510 B
C++

#pragma once
#include <stdint.h>
class Lcd
{
public:
union Command
{
struct
{
bool DB0: 1;
bool DB1: 1;
bool DB2: 1;
bool DB3: 1;
bool DB4: 1;
bool DB5: 1;
bool DB6: 1;
bool DB7: 1;
};
uint8_t data;
};
public:
void initDisplay();
void clear();
void output(const char &character);
void output(const char *string);
void output(const uint16_t &val);
private:
void setPos(const uint8_t &pos);
virtual void execute(const Command &cmd, bool RS, double delay) = 0;
};