Functions | |
s32 | BUFLCD_Init (u32 mode) |
s32 | BUFLCD_MaxBufferGet (void) |
s32 | BUFLCD_DeviceNumXSet (u8 num_x) |
s32 | BUFLCD_DeviceNumXGet (void) |
s32 | BUFLCD_DeviceNumYSet (u8 num_y) |
s32 | BUFLCD_DeviceNumYGet (void) |
s32 | BUFLCD_DeviceWidthSet (u8 width) |
s32 | BUFLCD_DeviceWidthGet (void) |
s32 | BUFLCD_DeviceHeightSet (u8 height) |
s32 | BUFLCD_DeviceHeightGet (void) |
s32 | BUFLCD_DeviceFontHandlingEnabled (void) |
s32 | BUFLCD_OffsetXSet (u8 offset) |
s32 | BUFLCD_OffsetXGet (void) |
s32 | BUFLCD_OffsetYSet (u8 offset) |
s32 | BUFLCD_OffsetYGet (void) |
s32 | BUFLCD_BufferGet (char *str, u8 line, u8 len) |
s32 | BUFLCD_Clear (void) |
s32 | BUFLCD_FontInit (u8 *font) |
s32 | BUFLCD_PrintChar (char c) |
s32 | BUFLCD_CursorSet (u16 column, u16 line) |
s32 | BUFLCD_Update (u8 force) |
s32 | BUFLCD_PrintString (char *str) |
s32 | BUFLCD_PrintFormattedString (char *format,...) |
s32 | BUFLCD_PrintSpaces (int num) |
s32 | BUFLCD_PrintStringPadded (char *str, u32 width) |
Buffered LCD output driver
This module provides similar functions like MIOS32_LCD, but characters are not print immediately. Instead, they will be buffered.
This method has the advantage, that multiple tasks can write to the LCD without accessing the IO pins or the requirement for semaphores (to save time)
Only changed characters (marked with flag 7 of each buffer byte) will be transfered to the LCD. This greatly improves performance as well, especially if a graphical display is connected.
Another advantage: LCD access works independent from the physical dimension of the LCDs. E.g. two 2x40 LCDs can be combined to one large 2x80 display, and BUFLCD_Update() function will take care for switching between the devices and setting the cursor.
BUFLCD_Update() has to be called periodically from a low-priority task!
Usage examples:
$MIOS32_PATH/apps/controllers/midibox_lc
$MIOS32_PATH/apps/controllers/midibox_mm
copies the current LCD buffer line into the output string
s32 BUFLCD_Clear | ( | void | ) |
clears the buffer
s32 BUFLCD_DeviceFontHandlingEnabled | ( | void | ) |
s32 BUFLCD_DeviceHeightGet | ( | void | ) |
s32 BUFLCD_DeviceNumXGet | ( | void | ) |
sets the number of devices which are combined to a single line
s32 BUFLCD_DeviceNumYGet | ( | void | ) |
s32 BUFLCD_DeviceWidthGet | ( | void | ) |
selects a font for GLCD (only works with BUFLCD_SUPPORT_GLCD_FONTS)
s32 BUFLCD_MaxBufferGet | ( | void | ) |
max. number of characters depends on GLCD and BUFLCD_SUPPORT_GLCD_FONTS
s32 BUFLCD_OffsetXGet | ( | void | ) |
returns the first column at which a line is print
s32 BUFLCD_OffsetYGet | ( | void | ) |
returns the first column at which characters are print
s32 BUFLCD_PrintChar | ( | char | c | ) |
prints char into buffer and increments cursor
s32 BUFLCD_PrintFormattedString | ( | char * | format, | |
... | ||||
) |
prints a formatted string
s32 BUFLCD_PrintSpaces | ( | int | num | ) |
prints <num> spaces
s32 BUFLCD_PrintString | ( | char * | str | ) |
prints a string
prints padded string replacement for not supported "%:-40s" of simple sprintf function