-libcec (2.1.0-1) unstable; urgency=low
+libcec (2.1.1-1) unstable; urgency=low
+
+ * changed / added:
+ * send an alert when the TV does not respond to polls
+ * fixed:
+ * LG didn't switch sources after the TV powered up
+ * always poll a device when the status is unknown, and don't try to
+ determine whether it needs to be polled by checking the status of other
+ devices
+ * don't mark a device as inactive when receiving a routing change message,
+ only when another device was made acive. fixes the issue that rc
+ passthrough doesn't work when a tv sends a quick routing change to
+ another port before requesting the active source when coming out of
+ standby
+ * LibCecSharp: fixed 14 char long OSD name (wasn't \0 terminated)
+ * LibCecSharp: fixed return value of GetActiveDevices(). issue #131
+ * cec-tray: fixed index out of range exception in CECSettingNumeric.cs.
+ bugzid: 2082
+ * cec-tray: ensure that the tray app only initialises once. bugzid: 2082
+ * rpi: don't set the physical address to 1.0.0.0 when receiving
+ VC_HDMI_UNPLUGGED. it may wake up device when they were just sent to
+ standby. issue #142
+ * osx: use the correct dylib name in cecloader.h, used by cec-client
+
+ -- Pulse-Eight Packaging <packaging@pulse-eight.com> Fri, 8 Mar 2013 17:21:00 +0100
+
+ libcec (2.1.0-1) unstable; urgency=low
* changed / added:
* added vendor id for Denon
-libcec (2.1.0-1) unstable; urgency=low
+libcec (2.1.1-1) unstable; urgency=low
+
+ * changed / added:
+ * send an alert when the TV does not respond to polls
+ * fixed:
+ * LG didn't switch sources after the TV powered up
+ * always poll a device when the status is unknown, and don't try to
+ determine whether it needs to be polled by checking the status of other
+ devices
+ * don't mark a device as inactive when receiving a routing change message,
+ only when another device was made acive. fixes the issue that rc
+ passthrough doesn't work when a tv sends a quick routing change to
+ another port before requesting the active source when coming out of
+ standby
+ * LibCecSharp: fixed 14 char long OSD name (wasn't \0 terminated)
+ * LibCecSharp: fixed return value of GetActiveDevices(). issue #131
+ * cec-tray: fixed index out of range exception in CECSettingNumeric.cs.
+ bugzid: 2082
+ * cec-tray: ensure that the tray app only initialises once. bugzid: 2082
+ * rpi: don't set the physical address to 1.0.0.0 when receiving
+ VC_HDMI_UNPLUGGED. it may wake up device when they were just sent to
+ standby. issue #142
+ * osx: use the correct dylib name in cecloader.h, used by cec-client
+
+ -- Pulse-Eight Packaging <packaging@pulse-eight.com> Fri, 8 Mar 2013 17:21:00 +0100
+
+ libcec (2.1.0-1) unstable; urgency=low
* changed / added:
* added vendor id for Denon
if (!g_libCEC)
{
#if defined(__APPLE__)
- g_libCEC = dlopen(strLib ? strLib : "libcec.dylib", RTLD_LAZY);
+ g_libCEC = dlopen(strLib ? strLib : "libcec." CEC_LIB_VERSION_MAJOR_STR ".dylib", RTLD_LAZY);
#else
g_libCEC = dlopen(strLib ? strLib : "libcec.so." CEC_LIB_VERSION_MAJOR_STR, RTLD_LAZY);
#endif
CEC_ALERT_CONNECTION_LOST,
CEC_ALERT_PERMISSION_ERROR,
CEC_ALERT_PORT_BUSY,
- CEC_ALERT_PHYSICAL_ADDRESS_ERROR
+ CEC_ALERT_PHYSICAL_ADDRESS_ERROR,
+ CEC_ALERT_TV_POLL_FAILED
} libcec_alert;
typedef enum libcec_parameter_type
CEC_CLIENT_VERSION_2_0_4 = 0x2004,
CEC_CLIENT_VERSION_2_0_5 = 0x2005,
CEC_CLIENT_VERSION_2_1_0 = 0x2100,
- CEC_CLIENT_VERSION_CURRENT = 0x2100
+ CEC_CLIENT_VERSION_2_1_1 = 0x2101,
+ CEC_CLIENT_VERSION_CURRENT = 0x2101
} cec_client_version;
typedef enum cec_server_version
CEC_SERVER_VERSION_2_0_4 = 0x2004,
CEC_SERVER_VERSION_2_0_5 = 0x2005,
CEC_SERVER_VERSION_2_1_0 = 0x2100,
- CEC_SERVER_VERSION_CURRENT = 0x2100
+ CEC_SERVER_VERSION_2_1_1 = 0x2101,
+ CEC_SERVER_VERSION_CURRENT = 0x2101
} cec_server_version;
struct libcec_configuration
!include "LogicLib.nsh"
!include "x64.nsh"
-Name "Pulse-Eight libCEC version 2.1.0"
+Name "Pulse-Eight libCEC version 2.1.1"
OutFile "..\build\libCEC-installer.exe"
XPStyle on
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
-[assembly: AssemblyVersion("2.1.0.0")]
-[assembly: AssemblyFileVersion("2.1.0.0")]
+[assembly: AssemblyVersion("2.1.1.0")]
+[assembly: AssemblyFileVersion("2.1.1.0")]
[assembly:AssemblyTrademarkAttribute("")];
[assembly:AssemblyCultureAttribute("")];
-[assembly:AssemblyVersionAttribute("2.1.0.0")];
+[assembly:AssemblyVersionAttribute("2.1.1.0")];
[assembly:ComVisible(false)];
[assembly:CLSCompliantAttribute(true)];
/// <summary>
/// v2.1.0
/// </summary>
- Version2_1_0 = 0x2100
+ Version2_1_0 = 0x2100,
+ /// <summary>
+ /// v2.1.1
+ /// </summary>
+ Version2_1_1 = 0x2101
};
/// <summary>
/// <summary>
/// v2.1.0
/// </summary>
- Version2_1_0 = 0x2100
+ Version2_1_0 = 0x2100,
+ /// <summary>
+ /// v2.1.1
+ /// </summary>
+ Version2_1_1 = 0x2101
};
/// <summary>
PhysicalAddress = CEC_DEFAULT_PHYSICAL_ADDRESS;
BaseDevice = (CecLogicalAddress)CEC_DEFAULT_BASE_DEVICE;
HDMIPort = CEC_DEFAULT_HDMI_PORT;
- ClientVersion = CecClientVersion::Version2_1_0;
- ServerVersion = CecServerVersion::Version2_1_0;
+ ClientVersion = CecClientVersion::Version2_1_1;
+ ServerVersion = CecServerVersion::Version2_1_1;
TvVendor = CecVendorId::Unknown;
GetSettingsFromROM = false;
for (uint8_t iPtr = 0; iPtr < 16; iPtr++)
if (activeDevices[iPtr])
- retVal->Addresses[iDevices++] = (CecLogicalAddress)iPtr;
+ retVal->Set((CecLogicalAddress)iPtr);
return retVal;
}
String ^ GetDeviceOSDName(CecLogicalAddress logicalAddress)
{
cec_osd_name osd = m_libCec->GetDeviceOSDName((cec_logical_address) logicalAddress);
- return gcnew String(osd.name);
+ // we need to terminate with \0, and we only got 14 chars in osd.name
+ char strOsdName[15];
+ memset(strOsdName, 0, sizeof(strOsdName));
+ memcpy(strOsdName, osd.name, sizeof(osd.name));
+ return gcnew String(strOsdName);
}
/// <summary>
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
-[assembly: AssemblyVersion("2.1.0.0")]
-[assembly: AssemblyFileVersion("2.1.0.0")]
+[assembly: AssemblyVersion("2.1.1.0")]
+[assembly: AssemblyFileVersion("2.1.1.0")]
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
-// Runtime Version:2.0.50727.5448
+// Runtime Version:2.0.50727.5466
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
}
/// <summary>
- /// Looks up a localized string similar to Pulse-Eight USB-CEC Adapter - libCECTray BETA3.
+ /// Looks up a localized string similar to Pulse-Eight USB-CEC Adapter - libCECTray.
/// </summary>
internal static string app_name {
get {
<value>Could not detect to any CEC adapter. Please check your configuration. Do you want to try again?</value>
</data>
<data name="app_name" xml:space="preserve">
- <value>Pulse-Eight USB-CEC Adapter - libCECTray BETA3</value>
+ <value>Pulse-Eight USB-CEC Adapter - libCECTray</value>
</data>
<data name="device_type_changed" xml:space="preserve">
<value>You have changed the device type. Persist the configuration, and restart the application to use the new setting.</value>
/// </summary>
public void Initialise()
{
+ // only load once
+ if (_initialised)
+ return;
+ _initialised = true;
+
CECActions.ConnectToDevice(Config);
Applications.Initialise(this);
}
Lib.DisableCallbacks();
Lib.StandbyDevices(CecLogicalAddress.Broadcast);
Lib.Close();
+ _initialised = false;
}
/// <summary>
private readonly CECTray _gui;
public Actions CECActions;
private bool _deviceChangeWarningDisplayed;
+ private bool _initialised;
#endregion
}
ResetItems(BaseItems.Count == 0);
- control.SelectedValueChanged += delegate
- {
- Value = BaseItems[control.SelectedIndex];
- };
+ if (BaseItems.Count > 0 && control.SelectedIndex < BaseItems.Count)
+ {
+ control.SelectedValueChanged += delegate
+ {
+ Value = BaseItems[control.SelectedIndex];
+ };
+ }
}
public override Control ValueControl
#define CEC_PROCESSOR_SIGNAL_WAIT_TIME 1000
#define ACTIVE_SOURCE_CHECK_INTERVAL 500
+#define TV_PRESENT_CHECK_INTERVAL 30000
#define ToString(x) CCECTypeUtils::ToString(x)
cec_command command; command.Clear();
CTimeout activeSourceCheck(ACTIVE_SOURCE_CHECK_INTERVAL);
+ CTimeout tvPresentCheck(TV_PRESENT_CHECK_INTERVAL);
// as long as we're not being stopped and the connection is open
while (!IsStopped() && m_communication->IsOpen())
TransmitPendingActiveSourceCommands();
activeSourceCheck.Init(ACTIVE_SOURCE_CHECK_INTERVAL);
}
+
+ // check whether the TV is present and responding
+ if (tvPresentCheck.TimeLeft() == 0)
+ {
+ if (!m_busDevices->At(CECDEVICE_TV)->IsPresent())
+ {
+ libcec_parameter param;
+ param.paramType = CEC_PARAMETER_TYPE_STRING;
+ param.paramData = (void*)"TV does not respond to CEC polls";
+ GetPrimaryClient()->Alert(CEC_ALERT_TV_POLL_FAILED, param);
+ }
+ tvPresentCheck.Init(TV_PRESENT_CHECK_INTERVAL);
+ }
}
}
return "2.0.5";
case CEC_CLIENT_VERSION_2_1_0:
return "2.1.0";
+ case CEC_CLIENT_VERSION_2_1_1:
+ return "2.1.1";
default:
return "Unknown";
}
return "2.0.5";
case CEC_SERVER_VERSION_2_1_0:
return "2.1.0";
+ case CEC_SERVER_VERSION_2_1_1:
+ return "2.1.1";
default:
return "Unknown";
}
{
switch(reason)
{
- case VC_HDMI_UNPLUGGED:
- {
- m_callback->HandlePhysicalAddressChanged(0x1000);
- break;
- }
case VC_HDMI_ATTACHED:
{
uint16_t iNewAddress = GetPhysicalAddress();
m_callback->HandlePhysicalAddressChanged(iNewAddress);
break;
}
+ case VC_HDMI_UNPLUGGED:
case VC_HDMI_DVI:
case VC_HDMI_HDMI:
case VC_HDMI_HDCP_UNAUTH:
if (bNeedsPoll)
{
bool bPollAcked(false);
- if (bNeedsPoll && NeedsPoll())
+ if (bNeedsPoll)
bPollAcked = m_processor->PollDevice(m_iLogicalAddress);
status = bPollAcked ? CEC_DEVICE_STATUS_PRESENT : CEC_DEVICE_STATUS_NOT_PRESENT;
else
newRoute->MarkAsActiveSource();
}
- else
- {
- // get the current active source and it's physical address
- CCECBusDevice *device = m_processor->GetDevices()->GetActiveSource();
- uint16_t iPhysicalAddress(device ? device->GetCurrentPhysicalAddress() : CEC_INVALID_PHYSICAL_ADDRESS);
-
- // check whether the route below the device changed
- if (CLibCEC::IsValidPhysicalAddress(iPhysicalAddress) &&
- !CCECTypeUtils::PhysicalAddressIsIncluded(iPhysicalAddress, iRoute))
- device->MarkAsInactiveSource();
- }
}
void CCECBusDevice::SetStreamPath(uint16_t iNewAddress, uint16_t iOldAddress /* = CEC_INVALID_PHYSICAL_ADDRESS */)
{
m_processor->GetPrimaryDevice()->SetPowerStatus(CEC_POWER_STATUS_IN_TRANSITION_STANDBY_TO_ON);
TransmitVendorCommand0205(command.destination, command.initiator);
+
+ CCECBusDevice* dev = m_processor->GetDevice(command.destination);
+ if (dev && dev->IsHandledByLibCEC() && dev->IsActiveSource())
+ dev->TransmitActiveSource(false);
}
void CSLCommandHandler::TransmitVendorCommand0205(const cec_logical_address iSource, const cec_logical_address iDestination)
response.PushBack(SL_COMMAND_TYPE_HDDRECORDER);
Transmit(response, false, true);
+ SetSLInitialised();
}
void CSLCommandHandler::HandleVendorCommandPowerOn(const cec_command &command)