Revision history for reportOnDisplay


Revision [264]

Last edited on 2015-10-03 23:11:06 by AdminUser
Additions:
======reportOnDisplay======
/// www.officinecibernetiche.net
// Display some datas on display
// usage: displayMessages(column, row, message)
void reportOnDisplay() //SOSTITUIRE LE VARIABILI GLOBALI CON ALTRE LOCALI
String message1;
String message2;
String message3;
String message4;
int str_len;
char* date = get_date();
char* time = get_time();
Serial.println(temper);
Serial.println(hum);
Serial.println(TH_char_array);
message1 = "Date: "; message1 += date;
//str_len = message1.length() + 1;
message1.toCharArray(char_array1, 18);
displayMessages(0, 10, char_array1);
message2 = "Time: "; message2 += time;
//str_len = message2.length() + 1;
message2.toCharArray(char_array2, 18);
displayMessages(0, 30, char_array2);
message3 = "Temp: "; message3 += Temperatura; message3 += " ^C";
message3.toCharArray(char_array3, 18);
displayMessages(0, 50, char_array3);
message4 = "Humi: "; message4 += Umidita; message4 += " %";
message4.toCharArray(char_array4, 18);
displayMessages(0, 60, char_array4);
Deletions:
======display_18======
// www.officinecibernetiche.net
/******************************
* displayMessages *
******************************/
void displayMessages(int X, int Y, const char* message)
/* La visualizzazione su display รจ relativamente lenta.
Usare solo per processi non ripetitivi e in condizioni di
navigazione sicura (lontano da ostacoli o a robot fermo).
*/
//Serial.println(message); // Togliere. Qui si blocca se non presente il TFT
// set negative value to use tft.print
if (X >= 0 && Y >= 0)
{
tft.setCursor(X, Y);
}
tft.println(message);
return;
// DISPLAY 1.8" TFT
void display_Setup()
Serial.println("Initializing Display");
logEvent2SD("Initializing Display"); // log event on SD card
digitalWrite(TFT_RST, HIGH); // reset off
tft.initR(INITR_BLACKTAB); // initialize a ST7735S chip, black tab
tft.setTextSize(1); // normal heigth (small)
tft.setTextWrap(true);
tft.setCursor(0, 0);
logEvent2SD("Display ready"); // log event on SD card
displayMessages(-1, -1, "1. Display ready");


Revision [263]

The oldest known version of this page was created on 2015-10-03 23:10:45 by AdminUser
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki