Last change
on this file since 368 was 136, checked in by ertl-honda, 9 years ago |
ライブラリとOS及びベーシックなサンプルの追加.
|
File size:
560 bytes
|
Rev | Line | |
---|
[136] | 1 | #include "TFT.h"
|
---|
| 2 | #include <Arduino.h> //modified
|
---|
| 3 |
|
---|
| 4 | #if ARDUINO_AVR_ESPLORA
|
---|
| 5 | TFT EsploraTFT(7, 0, 1);
|
---|
| 6 | #endif
|
---|
| 7 |
|
---|
| 8 | TFT::TFT(uint8_t CS, uint8_t RS, uint8_t RST)
|
---|
| 9 | : Adafruit_ST7735(CS, RS, RST)
|
---|
| 10 | {
|
---|
| 11 | // as we already know the orientation (landscape, therefore rotated),
|
---|
| 12 | // set default width and height without need to call begin() first.
|
---|
| 13 | _width = ST7735_TFTHEIGHT;
|
---|
| 14 | _height = ST7735_TFTWIDTH;
|
---|
| 15 | }
|
---|
| 16 |
|
---|
| 17 | void TFT::begin() {
|
---|
| 18 | //initR(INITR_REDTAB);
|
---|
| 19 | #if defined(ARDUINO_ARCH_SAMD)
|
---|
| 20 | if((!Serial) || (SerialUSB)) Serial.begin(1200);
|
---|
| 21 | #endif
|
---|
| 22 | initG();
|
---|
| 23 | setRotation(1);
|
---|
| 24 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.