diff -NaurwB client/command.cc client-patched/command.cc
--- client/command.cc	2008-07-15 18:35:33.000000000 +0200
+++ client-patched/command.cc	2008-08-23 19:50:58.000000000 +0200
@@ -49,6 +49,7 @@
 #include "boxx.h"
 #include "boxstack.h"
 #include "log.h"
+#include "vsleeptimer.h"
 
 
 Command* Command::instance = NULL;
@@ -466,6 +467,15 @@
       doFromTheTop(false);
       return;
     }
+   case Remote::GO:
+       {
+	  VSleeptimer* sleep = new VSleeptimer();
+	        boxstack->add(sleep);
+	        sleep->handleCommand(button); // this will draw+show
+	        return;
+	  
+       }
+     
   }
 }
 
@@ -502,6 +512,7 @@
     VDR::getInstance()->disconnect();
     Led::getInstance()->off();
     isStandby = 1;
+    Sleeptimer::getInstance()->shutdown();
 #ifdef WIN32
     stop(); //different behavoiur on windows, we exit
 #endif
diff -NaurwB client/main.cc client-patched/main.cc
--- client/main.cc	2008-03-26 16:09:09.000000000 +0100
+++ client-patched/main.cc	2008-08-23 19:50:58.000000000 +0200
@@ -41,7 +41,7 @@
 #include "audiomvp.h"
 #include "videomvp.h"
 #include "wol.h"
-
+#include "vsleeptimer.h"
 #ifndef WIN32
 void sighandler(int signalReceived);
 #endif
@@ -66,6 +66,7 @@
 Video* video;
 Audio* audio;
 Wol* wol;
+Sleeptimer* sleeptimer;
 
 // Linux MVP main function and sighandler
 #ifndef WIN32
@@ -117,8 +118,8 @@
   boxstack   = new BoxStack();
   command    = new Command();
   wol        = new Wol();
-
-  if (!logger || !remote || !mtd || !led || !osd || !video || !audio || !boxstack || !command || !wol)
+  sleeptimer = new Sleeptimer();
+  if (!logger || !remote || !mtd || !led || !osd || !video || !audio || !boxstack || !command || !wol || !sleeptimer)
   {
     printf("Could not create objects. Memory problems?\n");
     shutdown(1);
@@ -463,6 +464,15 @@
     logger->log("Core", Log::NOTICE, "WOL module shut down");
   }
 
