summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--HISTORY5
-rw-r--r--libsi/descriptor.c23
-rw-r--r--libsi/descriptor.h14
-rw-r--r--libsi/headers.h14
-rw-r--r--libsi/si.c6
5 files changed, 53 insertions, 9 deletions
diff --git a/HISTORY b/HISTORY
index 613d48a9..f1d04034 100644
--- a/HISTORY
+++ b/HISTORY
@@ -2652,7 +2652,7 @@ Video Disk Recorder Revision History
actual CAM type as reported by the CAM. The 'ca.conf' file has been stripped
down to the values 0..4.
-2004-02-21: Version 1.3.5
+2004-02-22: Version 1.3.5
- Fixed reading the EPG preferred language parameter from 'setup.conf'.
- Fixed switching to a visible programme in case the current channel has neither
@@ -2672,7 +2672,7 @@ Video Disk Recorder Revision History
- Limited automatic retuning to devices that actually provide the transponder
(necessary for the 'sky' plugin).
- Fixed handling receivers in the 'sky' plugin, so that a recording on the same
- channel won't interrupt an ongoing Transfer mode.
+ channel won't interrupt an ongoing Transfer Mode.
- Added subtable ID and TSDT handling to 'libsi' (thanks to Marcel Wiesweg).
- Fixed some Russian OSD texts (thanks to Vyacheslav Dikonov).
- Added the 'running status' to the EPG events. This might lead to a VPS like
@@ -2691,3 +2691,4 @@ Video Disk Recorder Revision History
a start time that is in the future, but are already running.
- Implemented an "EPG linger time", which can be set to have older EPG information
still displayed in the "Schedule" menu (thanks to Jaakko Hyvätti).
+- Added PDCDescriptor handling to 'libsi'.
diff --git a/libsi/descriptor.c b/libsi/descriptor.c
index 55a6a9c0..0b0019f8 100644
--- a/libsi/descriptor.c
+++ b/libsi/descriptor.c
@@ -6,7 +6,7 @@
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
- * $Id: descriptor.c 1.5 2004/01/24 14:52:41 kls Exp $
+ * $Id: descriptor.c 1.6 2004/02/22 11:11:36 kls Exp $
* *
***************************************************************************/
@@ -529,6 +529,27 @@ void ISO639LanguageDescriptor::Parse() {
languageCode[3]=0;
}
+void PDCDescriptor::Parse() {
+ unsigned int offset=0;
+ data.setPointerAndOffset<const descr_pdc>(s, offset);
+}
+
+int PDCDescriptor::getDay() const {
+ return ((s->pil0 & 0x0F) << 1) | ((s->pil1 & 0x80) >> 7);
+}
+
+int PDCDescriptor::getMonth() const {
+ return (s->pil1 >> 3) & 0x0F;
+}
+
+int PDCDescriptor::getHour() const {
+ return ((s->pil1 & 0x07) << 2) | ((s->pil2 & 0xC0) >> 6);
+}
+
+int PDCDescriptor::getMinute() const {
+ return s->pil2 & 0x3F;
+}
+
void ApplicationSignallingDescriptor::Parse() {
entryLoop.setData(data+sizeof(descr_application_signalling), getLength()-sizeof(descr_application_signalling));
}
diff --git a/libsi/descriptor.h b/libsi/descriptor.h
index 5541cc41..17c81eb0 100644
--- a/libsi/descriptor.h
+++ b/libsi/descriptor.h
@@ -6,7 +6,7 @@
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
- * $Id: descriptor.h 1.5 2004/01/24 14:52:05 kls Exp $
+ * $Id: descriptor.h 1.6 2004/02/22 10:16:47 kls Exp $
* *
***************************************************************************/
@@ -383,6 +383,18 @@ private:
const descr_iso_639_language *s;
};
+class PDCDescriptor : public Descriptor {
+public:
+ int getDay() const;
+ int getMonth() const;
+ int getHour() const;
+ int getMinute() const;
+protected:
+ virtual void Parse();
+private:
+ const descr_pdc *s;
+};
+
//a descriptor currently unimplemented in this library
class UnimplementedDescriptor : public Descriptor {
protected:
diff --git a/libsi/headers.h b/libsi/headers.h
index 26fdb27c..ff3e0f95 100644
--- a/libsi/headers.h
+++ b/libsi/headers.h
@@ -10,7 +10,7 @@
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
- * $Id: headers.h 1.3 2004/02/20 13:49:16 kls Exp $
+ * $Id: headers.h 1.4 2004/02/22 11:12:46 kls Exp $
* *
***************************************************************************/
@@ -1457,11 +1457,19 @@ struct descr_dsng {
/* 0x69 pdc_descriptor */
-#define DESCR_PDC_LEN XX
+#define DESCR_PDC_LEN 5
struct descr_pdc {
u_char descriptor_tag :8;
u_char descriptor_length :8;
- /* TBD */
+#if BYTE_ORDER == BIG_ENDIAN
+ u_char pil2 :8;
+ u_char pil1 :8;
+ u_char pil0 :8;
+#else
+ u_char pil0 :8;
+ u_char pil1 :8;
+ u_char pil2 :8;
+#endif
};
/* 0x6A ac3_descriptor */
diff --git a/libsi/si.c b/libsi/si.c
index b952fb51..ee648020 100644
--- a/libsi/si.c
+++ b/libsi/si.c
@@ -6,7 +6,7 @@
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
- * $Id: si.c 1.7 2004/02/20 13:46:12 kls Exp $
+ * $Id: si.c 1.8 2004/02/22 10:14:12 kls Exp $
* *
***************************************************************************/
@@ -334,6 +334,9 @@ Descriptor *Descriptor::getDescriptor(CharArray da, DescriptorTagDomain domain)
case ISO639LanguageDescriptorTag:
d=new ISO639LanguageDescriptor();
break;
+ case PDCDescriptorTag:
+ d=new PDCDescriptor();
+ break;
//note that it is no problem to implement one
//of the unimplemented descriptors.
@@ -375,7 +378,6 @@ Descriptor *Descriptor::getDescriptor(CharArray da, DescriptorTagDomain domain)
case CaSystemDescriptorTag:
case AC3DescriptorTag:
case DSNGDescriptorTag:
- case PDCDescriptorTag:
case AncillaryDataDescriptorTag:
case AnnouncementSupportDescriptorTag:
case AdaptationFieldDataDescriptorTag: