implement display update function for lcd menu

This commit is contained in:
Mario Hüttel 2020-06-09 22:50:20 +02:00
parent 7db5f02067
commit 917497e7e4

View File

@ -19,3 +19,24 @@
*/ */
#include <reflow-controller/lcd-menu.h> #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;
}