+   if (sleeptimer)
+     {
+	
+	delete sleeptimer;
+	logger->log("Core", Log::NOTICE, "Sleeptimer module shut down");
+     }
+   
+   
+
   if (logger)
   {
     logger->log("Core", Log::NOTICE, "Log module shutting down... bye!\n\n");
diff -NaurwB client/objects.mk client-patched/objects.mk
--- client/objects.mk	2008-05-25 19:01:05.000000000 +0200
+++ client-patched/objects.mk	2008-08-23 19:50:58.000000000 +0200
@@ -17,6 +17,6 @@
            vmedialist.o media.o vpicture.o vpicturebanner.o                   \
            vaudioplayer.o audioplayer.o demuxeraudio.o abstractoption.o       \
            eventdispatcher.o vdrrequestpacket.o vdrresponsepacket.o           \
-           vvideolivetv.o                                                     \
+           vvideolivetv.o vsleeptimer.o                                       \
            playerlivetv.o playerliveradio.o                                   \
            wprogressbar.o
diff -NaurwB client/vsleeptimer.cc client-patched/vsleeptimer.cc
--- client/vsleeptimer.cc	1970-01-01 01:00:00.000000000 +0100
+++ client-patched/vsleeptimer.cc	2008-08-23 19:50:58.000000000 +0200
@@ -0,0 +1,315 @@
+
+/*
+    Copyright 2004-2005 Chris Tallon
+
+    This file is part of VOMP.
+
+    VOMP is free software; you can redistribute it and/or modify
+    it under the terms of the GNU General Public License as published by
+    the Free Software Foundation; either version 2 of the License, or
+    (at your option) any later version.
+
+    VOMP is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with VOMP; if not, write to the Free Software
+    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+*/
+
+#include "vsleeptimer.h"
+
+#include "remote.h"
+#include "wsymbol.h"
+#include "colour.h"
+#include "video.h"
+#include "timers.h"
+#include "boxstack.h"
+#include "command.h"
+
+Sleeptimer* Sleeptimer::instance = NULL;
+
+Sleeptimer::Sleeptimer()
+{
+   if (instance) return;
+   sec = -1;
+   active = false;
+   instance = this;
+   
+}
+
+Sleeptimer::~Sleeptimer()
+{
+   instance = NULL;
+}
+
+
+const char* Sleeptimer::SetTime()
+{
+   if (sec <890)
+     {
+	sec=900;
+	if (active==false)
+	{
+	   active = true;
+	   threadStart();
+	}
+	
+	return "0:15";
+     }
+   else if (sec <1790)
+     {
+	sec = 1800;
+	if (active==false)
+	{
+	   active = true;
+	   threadStart();
+	}
+	
+	return "0:30";
+     }
+   else if (sec < 2690)
+     {
+	sec = 2700;
+	if (active==false)
+	{
+	   active = true;  
+	   threadStart();
+	}
+	
+	return "0:45";
+     }
+   else if (sec < 3590)
+     {
+	sec = 3600;
+	if (active==false)
+	{
+	   active = true;
+	   threadStart();
+	}
+	
+	return "1:00";
+     }
+   else if (sec < 4490)
+     {
+	sec = 4500;
+	if (active==false)
+	{
+	   active = true;
+	   threadStart();
+	}
+	
+	return "1:15";
+     }
+   else if (sec < 5390)
+     {
+	sec = 5400;
+	if (active==false)
+	{
+	   active = true;
+	   threadStart();
+	}
+	
+	return "1:30";
+     }
+   else if (sec < 6290)
+     {
+	sec = 6300;
+	if (active==false)
+	{
+	   active = true;
+	   threadStart();
+	}
+	
+	return "1:45";
+     }
+   else if (sec < 7190)
+     {
+	sec = 7200;
+	if (active==false)
+	{
+	   active = true;
+	   threadStart();
+	}
+	
+	return "2:00";
+	
+     }
+   else
+     {
+	sec = -1;
+	if (active==true)
+	shutdown();
+	return "AUS";
+     }
+   
+}
+
+Sleeptimer* Sleeptimer::getInstance()
+{
+     return instance;
+}
+
+void Sleeptimer::threadMethod()
+{
+   
+   while (sec>-1 && active==true)
+     {
+	sec--;
+	if (sec<31 && sec>-1)
+	  {
+	     VCountdown* count = new VCountdown();
+             char* temp;
+	     asprintf(&temp, "0:%d", sec);
+	     count->draw(temp);
+	     free (temp);
+	     Message* m1 = new Message();
+	     m1->message = Message::ADD_VIEW;
+             m1->to = BoxStack::getInstance();
+             m1->parameter = (ULONG)count;
+	     Command::getInstance()->postMessageNoLock(m1);
+	  }
+	 MILLISLEEP(1000);
+	
+	
+        if (sec==-1)
+	  {
+	     Message* m2 = new Message(); // Delete self
+	     m2->message = Message::UDP_BUTTON;
+	     m2->to = Command::getInstance();
+	     m2->from = this;
+	     m2->parameter = 61;
+	     Command::getInstance()->postMessageFromOuterSpace(m2);
+	     shutdown();
+	  }
+	
+     }
+   
+     
+}
+
+void Sleeptimer::shutdown()
+{
+   if (active==true)
+     {
+	sec=-1; 
+	threadCancel();
+	active = false;
+     }
+   
+}
+
+
+VSleeptimer::VSleeptimer()
+{
+  setSize(100, 28);
+  createBuffer();
+  if (Video::getInstance()->getFormat() == Video::PAL)
+  {
+    setPosition(100, 499);
+  }
+  else
+  {
+    setPosition(90, 400);
+  }
+}
+
+VSleeptimer::~VSleeptimer()
+{
+  // Make sure the timer is deleted
+  Timers::getInstance()->cancelTimer(this, 1);
+}
+
+void VSleeptimer::draw()
+{
+   fillColour(Colour::VIEWBACKGROUND);
+   WSymbol w;
+   TEMPADD(&w);
+   w.nextSymbol = WSymbol::CLOCK;
+   w.setPosition(3, 0);
+   w.draw();
+ 
+   Boxx::draw();
+   drawText(displaySleeptimer,50,2,Colour::LIGHTTEXT);
+   Timers::getInstance()->setTimerD(this, 1, 2);
+}
+
+void VSleeptimer::timercall(int clientReference)
+{
+  // delete me!
+  Message* m = new Message(); // Delete self
+  m->message = Message::CLOSE_ME;
+  m->to = BoxStack::getInstance();
+  m->from = this;
+  Command::getInstance()->postMessageFromOuterSpace(m);
+}
+
+int VSleeptimer::handleCommand(int command)
+{
+  switch(command)
+  {
+    case Remote::GO:
+    {
+      displaySleeptimer = Sleeptimer::getInstance()->SetTime();
+      draw();
+      BoxStack::getInstance()->update(this);
+      // handled
+      return 2;
+    }
+  }
+
+  // allow command to drop through to other views
+  return 0;
+}
+
+
+
+
+VCountdown::VCountdown()
+{
+
+  setSize(100, 28);
+  createBuffer();
+  if (Video::getInstance()->getFormat() == Video::PAL)
+  {
+    setPosition(100, 499);
+  }
+  else
+  {
+    setPosition(90, 400);
+  }
+}
+
+VCountdown::~VCountdown()
+{
+  // Make sure the timer is deleted
+  Timers::getInstance()->cancelTimer(this, 1);
+}
+
+void VCountdown::draw(const char* sec)
+{
+   
+   fillColour(Colour::VIEWBACKGROUND);
+   WSymbol w;
+   TEMPADD(&w);
+   w.nextSymbol = WSymbol::CLOCK;
+   w.nextColour = Colour::RED;
+   w.setPosition(3, 0);
+   w.draw();
+ 
+   Boxx::draw();
+   drawText(sec,50,2,Colour::RED); 
+   Timers::getInstance()->setTimerD(this, 1, 1);
+}
+
+void VCountdown::timercall(int clientReference)
+{
+  // delete me!
+  Message* m = new Message(); // Delete self
+  m->message = Message::CLOSE_ME;
+  m->to = BoxStack::getInstance();
+  m->from = this;
+  Command::getInstance()->postMessageFromOuterSpace(m);
+}
diff -NaurwB client/vsleeptimer.h client-patched/vsleeptimer.h
--- client/vsleeptimer.h	1970-01-01 01:00:00.000000000 +0100
+++ client-patched/vsleeptimer.h	2008-08-23 19:50:58.000000000 +0200
@@ -0,0 +1,87 @@
+
+/*
+    Copyright 2004-2005 Chris Tallon
+
+    This file is part of VOMP.
+
+    VOMP is free software; you can redistribute it and/or modify
+    it under the terms of the GNU General Public License as published by
+    the Free Software Foundation; either version 2 of the License, or
+    (at your option) any later version.
+
+    VOMP is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with VOMP; if not, write to the Free Software
+    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+*/
+
+#ifndef VSLEEPTIMER_H
+#define VSLEEPTIMER_H
+
+#include <stdio.h>
+
+#include "boxx.h"
+#include "timerreceiver.h"
+
+#ifndef WIN32
+#include "threadp.h"
+#else
+#include "threadwin.h"
+#endif
+
+class Sleeptimer : public Thread_TYPE
+{
+ public:
+   Sleeptimer();
+   virtual ~Sleeptimer();
+   static Sleeptimer* getInstance();
+   const char* SetTime();
+   void shutdown();   
+   virtual void threadMethod();
+   virtual void threadPostStopCleanup() {};
+   
+ private:
+   int sec;
+   bool active;
+   static Sleeptimer* instance;
+   
+
+   
+};
+
+
+
+
+class VSleeptimer : public Boxx, public TimerReceiver
+{
+  public:
+    VSleeptimer();
+    ~VSleeptimer();
+    void draw();
+    int handleCommand(int command);
+    void timercall(int clientReference);
+
+  private:
+    const char*  displaySleeptimer;
+
+};
+
+class VCountdown : public Boxx, public TimerReceiver
+{
+   
+ public:
+       VCountdown();
+       ~VCountdown();
+       void draw(const char* sec);
+       void timercall(int clientReference);
+   
+}
+;
+
+
+#endif
+
diff -NaurwB client/wsymbol.cc client-patched/wsymbol.cc
--- client/wsymbol.cc	2008-05-03 18:03:47.000000000 +0200
+++ client-patched/wsymbol.cc	2008-08-23 19:50:58.000000000 +0200
@@ -22,8 +22,8 @@
 
 #include "colour.h"
 
-UCHAR WSymbol::widths[] = { 2, 2, 4, 4, 1, 1, 3, 3, 3, 3, 3, 4, 4, 2, 2, 3, 5, 5, 4, 4, 2, 2, 5, 5, 4, 4};
-UCHAR WSymbol::heights[] = { 8, 8, 12, 12, 24, 4, 18, 18, 18, 18, 18, 30, 30, 16, 16, 18, 18, 18, 16, 16, 8, 8, 16, 16, 16, 16};
+UCHAR WSymbol::widths[] = { 2, 2, 4, 4, 1, 1, 3, 3, 3, 3, 3, 4, 4, 2, 2, 3, 5, 5, 4, 4, 2, 2, 5, 5, 4, 4, 5};
+UCHAR WSymbol::heights[] = { 8, 8, 12, 12, 24, 4, 18, 18, 18, 18, 18, 30, 30, 16, 16, 18, 18, 18, 16, 16, 8, 8, 16, 16, 16, 16, 26};
 
 UCHAR WSymbol::symbols[] = {
 
@@ -999,12 +999,61 @@
 0xFF, 0x03, 0xFC, 0xFF,
 0xFF, 0x03, 0xFC, 0xFF,
 
-
-
-
-
-
-
+/*
+00000000 00011111 11111111 11111000 00000000
+00000000 00111111 11111111 11111100 00000000
+00000000 01111111 11111111 11111110 00000000
+00000000 11111111 11111111 11111111 00000000
+00000001 11111111 11111111 11111111 10000000
+00000011 11111100 00000000 00111111 11000000
+00000111 11111000 00000000 00011111 11100000
+00001111 11110000 00111100 00001111 11110000
+00011111 11100000 00111100 00000111 11111000
+00111111 11000000 00111100 00000011 11111100
+01111111 10000000 00111100 00000001 11111110
+11111111 00000000 00111111 11111100 11111111
+11111111 00000000 00111111 11111100 11111111
+11111111 00000000 00111111 11111100 11111111
+11111111 00000000 00111111 11111100 11111111
+01111111 10000000 00000000 00000001 11111110
+00111111 11000000 00000000 00000011 11111100
+00011111 11100000 00000000 00000111 11111000
+00001111 11110000 00000000 00001111 11110000
+00000111 11111000 00000000 00011111 11100000
+00000011 11111100 00000000 00111111 11000000
+00000001 11111111 11111111 11111111 10000000
+00000000 11111111 11111111 11111110 00000000
+00000000 01111111 11111111 11111100 00000000
+00000000 00111111 11111111 11111000 00000000
+00000000 00011111 11111111 11110000 00000000
+*/
+
+0x00, 0x1F, 0xFF, 0xF8, 0x00,
+0x00, 0x3F, 0xFF, 0xFC, 0x00,
+0x00, 0x7F, 0xFF, 0xFE, 0x00,
+0x00, 0xFF, 0xFF, 0xFF, 0x00,
+0x01, 0xFF, 0xFF, 0xFF, 0x80,
+0x03, 0xFC, 0x00, 0x3F, 0xC0,
+0x07, 0xF8, 0x00, 0x1F, 0xE0,
+0x0F, 0xF0, 0x3C, 0x0F, 0xF0,
+0x1F, 0xE0, 0x3C, 0x07, 0xF8,
+0x3F, 0xC0, 0x3C, 0x03, 0xFC,
+0x7F, 0x80, 0x3C, 0x01, 0xFE, 
+0xFF, 0x00, 0x3F, 0xFC, 0xFF,
+0xFF, 0x00, 0x3F, 0xFC, 0xFF,
+0xFF, 0x00, 0x3F, 0xFC, 0xFF, 
+0xFF, 0x00, 0x3F, 0xFC, 0xFF,
+0x7F, 0x80, 0x00, 0x01, 0xFE,
+0x3F, 0xC0, 0x00, 0x03, 0xFC,
+0x1F, 0xE0, 0x00, 0x07, 0xF8,
+0x0F, 0xF0, 0x00, 0x0F, 0xF0,
+0x07, 0xF8, 0x00, 0x1F, 0xE0,
+0x03, 0xFC, 0x00, 0x3F, 0xC0,
+0x01, 0xFF, 0xFF, 0xFF, 0x80,
+0x00, 0xFF, 0xFF, 0xFE, 0x00,
+0x00, 0x7F, 0xFF, 0xFC, 0x00,
+0x00, 0x3F, 0xFF, 0xF8, 0x00,
+0x00, 0x1F, 0xFF, 0xF0, 0x00,
 
 };
 
diff -NaurwB client/wsymbol.h client-patched/wsymbol.h
--- client/wsymbol.h	2008-05-03 18:03:47.000000000 +0200
+++ client-patched/wsymbol.h	2008-08-23 19:50:58.000000000 +0200
@@ -61,7 +61,7 @@
     const static UCHAR VIDEOASPECT169 = 23;
     const static UCHAR SINGLEAUDIO = 24;
     const static UCHAR MULTIAUDIO = 25;
-    
+    const static UCHAR CLOCK = 26;    
   private:
     static UCHAR symbols[];
     static UCHAR widths[];
