summaryrefslogtreecommitdiff
path: root/bootloader/ondavx747.c
diff options
context:
space:
mode:
Diffstat (limited to 'bootloader/ondavx747.c')
-rw-r--r--bootloader/ondavx747.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/bootloader/ondavx747.c b/bootloader/ondavx747.c
index a3a3571ac4..8dd957eca5 100644
--- a/bootloader/ondavx747.c
+++ b/bootloader/ondavx747.c
@@ -160,7 +160,11 @@ int main(void)
160#endif 160#endif
161 while(1) 161 while(1)
162 { 162 {
163#ifdef ONDA_VX747
163 btn = button_read_device(&touch); 164 btn = button_read_device(&touch);
165#else
166 btn = button_read_device();
167#endif
164#define KNOP(x,y) lcd_set_foreground(LCD_BLACK); \ 168#define KNOP(x,y) lcd_set_foreground(LCD_BLACK); \
165 if(btn & x) \ 169 if(btn & x) \
166 lcd_set_foreground(LCD_WHITE); \ 170 lcd_set_foreground(LCD_WHITE); \
@@ -184,6 +188,7 @@ int main(void)
184 { 188 {
185 power_off(); 189 power_off();
186 } 190 }
191#ifdef ONDA_VX747
187 if(btn & BUTTON_TOUCH) 192 if(btn & BUTTON_TOUCH)
188 { 193 {
189 lcd_set_foreground(LCD_RGBPACK(touch & 0xFF, (touch >> 8)&0xFF, (touch >> 16)&0xFF)); 194 lcd_set_foreground(LCD_RGBPACK(touch & 0xFF, (touch >> 8)&0xFF, (touch >> 16)&0xFF));
@@ -191,6 +196,7 @@ int main(void)
191 lcd_update(); 196 lcd_update();
192 lcd_set_foreground(LCD_WHITE); 197 lcd_set_foreground(LCD_WHITE);
193 } 198 }
199#endif
194 snprintf(datetime, 30, "%02d/%02d/%04d %02d:%02d:%02d", get_time()->tm_mday, get_time()->tm_mon, get_time()->tm_year, 200 snprintf(datetime, 30, "%02d/%02d/%04d %02d:%02d:%02d", get_time()->tm_mday, get_time()->tm_mon, get_time()->tm_year,
195 get_time()->tm_hour, get_time()->tm_min, get_time()->tm_sec); 201 get_time()->tm_hour, get_time()->tm_min, get_time()->tm_sec);
196 lcd_putsxy(LCD_WIDTH-SYSFONT_WIDTH*strlen(datetime), LCD_HEIGHT-SYSFONT_HEIGHT, datetime); 202 lcd_putsxy(LCD_WIDTH-SYSFONT_WIDTH*strlen(datetime), LCD_HEIGHT-SYSFONT_HEIGHT, datetime);