implement display update function for lcd menu
This commit is contained in:
parent
7db5f02067
commit
917497e7e4
@ -19,3 +19,24 @@
|
||||
*/
|
||||
|
||||
#include <reflow-controller/lcd-menu.h>
|
||||
#include <reflow-controller/ui/menu.h>
|
||||
#include <reflow-controller/ui/lcd.h>
|
||||
|
||||
static char display_buffer[4][21] = {0};
|
||||
|
||||
static void update_display_buffer(uint8_t row, const char *data)
|
||||
{
|
||||
int i;
|
||||
|
||||
if (row > 4)
|
||||
return;
|
||||
if (!data)
|
||||
return;
|
||||
|
||||
for (i = 0; data[i] && i < LCD_CHAR_WIDTH; i++) {
|
||||
display_buffer[row][i] = data[i];
|
||||
}
|
||||
|
||||
display_buffer[row][i] = 0;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user