From 48dc6d871019762400fcdabe4f30f7e61b347d34 Mon Sep 17 00:00:00 2001 From: Klaus Schmidinger Date: Sat, 17 Jan 2004 15:41:52 +0100 Subject: [PATCH] New SVDRP command SCAN --- HISTORY | 2 ++ svdrp.c | 13 ++++++++++++- svdrp.h | 3 ++- 3 files changed, 16 insertions(+), 2 deletions(-) diff --git a/HISTORY b/HISTORY index ef33d5e4..371a0c25 100644 --- a/HISTORY +++ b/HISTORY @@ -2596,3 +2596,5 @@ Video Disk Recorder Revision History ones. - The "Red" button in the "Setup/EPG" menu can now be used to force an EPG scan on a single DVB card system (see MANUAL for details). +- The new SVDRP command 'SCAN' can be used to force an EPG scan on a single + DVB card system (see MANUAL under Setup/EPG for details). diff --git a/svdrp.c b/svdrp.c index 83847a0e..6191182a 100644 --- a/svdrp.c +++ b/svdrp.c @@ -10,7 +10,7 @@ * and interact with the Video Disk Recorder - or write a full featured * graphical interface that sits on top of an SVDRP connection. * - * $Id: svdrp.c 1.57 2003/12/28 10:09:30 kls Exp $ + * $Id: svdrp.c 1.58 2004/01/17 15:41:52 kls Exp $ */ #include "svdrp.h" @@ -29,6 +29,7 @@ #include "channels.h" #include "config.h" #include "device.h" +#include "eitscan.h" #include "keys.h" #include "remote.h" #include "timers.h" @@ -251,6 +252,9 @@ const char *HelpPages[] = { " format defined in vdr(5) for the 'epg.data' file. A '.' on a line\n" " by itself terminates the input and starts processing of the data (all\n" " entered data is buffered until the terminating '.' is seen).", + "SCAN\n" + " Forces an EPG scan. If this is a single DVB device system, the scan\n" + " will be done on the primary device unless it is currently recording.", "STAT disk\n" " Return information about disk usage (total, free, percent).", "UPDT \n" @@ -954,6 +958,12 @@ void cSVDRP::CmdPUTE(const char *Option) DELETENULL(PUTEhandler); } +void cSVDRP::CmdSCAN(const char *Option) +{ + EITScanner.ForceScan(); + Reply(250, "EPG scan triggered"); +} + void cSVDRP::CmdSTAT(const char *Option) { if (*Option) { @@ -1062,6 +1072,7 @@ void cSVDRP::Execute(char *Cmd) else if (CMD("NEWT")) CmdNEWT(s); else if (CMD("NEXT")) CmdNEXT(s); else if (CMD("PUTE")) CmdPUTE(s); + else if (CMD("SCAN")) CmdSCAN(s); else if (CMD("STAT")) CmdSTAT(s); else if (CMD("UPDT")) CmdUPDT(s); else if (CMD("VOLU")) CmdVOLU(s); diff --git a/svdrp.h b/svdrp.h index 67918ed5..8df86156 100644 --- a/svdrp.h +++ b/svdrp.h @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: svdrp.h 1.19 2003/04/27 14:09:59 kls Exp $ + * $Id: svdrp.h 1.20 2004/01/17 15:41:52 kls Exp $ */ #ifndef __SVDRP_H @@ -73,6 +73,7 @@ private: void CmdNEWT(const char *Option); void CmdNEXT(const char *Option); void CmdPUTE(const char *Option); + void CmdSCAN(const char *Option); void CmdSTAT(const char *Option); void CmdUPDT(const char *Option); void CmdVOLU(const char *Option);