WILLY BAYOT / stm32_adafruit

Dependents:   TDEMNucleo

Embed: (wiki syntax)

« Back to documentation index

STM32_ADAFRUIT_LCD_Private_Functions

STM32_ADAFRUIT_LCD_Private_Functions
[STM32_ADAFRUIT_LCD]

Functions

uint8_t BSP_LCD_Init (void)
 Initializes the LCD.
uint32_t BSP_LCD_GetXSize (void)
 Gets the LCD X size.
uint32_t BSP_LCD_GetYSize (void)
 Gets the LCD Y size.
uint16_t BSP_LCD_GetTextColor (void)
 Gets the LCD text color.
uint16_t BSP_LCD_GetBackColor (void)
 Gets the LCD background color.
void BSP_LCD_SetTextColor (uint16_t Color)
 Sets the LCD text color.
void BSP_LCD_SetBackColor (uint16_t Color)
 Sets the LCD background color.
void BSP_LCD_SetFont (sFONT *pFonts)
 Sets the LCD text font.
sFONT * BSP_LCD_GetFont (void)
 Gets the LCD text font.
void BSP_LCD_Clear (uint16_t Color)
 Clears the hole LCD.
void BSP_LCD_ClearStringLine (uint16_t Line)
 Clears the selected line.
void BSP_LCD_DisplayChar (uint16_t Xpos, uint16_t Ypos, uint8_t Ascii)
 Displays one character.
void BSP_LCD_DisplayStringAt (uint16_t Xpos, uint16_t Ypos, uint8_t *Text, Line_ModeTypdef Mode)
 Displays characters on the LCD.
void BSP_LCD_DisplayStringAtLine (uint16_t Line, uint8_t *ptr)
 Displays a character on the LCD.
void BSP_LCD_DrawPixel (uint16_t Xpos, uint16_t Ypos, uint16_t RGB_Code)
 Draws a pixel on LCD.
void BSP_LCD_DrawHLine (uint16_t Xpos, uint16_t Ypos, uint16_t Length)
 Draws an horizontal line.
void BSP_LCD_DrawVLine (uint16_t Xpos, uint16_t Ypos, uint16_t Length)
 Draws a vertical line.
void BSP_LCD_DrawLine (uint16_t x1, uint16_t y1, uint16_t x2, uint16_t y2)
 Draws an uni-line (between two points).
void BSP_LCD_DrawRect (uint16_t Xpos, uint16_t Ypos, uint16_t Width, uint16_t Height)
 Draws a rectangle.
void BSP_LCD_DrawCircle (uint16_t Xpos, uint16_t Ypos, uint16_t Radius)
 Draws a circle.
void BSP_LCD_DrawPolygon (pPoint Points, uint16_t PointCount)
 Draws an poly-line (between many points).
void BSP_LCD_DrawEllipse (int Xpos, int Ypos, int XRadius, int YRadius)
 Draws an ellipse on LCD.
void BSP_LCD_FillRect (uint16_t Xpos, uint16_t Ypos, uint16_t Width, uint16_t Height)
 Draws a full rectangle.
void BSP_LCD_FillCircle (uint16_t Xpos, uint16_t Ypos, uint16_t Radius)
 Draws a full circle.
void BSP_LCD_FillPolygon (pPoint Points, uint16_t PointCount)
 Draws a full poly-line (between many points).
void BSP_LCD_FillEllipse (int Xpos, int Ypos, int XRadius, int YRadius)
 Draws a full ellipse.
void BSP_LCD_DisplayOn (void)
 Enables the display.
void BSP_LCD_DisplayOff (void)
 Disables the display.
static void DrawChar (uint16_t Xpos, uint16_t Ypos, const uint8_t *c)
 Draws a character on LCD.
static void FillTriangle (uint16_t x1, uint16_t x2, uint16_t x3, uint16_t y1, uint16_t y2, uint16_t y3)
 Fills a triangle (between 3 points).

Function Documentation

void BSP_LCD_Clear ( uint16_t  Color )

Clears the hole LCD.

Parameters:
Color,:Color of the background
Return values:
None

Definition at line 246 of file stm32_adafruit_lcd.c.

void BSP_LCD_ClearStringLine ( uint16_t  Line )

Clears the selected line.

Parameters:
Line,:Line to be cleared This parameter can be one of the following values:

  • 0..9: if the Current fonts is Font16x24
  • 0..19: if the Current fonts is Font12x12 or Font8x12
  • 0..29: if the Current fonts is Font8x8
Return values:
None

