16x2 LCD Clock?

I bought a 16x2 Freetronics LCD shield v2.0 and I am trying to make a clock. Its difficult because I don't have an RTC shield and don't know where to fit both if I even had one.

Please can someone give me errors in my code or make one!
MY CODE

int time = 1;
#include <LiquidCrystal.h>
LiquidCrystal lcd(4, 5, 6, 7, 8, 9);

void setup()
{
  lcd.begin(16,2);
  lcd.clear();
}
void loop()
{
  lcd.setCursor(0,0);
  lcd.write(time);
  time = time + 1;
  delay(1000);
  lcd.clear();
}

What is your native language ?

raschemmel:
What is your native language ?

Australian

Please can someone give me errors in my code or make one!

like english, right ?

Please can someone give me errors in my code or make one!

Can you please explain what this means ?
Your asking us to give you errors ?
Or make one what ?

I think the hint here is - start by Googling for "Arduino clock" and study what is available and the code for it. you will find many examples of a clock with 7 segment displays, a few using Nixie tubes, and a number using an LCD. You should find the code with some of the projects.

The crystal in Arduinos - those with a crystal - should suffice to some degree as a timekeeper. Like cheap mains-powered clocks, you will have to set the time each time you turn it on, so a RTC would allow it to survive power failures if you really need that.

The later model of the JY-MCU clock/ matrix display actually has a quite good crystal - at least in my experience, there seem to have been complaints about an earlier model. I think it is a better way to start and it can be programmed as an Arduino (ATmega8) or in fact (using ISP) by an Arduino so it is eminently hackable (with some code already floating around).

Depending on the accuracy you need, and if you need batterry backup,
you might be able to use a s/w only clock.
See the Time library:
http://playground.arduino.cc/Code/time
And for alarms use the TimeAlarms addon library.

--- bill

One of these would help -

http://www.ebay.com.au/itm/New-DS1302-Real-Time-Clock-Module-With-CR2032-With-Battery-High-Quality-/310718597789?pt=AU_B_I_Electrical_Test_Equipment&hash=item4858458a9d&_uhb=1

and look at the code from -

http://blog.trendsmix.com/?p=93

As far as your code is concerned, I ran the program and it counts integers starting at 2.
Makes an interesting display on character position 0,0 if you shorten the delay to 250ms.