2017-02-20 18:55:16 +00:00
|
|
|
#ifndef __TEENSY_DISPLAY_H
|
|
|
|
#define __TEENSY_DISPLAY_H
|
|
|
|
|
|
|
|
#include <Arduino.h>
|
2020-07-15 07:21:17 +00:00
|
|
|
#include <ILI9341_t3n.h>
|
2017-02-28 13:15:11 +00:00
|
|
|
|
2020-07-06 20:46:14 +00:00
|
|
|
#include "physicaldisplay.h"
|
2017-02-20 18:55:16 +00:00
|
|
|
|
|
|
|
class BIOS;
|
|
|
|
|
|
|
|
class TeensyDisplay : public PhysicalDisplay {
|
|
|
|
friend class BIOS;
|
|
|
|
|
|
|
|
public:
|
|
|
|
TeensyDisplay();
|
|
|
|
virtual ~TeensyDisplay();
|
|
|
|
|
2020-07-07 01:31:37 +00:00
|
|
|
virtual void blit();
|
2017-02-26 16:00:41 +00:00
|
|
|
virtual void blit(AiieRect r);
|
2017-02-20 18:55:16 +00:00
|
|
|
virtual void redraw();
|
|
|
|
|
2018-02-07 15:20:26 +00:00
|
|
|
virtual void clrScr();
|
2020-07-06 20:46:14 +00:00
|
|
|
virtual void flush();
|
2017-02-20 18:55:16 +00:00
|
|
|
|
|
|
|
virtual void drawCharacter(uint8_t mode, uint16_t x, uint8_t y, char c);
|
|
|
|
virtual void drawString(uint8_t mode, uint16_t x, uint8_t y, const char *str);
|
|
|
|
|
2018-01-07 19:43:17 +00:00
|
|
|
virtual void drawImageOfSizeAt(const uint8_t *img, uint16_t sizex, uint8_t sizey, uint16_t wherex, uint8_t wherey);
|
2017-02-20 18:55:16 +00:00
|
|
|
|
2018-02-18 01:44:04 +00:00
|
|
|
virtual void cacheDoubleWidePixel(uint16_t x, uint16_t y, uint8_t color);
|
|
|
|
virtual void cache2DoubleWidePixels(uint16_t x, uint16_t y, uint8_t colorA, uint8_t colorB);
|
|
|
|
virtual void cachePixel(uint16_t x, uint16_t y, uint8_t color);
|
|
|
|
|
2020-07-15 07:21:17 +00:00
|
|
|
uint32_t frameCount();
|
2017-02-20 18:55:16 +00:00
|
|
|
private:
|
2018-01-07 19:43:17 +00:00
|
|
|
virtual void drawPixel(uint16_t x, uint16_t y, uint16_t color);
|
|
|
|
virtual void drawPixel(uint16_t x, uint16_t y, uint8_t r, uint8_t g, uint8_t b);
|
2018-02-18 01:44:04 +00:00
|
|
|
virtual void drawUIPixel(uint16_t x, uint16_t y, uint16_t color);
|
2017-02-20 18:55:16 +00:00
|
|
|
|
|
|
|
bool needsRedraw;
|
2017-02-27 01:25:47 +00:00
|
|
|
bool driveIndicator[2];
|
|
|
|
bool driveIndicatorDirty;
|
2017-02-20 18:55:16 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|