--with-rpi-lib-path="/path/to/libbcm_host.so"
===============================================================================
- === CuBox ===
+ === CuBox / TDA995x ===
===============================================================================
Solid-Run's CuBox uses a combined HDMI tranceiver / CEC controller by NXP. The
device driver for it is based on an SDK by the chip vendor and is compiled into
the Linux kernel. The following options for 'configure' have been introduced:
-To enable support for the CuBox:
---enable-cubox
+To enable support for the CuBox / TDA995x:
+--enable-tda995x
To specify the path to the SDK part of the kernel driver:
--with-tda995x-toolkit-path='path/to/linux/drivers/video/dovefb/nxp_hdmi'
[use_optimisation=$enableval],
[use_optimisation=yes])
-## CuBox support
+## TDA995x support
AC_ARG_ENABLE([cubox],
- [AS_HELP_STRING([--enable-cubox],
- [enable support for the CuBox (default is no)])],
+ [AS_HELP_STRING([--enable-tda995x],
+ [enable support for the TDA995x (default is no)])],
[use_tda995x=$enableval],
[use_tda995x=no])
features="$features\n Raspberry Pi support :\t\tno"
fi
-## mark CuBox support as available
+## mark TDA995x support as available
if test "x$use_tda995x" != "xno"; then
AC_DEFINE([HAVE_TDA995X_API],[1],[Define to 1 to include CuBox support])
AM_CONDITIONAL(USE_TDA995X_API, true)
- features="$features\n CuBox support :\t\t\tyes"
- LIB_INFO="$LIB_INFO 'CuBox'"
+ features="$features\n TDA995x support :\t\t\tyes"
+ LIB_INFO="$LIB_INFO 'TDA995x'"
CPPFLAGS="$CPPFLAGS $TDA995X_CFLAGS"
else
AM_CONDITIONAL(USE_TDA995X_API, false)
- features="$features\n CuBox support :\t\t\tno"
+ features="$features\n TDA995x support :\t\t\tno"
fi
## check if our build system is complete
## CuBox (NXP) support
if USE_TDA995X_API
-libcec_la_SOURCES += adapter/CuBox/NxpCECAdapterDetection.cpp \
- adapter/CuBox/NxpCECAdapterCommunication.cpp
+libcec_la_SOURCES += adapter/TDA995x/TDA995xCECAdapterDetection.cpp \
+ adapter/TDA995x/TDA995xCECAdapterCommunication.cpp
endif
#endif
#if defined(HAVE_TDA995X_API)
-#include "CuBox/NxpCECAdapterDetection.h"
-#include "CuBox/NxpCECAdapterCommunication.h"
+#include "TDA995x/TDA995xCECAdapterDetection.h"
+#include "TDA995x/TDA995xCECAdapterCommunication.h"
#endif
using namespace std;
#endif
#if defined(HAVE_TDA995X_API)
- if (iAdaptersFound < iBufSize && CNxpCECAdapterDetection::FindAdapter() &&
+ if (iAdaptersFound < iBufSize && CTDA995xCECAdapterDetection::FindAdapter() &&
(!strDevicePath || !strcmp(strDevicePath, CEC_TDA995x_VIRTUAL_COM)))
{
snprintf(deviceList[iAdaptersFound].path, 1024, CEC_TDA995x_PATH);
{
#if defined(HAVE_TDA995X_API)
if (!strcmp(strPort, CEC_TDA995x_VIRTUAL_COM))
- return new CNxpCECAdapterCommunication(m_lib->m_cec);
+ return new CTDA995xCECAdapterCommunication(m_lib->m_cec);
#endif
#if defined(HAVE_RPI_API)
#include "env.h"
#if defined(HAVE_TDA995X_API)
-#include "NxpCECAdapterCommunication.h"
+#include "TDA995xCECAdapterCommunication.h"
#include "lib/CECTypeUtils.h"
#include "lib/LibCEC.h"
#define CEC_MSG_FAIL_DATA_NOT_ACK 0x86 /*Message transmisson failed: Databyte not acknowledged*/
-CNxpCECAdapterCommunication::CNxpCECAdapterCommunication(IAdapterCommunicationCallback *callback) :
+CTDA995xCECAdapterCommunication::CTDA995xCECAdapterCommunication(IAdapterCommunicationCallback *callback) :
IAdapterCommunication(callback),
m_bLogicalAddressChanged(false)
{
}
-CNxpCECAdapterCommunication::~CNxpCECAdapterCommunication(void)
+CTDA995xCECAdapterCommunication::~CTDA995xCECAdapterCommunication(void)
{
Close();
}
-bool CNxpCECAdapterCommunication::IsOpen(void)
+bool CTDA995xCECAdapterCommunication::IsOpen(void)
{
return IsInitialised() && m_dev->IsOpen();
}
-bool CNxpCECAdapterCommunication::Open(uint32_t iTimeoutMs, bool UNUSED(bSkipChecks), bool bStartListening)
+bool CTDA995xCECAdapterCommunication::Open(uint32_t iTimeoutMs, bool UNUSED(bSkipChecks), bool bStartListening)
{
if (m_dev->Open(iTimeoutMs))
{
}
-void CNxpCECAdapterCommunication::Close(void)
+void CTDA995xCECAdapterCommunication::Close(void)
{
StopThread(0);
}
-std::string CNxpCECAdapterCommunication::GetError(void) const
+std::string CTDA995xCECAdapterCommunication::GetError(void) const
{
std::string strError(m_strError);
return strError;
}
-cec_adapter_message_state CNxpCECAdapterCommunication::Write(
+cec_adapter_message_state CTDA995xCECAdapterCommunication::Write(
const cec_command &data, bool &UNUSED(bRetry), uint8_t UNUSED(iLineTimeout), bool UNUSED(bIsReply))
{
cec_frame frame;
}
-uint16_t CNxpCECAdapterCommunication::GetFirmwareVersion(void)
+uint16_t CTDA995xCECAdapterCommunication::GetFirmwareVersion(void)
{
cec_sw_version vers = { 0 };
}
-cec_vendor_id CNxpCECAdapterCommunication::GetVendorId(void)
+cec_vendor_id CTDA995xCECAdapterCommunication::GetVendorId(void)
{
cec_raw_info info;
}
-uint16_t CNxpCECAdapterCommunication::GetPhysicalAddress(void)
+uint16_t CTDA995xCECAdapterCommunication::GetPhysicalAddress(void)
{
cec_raw_info info;
}
-cec_logical_addresses CNxpCECAdapterCommunication::GetLogicalAddresses(void)
+cec_logical_addresses CTDA995xCECAdapterCommunication::GetLogicalAddresses(void)
{
CLockObject lock(m_mutex);
}
-bool CNxpCECAdapterCommunication::SetLogicalAddresses(const cec_logical_addresses &addresses)
+bool CTDA995xCECAdapterCommunication::SetLogicalAddresses(const cec_logical_addresses &addresses)
{
unsigned char log_addr = addresses.primary;
}
-void CNxpCECAdapterCommunication::HandleLogicalAddressLost(cec_logical_address UNUSED(oldAddress))
+void CTDA995xCECAdapterCommunication::HandleLogicalAddressLost(cec_logical_address UNUSED(oldAddress))
{
unsigned char log_addr = CECDEVICE_BROADCAST;
}
-void *CNxpCECAdapterCommunication::Process(void)
+void *CTDA995xCECAdapterCommunication::Process(void)
{
bool bHandled;
cec_frame frame;
#include "lib/adapter/AdapterCommunication.h"
#include <map>
-#define NXP_ADAPTER_VID 0x0471
-#define NXP_ADAPTER_PID 0x1001
+#define TDA995X_ADAPTER_VID 0x0471
+#define TDA995X_ADAPTER_PID 0x1001
namespace PLATFORM
{
{
class CAdapterMessageQueueEntry;
- class CNxpCECAdapterCommunication : public IAdapterCommunication, public PLATFORM::CThread
+ class CTDA995xCECAdapterCommunication : public IAdapterCommunication, public PLATFORM::CThread
{
public:
/*!
* @brief Create a new USB-CEC communication handler.
* @param callback The callback to use for incoming CEC commands.
*/
- CNxpCECAdapterCommunication(IAdapterCommunicationCallback *callback);
- virtual ~CNxpCECAdapterCommunication(void);
+ CTDA995xCECAdapterCommunication(IAdapterCommunicationCallback *callback);
+ virtual ~CTDA995xCECAdapterCommunication(void);
/** @name IAdapterCommunication implementation */
///{
bool IsRunningLatestFirmware(void) { return true; }
bool PersistConfiguration(const libcec_configuration & UNUSED(configuration)) { return false; }
bool GetConfiguration(libcec_configuration & UNUSED(configuration)) { return false; }
- std::string GetPortName(void) { return std::string("NXP"); }
+ std::string GetPortName(void) { return std::string("TDA995X"); }
uint16_t GetPhysicalAddress(void);
bool SetControlledMode(bool UNUSED(controlled)) { return true; }
cec_vendor_id GetVendorId(void);
bool SupportsSourceLogicalAddress(const cec_logical_address address) { return address > CECDEVICE_TV && address <= CECDEVICE_BROADCAST; }
cec_adapter_type GetAdapterType(void) { return ADAPTERTYPE_TDA995x; }
- uint16_t GetAdapterVendorId(void) const { return NXP_ADAPTER_VID; }
- uint16_t GetAdapterProductId(void) const { return NXP_ADAPTER_PID; }
+ uint16_t GetAdapterVendorId(void) const { return TDA995X_ADAPTER_VID; }
+ uint16_t GetAdapterProductId(void) const { return TDA995X_ADAPTER_PID; }
void HandleLogicalAddressLost(cec_logical_address oldAddress);
///}
#include <stdio.h>
#if defined(HAVE_TDA995X_API)
-#include "NxpCECAdapterDetection.h"
+#include "TDA995xCECAdapterDetection.h"
extern "C" {
#define __cec_h__
using namespace CEC;
-bool CNxpCECAdapterDetection::FindAdapter(void)
+bool CTDA995xCECAdapterDetection::FindAdapter(void)
{
return access(CEC_TDA995x_PATH, 0) == 0;
}
namespace CEC
{
- class CNxpCECAdapterDetection
+ class CTDA995xCECAdapterDetection
{
public:
static bool FindAdapter(void);