#include "AdapterCommunication.h"
#include "devices/CECBusDevice.h"
+#include "devices/CECAudioSystem.h"
+#include "devices/CECPlaybackDevice.h"
+#include "devices/CECRecordingDevice.h"
+#include "devices/CECTuner.h"
+#include "devices/CECTV.h"
#include "LibCEC.h"
#include "util/StdString.h"
#include "platform/timeutils.h"
{
m_logicalAddresses.clear();
for (int iPtr = 0; iPtr < 16; iPtr++)
- m_busDevices[iPtr] = new CCECBusDevice(this, (cec_logical_address) iPtr, 0);
+ {
+ switch(iPtr)
+ {
+ case CECDEVICE_AUDIOSYSTEM:
+ m_busDevices[iPtr] = new CCECAudioSystem(this, (cec_logical_address) iPtr, 0);
+ break;
+ case CECDEVICE_PLAYBACKDEVICE1:
+ case CECDEVICE_PLAYBACKDEVICE2:
+ case CECDEVICE_PLAYBACKDEVICE3:
+ m_busDevices[iPtr] = new CCECPlaybackDevice(this, (cec_logical_address) iPtr, 0);
+ break;
+ case CECDEVICE_RECORDINGDEVICE1:
+ case CECDEVICE_RECORDINGDEVICE2:
+ case CECDEVICE_RECORDINGDEVICE3:
+ m_busDevices[iPtr] = new CCECRecordingDevice(this, (cec_logical_address) iPtr, 0);
+ break;
+ case CECDEVICE_TUNER1:
+ case CECDEVICE_TUNER2:
+ case CECDEVICE_TUNER3:
+ case CECDEVICE_TUNER4:
+ m_busDevices[iPtr] = new CCECTuner(this, (cec_logical_address) iPtr, 0);
+ break;
+ case CECDEVICE_TV:
+ m_busDevices[iPtr] = new CCECTV(this, (cec_logical_address) iPtr, 0);
+ break;
+ default:
+ m_busDevices[iPtr] = new CCECBusDevice(this, (cec_logical_address) iPtr, 0);
+ break;
+ }
+ }
}
CCECProcessor::~CCECProcessor(void)
return false;
}
-bool CCECProcessor::TryLogicalAddress(cec_logical_address address, const char *strLabel)
+bool CCECProcessor::TryLogicalAddress(cec_logical_address address, const char *strLabel, unsigned int iIndex)
{
CStdString strLog;
strLog.Format("trying logical address '%s'", strLabel);
m_logicalAddresses.set(address);
// TODO
- m_busDevices[address]->SetPhysicalAddress(CEC_DEFAULT_PHYSICAL_ADDRESS);
+ m_busDevices[address]->SetPhysicalAddress(CEC_DEFAULT_PHYSICAL_ADDRESS + iIndex);
return true;
}
return false;
}
-bool CCECProcessor::FindLogicalAddressRecordingDevice(void)
+bool CCECProcessor::FindLogicalAddressRecordingDevice(unsigned int iIndex)
{
AddLog(CEC_LOG_DEBUG, "detecting logical address for type 'recording device'");
- return TryLogicalAddress(CECDEVICE_RECORDINGDEVICE1, "recording 1") ||
- TryLogicalAddress(CECDEVICE_RECORDINGDEVICE2, "recording 2") ||
- TryLogicalAddress(CECDEVICE_RECORDINGDEVICE3, "recording 3");
+ return TryLogicalAddress(CECDEVICE_RECORDINGDEVICE1, "recording 1", iIndex) ||
+ TryLogicalAddress(CECDEVICE_RECORDINGDEVICE2, "recording 2", iIndex) ||
+ TryLogicalAddress(CECDEVICE_RECORDINGDEVICE3, "recording 3", iIndex);
}
-bool CCECProcessor::FindLogicalAddressTuner(void)
+bool CCECProcessor::FindLogicalAddressTuner(unsigned int iIndex)
{
AddLog(CEC_LOG_DEBUG, "detecting logical address for type 'tuner'");
- return TryLogicalAddress(CECDEVICE_TUNER1, "tuner 1") ||
- TryLogicalAddress(CECDEVICE_TUNER2, "tuner 2") ||
- TryLogicalAddress(CECDEVICE_TUNER3, "tuner 3") ||
- TryLogicalAddress(CECDEVICE_TUNER4, "tuner 4");
+ return TryLogicalAddress(CECDEVICE_TUNER1, "tuner 1", iIndex) ||
+ TryLogicalAddress(CECDEVICE_TUNER2, "tuner 2", iIndex) ||
+ TryLogicalAddress(CECDEVICE_TUNER3, "tuner 3", iIndex) ||
+ TryLogicalAddress(CECDEVICE_TUNER4, "tuner 4", iIndex);
}
-bool CCECProcessor::FindLogicalAddressPlaybackDevice(void)
+bool CCECProcessor::FindLogicalAddressPlaybackDevice(unsigned int iIndex)
{
AddLog(CEC_LOG_DEBUG, "detecting logical address for type 'playback device'");
- return TryLogicalAddress(CECDEVICE_PLAYBACKDEVICE1, "playback 1") ||
- TryLogicalAddress(CECDEVICE_PLAYBACKDEVICE2, "playback 2") ||
- TryLogicalAddress(CECDEVICE_PLAYBACKDEVICE3, "playback 3");
+ return TryLogicalAddress(CECDEVICE_PLAYBACKDEVICE1, "playback 1", iIndex) ||
+ TryLogicalAddress(CECDEVICE_PLAYBACKDEVICE2, "playback 2", iIndex) ||
+ TryLogicalAddress(CECDEVICE_PLAYBACKDEVICE3, "playback 3", iIndex);
}
-bool CCECProcessor::FindLogicalAddressAudioSystem(void)
+bool CCECProcessor::FindLogicalAddressAudioSystem(unsigned int iIndex)
{
AddLog(CEC_LOG_DEBUG, "detecting logical address for type 'audio'");
- return TryLogicalAddress(CECDEVICE_AUDIOSYSTEM, "audio");
+ return TryLogicalAddress(CECDEVICE_AUDIOSYSTEM, "audio", iIndex);
}
bool CCECProcessor::FindLogicalAddresses(void)
AddLog(CEC_LOG_DEBUG, strLog);
if (m_types.types[iPtr] == CEC_DEVICE_TYPE_RECORDING_DEVICE)
- bReturn &= FindLogicalAddressRecordingDevice();
+ bReturn &= FindLogicalAddressRecordingDevice(iPtr);
if (m_types.types[iPtr] == CEC_DEVICE_TYPE_TUNER)
- bReturn &= FindLogicalAddressTuner();
+ bReturn &= FindLogicalAddressTuner(iPtr);
if (m_types.types[iPtr] == CEC_DEVICE_TYPE_PLAYBACK_DEVICE)
- bReturn &= FindLogicalAddressPlaybackDevice();
+ bReturn &= FindLogicalAddressPlaybackDevice(iPtr);
if (m_types.types[iPtr] == CEC_DEVICE_TYPE_AUDIO_SYSTEM)
- bReturn &= FindLogicalAddressAudioSystem();
+ bReturn &= FindLogicalAddressAudioSystem(iPtr);
}
return bReturn;
CCECBusDevice *m_busDevices[16];
private:
- bool TryLogicalAddress(cec_logical_address address, const char *strLabel);
- bool FindLogicalAddressRecordingDevice(void);
- bool FindLogicalAddressTuner(void);
- bool FindLogicalAddressPlaybackDevice(void);
- bool FindLogicalAddressAudioSystem(void);
+ bool TryLogicalAddress(cec_logical_address address, const char *strLabel, unsigned int iIndex);
+ bool FindLogicalAddressRecordingDevice(unsigned int iIndex);
+ bool FindLogicalAddressTuner(unsigned int iIndex);
+ bool FindLogicalAddressPlaybackDevice(unsigned int iIndex);
+ bool FindLogicalAddressAudioSystem(unsigned int iIndex);
bool SetAckMask(uint16_t iMask);
void LogOutput(const cec_command &data);
LibCEC.h \
LibCECC.cpp \
util/StdString.h \
+ devices/CECAudioSystem.h \
+ devices/CECAudioSystem.cpp \
devices/CECBusDevice.cpp \
devices/CECBusDevice.h \
+ devices/CECPlaybackDevice.h \
+ devices/CECPlaybackDevice.cpp \
+ devices/CECRecordingDevice.h \
+ devices/CECRecordingDevice.cpp \
+ devices/CECTuner.h \
+ devices/CECTuner.cpp \
+ devices/CECTV.h \
+ devices/CECTV.cpp \
implementations/ANCommandHandler.cpp \
implementations/ANCommandHandler.h \
implementations/CECCommandHandler.cpp \
--- /dev/null
+/*
+ * This file is part of the libCEC(R) library.
+ *
+ * libCEC(R) is Copyright (C) 2011 Pulse-Eight Limited. All rights reserved.
+ * libCEC(R) is an original work, containing original code.
+ *
+ * libCEC(R) is a trademark of Pulse-Eight Limited.
+ *
+ * This program is dual-licensed; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ *
+ *
+ * Alternatively, you can license this library under a commercial license,
+ * please contact Pulse-Eight Licensing for more information.
+ *
+ * For more information contact:
+ * Pulse-Eight Licensing <license@pulse-eight.com>
+ * http://www.pulse-eight.com/
+ * http://www.pulse-eight.net/
+ */
+
+#include "CECAudioSystem.h"
+
+using namespace CEC;
+
+CCECAudioSystem::CCECAudioSystem(CCECProcessor *processor, cec_logical_address address, uint16_t iPhysicalAddress /* = 0 */) :
+ CCECBusDevice(processor, address, iPhysicalAddress)
+{
+ m_type = CEC_DEVICE_TYPE_AUDIO_SYSTEM;
+ m_strDeviceName = "Audio";
+}
--- /dev/null
+#pragma once
+/*
+ * This file is part of the libCEC(R) library.
+ *
+ * libCEC(R) is Copyright (C) 2011 Pulse-Eight Limited. All rights reserved.
+ * libCEC(R) is an original work, containing original code.
+ *
+ * libCEC(R) is a trademark of Pulse-Eight Limited.
+ *
+ * This program is dual-licensed; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ *
+ *
+ * Alternatively, you can license this library under a commercial license,
+ * please contact Pulse-Eight Licensing for more information.
+ *
+ * For more information contact:
+ * Pulse-Eight Licensing <license@pulse-eight.com>
+ * http://www.pulse-eight.com/
+ * http://www.pulse-eight.net/
+ */
+
+#include "CECBusDevice.h"
+
+namespace CEC
+{
+ class CCECAudioSystem : public CCECBusDevice
+ {
+ public:
+ CCECAudioSystem(CCECProcessor *processor, cec_logical_address address, uint16_t iPhysicalAddress = 0);
+ virtual ~CCECAudioSystem(void) {};
+ };
+}
m_cecVersion(CEC_VERSION_UNKNOWN)
{
m_handler = new CCECCommandHandler(this);
+
for (unsigned int iPtr = 0; iPtr < 4; iPtr++)
m_menuLanguage.language[iPtr] = '?';
m_menuLanguage.language[3] = 0;
m_menuLanguage.device = iLogicalAddress;
- m_vendor.vendor = CEC_VENDOR_UNKNOWN;
- switch(iLogicalAddress)
- {
- case CECDEVICE_AUDIOSYSTEM:
- m_type = CEC_DEVICE_TYPE_AUDIO_SYSTEM;
- m_strDeviceName = "Audio";
- break;
- case CECDEVICE_PLAYBACKDEVICE1:
- case CECDEVICE_PLAYBACKDEVICE2:
- case CECDEVICE_PLAYBACKDEVICE3:
- m_type = CEC_DEVICE_TYPE_PLAYBACK_DEVICE;
- m_strDeviceName = "Player";
- break;
- case CECDEVICE_RECORDINGDEVICE1:
- case CECDEVICE_RECORDINGDEVICE2:
- case CECDEVICE_RECORDINGDEVICE3:
- m_type = CEC_DEVICE_TYPE_RECORDING_DEVICE;
- m_strDeviceName = "Recorder";
- break;
- case CECDEVICE_TUNER1:
- case CECDEVICE_TUNER2:
- case CECDEVICE_TUNER3:
- case CECDEVICE_TUNER4:
- m_type = CEC_DEVICE_TYPE_TUNER;
- m_strDeviceName = "Tuner";
- break;
- case CECDEVICE_TV:
- m_type = CEC_DEVICE_TYPE_TV;
- m_strDeviceName = "TV";
- break;
- default:
- m_type = CEC_DEVICE_TYPE_RESERVED;
- m_strDeviceName = "Unknown";
- break;
- }
+ m_vendor.vendor = CEC_VENDOR_UNKNOWN;
+ m_type = CEC_DEVICE_TYPE_RESERVED;
+ m_strDeviceName = "Unknown";
}
CCECBusDevice::~CCECBusDevice(void)
--- /dev/null
+/*
+ * This file is part of the libCEC(R) library.
+ *
+ * libCEC(R) is Copyright (C) 2011 Pulse-Eight Limited. All rights reserved.
+ * libCEC(R) is an original work, containing original code.
+ *
+ * libCEC(R) is a trademark of Pulse-Eight Limited.
+ *
+ * This program is dual-licensed; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ *
+ *
+ * Alternatively, you can license this library under a commercial license,
+ * please contact Pulse-Eight Licensing for more information.
+ *
+ * For more information contact:
+ * Pulse-Eight Licensing <license@pulse-eight.com>
+ * http://www.pulse-eight.com/
+ * http://www.pulse-eight.net/
+ */
+
+#include "CECPlaybackDevice.h"
+
+using namespace CEC;
+
+CCECPlaybackDevice::CCECPlaybackDevice(CCECProcessor *processor, cec_logical_address address, uint16_t iPhysicalAddress /* = 0 */) :
+ CCECBusDevice(processor, address, iPhysicalAddress)
+{
+ m_type = CEC_DEVICE_TYPE_PLAYBACK_DEVICE;
+ m_strDeviceName = "Player";
+}
--- /dev/null
+#pragma once
+/*
+ * This file is part of the libCEC(R) library.
+ *
+ * libCEC(R) is Copyright (C) 2011 Pulse-Eight Limited. All rights reserved.
+ * libCEC(R) is an original work, containing original code.
+ *
+ * libCEC(R) is a trademark of Pulse-Eight Limited.
+ *
+ * This program is dual-licensed; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ *
+ *
+ * Alternatively, you can license this library under a commercial license,
+ * please contact Pulse-Eight Licensing for more information.
+ *
+ * For more information contact:
+ * Pulse-Eight Licensing <license@pulse-eight.com>
+ * http://www.pulse-eight.com/
+ * http://www.pulse-eight.net/
+ */
+
+#include "CECBusDevice.h"
+
+namespace CEC
+{
+ class CCECPlaybackDevice : public CCECBusDevice
+ {
+ public:
+ CCECPlaybackDevice(CCECProcessor *processor, cec_logical_address address, uint16_t iPhysicalAddress = 0);
+ virtual ~CCECPlaybackDevice(void) {};
+ };
+}
--- /dev/null
+/*
+ * This file is part of the libCEC(R) library.
+ *
+ * libCEC(R) is Copyright (C) 2011 Pulse-Eight Limited. All rights reserved.
+ * libCEC(R) is an original work, containing original code.
+ *
+ * libCEC(R) is a trademark of Pulse-Eight Limited.
+ *
+ * This program is dual-licensed; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ *
+ *
+ * Alternatively, you can license this library under a commercial license,
+ * please contact Pulse-Eight Licensing for more information.
+ *
+ * For more information contact:
+ * Pulse-Eight Licensing <license@pulse-eight.com>
+ * http://www.pulse-eight.com/
+ * http://www.pulse-eight.net/
+ */
+
+#include "CECRecordingDevice.h"
+
+using namespace CEC;
+
+CCECRecordingDevice::CCECRecordingDevice(CCECProcessor *processor, cec_logical_address address, uint16_t iPhysicalAddress /* = 0 */) :
+ CCECBusDevice(processor, address, iPhysicalAddress)
+{
+ m_type = CEC_DEVICE_TYPE_RECORDING_DEVICE;
+ m_strDeviceName = "Recorder";
+}
--- /dev/null
+#pragma once
+/*
+ * This file is part of the libCEC(R) library.
+ *
+ * libCEC(R) is Copyright (C) 2011 Pulse-Eight Limited. All rights reserved.
+ * libCEC(R) is an original work, containing original code.
+ *
+ * libCEC(R) is a trademark of Pulse-Eight Limited.
+ *
+ * This program is dual-licensed; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ *
+ *
+ * Alternatively, you can license this library under a commercial license,
+ * please contact Pulse-Eight Licensing for more information.
+ *
+ * For more information contact:
+ * Pulse-Eight Licensing <license@pulse-eight.com>
+ * http://www.pulse-eight.com/
+ * http://www.pulse-eight.net/
+ */
+
+#include "CECBusDevice.h"
+
+namespace CEC
+{
+ class CCECRecordingDevice : public CCECBusDevice
+ {
+ public:
+ CCECRecordingDevice(CCECProcessor *processor, cec_logical_address address, uint16_t iPhysicalAddress = 0);
+ virtual ~CCECRecordingDevice(void) {};
+ };
+}
--- /dev/null
+/*
+ * This file is part of the libCEC(R) library.
+ *
+ * libCEC(R) is Copyright (C) 2011 Pulse-Eight Limited. All rights reserved.
+ * libCEC(R) is an original work, containing original code.
+ *
+ * libCEC(R) is a trademark of Pulse-Eight Limited.
+ *
+ * This program is dual-licensed; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ *
+ *
+ * Alternatively, you can license this library under a commercial license,
+ * please contact Pulse-Eight Licensing for more information.
+ *
+ * For more information contact:
+ * Pulse-Eight Licensing <license@pulse-eight.com>
+ * http://www.pulse-eight.com/
+ * http://www.pulse-eight.net/
+ */
+
+#include "CECTV.h"
+
+using namespace CEC;
+
+CCECTV::CCECTV(CCECProcessor *processor, cec_logical_address address, uint16_t iPhysicalAddress /* = 0 */) :
+ CCECBusDevice(processor, address, iPhysicalAddress)
+{
+ m_type = CEC_DEVICE_TYPE_TV;
+ m_strDeviceName = "TV";
+}
--- /dev/null
+#pragma once
+/*
+ * This file is part of the libCEC(R) library.
+ *
+ * libCEC(R) is Copyright (C) 2011 Pulse-Eight Limited. All rights reserved.
+ * libCEC(R) is an original work, containing original code.
+ *
+ * libCEC(R) is a trademark of Pulse-Eight Limited.
+ *
+ * This program is dual-licensed; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ *
+ *
+ * Alternatively, you can license this library under a commercial license,
+ * please contact Pulse-Eight Licensing for more information.
+ *
+ * For more information contact:
+ * Pulse-Eight Licensing <license@pulse-eight.com>
+ * http://www.pulse-eight.com/
+ * http://www.pulse-eight.net/
+ */
+
+#include "CECBusDevice.h"
+
+namespace CEC
+{
+ class CCECTV : public CCECBusDevice
+ {
+ public:
+ CCECTV(CCECProcessor *processor, cec_logical_address address, uint16_t iPhysicalAddress = 0);
+ virtual ~CCECTV(void) {};
+ };
+}
--- /dev/null
+/*
+ * This file is part of the libCEC(R) library.
+ *
+ * libCEC(R) is Copyright (C) 2011 Pulse-Eight Limited. All rights reserved.
+ * libCEC(R) is an original work, containing original code.
+ *
+ * libCEC(R) is a trademark of Pulse-Eight Limited.
+ *
+ * This program is dual-licensed; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ *
+ *
+ * Alternatively, you can license this library under a commercial license,
+ * please contact Pulse-Eight Licensing for more information.
+ *
+ * For more information contact:
+ * Pulse-Eight Licensing <license@pulse-eight.com>
+ * http://www.pulse-eight.com/
+ * http://www.pulse-eight.net/
+ */
+
+#include "CECTuner.h"
+
+using namespace CEC;
+
+CCECTuner::CCECTuner(CCECProcessor *processor, cec_logical_address address, uint16_t iPhysicalAddress /* = 0 */) :
+ CCECBusDevice(processor, address, iPhysicalAddress)
+{
+ m_type = CEC_DEVICE_TYPE_TUNER;
+ m_strDeviceName = "Tuner";
+}
--- /dev/null
+#pragma once
+/*
+ * This file is part of the libCEC(R) library.
+ *
+ * libCEC(R) is Copyright (C) 2011 Pulse-Eight Limited. All rights reserved.
+ * libCEC(R) is an original work, containing original code.
+ *
+ * libCEC(R) is a trademark of Pulse-Eight Limited.
+ *
+ * This program is dual-licensed; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ *
+ *
+ * Alternatively, you can license this library under a commercial license,
+ * please contact Pulse-Eight Licensing for more information.
+ *
+ * For more information contact:
+ * Pulse-Eight Licensing <license@pulse-eight.com>
+ * http://www.pulse-eight.com/
+ * http://www.pulse-eight.net/
+ */
+
+#include "CECBusDevice.h"
+
+namespace CEC
+{
+ class CCECTuner : public CCECBusDevice
+ {
+ public:
+ CCECTuner(CCECProcessor *processor, cec_logical_address address, uint16_t iPhysicalAddress = 0);
+ virtual ~CCECTuner(void) {};
+ };
+}