summaryrefslogtreecommitdiff
path: root/libdtv/libsi/si_debug_services.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <kls (at) cadsoft (dot) de>2003-04-13 18:00:00 +0200
committerKlaus Schmidinger <kls (at) cadsoft (dot) de>2003-04-13 18:00:00 +0200
commit9f919801465f49be6b2118f54bd54df846e2f865 (patch)
tree721f42c9fd88ab33b47ad9b945247353bac9bc4c /libdtv/libsi/si_debug_services.c
parentb60eda5a8e8a9b9b96a90016fd27c03cd3f1ec8b (diff)
downloadvdr-patch-lnbsharing-9f919801465f49be6b2118f54bd54df846e2f865.tar.gz
vdr-patch-lnbsharing-9f919801465f49be6b2118f54bd54df846e2f865.tar.bz2
Version 1.1.27vdr-1.1.27
- The CAM is now accessed only if the current channel actually has a non-zero Ca value, and CAM access is completely suppressed during replay, which avoids problems in case the CAM is attached to the primary DVB device. - The "Left" and "Right" buttons now set the cursor to the first or last list item even if the list consist only of a single page, like, for instance, the Main menu (thanks to Oliver Endriss). - Made the log message "OSD window width must be a multiple of 4..." a debug message instead of an error message, so it can be avoided by using a log level less than 3. - Updated Greek language texts (thanks to Dimitrios Dimitrakos). - Fixed faulty behaviour of the "Mute" key in case the channel display is visible (thanks to Florian Bartels for reporting this one and Sascha Volkenandt for helping to fix it). - Modified LOF handling to allow for C-band reception (thanks to Malcolm Caldwell). - Added some missing cAudio handling calls (thanks to Werner Fink). - Replaced the 'for' loops in StripAudioPackets() with memset() calls (thanks to Werner Fink). - Further increased the timeout until an index file is considerd no longer to be written. - Fixed a crash in case the index file can't be accessed any more during replay (thanks to Stefan Huelswitt for reporting this one). - Fixed displaying messages in the status line in case they exceed the OSD width (thanks to Gerhard Steiner for reporting this one). - Avoiding high CPU load in case the connection to LIRC gets lost (thanks to Ludwig Nussel). - Fixed handling repeat function with LIRC (thanks to Ludwig Nussel). - Fixed handling min/max borders when entering integer values (thanks to Andy Grobb for reporting this one). - Implemented a "resume ID" which allows several users to each have their own resume.vdr files (thanks to Martin Hammerschmid). This parameter can be set in the "Setup/Replay" menu (see MANUAL for details). - Now using 'libdtv' version 0.0.5 (thanks to Rolf Hakenes for the new version and Stefan Huelswitt for adapting VDR to it). - If no device with an MPEG decoder can be found at startup, the first device is now used as primary device (just to have some device). - Adjusted some Premiere channels in 'channels.conf' (thanks to Thomas Koch). - Updated 'channels.conf.cable' (thanks to Stefan Hußfeldt). - The 'epg.data' file is now read after all plugins have been started (thanks to Sascha Volkenandt). - The LIRC remote control no longer tries to learn keys if it can't connect to the LIRC daemon (thanks to Ludwig Nussel for reporting this one). The same applies to the RCU remote control in case of errors during startup. - Fixed handling of Ca parameters with values <= MAXDEVICES, which don't indicate an actual encrypted channel (thanks to Stefan Huelswitt for reporting this one).
Diffstat (limited to 'libdtv/libsi/si_debug_services.c')
-rw-r--r--libdtv/libsi/si_debug_services.c130
1 files changed, 122 insertions, 8 deletions
diff --git a/libdtv/libsi/si_debug_services.c b/libdtv/libsi/si_debug_services.c
index ae2a92a..ac8de34 100644
--- a/libdtv/libsi/si_debug_services.c
+++ b/libdtv/libsi/si_debug_services.c
@@ -4,11 +4,13 @@
/// ///
//////////////////////////////////////////////////////////////
-// $Revision: 1.4 $
-// $Date: 2001/10/07 10:24:46 $
+// $Revision: 1.5 $
+// $Date: 2003/02/04 18:45:35 $
// $Author: hakenes $
//
-// (C) 2001 Rolf Hakenes <hakenes@hippomi.de>, under the GNU GPL.
+// (C) 2001-03 Rolf Hakenes <hakenes@hippomi.de>, under the
+// GNU GPL with contribution of Oleg Assovski,
+// www.satmania.com
//
// libsi is free software; you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
@@ -26,11 +28,13 @@
// Boston, MA 02111-1307, USA.
#include <stdio.h>
+#include <stdlib.h>
#include <string.h>
#include <time.h>
#include "../liblx/liblx.h"
#include "libsi.h"
+#include "si_tables.h"
#include "si_debug_services.h"
@@ -208,6 +212,8 @@ void siDebugPids (char *Prepend, struct LIST *PidList)
printf ("%s ProgramID: %d\n", Prepend, Pid->ProgramID);
printf ("%s PcrPid: %d\n", Prepend, Pid->PcrPID);
printf ("%s PmtVersion: %d\n", Prepend, Pid->PmtVersion);
+ sprintf (NewPrepend, "%s ", Prepend);
+ siDebugDescriptors (NewPrepend, Pid->Descriptors);
xForeach (Pid->InfoList, PidInfo)
{
@@ -256,6 +262,11 @@ void siDebugDescriptors (char *Prepend, struct LIST *Descriptors)
printf ("\n");
break;
+ case DESCR_NW_NAME:
+ printf ("%sDescriptor: Network Name\n", Prepend);
+ printf ("%s Name: %s\n", Prepend, xName (Descriptor));
+ break;
+
case DESCR_BOUQUET_NAME:
printf ("%sDescriptor: Bouquet Name\n", Prepend);
printf ("%s Name: %s\n", Prepend, xName (Descriptor));
@@ -336,12 +347,38 @@ void siDebugDescriptors (char *Prepend, struct LIST *Descriptors)
case DESCR_CA_IDENT:
printf ("%sDescriptor: Conditional Access Identity\n", Prepend);
{
- int j;
+ int j,k;
for (j = 0; j < ((struct CaIdentifierDescriptor *)Descriptor)->Amount; j++)
- printf ("%s SystemID: 0x%04x\n", Prepend, GetCaIdentifierID (Descriptor, j));
+ {
+ printf ("%s SystemID: 0x%04x", Prepend, GetCaIdentifierID (Descriptor, j));
+ k = GetCaIdentifierID (Descriptor, j) >> 8;
+ if (k < 0 || k > MAX_CA_IDENT) printf (" (unknown)\n");
+ else printf (" (%s)\n", CaIdents[k]);
+ }
}
break;
+ case DESCR_CA:
+ {
+ int j,k;
+
+ printf ("%sDescriptor: Conditional Access\n", Prepend);
+ printf ("%s CA type: 0x%04x", Prepend, (((struct CaDescriptor *)Descriptor)->CA_type));
+ k = (((struct CaDescriptor *)Descriptor)->CA_type) >> 8;
+ if (k < 0 || k > MAX_CA_IDENT) printf (" (unknown)\n");
+ else printf (" (%s)\n", CaIdents[k]);
+ printf ("%s CA PID: %d\n", Prepend, (((struct CaDescriptor *)Descriptor)->CA_PID));
+ printf ("%s ProviderID: 0x%04X\n", Prepend, (((struct CaDescriptor *)Descriptor)->ProviderID));
+ if (((struct CaDescriptor *)Descriptor)->DataLength > 0)
+ {
+ printf ("%s CA data:", Prepend);
+ for (j = 0; j < ((struct CaDescriptor *)Descriptor)->DataLength; j++)
+ printf (" 0x%02x", GetCaData (Descriptor, j));
+ printf ("\n");
+ }
+ }
+ break;
+
case DESCR_CONTENT:
printf ("%sDescriptor: Content\n", Prepend);
{
@@ -489,16 +526,57 @@ void siDebugDescriptors (char *Prepend, struct LIST *Descriptors)
}
break;
- case DESCR_NW_NAME:
+ case DESCR_SAT_DEL_SYS:
+ {
+ struct SatelliteDeliverySystemDescriptor *sds =
+ (struct SatelliteDeliverySystemDescriptor *)Descriptor;
+
+ printf ("%sDescriptor: Satellite Delivery System\n", Prepend);
+ printf ("%s Frequency: %ld\n", Prepend, sds->Frequency);
+ printf ("%s OrbitalPosition: %d\n", Prepend, sds->OrbitalPosition);
+ printf ("%s Polarization: %c\n", Prepend, sds->Polarization);
+ printf ("%s SymbolRate: %ld\n", Prepend, sds->SymbolRate);
+ printf ("%s FEC: %c\n", Prepend, sds->FEC);
+ }
+ break;
+
case DESCR_SERVICE_LIST:
+ {
+ struct ServiceListEntry *Entry;
+
+ printf ("%sDescriptor: Service List\n", Prepend);
+ xForeach (((struct ServiceListDescriptor *)Descriptor)->ServiceList, Entry)
+ {
+ printf ("%s Entry:\n");
+ printf ("%s ServiceID: %d\n", Prepend, Entry->ServiceID);
+ printf ("%s ServiceType: %04x\n", Prepend, Entry->ServiceType);
+ }
+ }
+ break;
+
+ case DESCR_LOCAL_TIME_OFF:
+ {
+ struct LocalTimeOffsetEntry *Offset;
+
+ printf ("%sDescriptor: Local Time Offset\n", Prepend);
+ xForeach (((struct LocalTimeOffsetDescriptor *)Descriptor)->LocalTimeOffsets, Offset)
+ {
+ printf ("%s Offset:\n");
+ printf ("%s CountryCode: %s\n", Offset->CountryCode);
+ printf ("%s RegionID: %c\n", Offset->RegionID);
+ printf ("%s CurrentOffset: %ld\n", Offset->CurrentOffset);
+ printf ("%s ChangeTime: %ld\n", Offset->ChangeTime);
+ printf ("%s NextOffset: %ld\n", Offset->NextOffset);
+ }
+ }
+ break;
+
case DESCR_STUFFING:
- case DESCR_SAT_DEL_SYS:
case DESCR_CABLE_DEL_SYS:
case DESCR_VBI_DATA:
case DESCR_VBI_TELETEXT:
case DESCR_MOSAIC:
case DESCR_TELEPHONE:
- case DESCR_LOCAL_TIME_OFF:
case DESCR_TERR_DEL_SYS:
case DESCR_ML_NW_NAME:
case DESCR_ML_BQ_NAME:
@@ -527,3 +605,39 @@ void siDebugDescriptors (char *Prepend, struct LIST *Descriptors)
return;
}
+void siDumpDescriptor (void * Descriptor)
+{
+ int Length, i;
+ unsigned char *ptr;
+
+ Length = GetDescriptorLength (Descriptor);
+ for (i = 0, ptr = (char*) Descriptor; i < Length; i++) {
+ if ((i % 8) == 0)
+ printf ("\n");
+ printf ("0x%02X ", (unsigned int) ptr[i]);
+ }
+ printf ( "\n");
+}
+
+void siDumpSection (void *Section)
+{
+ int Length, i;
+ unsigned char *ptr;
+ char str[9];
+
+ Length = GetSectionLength (Section) + 3;
+ for (i = 0, ptr = (unsigned char*) Section, memset (str, 0, 9); i < Length; i++) {
+ if ((i % 8) == 0)
+ {
+ printf (" %s\n", str);
+ memset (str, 0, 8);
+ }
+ printf ("0x%02X ", (unsigned int) ptr[i]);
+ if (ptr[i] < 0x20 || (ptr[i] > 'z' && ptr[i] < ((unsigned char )'À')) )
+ str[i % 8] = '.';
+ else
+ str[i % 8] = ptr[i];
+ }
+ printf (" %*s\n", (8 - ((abs(i - 1) % 8) ? (abs(i - 1) % 8) : 8)) * 5, str);
+}
+