-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathSharpMemoryLcd.h
More file actions
52 lines (44 loc) · 1.46 KB
/
SharpMemoryLcd.h
File metadata and controls
52 lines (44 loc) · 1.46 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
/***********************************
Written by Joshua Oster-Morris/craftycoder.
BSD license, check license.txt for more information
All text above must be included in any redistribution
This class extends the Adafruit_GFX library.
It can be found at https://github.com/adafruit/Adafruit-GFX-Library
I owe a debt of gratitude to Adafruit for the use of
this interface in the creation of this class.
****************************************/
#ifndef SHARPMEMORYLCD_H
#define SHARPMEMORYLCD_H
#if ARDUINO >= 100
#include "Arduino.h"
#else
#include "WProgram.h"
#endif
#include <Adafruit_GFX.h>
#define DEFAULT_WIDTH 96
#define DEFAULT_HEIGHT 96
class SHARPMEMORYLCD : public Adafruit_GFX {
public:
SHARPMEMORYLCD(int16_t w = DEFAULT_WIDTH, int16_t h = DEFAULT_HEIGHT);
~SHARPMEMORYLCD();
void LcdInitialize();
void LcdAllClearMode();
void LcdSetMode(int M0, int M2);
void LcdSendPixels(int num, int state);
void LcdSetLineAddress(int line);
void LcdPrintImage(int bitmap, int arraySize);
void LcdPrintImage(void);
void LcdPost();
void LcdPost(int delayTime);
void LcdStartEXTC(); //frame signal
void LcdStopEXTC();
void LcdPrintBuffer();
void drawPixel(int16_t x, int16_t y, uint16_t color);
void invert(uint8_t i);
void LcdClearBuffer();
private:
unsigned char _buffer[1152];
int _invert;
void LcdSendByte(char byteToSend);
};
#endif