Convenience routines for an I"C connected LCD display. Handy things like taking cursor to home, positioning cursor, clearing display, writing strings etc

Dependents:   gu_squirt_tester

Revision:
3:5744bf6006e1
Parent:
2:5b220477045b
Child:
4:ce867009531a
--- a/jtlcd.cpp	Thu Nov 08 06:12:34 2012 +0000
+++ b/jtlcd.cpp	Fri Nov 09 09:36:36 2012 +0000
@@ -279,6 +279,23 @@
 } 
 
 /*==============================================================*/
+/* Writes to LCD and fills rest of line with space                      */
+/*==============================================================*/
+void LcdWriteTextAndFill(char *text, int numb) 
+{ 
+ 
+ int length = strlen(text);
+ int diff = numb -length;
+    LcdWriteText(text);
+    if (diff >0)
+    {
+        for (int n=0; n <= diff; n++)
+            LcdWriteText(" ");
+    
+    }
+} 
+
+/*==============================================================*/
 /* attemp at lcdlcdprintf                       */
 /*==============================================================*/