107 #ifndef _ST7735H_SDC_
108 #define _ST7735H_SDC_
123 #define ST7735_TFTWIDTH 128
127 #define ST7735_TFTHEIGHT 160
133 #define ST7735_BLACK 0x0000
134 #define ST7735_BLUE 0xF800
135 #define ST7735_RED 0x001F
136 #define ST7735_GREEN 0x07E0
137 #define ST7735_CYAN 0xFFE0
138 #define ST7735_MAGENTA 0xF81F
139 #define ST7735_YELLOW 0x07FF
140 #define ST7735_WHITE 0xFFFF
141 #define ST7735_LIGHTGREY ST7735_Color565(228,228,228)
142 #define ST7735_DARKGREY ST7735_Color565(32,32,32)
143 #define ST7735_ORANGE ST7735_Color565(255,102,0)
144 #define ST7735_PURPLE ST7735_Color565(106,13,173)
237 void ST7735_FillRect(int16_t x, int16_t y, int16_t w, int16_t h, uint16_t color);
304 void ST7735_DrawBitmap(int16_t x, int16_t y,
const uint16_t *image, int16_t w, int16_t h);
323 void ST7735_DrawCharS(int16_t x, int16_t y,
char c, int16_t textColor, int16_t bgColor, uint8_t size);
341 void ST7735_DrawChar(int16_t x, int16_t y,
char c, int16_t textColor, int16_t bgColor, uint8_t size);
356 uint32_t
ST7735_DrawString(uint16_t x, uint16_t y,
char *pt, int16_t textColor);;
477 void ST7735_Drawaxes(uint16_t axisColor, uint16_t bgColor,
char *xLabel,
478 char *yLabel1, uint16_t label1Color,
char *yLabel2, uint16_t label2Color,
479 int32_t ymax, int32_t ymin);
758 void ST7735_XYplotInit(
char *title, int32_t minX, int32_t maxX, int32_t minY, int32_t maxY);
769 void ST7735_XYplot(uint32_t num, int32_t bufX[], int32_t bufY[]);
786 void ST7735_Line(uint16_t x1, uint16_t y1, uint16_t x2, uint16_t y2,
807 void ST7735_Message(uint32_t d, uint32_t l,
char *pt, int32_t value);
void ST7735_DrawFastHLine(int16_t x, int16_t y, int16_t w, uint16_t color)
Draw a horizontal line.
void ST7735_OutUDec(uint32_t n)
Output an unsigned decimal.
void ST7735_DrawCharS(int16_t x, int16_t y, char c, int16_t textColor, int16_t bgColor, uint8_t size)
Draw a character.
void ST7735_PlotdBfs(int32_t y)
Plot one bar.
void ST7735_PlotPoint2(int32_t data1, uint16_t color1)
Plot one point with color.
void ST7735_PlotPoint(int32_t y)
Plot one point.
void ST7735_InitR(enum initRFlags option)
Initialize ST7735R LCD.
void ST7735_InvertDisplay(int i)
invert display
uint16_t ST7735_Color565(uint8_t r, uint8_t g, uint8_t b)
RGB to color creation.
void ST7735_DrawFastVLine(int16_t x, int16_t y, int16_t h, uint16_t color)
Draw a vertical line.
void ST7735_Line(uint16_t x1, uint16_t y1, uint16_t x2, uint16_t y2, uint16_t color)
Draws line.
void ST7735_FillScreen(uint16_t color)
Fill the screen.
void ST7735_PlotLine(int32_t y)
Plot one line.
void ST7735_PlotNextErase(void)
Move X coordinate
void ST7735_OutChar(char ch)
Output a character.
void ST7735_uBinOut6(uint32_t n)
fixed point output resolution 1/64
void ST7735_OutUHex2(uint32_t n, int16_t textColor)
Output a 2-digit hexadecimal number.
void ST7735_DrawChar(int16_t x, int16_t y, char c, int16_t textColor, int16_t bgColor, uint8_t size)
Draw a character.
void ST7735_OutString(char *ptr)
Output a string.
void ST7735_SetCursor(uint32_t newX, uint32_t newY)
Move the cursor.
void ST7735_SetTextColor(uint16_t color)
sets the text color
uint32_t ST7735_DrawString(uint16_t x, uint16_t y, char *pt, int16_t textColor)
Draw a string.
void ST7735PlotIncrement(void)
Moves the plot cursor in time.
initRFlags
some flags for ST7735_InitR()
Definition: ST7735.h:132
void ST7735_DrawSmallCircle(int16_t x, int16_t y, uint16_t color)
Draw a small circle.
void ST7735_Drawaxes(uint16_t axisColor, uint16_t bgColor, char *xLabel, char *yLabel1, uint16_t label1Color, char *yLabel2, uint16_t label2Color, int32_t ymax, int32_t ymin)
Initializes a plot.
void ST7735_DrawPixel(int16_t x, int16_t y, uint16_t color)
Color one pixel.
void ST7735_DrawBitmap(int16_t x, int16_t y, const uint16_t *image, int16_t w, int16_t h)
Displays a BMP image.
void ST7735_XYplotInit(char *title, int32_t minX, int32_t maxX, int32_t minY, int32_t maxY)
initialize XY plot
void ST7735_InitPrintf(void)
use ST7735 LCD to output from printf
void ST7735_SetRotation(uint8_t m)
Change rotation.
void ST7735_OutUFix2_1(uint32_t n, int16_t textColor)
Output a 2-digit fixed-point decimal.
void ST7735_sDecOut2(int32_t n)
fixed point output resolution 0.01
uint16_t ST7735_SwapColor(uint16_t x)
Swaps red and blue.
void ST7735_SetX(int32_t newX)
set X-position
void ST7735_FillRect(int16_t x, int16_t y, int16_t w, int16_t h, uint16_t color)
Draw a filled rectangle.
void ST7735_PlotBar(int32_t y)
Plot one bar.
void ST7735_DrawCircle(int16_t x, int16_t y, uint16_t color)
Draw a circle.
void ST7735_OutUDec4(uint32_t n)
Output a 4-digit unsigned decimal.
void ST7735_InitB(void)
Initialize ST7735B LCD.
void ST7735_OutUDec5(uint32_t n)
Output a 5-digit unsigned decimal.
void ST7735_PlotPoints(int32_t y1, int32_t y2)
Plot two points.
void ST7735_PlotNext(void)
Move x-axis parameter.
void ST7735_XYplot(uint32_t num, int32_t bufX[], int32_t bufY[])
XY plot.
void ST7735_PlotClear(int32_t ymin, int32_t ymax)
Clear plot.