forked from luetee/ST7567S_128X64_I2C
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathST7567S_128X64_I2C.ino
48 lines (37 loc) · 934 Bytes
/
ST7567S_128X64_I2C.ino
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
/******************************
* original code from
* URL: https://github.com/mworkfun/ST7567A_128X32DOT_LCD
*
*
* Modify for LCD ST7567S 128x64
* screen:
* x-----------------------> +
* y |
* | |
* |---------------------
* |
* v +
*
******************************/
#include "ST7567S-IIC-128x64.h"
#include <GFX_fonts/arial6pt7b.h>
GFXfont font=arial6pt7b;
//create an lcd object.
ST7567S_IIC Lcd;
/////////////////////////////////////////////////////////
void setup() {
delay(2000);
Lcd.Init();
Lcd.fillScreen(0xff);
Lcd.setRotation(0);
Lcd.setFont(&font);
Lcd.drawRect(10,10,50,30,1);
// Lcd.drawPixel(1,1,1);
Lcd.setCursor(0,font.yAdvance);
Lcd.drawCircle(64,32,10,1);
Lcd.print(F("Xin Chao"));
Lcd.render();
}
/////////////////////////////////////////////////////////
void loop() {
}