Hi Folks,
I am new to the world of Arduino but absolutly love the concept of it

I got a Sensor Kit and Uno from ebay which contained a DHT11, LM35 and LCD 16,2.
I downloaded some sample code for a similar kit with the additions of light & Tilt and adapted that code as far as i could, I have got the values displayed on the LCD but they are not refreshing.
I have had a good read of many forum posts but cant seem to find the solution.
heres the adapted code
/////////////////////////////////////////////
// This demo code uses 4 different sensors and an LCD module
// to demonstrate reading a displaying continuous sensor data.
// Data is read from a mechanical tilt sensor to show FLAT or TILT
// An LDR is used to measure light level and is roughly converted to Lux
// A DHT11 is used to measure Humidity in %RH
// Finally an LM35 is used to measure temperature in degress C
//
// This code may be freely used and copied.
//
// Gareth Davies - June 2012
//
////////////////////////////////////////////////
#include <LiquidCrystal.h>
#include <dht11.h>
LiquidCrystal lcd(12, 11, 5, 4, 3, 2);
int temp, humidity, hCheck;
#define tempPin 1
#define humidityPin 6
dht11 DHT11;
// initialise LCD library and pins
void setup() {
lcd.begin(16, 2);
pinMode(humidityPin, INPUT);
pinMode(tempPin, INPUT);
}
void loop()
{
temp = (5.0 * analogRead(tempPin) * 100.0) / 1024;
delay(10);
hCheck = DHT11.read(humidityPin);
if(hCheck != 0)
humidity = 255; //Must be an error
else
humidity = DHT11.humidity;
showData(temp, humidity);
delay(1000);
}
void showData (int temp, int humidity)
{
String s1, s2, s3;
String spaces = " ";
s1 = String(temp) + char(0xdf) + "C";
if(humidity == 255)
s2 = "ERROR";
else
s2 = String(humidity) + "%";
s3 = s1 + spaces.substring(0, 16 - s1.length() - s2.length()) + s2;
lcd.setCursor(0,0);
lcd.print(s3);
}
Please accept my humble apologies if this is a daft question / post
Edit: After playing a little more i added some serial commands and ran project again - Interestingly the programme only looped twice i.e. only displayed via serial temp, humidity values twice.
Kindest Regards
Tony