thermferm/lcd-buffer.c

changeset 420
644a6106d712
parent 418
0bfe08c7ba6e
child 422
13502d0dda65
equal deleted inserted replaced
419:8a7f8272516c 420:644a6106d712
1 /***************************************************************************** 1 /*****************************************************************************
2 * Copyright (C) 2014 2 * Copyright (C) 2014-2015
3 * 3 *
4 * Michiel Broek <mbroek at mbse dot eu> 4 * Michiel Broek <mbroek at mbse dot eu>
5 * 5 *
6 * This file is part of the mbsePi-apps 6 * This file is part of the mbsePi-apps
7 * 7 *
21 *****************************************************************************/ 21 *****************************************************************************/
22 22
23 #include "thermferm.h" 23 #include "thermferm.h"
24 #include "lcd-buffer.h" 24 #include "lcd-buffer.h"
25 #include "lcd-pcf8574.h" 25 #include "lcd-pcf8574.h"
26 #include "slcd.h"
26 #include "panel.h" 27 #include "panel.h"
27 28
28 29
29 int current_lines = 0; 30 int current_lines = 0;
30 int current_offset = 0; 31 int current_offset = 0;
31 lcd_rows *my_lcd_rows = NULL; 32 lcd_rows *my_lcd_rows = NULL;
32 33
33 extern int lcdHandle; 34 extern int lcdHandle;
35 extern int slcdHandle;
34 extern sys_config Config; 36 extern sys_config Config;
35 37
36 38
37 39
38 /* 40 /*
149 151
150 #ifdef HAVE_WIRINGPI_H 152 #ifdef HAVE_WIRINGPI_H
151 lcdPosition(lcdHandle, 0, r); 153 lcdPosition(lcdHandle, 0, r);
152 lcdPuts(lcdHandle, tmp->row); 154 lcdPuts(lcdHandle, tmp->row);
153 #endif 155 #endif
156 slcdPosition(slcdHandle, 0, r);
157 slcdPuts(slcdHandle, tmp->row);
154 158
155 r++; 159 r++;
156 if (r < Config.lcd_rows) { 160 if (r < Config.lcd_rows) {
157 if (tmp->next != NULL) 161 if (tmp->next != NULL)
158 tmp = tmp->next; 162 tmp = tmp->next;
160 tmp = my_lcd_rows; 164 tmp = my_lcd_rows;
161 #ifdef HAVE_WIRINGPI_H 165 #ifdef HAVE_WIRINGPI_H
162 lcdPosition(lcdHandle, 0, r); 166 lcdPosition(lcdHandle, 0, r);
163 lcdPuts(lcdHandle, tmp->row); 167 lcdPuts(lcdHandle, tmp->row);
164 #endif 168 #endif
169 slcdPosition(slcdHandle, 0, r);
170 slcdPuts(slcdHandle, tmp->row);
165 } 171 }
166 } 172 }
167 173
168 174

mercurial