Cleaning up Serial Print to LCDs


one of final obsticles project cleaning code , encapsulating serial prints lcd if change out lcd, minimal modification required.

i.e.  the right way it.

i have tried , im not getting errors on compile arduino locking in random places. well, random meaning during print function different ones. have different print functions handling strings , ints.  i reset code old here functions used, wokred of time......

code: [select]

void clssendstring(string message){ cls(); myserial.print(message); }    //clear screen send message lcd
void sendstring(string message){ myserial.print(message); }              //send message lcd
void clssendint(int integer){ cls(); myserial.print(integer); }         //clear screen adn send integer lcd
void sendint(int integer){ myserial.print(integer); }                //send integer lcd  
void cls(){ myserial.print("?f"); }                                         //clear screen
void line1(){ myserial.print("?x00?y0"); }                               //move cursor line 1
void line2(){ myserial.print("?x00?y1"); }                               //move cursor line 2


any obvious mistakes here? there basic guidelines follow here?  seems simple enough...i think int wouldn't print along lockup issue.  i try clean code , start break it............



Arduino Forum > Forum 2005-2010 (read only) > Software > Syntax & Programs > Cleaning up Serial Print to LCDs


arduino

Comments

Popular posts from this blog

CAN'T INSTALL MAMBELFISH 1.5 FROM DIRECTORY - Joomla! Forum - community, help and support

error: expected initializer before 'void'

CPU load monitoring using GPIO and leds - Raspberry Pi Forums