Definition at line 269 of file stm32_adafruit_lcd.c.

void BSP_LCD_DisplayChar ( uint16_t  Xpos,
uint16_t  Ypos,
uint8_t  Ascii 
)

Displays one character.

Parameters:
Xpos,:Start column address
Ypos,:Line where to display the character shape.
Ascii,:Character ascii code This parameter must be a number between Min_Data = 0x20 and Max_Data = 0x7E
Return values:
None

Definition at line 289 of file stm32_adafruit_lcd.c.

void BSP_LCD_DisplayOff ( void   )

Disables the display.

Parameters:
None
Return values:
None

Definition at line 824 of file stm32_adafruit_lcd.c.

void BSP_LCD_DisplayOn ( void   )

Enables the display.

Parameters:
None
Return values:
None

Definition at line 814 of file stm32_adafruit_lcd.c.

void BSP_LCD_DisplayStringAt ( uint16_t  Xpos,
uint16_t  Ypos,
uint8_t *  Text,
Line_ModeTypdef  Mode 
)

Displays characters on the LCD.

Parameters:
Xpos,:X position (in pixel)
Ypos,:Y position (in pixel)
Text,:Pointer to string to display on LCD
Mode,:Display mode This parameter can be one of the following values:

  • CENTER_MODE
  • RIGHT_MODE
  • LEFT_MODE
Return values:
None

Definition at line 307 of file stm32_adafruit_lcd.c.

void BSP_LCD_DisplayStringAtLine ( uint16_t  Line,
uint8_t *  ptr 
)

Displays a character on the LCD.

Parameters:
Line,:Line where to display the character shape This parameter can be one of the following values:

  • 0..19: if the Current fonts is Font8
  • 0..12: if the Current fonts is Font12
  • 0...9: if the Current fonts is Font16
  • 0...7: if the Current fonts is Font20
  • 0...5: if the Current fonts is Font24
ptr,:Pointer to string to display on LCD
Return values:
None

Definition at line 368 of file stm32_adafruit_lcd.c.

void BSP_LCD_DrawCircle ( uint16_t  Xpos,
uint16_t  Ypos,
uint16_t  Radius 
)

Draws a circle.

Parameters:
Xpos,:X position
Ypos,:Y position
Radius,:Circle radius
Return values:
None

Definition at line 537 of file stm32_adafruit_lcd.c.

void BSP_LCD_DrawEllipse ( int  Xpos,
int  Ypos,
int  XRadius,
int  YRadius 
)

Draws an ellipse on LCD.

Parameters:
Xpos,:X position
Ypos,:Y position
XRadius,:Ellipse X radius
YRadius,:Ellipse Y radius
Return values:
None

Definition at line 615 of file stm32_adafruit_lcd.c.

void BSP_LCD_DrawHLine ( uint16_t  Xpos,
uint16_t  Ypos,
uint16_t  Length 
)

Draws an horizontal line.

Parameters:
Xpos,:X position
Ypos,:Y position
Length,:Line length
Return values:
None

Definition at line 395 of file stm32_adafruit_lcd.c.

void BSP_LCD_DrawLine ( uint16_t  x1,
uint16_t  y1,
uint16_t  x2,
uint16_t  y2 
)

Draws an uni-line (between two points).

Parameters:
x1,:Point 1 X position
y1,:Point 1 Y position
x2,:Point 2 X position
y2,:Point 2 Y position
Return values:
None

Definition at line 444 of file stm32_adafruit_lcd.c.

void BSP_LCD_DrawPixel ( uint16_t  Xpos,
uint16_t  Ypos,
uint16_t  RGB_Code 
)

Draws a pixel on LCD.

Parameters:
Xpos,:X position
Ypos,:Y position
RGB_Code,:Pixel color in RGB mode (5-6-5)
Return values:
None

Definition at line 380 of file stm32_adafruit_lcd.c.

void BSP_LCD_DrawPolygon ( pPoint  Points,
uint16_t  PointCount 
)

Draws an poly-line (between many points).

Parameters:
Points,:Pointer to the points array
PointCount,:Number of points
Return values:
None

Definition at line 587 of file stm32_adafruit_lcd.c.

void BSP_LCD_DrawRect ( uint16_t  Xpos,
uint16_t  Ypos,
uint16_t  Width,
uint16_t  Height 
)

Draws a rectangle.

Parameters:
Xpos,:X position
Ypos,:Y position
Width,:Rectangle width
Height,:Rectangle height
Return values:
None

Definition at line 519 of file stm32_adafruit_lcd.c.

