Console Serial IO con display OLED e seriale asincrona
Dependencies: mbed BufferedSerial AserialIOFuncLib SSD1306 TerminalPlusV2
Fork of SerialIO by
Console Serial IO con display OLED e seriale asincrona
Diff: Functions.h
- Revision:
- 31:abff828992d7
- Parent:
- 29:bfb815540de7
- Child:
- 32:b7859f48942a
--- a/Functions.h Wed Sep 16 00:08:36 2015 +0000 +++ b/Functions.h Sat Sep 19 01:08:34 2015 +0000 @@ -31,11 +31,11 @@ funcnum=strIn.substr(1,1); param=strIn.substr(2,3); //write param - term.formatPrintf(fnzAdd.string2char(fnzAdd.addEOS(func)),2,8,15); - term.formatPrintf(fnzAdd.string2char(fnzAdd.addEOS(funcnum)),22,8,15); - term.formatPrintf(fnzAdd.string2char(fnzAdd.addEOS(param)),42,8,15); + term.formatPrintf(fnzAdd.string2char(fnzAdd.addEOS(func)),11,4,10); + term.formatPrintf(fnzAdd.string2char(fnzAdd.addEOS(funcnum)),39,4,10); + term.formatPrintf(fnzAdd.string2char(fnzAdd.addEOS(param)),61,4,10); //write input string - term.formatPrintf(fnzAdd.string2char(strIn),2,16,20); + term.formatPrintf(fnzAdd.string2char(strIn),21,10,10); //term.formatPrintf(((char*)func.c_str() ,02,07); funziona anche cosi' //extra serial output (output reale su arduino default true) @@ -58,16 +58,16 @@ if (func=="l") { if (funcnum=="1") { if (param=="on ") { - term.formatPrintf("ON \n",2,13,3); - term.formatPrintf("Led ACCESO \n",42,16,99); + term.formatPrintf("ON \n",21,6,3); + term.formatPrintf("Led ACCESO \n",61,6,99); if (realExtraSerial==false) ardser.printf("\nLed ACCESO \n\r"); printDisp(dispType,"Led ACCESO \n\r"); led.onOff(1); //Accende il led errp=0; } if (param=="off") { - term.formatPrintf("OFF \n",2,13); - term.formatPrintf("Led SPENTO! \n",42,16,99); + term.formatPrintf("OFF \n",21,6,3); + term.formatPrintf("Led SPENTO! \n",61,6,99); if (realExtraSerial==false) ardser.printf("\nLed SPENTO! \n\r"); printDisp(dispType,"Led SPENTO \n\r"); led.onOff(0); //Spegne il led @@ -134,11 +134,11 @@ funcnum=strIn.substr(1,1); param=strIn.substr(2,3); //write param - term.formatPrintf(fnzAdd.string2char(fnzAdd.addEOS(func)),2,8,15); - term.formatPrintf(fnzAdd.string2char(fnzAdd.addEOS(funcnum)),22,8,15); + term.formatPrintf(fnzAdd.string2char(fnzAdd.addEOS(func)),2,8,10); + term.formatPrintf(fnzAdd.string2char(fnzAdd.addEOS(funcnum)),22,8,10); term.formatPrintf(fnzAdd.string2char(fnzAdd.addEOS(param)),42,8,15); //write input string - term.formatPrintf(fnzAdd.string2char(strIn),2,16,20); + term.formatPrintf(fnzAdd.string2char(strIn),20,10,10); //term.formatPrintf((char*)func.c_str() ,02,07); funziona anche cosi' //extra serial output (output reale su arduino default true) @@ -226,7 +226,7 @@ string strIn = string(stringa); strIn=fnzAdd.addEOS(strIn); //ardser.printf(strIn+" \n\r"); - term.formatPrintf(fnzAdd.string2char(strIn),2,20,20); + term.formatPrintf(fnzAdd.string2char(strIn),2,21,2); term.readypos(); }