diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Bridges/JoinMaps/DmRmcControllerJoinMap.cs b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Bridges/JoinMaps/DmRmcControllerJoinMap.cs
index ec4661a4..9ff3f234 100644
--- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Bridges/JoinMaps/DmRmcControllerJoinMap.cs
+++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Bridges/JoinMaps/DmRmcControllerJoinMap.cs
@@ -36,6 +36,28 @@ namespace PepperDash.Essentials.Core.Bridges
public JoinDataComplete AudioVideoSource = new JoinDataComplete(new JoinData { JoinNumber = 1, JoinSpan = 1 },
new JoinMetadata { Description = "DM RMC Audio Video Source Set / Get", JoinCapabilities = eJoinCapabilities.ToFromSIMPL, JoinType = eJoinType.Analog });
+ [JoinName("HdcpSupportCapability")]
+ public JoinDataComplete HdcpSupportCapability = new JoinDataComplete(new JoinData { JoinNumber = 2, JoinSpan = 1 },
+ new JoinMetadata { Description = "DM RMC HDCP Support Capability", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Analog });
+
+ [JoinName("Port1HdcpState")]
+ public JoinDataComplete Port1HdcpState = new JoinDataComplete(new JoinData { JoinNumber = 3, JoinSpan = 1 },
+ new JoinMetadata { Description = "DM RMC Port 1 (DM) HDCP State Set / Get", JoinCapabilities = eJoinCapabilities.ToFromSIMPL, JoinType = eJoinType.Analog });
+
+ [JoinName("Port2HdcpState")]
+ public JoinDataComplete Port2HdcpState = new JoinDataComplete(new JoinData { JoinNumber = 4, JoinSpan = 1 },
+ new JoinMetadata { Description = "DM TX Port 2 (HDMI) HDCP State Set / Get", JoinCapabilities = eJoinCapabilities.ToFromSIMPL, JoinType = eJoinType.Analog });
+
+ [JoinName("HdmiInputSync")]
+ public JoinDataComplete HdmiInputSync = new JoinDataComplete(new JoinData { JoinNumber = 2, JoinSpan = 1 },
+ new JoinMetadata { Description = "DM RMC HDMI Input Sync", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Digital });
+
+ [JoinName("HdcpInputPortCount")]
+ public JoinDataComplete HdcpInputPortCount = new JoinDataComplete(new JoinData { JoinNumber = 5, JoinSpan = 1 },
+ new JoinMetadata { Description = "Number of Input Ports that support HDCP", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Analog });
+
+
+
///
/// Constructor to use when instantiating this Join Map without inheriting from it
///
diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Bridges/JoinMaps/DmTxControllerJoinMap.cs b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Bridges/JoinMaps/DmTxControllerJoinMap.cs
index 11e20375..d4fb8d60 100644
--- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Bridges/JoinMaps/DmTxControllerJoinMap.cs
+++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Bridges/JoinMaps/DmTxControllerJoinMap.cs
@@ -68,6 +68,11 @@ namespace PepperDash.Essentials.Core.Bridges
public JoinDataComplete Port3HdcpState = new JoinDataComplete(new JoinData { JoinNumber = 8, JoinSpan = 1 },
new JoinMetadata { Description = "DM TX Port 3 HDCP State Set / Get", JoinCapabilities = eJoinCapabilities.ToFromSIMPL, JoinType = eJoinType.Analog });
+ [JoinName("HdcpInputPortCount")]
+ public JoinDataComplete HdcpInputPortCount = new JoinDataComplete(new JoinData { JoinNumber = 9, JoinSpan = 1 },
+ new JoinMetadata { Description = "Number of Input Ports that support HDCP", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Analog });
+
+
///
/// Constructor to use when instantiating this Join Map without inheriting from it
diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Routing/RoutingInterfaces.cs b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Routing/RoutingInterfaces.cs
index 467bf045..dbad3712 100644
--- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Routing/RoutingInterfaces.cs
+++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Routing/RoutingInterfaces.cs
@@ -20,7 +20,6 @@ namespace PepperDash.Essentials.Core
//*******************************************************************************************
// Interfaces
-
///
/// For rooms with a single presentation source, change event
///
diff --git a/essentials-framework/Essentials DM/Essentials_DM/Chassis/DmpsRoutingController.cs b/essentials-framework/Essentials DM/Essentials_DM/Chassis/DmpsRoutingController.cs
index a3092f71..46f33f9e 100644
--- a/essentials-framework/Essentials DM/Essentials_DM/Chassis/DmpsRoutingController.cs
+++ b/essentials-framework/Essentials DM/Essentials_DM/Chassis/DmpsRoutingController.cs
@@ -692,14 +692,14 @@ namespace PepperDash.Essentials.DM
var cecPort = hdmiInputCard.HdmiInputPort;
- AddInputPortWithDebug(number, string.Format("HdmiIn{0}", number), eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.Hdmi, cecPort);
+ AddInputPortWithDebug(number, string.Format("HdmiIn1{0}", number), eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.Hdmi, cecPort);
}
else if (inputCard is Card.Dmps3HdmiInput)
{
var hdmiInputCard = inputCard as Card.Dmps3HdmiInput;
var cecPort = hdmiInputCard.HdmiInputPort;
- AddInputPortWithDebug(number, string.Format("HdmiIn{0}", number), eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.Hdmi, cecPort);
+ AddInputPortWithDebug(number, string.Format("HdmiIn1{0}", number), eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.Hdmi, cecPort);
AddInputPortWithDebug(number, string.Format("HudioIn{1}", number), eRoutingSignalType.Audio, eRoutingPortConnectionType.LineAudio);
}
else if (inputCard is Card.Dmps3HdmiVgaInput)
diff --git a/essentials-framework/Essentials DM/Essentials_DM/DmPortName.cs b/essentials-framework/Essentials DM/Essentials_DM/DmPortName.cs
index 4ce4d34d..591f163f 100644
--- a/essentials-framework/Essentials DM/Essentials_DM/DmPortName.cs
+++ b/essentials-framework/Essentials DM/Essentials_DM/DmPortName.cs
@@ -28,7 +28,7 @@ namespace PepperDash.Essentials.DM
public const string DmOut2 = "DmOut2";
public const string FromTx = "FromTx";
public const string Hdmi = "Hdmi";
- public const string HdmiIn = "HdmiIn";
+ public const string HdmiIn = "HdmiIn1";
public const string HdmiIn1 = "HdmiIn1";
public const string HdmiIn2 = "HdmiIn2";
public const string HdmiOut1 = "HdmiOut1";
diff --git a/essentials-framework/Essentials DM/Essentials_DM/Endpoints/EndpointInterfaces.cs b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/EndpointInterfaces.cs
new file mode 100644
index 00000000..adbb74dd
--- /dev/null
+++ b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/EndpointInterfaces.cs
@@ -0,0 +1,105 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using Crestron.SimplSharp;
+using Crestron.SimplSharpPro.DM;
+using Crestron.SimplSharpPro.DM.Endpoints;
+using PepperDash.Essentials.Core;
+
+namespace PepperDash_Essentials_DM
+{
+ public interface IHasDmInHdcpSet
+ {
+ void SetDmInHdcpState(eHdcpCapabilityType hdcpState);
+ }
+
+ public interface IHasDmInHdcpGet
+ {
+ IntFeedback DmInHdcpStateFeedback { get; }
+ }
+
+ public interface IHasDmInHdcp : IHasDmInHdcpGet, IHasDmInHdcpSet
+ {
+ eHdcpCapabilityType DmInHdcpCapability { get; }
+ }
+
+
+
+
+ public interface IHasHdmiInHdcpSet
+ {
+ void SetHdmiInHdcpState(eHdcpCapabilityType hdcpState);
+ }
+
+ public interface IHasHdmiInHdcpGet
+ {
+ IntFeedback HdmiInHdcpStateFeedback { get; }
+ }
+
+ public interface IHasHdmiInHdcp : IHasHdmiInHdcpGet, IHasHdmiInHdcpSet
+ {
+ eHdcpCapabilityType HdmiInHdcpCapability { get; }
+ }
+
+
+
+
+ public interface IHasHdmiIn1HdcpSet
+ {
+ void SetHdmiIn1HdcpState(eHdcpCapabilityType hdcpState);
+ }
+
+ public interface IHasHdmiIn1HdcpGet
+ {
+ IntFeedback HdmiIn1HdcpStateFeedback { get; }
+ }
+
+ public interface IHasHdmiIn1Hdcp : IHasHdmiIn1HdcpGet, IHasHdmiIn1HdcpSet
+ {
+ eHdcpCapabilityType HdmiIn1HdcpCapability { get; }
+ }
+
+
+
+
+ public interface IHasHdmiIn2HdcpSet
+ {
+ void SetHdmiIn2HdcpState(eHdcpCapabilityType hdcpState);
+ }
+
+ public interface IHasHdmiIn2HdcpGet
+ {
+ IntFeedback HdmiInIn2HdcpStateFeedback { get; }
+ }
+
+ public interface IHasHdmi2InHdcp : IHasHdmiIn2HdcpGet, IHasHdmiIn2HdcpSet
+ {
+ eHdcpCapabilityType Hdmi2InHdcpCapability { get; }
+ }
+
+
+
+
+
+
+
+ public interface IHasDisplayPortInHdcpGet
+ {
+ IntFeedback DisplayPortInHdcpStateFeedback { get; }
+ }
+
+ public interface IHasDisplayPortInHdcpSet
+ {
+ void SetDisplayPortInHdcpState(eHdcpCapabilityType hdcpState);
+ }
+
+ public interface IHasDisplayPortInHdcp : IHasDisplayPortInHdcpGet, IHasDisplayPortInHdcpSet
+ {
+ eHdcpCapabilityType DisplayPortInHdcpCapability { get; }
+ }
+
+
+
+
+}
\ No newline at end of file
diff --git a/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Receivers/DmRmc4KScalerCController.cs b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Receivers/DmRmc4KScalerCController.cs
index 052f0726..668151b4 100644
--- a/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Receivers/DmRmc4KScalerCController.cs
+++ b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Receivers/DmRmc4KScalerCController.cs
@@ -5,8 +5,9 @@ using Crestron.SimplSharpPro.DM.Endpoints;
using Crestron.SimplSharpPro.DM.Endpoints.Receivers;
using PepperDash.Core;
using PepperDash.Essentials.Core;
-using PepperDash.Essentials.Core.Bridges;
-
+using PepperDash.Essentials.Core.Bridges;
+using PepperDash_Essentials_DM;
+
namespace PepperDash.Essentials.DM
{
///
@@ -15,7 +16,7 @@ namespace PepperDash.Essentials.DM
///
[Description("Wrapper Class for DM-RMC-4K-SCALER-C")]
public class DmRmc4kScalerCController : DmRmcControllerBase, IRoutingInputsOutputs, IBasicVolumeWithFeedback,
- IIROutputPorts, IComPorts, ICec, IRelayPorts
+ IIROutputPorts, IComPorts, ICec, IRelayPorts, IHasDmInHdcp
{
private readonly DmRmc4kScalerC _rmc;
@@ -27,6 +28,12 @@ namespace PepperDash.Essentials.DM
public RoutingPortCollection OutputPorts { get; private set; }
+ public EndpointDmInputStreamWithCec DmInput { get; private set; }
+
+ public IntFeedback DmInHdcpStateFeedback { get; private set; }
+
+
+
///
/// Make a Crestron RMC and put it in here
///
@@ -55,7 +62,12 @@ namespace PepperDash.Essentials.DM
InputPorts = new RoutingPortCollection {DmIn};
OutputPorts = new RoutingPortCollection {HdmiOut, BalancedAudioOut};
- VideoOutputResolutionFeedback = new StringFeedback(() => _rmc.HdmiOutput.GetVideoResolutionString());
+ VideoOutputResolutionFeedback = new StringFeedback(() => _rmc.HdmiOutput.GetVideoResolutionString());
+ DmInHdcpStateFeedback = new IntFeedback("DmInHdcpCapability",
+ () => (int)_rmc.DmInput.HdcpCapabilityFeedback);
+
+ AddToFeedbackList(DmInHdcpStateFeedback);
+
_rmc.HdmiOutput.OutputStreamChange += HdmiOutput_OutputStreamChange;
_rmc.HdmiOutput.ConnectedDevice.DeviceInformationChange += ConnectedDevice_DeviceInformationChange;
@@ -191,6 +203,18 @@ namespace PepperDash.Essentials.DM
_rmc.AudioOutput.Volume.StopRamp();
}
- #endregion
+ #endregion
+
+ public eHdcpCapabilityType DmInHdcpCapability
+ {
+ get { return eHdcpCapabilityType.Hdcp2_2Support; }
+ }
+
+ public void SetDmInHdcpState(eHdcpCapabilityType hdcpState)
+ {
+ if (_rmc == null) return;
+ _rmc.DmInput.HdcpCapability = hdcpState;
+ }
+
}
}
\ No newline at end of file
diff --git a/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Receivers/DmRmc4kZScalerCController.cs b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Receivers/DmRmc4kZScalerCController.cs
index 73dd59b9..a6a3d299 100644
--- a/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Receivers/DmRmc4kZScalerCController.cs
+++ b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Receivers/DmRmc4kZScalerCController.cs
@@ -9,12 +9,13 @@ using Crestron.SimplSharpPro.DM.Endpoints.Receivers;
using PepperDash.Essentials.Core;
using PepperDash.Essentials.Core.Bridges;
using PepperDash.Core;
+using PepperDash_Essentials_DM;
namespace PepperDash.Essentials.DM
{
[Description("Wrapper Class for DM-RMC-4K-Z-SCALER-C")]
public class DmRmc4kZScalerCController : DmRmcControllerBase, IRmcRoutingWithFeedback,
- IIROutputPorts, IComPorts, ICec, IRelayPorts
+ IIROutputPorts, IComPorts, ICec, IRelayPorts, IHasDmInHdcp, IHasHdmiInHdcp
{
private readonly DmRmc4kzScalerC _rmc;
@@ -22,6 +23,13 @@ namespace PepperDash.Essentials.DM
public RoutingInputPort HdmiIn { get; private set; }
public RoutingOutputPort HdmiOut { get; private set; }
+ public IntFeedback DmInHdcpStateFeedback { get; private set; }
+ public IntFeedback HdmiInHdcpStateFeedback { get; private set; }
+
+ public BoolFeedback HdmiVideoSyncFeedback { get; private set; }
+
+
+
///
/// The value of the current video source for the HDMI output on the receiver
///
@@ -42,13 +50,13 @@ namespace PepperDash.Essentials.DM
{
var newEvent = NumericSwitchChange;
if (newEvent != null) newEvent(this, e);
- }
-
+ }
public DmRmc4kZScalerCController(string key, string name, DmRmc4kzScalerC rmc)
: base(key, name, rmc)
{
_rmc = rmc;
+
DmIn = new RoutingInputPort(DmPortName.DmIn, eRoutingSignalType.AudioVideo,
eRoutingPortConnectionType.DmCat, 0, this)
{
@@ -62,6 +70,16 @@ namespace PepperDash.Essentials.DM
HdmiOut = new RoutingOutputPort(DmPortName.HdmiOut, eRoutingSignalType.AudioVideo,
eRoutingPortConnectionType.Hdmi, null, this);
+ HdmiInHdcpStateFeedback = new IntFeedback("HdmiInHdcpCapability",
+ () => (int)_rmc.HdmiIn.HdcpCapabilityFeedback);
+ DmInHdcpStateFeedback = new IntFeedback("DmInHdcpCapability",
+ () => (int)_rmc.DmInput.HdcpCapabilityFeedback);
+ HdmiVideoSyncFeedback = new BoolFeedback("HdmiInVideoSync",
+ () => _rmc.HdmiIn.SyncDetectedFeedback.BoolValue);
+
+ AddToFeedbackList(HdmiInHdcpStateFeedback, DmInHdcpStateFeedback, HdmiVideoSyncFeedback);
+
+
EdidManufacturerFeedback = new StringFeedback(() => _rmc.HdmiOutput.ConnectedDevice.Manufacturer.StringValue);
EdidNameFeedback = new StringFeedback(() => _rmc.HdmiOutput.ConnectedDevice.Name.StringValue);
EdidPreferredTimingFeedback = new StringFeedback(() => _rmc.HdmiOutput.ConnectedDevice.PreferredTiming.StringValue);
@@ -74,6 +92,8 @@ namespace PepperDash.Essentials.DM
_rmc.HdmiOutput.OutputStreamChange += HdmiOutput_OutputStreamChange;
_rmc.HdmiOutput.ConnectedDevice.DeviceInformationChange += ConnectedDevice_DeviceInformationChange;
+ _rmc.HdmiIn.InputStreamChange += InputStreamChangeEvent;
+ _rmc.DmInput.InputStreamChange += InputStreamChangeEvent;
_rmc.OnlineStatusChange += _rmc_OnlineStatusChange;
@@ -83,6 +103,20 @@ namespace PepperDash.Essentials.DM
AudioVideoSourceNumericFeedback = new IntFeedback(() => (ushort)(_rmc.SelectedSourceFeedback));
}
+ void InputStreamChangeEvent(EndpointInputStream inputStream, EndpointInputStreamEventArgs args)
+ {
+ switch (args.EventId)
+ {
+ case EndpointInputStreamEventIds.HdcpCapabilityFeedbackEventId:
+ if (inputStream == _rmc.HdmiIn) HdmiInHdcpStateFeedback.FireUpdate();
+ if (inputStream == _rmc.DmInput) DmInHdcpStateFeedback.FireUpdate();
+ break;
+ case EndpointInputStreamEventIds.SyncDetectedFeedbackEventId:
+ if (inputStream == _rmc.HdmiIn) HdmiVideoSyncFeedback.FireUpdate();
+ break;
+ }
+ }
+
private void _rmc_OnlineStatusChange(GenericBase currentDevice, OnlineOfflineEventArgs args)
{
AudioVideoSourceNumericFeedback.FireUpdate();
@@ -181,5 +215,31 @@ namespace PepperDash.Essentials.DM
}
#endregion
+
+
+ public eHdcpCapabilityType DmInHdcpCapability
+ {
+ get { return eHdcpCapabilityType.Hdcp2_2Support; }
+ }
+
+ public void SetDmInHdcpState(eHdcpCapabilityType hdcpState)
+ {
+
+ if (_rmc == null) return;
+ _rmc.DmInput.HdcpCapability = hdcpState;
+ }
+
+
+ public eHdcpCapabilityType HdmiInHdcpCapability
+ {
+ get { return eHdcpCapabilityType.Hdcp2_2Support; }
+ }
+
+ public void SetHdmiInHdcpState(eHdcpCapabilityType hdcpState)
+ {
+ if (_rmc == null) return;
+ _rmc.HdmiIn.HdcpCapability = hdcpState;
+ }
+
}
}
\ No newline at end of file
diff --git a/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Receivers/DmRmcHelper.cs b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Receivers/DmRmcHelper.cs
index e237c3a5..85c78f9c 100644
--- a/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Receivers/DmRmcHelper.cs
+++ b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Receivers/DmRmcHelper.cs
@@ -1,5 +1,6 @@
using System;
using System.Collections.Generic;
+using System.Linq;
using Crestron.SimplSharpPro.DeviceSupport;
using Crestron.SimplSharpPro.DM;
using Crestron.SimplSharpPro.DM.Cards;
@@ -11,6 +12,7 @@ using PepperDash.Essentials.Core.Bridges;
using PepperDash.Essentials.Core.DeviceInfo;
using PepperDash.Essentials.DM.Config;
using PepperDash.Essentials.Core.Config;
+using PepperDash_Essentials_DM;
namespace PepperDash.Essentials.DM
{
@@ -73,19 +75,80 @@ namespace PepperDash.Essentials.DM
rmc.EdidPreferredTimingFeedback.LinkInputSig(trilist.StringInput[joinMap.EdidPrefferedTiming.JoinNumber]);
if (rmc.EdidSerialNumberFeedback != null)
rmc.EdidSerialNumberFeedback.LinkInputSig(trilist.StringInput[joinMap.EdidSerialNumber.JoinNumber]);
+
//If the device is an DM-RMC-4K-Z-SCALER-C
- var routing = rmc as IRmcRouting;
+ var routing = rmc as IRoutingInputsOutputs;
+
+ trilist.UShortInput[joinMap.HdcpInputPortCount.JoinNumber].UShortValue = (ushort)(routing == null
+ ? 1
+ : routing.InputPorts.Count);
if (routing == null)
{
return;
}
+ var hdcpCapability = eHdcpCapabilityType.HdcpSupportOff;
+ if (routing.InputPorts[DmPortName.HdmiIn] != null)
+ {
+ var hdmiInHdcp = routing as IHasHdmiInHdcp;
+ if (hdmiInHdcp != null)
+ {
+ if (rmc.Feedbacks["HdmiInHdcpCapability"] != null)
+ {
+ var intFeedback = rmc.Feedbacks["HdmiInHdcpCapability"] as IntFeedback;
+ if (intFeedback != null)
+ intFeedback.LinkInputSig(trilist.UShortInput[joinMap.Port1HdcpState.JoinNumber]);
+ }
+ if (rmc.Feedbacks["HdmiInVideoSync"] != null)
+ {
+ var boolFeedback = rmc.Feedbacks["HdmiInVideoSync"] as BoolFeedback;
+ if (boolFeedback != null)
+ boolFeedback.LinkInputSig(trilist.BooleanInput[joinMap.HdmiInputSync.JoinNumber]);
+ }
+ hdcpCapability = hdmiInHdcp.HdmiInHdcpCapability > hdcpCapability
+ ? hdmiInHdcp.HdmiInHdcpCapability
+ : hdcpCapability;
- if (routing.AudioVideoSourceNumericFeedback != null)
- routing.AudioVideoSourceNumericFeedback.LinkInputSig(trilist.UShortInput[joinMap.AudioVideoSource.JoinNumber]);
+ trilist.SetUShortSigAction(joinMap.Port1HdcpState.JoinNumber, a => hdmiInHdcp.SetHdmiInHdcpState((eHdcpCapabilityType)a));
+ }
+ }
+ if (routing.InputPorts[DmPortName.DmIn] != null)
+ {
+ var dmInHdcp = rmc as IHasDmInHdcp;
- trilist.SetUShortSigAction(joinMap.AudioVideoSource.JoinNumber, a => routing.ExecuteNumericSwitch(a, 1, eRoutingSignalType.AudioVideo));
+ if (dmInHdcp != null)
+ {
+ if (rmc.Feedbacks["DmInHdcpCapability"] != null)
+ {
+ var intFeedback = rmc.Feedbacks["DmInHdcpCapability"] as IntFeedback;
+ if (intFeedback != null)
+ intFeedback.LinkInputSig(trilist.UShortInput[joinMap.Port2HdcpState.JoinNumber]);
+ }
+
+ hdcpCapability = dmInHdcp.DmInHdcpCapability > hdcpCapability
+ ? dmInHdcp.DmInHdcpCapability
+ : hdcpCapability;
+
+
+ trilist.SetUShortSigAction(joinMap.Port2HdcpState.JoinNumber, a => dmInHdcp.SetDmInHdcpState((eHdcpCapabilityType)a));
+ }
+ }
+
+ trilist.UShortInput[joinMap.HdcpSupportCapability.JoinNumber].UShortValue = (ushort) hdcpCapability;
+
+ trilist.UShortInput[joinMap.HdcpInputPortCount.JoinNumber].UShortValue = (ushort) routing.InputPorts.Count;
+
+ var routingWithFeedback = routing as IRmcRouting;
+ if (routingWithFeedback == null) return;
+
+ if (routingWithFeedback.AudioVideoSourceNumericFeedback != null)
+ routingWithFeedback.AudioVideoSourceNumericFeedback.LinkInputSig(
+ trilist.UShortInput[joinMap.AudioVideoSource.JoinNumber]);
+
+
+ trilist.SetUShortSigAction(joinMap.AudioVideoSource.JoinNumber,
+ a => routingWithFeedback.ExecuteNumericSwitch(a, 1, eRoutingSignalType.AudioVideo));
}
#region Implementation of IDeviceInfoProvider
diff --git a/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTx4k202CController.cs b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTx4k202CController.cs
index 387562e4..644ea089 100644
--- a/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTx4k202CController.cs
+++ b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTx4k202CController.cs
@@ -137,15 +137,10 @@ namespace PepperDash.Essentials.DM
HdmiIn2HdcpCapabilityFeedback = new IntFeedback("HdmiIn2HdcpCapability",
() => (int) tx.HdmiInputs[2].HdcpCapabilityFeedback);
- HdcpStateFeedback =
- new IntFeedback(
- () =>
- tx.HdmiInputs[1].HdcpCapabilityFeedback > tx.HdmiInputs[2].HdcpCapabilityFeedback
- ? (int) tx.HdmiInputs[1].HdcpCapabilityFeedback
- : (int) tx.HdmiInputs[2].HdcpCapabilityFeedback);
-
HdcpSupportCapability = eHdcpCapabilityType.Hdcp2_2Support;
+ HdcpStateFeedback = new IntFeedback(() => (int) HdcpSupportCapability);
+
Hdmi1VideoSyncFeedback = new BoolFeedback(() => (bool) tx.HdmiInputs[1].SyncDetectedFeedback.BoolValue);
Hdmi2VideoSyncFeedback = new BoolFeedback(() => (bool) tx.HdmiInputs[2].SyncDetectedFeedback.BoolValue);
diff --git a/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTx4k302CController.cs b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTx4k302CController.cs
index c03a2291..e7a9d7a2 100644
--- a/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTx4k302CController.cs
+++ b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTx4k302CController.cs
@@ -145,15 +145,10 @@ namespace PepperDash.Essentials.DM
HdmiIn2HdcpCapabilityFeedback = new IntFeedback("HdmiIn2HdcpCapability", () => (int)tx.HdmiInputs[2].HdcpCapabilityFeedback);
- HdcpStateFeedback =
- new IntFeedback(
- () =>
- tx.HdmiInputs[1].HdcpCapabilityFeedback > tx.HdmiInputs[2].HdcpCapabilityFeedback
- ? (int)tx.HdmiInputs[1].HdcpCapabilityFeedback
- : (int)tx.HdmiInputs[2].HdcpCapabilityFeedback);
-
HdcpSupportCapability = eHdcpCapabilityType.Hdcp2_2Support;
+ HdcpStateFeedback = new IntFeedback(() => (int)HdcpSupportCapability);
+
Hdmi1VideoSyncFeedback = new BoolFeedback(() => (bool)tx.HdmiInputs[1].SyncDetectedFeedback.BoolValue);
Hdmi2VideoSyncFeedback = new BoolFeedback(() => (bool)tx.HdmiInputs[2].SyncDetectedFeedback.BoolValue);
diff --git a/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTx4kz202CController.cs b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTx4kz202CController.cs
index b9f521c6..50d6dc16 100644
--- a/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTx4kz202CController.cs
+++ b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTx4kz202CController.cs
@@ -124,15 +124,10 @@ namespace PepperDash.Essentials.DM
HdmiIn2HdcpCapabilityFeedback = new IntFeedback("HdmiIn2HdcpCapability", () => (int)tx.HdmiInputs[2].HdcpCapabilityFeedback);
- HdcpStateFeedback =
- new IntFeedback(
- () =>
- tx.HdmiInputs[1].HdcpCapabilityFeedback > tx.HdmiInputs[2].HdcpCapabilityFeedback
- ? (int)tx.HdmiInputs[1].HdcpCapabilityFeedback
- : (int)tx.HdmiInputs[2].HdcpCapabilityFeedback);
-
HdcpSupportCapability = eHdcpCapabilityType.Hdcp2_2Support;
+ HdcpStateFeedback = new IntFeedback(() => (int)HdcpSupportCapability);
+
Hdmi1VideoSyncFeedback = new BoolFeedback(() => (bool)tx.HdmiInputs[1].SyncDetectedFeedback.BoolValue);
Hdmi2VideoSyncFeedback = new BoolFeedback(() => (bool)tx.HdmiInputs[2].SyncDetectedFeedback.BoolValue);
diff --git a/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTx4kz302CController.cs b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTx4kz302CController.cs
index 4d77a7fc..8446cb9f 100644
--- a/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTx4kz302CController.cs
+++ b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTx4kz302CController.cs
@@ -146,13 +146,18 @@ namespace PepperDash.Essentials.DM
*/
//yeah this is gross - but it's the quickest way to do this...
+ /*
HdcpStateFeedback = new IntFeedback(() => {
var states = new[] {(int) tx.DisplayPortInput.HdcpCapabilityFeedback, (int) tx.HdmiInputs[1].HdcpCapabilityFeedback, (int) tx.HdmiInputs[2].HdcpCapabilityFeedback};
return states.Max();
});
+ */
HdcpSupportCapability = eHdcpCapabilityType.Hdcp2_2Support;
+ // I feel like we have had this as a misnomer for so long, that it really needed to be fixed
+ // All we were doing was reporting the best of the current statuses - not the actual capability of the device.
+ HdcpStateFeedback = new IntFeedback(() => (int)HdcpSupportCapability);
Hdmi1VideoSyncFeedback = new BoolFeedback(() => (bool)tx.HdmiInputs[1].SyncDetectedFeedback.BoolValue);
diff --git a/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTxHelpers.cs b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTxHelpers.cs
index 771864d6..375d92c0 100644
--- a/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTxHelpers.cs
+++ b/essentials-framework/Essentials DM/Essentials_DM/Endpoints/Transmitters/DmTxHelpers.cs
@@ -411,9 +411,22 @@ namespace PepperDash.Essentials.DM
SetHdcpCapabilityAction(hdcpTypeSimple, port, joinMap.Port3HdcpState.JoinNumber, trilist);
}
-
}
+
+ var hdcpInputPortCount =
+ (ushort)
+ txR.InputPorts.Where(
+ x => (x.Type == eRoutingSignalType.Video) || (x.Type == eRoutingSignalType.AudioVideo))
+ .Where(
+ x =>
+ (x.ConnectionType == eRoutingPortConnectionType.DmCat) ||
+ (x.ConnectionType == eRoutingPortConnectionType.Hdmi) ||
+ (x.ConnectionType == eRoutingPortConnectionType.DisplayPort))
+ .ToList().Count();
+
+ trilist.SetUshort(joinMap.HdcpInputPortCount.JoinNumber, hdcpInputPortCount);
+
}
var txFreeRun = tx as IHasFreeRun;
diff --git a/essentials-framework/Essentials DM/Essentials_DM/PepperDash_Essentials_DM.csproj b/essentials-framework/Essentials DM/Essentials_DM/PepperDash_Essentials_DM.csproj
index 0135334e..730915b8 100644
--- a/essentials-framework/Essentials DM/Essentials_DM/PepperDash_Essentials_DM.csproj
+++ b/essentials-framework/Essentials DM/Essentials_DM/PepperDash_Essentials_DM.csproj
@@ -107,6 +107,7 @@
+