2014-03-08 12:07:47 +01:00
|
|
|
/*
|
|
|
|
* config.h: SAT>IP plugin for the Video Disk Recorder
|
|
|
|
*
|
|
|
|
* See the README file for copyright information and how to reach the author.
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __SATIP_CONFIG_H
|
|
|
|
#define __SATIP_CONFIG_H
|
|
|
|
|
|
|
|
#include <vdr/menuitems.h>
|
|
|
|
#include "common.h"
|
|
|
|
|
|
|
|
class cSatipConfig
|
|
|
|
{
|
|
|
|
private:
|
2014-03-10 20:21:08 +01:00
|
|
|
unsigned int operatingModeM;
|
2014-12-21 15:11:05 +01:00
|
|
|
unsigned int traceModeM;
|
2015-01-05 23:58:35 +01:00
|
|
|
unsigned int ciExtensionM;
|
2014-03-08 12:07:47 +01:00
|
|
|
unsigned int eitScanM;
|
|
|
|
unsigned int useBytesM;
|
2015-01-17 16:29:21 +01:00
|
|
|
bool disableServerQuirksM;
|
2015-01-15 18:27:02 +01:00
|
|
|
bool useSingleModelServersM;
|
2015-01-11 00:49:59 +01:00
|
|
|
int cicamsM[MAX_CICAM_COUNT];
|
2014-10-31 21:07:33 +01:00
|
|
|
int disabledSourcesM[MAX_DISABLED_SOURCES_COUNT];
|
2014-03-08 12:07:47 +01:00
|
|
|
int disabledFiltersM[SECTION_FILTER_TABLE_SIZE];
|
|
|
|
|
|
|
|
public:
|
2014-12-07 15:09:56 +01:00
|
|
|
enum eOperatingMode {
|
2014-03-13 17:23:55 +01:00
|
|
|
eOperatingModeOff = 0,
|
|
|
|
eOperatingModeLow,
|
|
|
|
eOperatingModeNormal,
|
|
|
|
eOperatingModeHigh,
|
|
|
|
eOperatingModeCount
|
2014-03-10 20:21:08 +01:00
|
|
|
};
|
2014-12-21 15:11:05 +01:00
|
|
|
enum eTraceMode {
|
2015-03-04 18:43:01 +01:00
|
|
|
eTraceModeNormal = 0x0000,
|
|
|
|
eTraceModeDebug1 = 0x0001,
|
|
|
|
eTraceModeDebug2 = 0x0002,
|
|
|
|
eTraceModeDebug3 = 0x0004,
|
|
|
|
eTraceModeDebug4 = 0x0008,
|
|
|
|
eTraceModeDebug5 = 0x0010,
|
|
|
|
eTraceModeDebug6 = 0x0020,
|
|
|
|
eTraceModeDebug7 = 0x0040,
|
|
|
|
eTraceModeDebug8 = 0x0080,
|
|
|
|
eTraceModeDebug9 = 0x0100,
|
|
|
|
eTraceModeDebug10 = 0x0200,
|
|
|
|
eTraceModeDebug11 = 0x0400,
|
|
|
|
eTraceModeDebug12 = 0x0800,
|
|
|
|
eTraceModeDebug13 = 0x1000,
|
|
|
|
eTraceModeDebug14 = 0x2000,
|
|
|
|
eTraceModeDebug15 = 0x4000,
|
|
|
|
eTraceModeDebug16 = 0x8000,
|
|
|
|
eTraceModeMask = 0xFFFF
|
2014-12-03 18:57:23 +01:00
|
|
|
};
|
2014-03-08 12:07:47 +01:00
|
|
|
cSatipConfig();
|
2014-03-10 20:21:08 +01:00
|
|
|
unsigned int GetOperatingMode(void) const { return operatingModeM; }
|
2014-03-13 17:23:55 +01:00
|
|
|
bool IsOperatingModeOff(void) const { return (operatingModeM == eOperatingModeOff); }
|
|
|
|
bool IsOperatingModeLow(void) const { return (operatingModeM == eOperatingModeLow); }
|
|
|
|
bool IsOperatingModeNormal(void) const { return (operatingModeM == eOperatingModeNormal); }
|
|
|
|
bool IsOperatingModeHigh(void) const { return (operatingModeM == eOperatingModeHigh); }
|
|
|
|
void ToggleOperatingMode(void) { operatingModeM = (operatingModeM + 1) % eOperatingModeCount; }
|
2014-12-21 15:11:05 +01:00
|
|
|
unsigned int GetTraceMode(void) const { return traceModeM; }
|
|
|
|
bool IsTraceMode(eTraceMode modeP) const { return (traceModeM & modeP); }
|
2015-01-05 23:58:35 +01:00
|
|
|
unsigned int GetCIExtension(void) const { return ciExtensionM; }
|
2015-01-11 00:49:59 +01:00
|
|
|
int GetCICAM(unsigned int indexP) const;
|
2014-03-08 12:07:47 +01:00
|
|
|
unsigned int GetEITScan(void) const { return eitScanM; }
|
|
|
|
unsigned int GetUseBytes(void) const { return useBytesM; }
|
2015-01-17 16:29:21 +01:00
|
|
|
bool GetDisableServerQuirks(void) const { return disableServerQuirksM; }
|
2015-01-15 18:27:02 +01:00
|
|
|
bool GetUseSingleModelServers(void) const { return useSingleModelServersM; }
|
2014-10-31 21:07:33 +01:00
|
|
|
unsigned int GetDisabledSourcesCount(void) const;
|
|
|
|
int GetDisabledSources(unsigned int indexP) const;
|
2014-03-08 12:07:47 +01:00
|
|
|
unsigned int GetDisabledFiltersCount(void) const;
|
|
|
|
int GetDisabledFilters(unsigned int indexP) const;
|
|
|
|
|
2014-03-10 20:21:08 +01:00
|
|
|
void SetOperatingMode(unsigned int operatingModeP) { operatingModeM = operatingModeP; }
|
2014-12-21 15:11:05 +01:00
|
|
|
void SetTraceMode(unsigned int modeP) { traceModeM = (modeP & eTraceModeMask); }
|
2015-01-05 23:58:35 +01:00
|
|
|
void SetCIExtension(unsigned int onOffP) { ciExtensionM = onOffP; }
|
2015-01-11 00:49:59 +01:00
|
|
|
void SetCICAM(unsigned int indexP, int cicamP);
|
2014-03-08 12:07:47 +01:00
|
|
|
void SetEITScan(unsigned int onOffP) { eitScanM = onOffP; }
|
|
|
|
void SetUseBytes(unsigned int onOffP) { useBytesM = onOffP; }
|
2015-01-17 16:29:21 +01:00
|
|
|
void SetDisableServerQuirks(bool onOffP) { disableServerQuirksM = onOffP; }
|
2015-01-15 18:27:02 +01:00
|
|
|
void SetUseSingleModelServers(bool onOffP) { useSingleModelServersM = onOffP; }
|
2014-10-31 21:07:33 +01:00
|
|
|
void SetDisabledSources(unsigned int indexP, int sourceP);
|
2014-03-08 12:07:47 +01:00
|
|
|
void SetDisabledFilters(unsigned int indexP, int numberP);
|
|
|
|
};
|
|
|
|
|
|
|
|
extern cSatipConfig SatipConfig;
|
|
|
|
|
|
|
|
#endif // __SATIP_CONFIG_H
|