AberLED shield library
Library for the bicolor LED (and TFT screen) shield used in CS12020
|
#include <TFT_ST7735.h>
Public Member Functions | |
TFT_ST7735 (int16_t _W=ST7735_TFTWIDTH, int16_t _H=ST7735_TFTHEIGHT) | |
void | init (void) |
void | begin (void) |
void | drawPixel (uint16_t x, uint16_t y, uint16_t color) |
void | drawChar (int16_t x, int16_t y, unsigned char c, uint16_t color, uint16_t bg, uint8_t font) |
void | setAddrWindow (int16_t x0, int16_t y0, int16_t x1, int16_t y1) |
void | pushColor (uint16_t color) |
void | pushColor (uint16_t color, uint16_t len) |
void | pushColors (uint16_t *data, uint8_t len) |
void | pushColors (uint8_t *data, uint16_t len) |
void | fillScreen (uint16_t color) |
void | writeEnd (void) |
void | backupSPCR (void) |
void | restoreSPCR (void) |
void | drawLine (int16_t x0, int16_t y0, int16_t x1, int16_t y1, uint16_t color) |
void | drawFastVLine (int16_t x, int16_t y, int16_t h, uint16_t color) |
void | drawFastHLine (int16_t x, int16_t y, int16_t w, uint16_t color) |
void | drawRect (int16_t x, int16_t y, int16_t w, int16_t h, uint16_t color) |
void | fillRect (int16_t x, int16_t y, int16_t w, int16_t h, uint16_t color) |
void | drawRoundRect (int16_t x0, int16_t y0, int16_t w, int16_t h, int16_t radius, uint16_t color) |
void | fillRoundRect (int16_t x0, int16_t y0, int16_t w, int16_t h, int16_t radius, uint16_t color) |
void | setRotation (uint8_t r) |
void | invertDisplay (boolean i) |
void | drawCircle (int16_t x0, int16_t y0, int16_t r, uint16_t color) |
void | drawCircleHelper (int16_t x0, int16_t y0, int16_t r, uint8_t cornername, uint16_t color) |
void | fillCircle (int16_t x0, int16_t y0, int16_t r, uint16_t color) |
void | fillCircleHelper (int16_t x0, int16_t y0, int16_t r, uint8_t cornername, int16_t delta, uint16_t color) |
void | drawEllipse (int16_t x0, int16_t y0, int16_t rx, int16_t ry, uint16_t color) |
void | fillEllipse (int16_t x0, int16_t y0, int16_t rx, int16_t ry, uint16_t color) |
void | drawTriangle (int16_t x0, int16_t y0, int16_t x1, int16_t y1, int16_t x2, int16_t y2, uint16_t color) |
void | fillTriangle (int16_t x0, int16_t y0, int16_t x1, int16_t y1, int16_t x2, int16_t y2, uint16_t color) |
void | drawBitmap (int16_t x, int16_t y, const uint8_t *bitmap, int16_t w, int16_t h, uint16_t color) |
void | setCursor (int16_t x, int16_t y) |
void | setCursor (int16_t x, int16_t y, uint8_t font) |
void | setTextColor (uint16_t color) |
void | setTextColor (uint16_t fgcolor, uint16_t bgcolor) |
void | setTextSize (uint8_t size) |
void | setTextFont (uint8_t font) |
void | setTextWrap (boolean wrap) |
void | setTextDatum (uint8_t datum) |
void | setTextPadding (uint16_t x_width) |
void | spiwrite (uint8_t) |
void | writecommand (uint8_t c) |
void | writedata (uint8_t d) |
void | commandList (const uint8_t *addr) |
uint8_t | getRotation (void) |
uint16_t | fontsLoaded (void) |
uint16_t | color565 (uint8_t r, uint8_t g, uint8_t b) |
int16_t | drawChar (unsigned int uniCode, int x, int y, int font) |
int16_t | drawNumber (long long_num, int poX, int poY, int font) |
int16_t | drawFloat (float floatNumber, int decimal, int poX, int poY, int font) |
int16_t | drawString (char *string, int poX, int poY, int font) |
int16_t | drawCentreString (char *string, int dX, int poY, int font) |
int16_t | drawRightString (char *string, int dX, int poY, int font) |
int16_t | height (void) |
int16_t | width (void) |
int16_t | textWidth (char *string, int font) |
int16_t | fontHeight (int font) |
virtual size_t | write (uint8_t) |
Protected Attributes | |
int16_t | _width |
int16_t | _height |
int16_t | cursor_x |
int16_t | cursor_y |
int16_t | padX |
uint16_t | textcolor |
uint16_t | textbgcolor |
uint16_t | fontsloaded |
uint8_t | addr_row |
uint8_t | addr_col |
uint8_t | textfont |
uint8_t | textsize |
uint8_t | textdatum |
uint8_t | rotation |
boolean | textwrap |
Definition at line 261 of file TFT_ST7735.h.
TFT_ST7735::TFT_ST7735 | ( | int16_t | _W = ST7735_TFTWIDTH , |
int16_t | _H = ST7735_TFTHEIGHT |
||
) |
Definition at line 38 of file TFT_ST7735.cpp.
void TFT_ST7735::backupSPCR | ( | void | ) |
Definition at line 148 of file TFT_ST7735.cpp.
void TFT_ST7735::begin | ( | void | ) |
Definition at line 199 of file TFT_ST7735.cpp.
uint16_t TFT_ST7735::color565 | ( | uint8_t | r, |
uint8_t | g, | ||
uint8_t | b | ||
) |
Definition at line 1488 of file TFT_ST7735.cpp.
void TFT_ST7735::commandList | ( | const uint8_t * | addr | ) |
Definition at line 407 of file TFT_ST7735.cpp.
void TFT_ST7735::drawBitmap | ( | int16_t | x, |
int16_t | y, | ||
const uint8_t * | bitmap, | ||
int16_t | w, | ||
int16_t | h, | ||
uint16_t | color | ||
) |
Definition at line 790 of file TFT_ST7735.cpp.
int TFT_ST7735::drawCentreString | ( | char * | string, |
int | dX, | ||
int | poY, | ||
int | font | ||
) |
Definition at line 2032 of file TFT_ST7735.cpp.
void TFT_ST7735::drawChar | ( | int16_t | x, |
int16_t | y, | ||
unsigned char | c, | ||
uint16_t | color, | ||
uint16_t | bg, | ||
uint8_t | font | ||
) |
Definition at line 970 of file TFT_ST7735.cpp.
int TFT_ST7735::drawChar | ( | unsigned int | uniCode, |
int | x, | ||
int | y, | ||
int | font | ||
) |
Definition at line 1677 of file TFT_ST7735.cpp.
void TFT_ST7735::drawCircle | ( | int16_t | x0, |
int16_t | y0, | ||
int16_t | r, | ||
uint16_t | color | ||
) |
Definition at line 438 of file TFT_ST7735.cpp.
void TFT_ST7735::drawCircleHelper | ( | int16_t | x0, |
int16_t | y0, | ||
int16_t | r, | ||
uint8_t | cornername, | ||
uint16_t | color | ||
) |
Definition at line 476 of file TFT_ST7735.cpp.
void TFT_ST7735::drawEllipse | ( | int16_t | x0, |
int16_t | y0, | ||
int16_t | rx, | ||
int16_t | ry, | ||
uint16_t | color | ||
) |
Definition at line 560 of file TFT_ST7735.cpp.
void TFT_ST7735::drawFastHLine | ( | int16_t | x, |
int16_t | y, | ||
int16_t | w, | ||
uint16_t | color | ||
) |
Definition at line 1443 of file TFT_ST7735.cpp.
void TFT_ST7735::drawFastVLine | ( | int16_t | x, |
int16_t | y, | ||
int16_t | h, | ||
uint16_t | color | ||
) |
Definition at line 1421 of file TFT_ST7735.cpp.
int TFT_ST7735::drawFloat | ( | float | floatNumber, |
int | decimal, | ||
int | poX, | ||
int | poY, | ||
int | font | ||
) |
Definition at line 2073 of file TFT_ST7735.cpp.
void TFT_ST7735::drawLine | ( | int16_t | x0, |
int16_t | y0, | ||
int16_t | x1, | ||
int16_t | y1, | ||
uint16_t | color | ||
) |
Definition at line 1366 of file TFT_ST7735.cpp.
int TFT_ST7735::drawNumber | ( | long | long_num, |
int | poX, | ||
int | poY, | ||
int | font | ||
) |
Definition at line 2060 of file TFT_ST7735.cpp.
void TFT_ST7735::drawPixel | ( | uint16_t | x, |
uint16_t | y, | ||
uint16_t | color | ||
) |
Definition at line 1111 of file TFT_ST7735.cpp.
void TFT_ST7735::drawRect | ( | int16_t | x, |
int16_t | y, | ||
int16_t | w, | ||
int16_t | h, | ||
uint16_t | color | ||
) |
Definition at line 657 of file TFT_ST7735.cpp.
int TFT_ST7735::drawRightString | ( | char * | string, |
int | dX, | ||
int | poY, | ||
int | font | ||
) |
Definition at line 2046 of file TFT_ST7735.cpp.
void TFT_ST7735::drawRoundRect | ( | int16_t | x0, |
int16_t | y0, | ||
int16_t | w, | ||
int16_t | h, | ||
int16_t | radius, | ||
uint16_t | color | ||
) |
Definition at line 670 of file TFT_ST7735.cpp.
int TFT_ST7735::drawString | ( | char * | string, |
int | poX, | ||
int | poY, | ||
int | font | ||
) |
Definition at line 1916 of file TFT_ST7735.cpp.
void TFT_ST7735::drawTriangle | ( | int16_t | x0, |
int16_t | y0, | ||
int16_t | x1, | ||
int16_t | y1, | ||
int16_t | x2, | ||
int16_t | y2, | ||
uint16_t | color | ||
) |
Definition at line 705 of file TFT_ST7735.cpp.
void TFT_ST7735::fillCircle | ( | int16_t | x0, |
int16_t | y0, | ||
int16_t | r, | ||
uint16_t | color | ||
) |
Definition at line 516 of file TFT_ST7735.cpp.
void TFT_ST7735::fillCircleHelper | ( | int16_t | x0, |
int16_t | y0, | ||
int16_t | r, | ||
uint8_t | cornername, | ||
int16_t | delta, | ||
uint16_t | color | ||
) |
Definition at line 527 of file TFT_ST7735.cpp.
void TFT_ST7735::fillEllipse | ( | int16_t | x0, |
int16_t | y0, | ||
int16_t | rx, | ||
int16_t | ry, | ||
uint16_t | color | ||
) |
Definition at line 604 of file TFT_ST7735.cpp.
void TFT_ST7735::fillRect | ( | int16_t | x, |
int16_t | y, | ||
int16_t | w, | ||
int16_t | h, | ||
uint16_t | color | ||
) |
Definition at line 1464 of file TFT_ST7735.cpp.
void TFT_ST7735::fillRoundRect | ( | int16_t | x0, |
int16_t | y0, | ||
int16_t | w, | ||
int16_t | h, | ||
int16_t | radius, | ||
uint16_t | color | ||
) |
Definition at line 690 of file TFT_ST7735.cpp.
void TFT_ST7735::fillScreen | ( | uint16_t | color | ) |
Definition at line 647 of file TFT_ST7735.cpp.
void TFT_ST7735::fillTriangle | ( | int16_t | x0, |
int16_t | y0, | ||
int16_t | x1, | ||
int16_t | y1, | ||
int16_t | x2, | ||
int16_t | y2, | ||
uint16_t | color | ||
) |
Definition at line 717 of file TFT_ST7735.cpp.
int16_t TFT_ST7735::fontHeight | ( | int | font | ) |
Definition at line 961 of file TFT_ST7735.cpp.
uint16_t TFT_ST7735::fontsLoaded | ( | void | ) |
Definition at line 951 of file TFT_ST7735.cpp.
uint8_t TFT_ST7735::getRotation | ( | void | ) |
Definition at line 896 of file TFT_ST7735.cpp.
int16_t TFT_ST7735::height | ( | void | ) |
Definition at line 915 of file TFT_ST7735.cpp.
void TFT_ST7735::init | ( | void | ) |
Definition at line 210 of file TFT_ST7735.cpp.
void TFT_ST7735::invertDisplay | ( | boolean | i | ) |
Definition at line 1599 of file TFT_ST7735.cpp.
void TFT_ST7735::pushColor | ( | uint16_t | color | ) |
Definition at line 1162 of file TFT_ST7735.cpp.
void TFT_ST7735::pushColor | ( | uint16_t | color, |
uint16_t | len | ||
) |
Definition at line 1187 of file TFT_ST7735.cpp.
void TFT_ST7735::pushColors | ( | uint16_t * | data, |
uint8_t | len | ||
) |
Definition at line 1208 of file TFT_ST7735.cpp.
void TFT_ST7735::pushColors | ( | uint8_t * | data, |
uint16_t | len | ||
) |
Definition at line 1242 of file TFT_ST7735.cpp.
void TFT_ST7735::restoreSPCR | ( | void | ) |
Definition at line 157 of file TFT_ST7735.cpp.
void TFT_ST7735::setAddrWindow | ( | int16_t | x0, |
int16_t | y0, | ||
int16_t | x1, | ||
int16_t | y1 | ||
) |
Definition at line 1053 of file TFT_ST7735.cpp.
void TFT_ST7735::setCursor | ( | int16_t | x, |
int16_t | y | ||
) |
Definition at line 808 of file TFT_ST7735.cpp.
void TFT_ST7735::setCursor | ( | int16_t | x, |
int16_t | y, | ||
uint8_t | font | ||
) |
Definition at line 818 of file TFT_ST7735.cpp.
void TFT_ST7735::setRotation | ( | uint8_t | r | ) |
Definition at line 1506 of file TFT_ST7735.cpp.
void TFT_ST7735::setTextColor | ( | uint16_t | color | ) |
Definition at line 848 of file TFT_ST7735.cpp.
void TFT_ST7735::setTextColor | ( | uint16_t | fgcolor, |
uint16_t | bgcolor | ||
) |
Definition at line 859 of file TFT_ST7735.cpp.
void TFT_ST7735::setTextDatum | ( | uint8_t | datum | ) |
Definition at line 878 of file TFT_ST7735.cpp.
void TFT_ST7735::setTextFont | ( | uint8_t | font | ) |
Definition at line 839 of file TFT_ST7735.cpp.
void TFT_ST7735::setTextPadding | ( | uint16_t | x_width | ) |
Definition at line 887 of file TFT_ST7735.cpp.
void TFT_ST7735::setTextSize | ( | uint8_t | size | ) |
Definition at line 829 of file TFT_ST7735.cpp.
void TFT_ST7735::setTextWrap | ( | boolean | wrap | ) |
Definition at line 869 of file TFT_ST7735.cpp.
void TFT_ST7735::spiwrite | ( | uint8_t | c | ) |
Definition at line 102 of file TFT_ST7735.cpp.
int16_t TFT_ST7735::textWidth | ( | char * | string, |
int | font | ||
) |
Definition at line 924 of file TFT_ST7735.cpp.
int16_t TFT_ST7735::width | ( | void | ) |
Definition at line 906 of file TFT_ST7735.cpp.
|
virtual |
Definition at line 1612 of file TFT_ST7735.cpp.
void TFT_ST7735::writecommand | ( | uint8_t | c | ) |
Definition at line 116 of file TFT_ST7735.cpp.
void TFT_ST7735::writedata | ( | uint8_t | d | ) |
Definition at line 128 of file TFT_ST7735.cpp.
void TFT_ST7735::writeEnd | ( | void | ) |
Definition at line 140 of file TFT_ST7735.cpp.
|
protected |
Definition at line 362 of file TFT_ST7735.h.
|
protected |
Definition at line 362 of file TFT_ST7735.h.
|
protected |
Definition at line 367 of file TFT_ST7735.h.
|
protected |
Definition at line 367 of file TFT_ST7735.h.
|
protected |
Definition at line 362 of file TFT_ST7735.h.
|
protected |
Definition at line 362 of file TFT_ST7735.h.
|
protected |
Definition at line 365 of file TFT_ST7735.h.
|
protected |
Definition at line 362 of file TFT_ST7735.h.
|
protected |
Definition at line 369 of file TFT_ST7735.h.
|
protected |
Definition at line 365 of file TFT_ST7735.h.
|
protected |
Definition at line 365 of file TFT_ST7735.h.
|
protected |
Definition at line 369 of file TFT_ST7735.h.
|
protected |
Definition at line 369 of file TFT_ST7735.h.
|
protected |
Definition at line 369 of file TFT_ST7735.h.
|
protected |
Definition at line 374 of file TFT_ST7735.h.