summaryrefslogtreecommitdiff
path: root/svdrp.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <kls (at) cadsoft (dot) de>2003-04-27 18:00:00 +0200
committerKlaus Schmidinger <kls (at) cadsoft (dot) de>2003-04-27 18:00:00 +0200
commit0686038af36be65b666bce669957c4d94c13f409 (patch)
tree50c5bc80b5f49e0bc14b6846f1f53794c5da6f65 /svdrp.c
parent21a52ccb6d43cce35f7a381f55ea291195416f33 (diff)
downloadvdr-patch-lnbsharing-0686038af36be65b666bce669957c4d94c13f409.tar.gz
vdr-patch-lnbsharing-0686038af36be65b666bce669957c4d94c13f409.tar.bz2
Version 1.1.29vdr-1.1.29
- Fixed detecting broken connection to the LIRC daemon (thanks to Ludwig Nussel). - Now sending CA descriptors to the CAM in the same sequence as they were originally received (thanks to Stefan Huelswitt). - The PCR PID can now be set separately from the video PID. The syntax in the 'channels.conf' file is, for example, ...:164+17:..., where 164 is the video PID and 17 is the PCR PID. The separator is a '+' sign, not a comma or semicolon as with the audio PIDs, because this is not an alternate PID, but rather an additional, necessary PID. In order to use this feature you need a driver version dated 2003-04-27 or higher (setting the PCR PID didn't work in earlier versions). - Fixed deleting the last recording in the "Recordings" menu, which started pausing live video (thanks to Christoph Friederich for reporting this one). - Now setting the "broken link" flag for GOPs at the beginning of a new video sequence, which avoids artefacts when cutting (thanks to Stefan Huelswitt). - Removed the Mute() call from cDvbDevice::StillPicture() (suggested by Andreas Schultz). - Updated 'channels.conf.terr' for Berlin (thanks to Andreas Brachold). - Extended logging info when starting/stopping timers to show the channel number, start/stop time and the file name (suggested by Manuel Hartl). - Added a note regarding non-VDR files in the /videoX directories to INSTALL (suggested by Benjamin Harling). - Skipping keys that come in too fast from LIRC (thanks to Christian Jacobsen). - Avoiding short display of the main menu if a plugin displays its own OSD and is started through a user defined key macro (thanks to Andreas Mair for reporting this one). - Reduced the time to wait for EPG data when starting a recording to 3 seconds. - The new SVDRP command STAT can be used to request information about the disk usage (thanks to Thomas Koch). - Fixed faulty calculation of section length in eit.c (thanks to Teemu Rantanen).
Diffstat (limited to 'svdrp.c')
-rw-r--r--svdrp.c22
1 files changed, 21 insertions, 1 deletions
diff --git a/svdrp.c b/svdrp.c
index 102abe0..6dafddd 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.50 2002/12/22 14:04:08 kls Exp $
+ * $Id: svdrp.c 1.51 2003/04/27 14:21:07 kls Exp $
*/
#include "svdrp.h"
@@ -33,6 +33,7 @@
#include "remote.h"
#include "timers.h"
#include "tools.h"
+#include "videodir.h"
// --- cSocket ---------------------------------------------------------------
@@ -250,6 +251,8 @@ 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).",
+ "STAT disk\n"
+ " Return information about disk usage (total, free, percent).",
"UPDT <settings>\n"
" Updates a timer. Settings must be in the same format as returned\n"
" by the LSTT command. If a timer with the same channel, day, start\n"
@@ -929,6 +932,22 @@ void cSVDRP::CmdPUTE(const char *Option)
DELETENULL(PUTEhandler);
}
+void cSVDRP::CmdSTAT(const char *Option)
+{
+ if (*Option) {
+ if (strcasecmp(Option, "DISK") == 0) {
+ int FreeMB;
+ int Percent = VideoDiskSpace(&FreeMB);
+ int Total = (FreeMB / (100 - Percent)) * 100;
+ Reply(250, "%dMB %dMB %d%%", Total, FreeMB, Percent);
+ }
+ else
+ Reply(501, "Invalid Option \"%s\"", Option);
+ }
+ else
+ Reply(501, "No option given");
+}
+
void cSVDRP::CmdUPDT(const char *Option)
{
if (*Option) {
@@ -1021,6 +1040,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("STAT")) CmdSTAT(s);
else if (CMD("UPDT")) CmdUPDT(s);
else if (CMD("VOLU")) CmdVOLU(s);
else if (CMD("QUIT")) Close();