Tinkerkit LCD module not working over serial. Nothing on display.

So i have been working for 3 days trying to figure this out i took the Tinkerkit LCD Thermostat example and began to add-on to it to make it a functional thermostat. The problem is i would like to rig up a regular 5V relay to the arduino but the Built-in Leonardo function on the TKLCD won’t work because the power pin is always outputting 5vdc and the input pin which would be wired to an arduino pin on the tk shield. Is only output between 0.5 and 1vdc which is pretty useless. So if someone can figure out a way to fix the serial problem or have the input pin output 5volts would be great too.

Here is my code:

/**
* Simple Thermostat Example
*/

#include <LiquidCrystal.h>
#include <TKLCD.h>
#include <TinkerKit.h>
#include <Wire.h>


TKLCD_Serial lcd = TKLCD_Serial(); // when connecting to TKLCD over Serial
//TKLCD_Local lcd = TKLCD_Local(); // when programming a TKLCD module itself
//TKLCD_Twi lcd = TKLCD_Twi();
TKThermistor therm = TKThermistor(A0);
TKThermistor set = TKThermistor(A1);


void setup() {
  lcd.begin();
  
  lcd.clear();
}

void loop() {
  lcd.setBrightness(200);
  int temp = therm.readCelsius();
  int st = set.readCelsius();
  int relay = 11;
  int heat = 5;
  int cool = 6;
  int coolrelay =  10;
  lcd.home();
  lcd.print("TEMP: ");
  lcd.print(temp);
  lcd.print("C   ");
  lcd.setCursor(0,1);
  
 lcd.print("SET TEMP:");
 lcd.print(st);
 lcd.print("C    ");

lcd.setCursor(11,0);
pinMode(relay, OUTPUT);
pinMode(heat, INPUT);
pinMode(cool, INPUT);
pinMode(coolrelay, OUTPUT);
if ((st > temp) && (heat = HIGH))   {
    lcd.print("HEAT");
    digitalWrite(relay, HIGH); 
    digitalWrite(coolrelay, LOW); }
 
  else if ((temp > st) && (cool = HIGH)) {
    lcd.print("COOL");
    digitalWrite(relay, LOW); 
    
    digitalWrite(coolrelay, HIGH ); }
  


  
}

PS: Sorry for my laziness with paragraphs :stuck_out_tongue:

Hi,

Can you please post a copy of your circuit, in CAD or a picture of a hand drawn circuit in jpg, png?
And/Or a picture of your project, please.

I hope you are not trying to control a relay directly from the controller.

input pin which would be wired to an arduino pin on the tk shield. Is only output between 0.5 and 1vdc which is pretty useless.

An input pin cannot output.

Tom.... :slight_smile:

Sorry change of plans i have found another tinkerkit relay module with the 3pin connector in my junk.
But i would still like to use the tinkerkit lcd as a module not by itself becuase i would like to use my Uno with it.

How do i connect it over serial?

I have tried but the TX light on the UNO lights up but the TK LCD just sits and does nothing no RX light no thing on display.

I got my tinkerkit LCD module working with arduino uno like this:

connecting to the pins marked "SERIAL" which is the low left corner of the 9 connectors on the LCD module.

pin 1 - is TX. wire is white. connect it to TX (pin 1) on your Uno
pin 2 - is RX. wire is blue. connect to RX (pin 2) on your Uno (perhaps not needed)
pin 3 - is 5v. wire is red. connect to 5v on power side Uno connector
pin 4 - is ground. wire is green. connect to GND on power side Uno connector

after that i am able to write to the LCD in several different ways.

1 - open a terminal and type this:
def@brainiac:~$ dmesg | grep tty
[ 0.000000] console [tty0] enabled
[721528.083140] cdc_acm 3-1:1.0: ttyACM0: USB ACM device
plus a bunch more lines similar to previous.

2 - in the terminal type: screen /dev/ttyACM0
the terminal should go blank, and any typing you do should show on your LCD.

or

1 - open a terminal and type this:
def@brainiac:~$ echo "what you want to write" > /dev/ttyACM0

this should print 'what you want to write' onto the LCD.

or

you could use the arduino sketchpad - under tools > serial monitor.
the magnifying glass on the top right of the sketchpad also opens the serial monitor.