void BSP_LCD_DrawVLine ( uint16_t  Xpos,
uint16_t  Ypos,
uint16_t  Length 
)

Draws a vertical line.

Parameters:
Xpos,:X position
Ypos,:Y position
Length,:Line length
Return values:
None

Definition at line 419 of file stm32_adafruit_lcd.c.

void BSP_LCD_FillCircle ( uint16_t  Xpos,
uint16_t  Ypos,
uint16_t  Radius 
)

Draws a full circle.

Parameters:
Xpos,:X position
Ypos,:Y position
Radius,:Circle radius
Return values:
None

Definition at line 666 of file stm32_adafruit_lcd.c.

void BSP_LCD_FillEllipse ( int  Xpos,
int  Ypos,
int  XRadius,
int  YRadius 
)

Draws a full ellipse.

Parameters:
Xpos,:X position
Ypos,:Y position
XRadius,:Ellipse X radius
YRadius,:Ellipse Y radius
Return values:
None

Definition at line 783 of file stm32_adafruit_lcd.c.

void BSP_LCD_FillPolygon ( pPoint  Points,
uint16_t  PointCount 
)

Draws a full poly-line (between many points).

Parameters:
Points,:Pointer to the points array
PointCount,:Number of points
Return values:
None

Definition at line 714 of file stm32_adafruit_lcd.c.

void BSP_LCD_FillRect ( uint16_t  Xpos,
uint16_t  Ypos,
uint16_t  Width,
uint16_t  Height 
)

Draws a full rectangle.

Parameters:
Xpos,:X position
Ypos,:Y position
Width,:Rectangle width
Height,:Rectangle height
Return values:
None

Definition at line 649 of file stm32_adafruit_lcd.c.

uint16_t BSP_LCD_GetBackColor ( void   )

Gets the LCD background color.

Parameters:
None
Return values:
Usedbackground color

Definition at line 196 of file stm32_adafruit_lcd.c.

sFONT* BSP_LCD_GetFont ( void   )

Gets the LCD text font.

Parameters:
None
Return values:
Usedfont

Definition at line 236 of file stm32_adafruit_lcd.c.

uint16_t BSP_LCD_GetTextColor ( void   )

Gets the LCD text color.

Parameters:
None
Return values:
Usedtext color.

Definition at line 186 of file stm32_adafruit_lcd.c.

uint32_t BSP_LCD_GetXSize ( void   )

Gets the LCD X size.

Parameters:
None
Return values:
UsedLCD X size

Definition at line 166 of file stm32_adafruit_lcd.c.

uint32_t BSP_LCD_GetYSize ( void   )

Gets the LCD Y size.

Parameters:
None
Return values:
UsedLCD Y size

Definition at line 176 of file stm32_adafruit_lcd.c.

uint8_t BSP_LCD_Init ( void   )

Initializes the LCD.

Parameters:
None
Return values:
LCDstate

Definition at line 136 of file stm32_adafruit_lcd.c.

void BSP_LCD_SetBackColor ( uint16_t  Color )

Sets the LCD background color.

Parameters:
Color,:Background color code RGB(5-6-5)
Return values:
None

Definition at line 216 of file stm32_adafruit_lcd.c.

void BSP_LCD_SetFont ( sFONT *  pFonts )

Sets the LCD text font.

Parameters:
fonts,:Font to be used
Return values:
None

Definition at line 226 of file stm32_adafruit_lcd.c.

void BSP_LCD_SetTextColor ( uint16_t  Color )

Sets the LCD text color.

Parameters:
Color,:Text color code RGB(5-6-5)
Return values:
None

Definition at line 206 of file stm32_adafruit_lcd.c.

static void DrawChar ( uint16_t  Xpos,
uint16_t  Ypos,
const uint8_t *  c 
) [static]

Draws a character on LCD.

Parameters:
Xpos,:Line where to display the character shape
Ypos,:Start column address
c,:Pointer to the character data
Return values:
None

Definition at line 840 of file stm32_adafruit_lcd.c.

static void FillTriangle ( uint16_t  x1,
uint16_t  x2,
uint16_t  x3,
uint16_t  y1,
uint16_t  y2,
uint16_t  y3 
) [static]

Fills a triangle (between 3 points).

Parameters:
Points,:Pointer to the points array
x1,:Point 1 X position
y1,:Point 1 Y position
x2,:Point 2 X position
y2,:Point 2 Y position
x3,:Point 3 X position
y3,:Point 3 Y position
Return values:
None

Definition at line 899 of file stm32_adafruit_lcd.c.