thermferm/lcd-pcf8574.c

changeset 213
2317b8d644fa
parent 106
1bd9a16f5061
child 223
14700edd2a67
--- a/thermferm/lcd-pcf8574.c	Sun Aug 10 20:01:17 2014 +0200
+++ b/thermferm/lcd-pcf8574.c	Sun Aug 10 21:22:17 2014 +0200
@@ -39,7 +39,10 @@
     int dataPins [8] ;
     int cx, cy ;
 };
+
 extern struct lcdDataStruct	*lcds [MAX_LCDS];
+extern sys_config       	Config;
+
 
 
 /*
@@ -95,8 +98,8 @@
     }
 
     lcdClear (lcdHandle) ;
-    for (x = 0; x < 20; x++)
-	for (y = 0; y < 4; y++)
+    for (x = 0; x < Config.lcd_cols; x++)
+	for (y = 0; y < Config.lcd_rows; y++)
 	    lcdbuf[lcdHandle][x][y] = ' ';
 
     setBacklight (1) ;
@@ -133,8 +136,8 @@
     int	x, y;
 
     lcdClear(fd);
-    for (x = 0; x < 20; x++)
-	for (y = 0; y < 4; y++)
+    for (x = 0; x < Config.lcd_cols; x++)
+	for (y = 0; y < Config.lcd_rows; y++)
 	    lcdbuf[fd][x][y] = ' ';
 }
 

mercurial