Go Down

Topic: Iteadstudio 16X2 Serial LCD Problem (Read 1 time) previous topic - next topic


Apr 12, 2013, 11:48 pm Last Edit: Apr 12, 2013, 11:50 pm by SYNC3D Reason: 1
Hi there guys.

Okay let me explain my problem. I've got myself the Iteadstudio 16X2 Serial LCD today which I will be using on my Weather Station project. The project itself is going great and I got it to work with the LCD1602 KeyShield 2.0. Due to the the amount of pins the Shield uses, I decided to go for the IdeadStudio 16X2 Serial LCD which only uses 2 pins which appealed to me.

I got the screen to work and it is showing whatever I am sending to it, my problem is I don't know how to send the value of a ever changing variable to it. To send text to the screen you need to use Serial.print("ssSample text;"); unlike the shield which uses lcd.print("Sample text");. Now I've got a variable celsius which obviously changes from time to time and to print that to the screen on the shield I would just use lcd.print(celsius); but I've looked all over the internet but can't seem to find a way to do that with the SerialLCD.

Hope I explained my problem well enough here.



What about Serial.print(celsius);?


Try this. Should work. It's just a part of the code.

  int h = DHT11.humidity; //integerValue;
  char sh[1]; // maximun number
  sprintf(sh, "ss%d;", h); // Integer conversion and string format
  myLcdSerial.print("sd0,0;"); //set coordinate (col 0,row 2)
  myLcdSerial.print(sh); // Command IteadStudio for 'send string'

Go Up

Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

via Egeo 16
Torino, 10131