?? lcddriver.h
字號:
/***************************************************************************** * * MODULE: Driver for LCD Driver-Controller * * COMPONENT: $RCSfile: LcdDriver.h,v $ * * VERSION: $Name: zed003_cd $ * * REVISION: $Revision: 1.7 $ * * DATED: $Date: 2006/02/16 13:52:36 $ * * STATUS: $State: Exp $ * * AUTHOR: CJG * * DESCRIPTION: * Provides API for driving LCD panels using LCD Driver-Controller. * * LAST MODIFIED BY: $Author: cjg $ * $Modtime: $ * **************************************************************************** * * (c) Copyright JENNIC Ltd 2006 * ****************************************************************************/#ifndef LCD_DRIVER_INCLUDED#define LCD_DRIVER_INCLUDED#if defined __cplusplusextern "C" {#endif/****************************************************************************//*** Include Files ***//****************************************************************************/#include "jendefs.h"/****************************************************************************//*** Macro Definitions ***//****************************************************************************/#define LCD_SS (1)#define LCD_SS_MASK (1 << LCD_SS)#define LCD_CD_BIT_MASK (1 << 1)#define LCD_RST_BIT_MASK (1 << 2)#define LCD_DIO_BIT_MASK (LCD_CD_BIT_MASK | LCD_RST_BIT_MASK)/****************************************************************************//*** Type Definitions ***//****************************************************************************/typedef struct{ /* Bitmap can be any number of columns but a multiple of eight bits high, will be aligned to a character row when displayed and is as follows: column 0 1 2 y-1 row 0 aa ab ac .. ax row 1 ba bb bc .. bx row 2 ca cb cc .. cx .. .. .. .. .. row 7 ha hb hc .. hx row 8 ia ib ic .. ix row 9 ja jb jc .. jx .. .. .. .. .. row 15 pa pb pc .. px pu8Bitmap[0] = (MSB) ha ga fa ea da ca ba aa (LSB) pu8Bitmap[1] = (MSB) hb gb fb eb db cb bb ab (LSB) pu8Bitmap[y-1] = (MSB) hx gx fx ex dx cx bx ax (LSB) pu8Bitmap[y] = (MSB) pa oa na ma la ka ja ia (LSB) */ uint8 *pu8Bitmap; uint8 u8Width; /* Width in pixels (y in example above) */ uint8 u8Height; /* Height in character rows (2 in example above) */} tsBitmap;/****************************************************************************//*** Exported Functions ***//****************************************************************************/PUBLIC void vLcdResetDefault(void);PUBLIC void vLcdReset(uint8 u8Bias, uint8 u8Gain);PUBLIC void vLcdStop(void);PUBLIC void vLcdClear(void);PUBLIC void vLcdRefreshAll(void);PUBLIC void vLcdRefreshArea(uint8 u8LeftColumn, uint8 u8TopRow, uint8 u8Width, uint8 u8Height);PUBLIC void vLcdWriteText(char *pcString, uint8 u8Row, uint8 u8Column);PUBLIC void vLcdWriteTextRightJustified(char *pcString, uint8 u8Row, uint8 u8EndColumn);PUBLIC void vLcdWriteInvertedText(char *pcString, uint8 u8Row, uint8 u8Column);PUBLIC void vLcdWriteBitmap(tsBitmap *psBitmap, uint8 u8LeftColumn, uint8 u8TopRow);PUBLIC void vLcdScrollUp(uint8 u8Row);PUBLIC void vLcdClearLine(uint8 u8Row);PUBLIC void vLcdWriteTextToClearLine(char *pcString, uint8 u8Row, uint8 u8Column);/****************************************************************************//*** Exported Variables ***//****************************************************************************/PUBLIC uint8 au8Shadow[1024];#if defined __cplusplus}#endif#endif /* LCD_DRIVER_INCLUDED *//****************************************************************************//*** END OF FILE ***//****************************************************************************/
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -