mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-01-11 19:44:52 +00:00
Merged in maintenance/pd-core-submodule (pull request #35)
Maintenance/pd core submodule Approved-by: Neil Dorin <ndorin@pepperdash.com>
This commit is contained in:
4
.gitmodules
vendored
4
.gitmodules
vendored
@@ -0,0 +1,4 @@
|
||||
[submodule "essentials-framework/pepperdashcore-builds"]
|
||||
path = essentials-framework/pepperdashcore-builds
|
||||
url = https://ndorin@bitbucket.org/Pepperdash_Products/pepperdashcore-builds.git
|
||||
branch = development
|
||||
|
||||
@@ -57,7 +57,7 @@ namespace PepperDash.Essentials.Bridges
|
||||
var txKey = dmChassis.TxDictionary[ioSlot];
|
||||
var basicTxDevice = DeviceManager.GetDeviceForKey(txKey) as BasicDmTxControllerBase;
|
||||
|
||||
var txDevice = basicTxDevice as DmTxControllerBase;
|
||||
var advancedTxDevice = basicTxDevice as DmTxControllerBase;
|
||||
|
||||
if (dmChassis.Chassis is DmMd8x8Cpu3 || dmChassis.Chassis is DmMd8x8Cpu3rps
|
||||
|| dmChassis.Chassis is DmMd16x16Cpu3 || dmChassis.Chassis is DmMd16x16Cpu3rps
|
||||
@@ -67,43 +67,83 @@ namespace PepperDash.Essentials.Bridges
|
||||
}
|
||||
else
|
||||
{
|
||||
if (txDevice != null)
|
||||
if (advancedTxDevice != null)
|
||||
{
|
||||
txDevice.IsOnline.LinkInputSig(trilist.BooleanInput[joinMap.InputEndpointOnline + ioSlot]);
|
||||
advancedTxDevice.IsOnline.LinkInputSig(trilist.BooleanInput[joinMap.InputEndpointOnline + ioSlot]);
|
||||
Debug.Console(2, "Linking Tx Online Feedback from Advanced Transmitter at input {0}", ioSlot);
|
||||
}
|
||||
else if (dmChassis.InputEndpointOnlineFeedbacks[ioSlot] != null)
|
||||
{
|
||||
Debug.Console(2, "Linking Tx Online Feedback from Input Card {0}", ioSlot);
|
||||
dmChassis.InputEndpointOnlineFeedbacks[ioSlot].LinkInputSig(trilist.BooleanInput[joinMap.InputEndpointOnline + ioSlot]);
|
||||
}
|
||||
}
|
||||
|
||||
if (basicTxDevice != null && txDevice == null)
|
||||
if (basicTxDevice != null && advancedTxDevice == null)
|
||||
trilist.BooleanInput[joinMap.TxAdvancedIsPresent + ioSlot].BoolValue = true;
|
||||
|
||||
|
||||
if (txDevice != null)
|
||||
if (advancedTxDevice != null)
|
||||
{
|
||||
txDevice.AnyVideoInput.VideoStatus.VideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.VideoSyncStatus + ioSlot]);
|
||||
advancedTxDevice.AnyVideoInput.VideoStatus.VideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.VideoSyncStatus + ioSlot]);
|
||||
}
|
||||
else
|
||||
else if(advancedTxDevice == null || basicTxDevice != null)
|
||||
{
|
||||
Debug.Console(1, "Setting up actions and feedbacks on input card {0}", ioSlot);
|
||||
dmChassis.VideoInputSyncFeedbacks[ioSlot].LinkInputSig(trilist.BooleanInput[joinMap.VideoSyncStatus + ioSlot]);
|
||||
|
||||
var inputPort = dmChassis.InputPorts[string.Format("inputCard{0}--hdmiIn", ioSlot)];
|
||||
if (inputPort != null)
|
||||
{
|
||||
var hdmiInPort = inputPort.Port;
|
||||
Debug.Console(1, "Port value for input card {0} is set", ioSlot);
|
||||
var port = inputPort.Port;
|
||||
|
||||
if (hdmiInPort != null)
|
||||
if (port != null)
|
||||
{
|
||||
if (hdmiInPort is HdmiInputWithCEC)
|
||||
if (port is HdmiInputWithCEC)
|
||||
{
|
||||
var hdmiInPortWCec = hdmiInPort as HdmiInputWithCEC;
|
||||
Debug.Console(1, "Port is HdmiInputWithCec");
|
||||
|
||||
var hdmiInPortWCec = port as HdmiInputWithCEC;
|
||||
|
||||
if (hdmiInPortWCec.HdcpSupportedLevel != eHdcpSupportedLevel.Unknown)
|
||||
{
|
||||
SetHdcpCapabilityAction(true, hdmiInPortWCec, joinMap.HdcpSupportState + ioSlot, trilist);
|
||||
SetHdcpStateAction(true, hdmiInPortWCec, joinMap.HdcpSupportState + ioSlot, trilist);
|
||||
}
|
||||
|
||||
dmChassis.InputCardHdcpCapabilityFeedbacks[ioSlot].LinkInputSig(trilist.UShortInput[joinMap.HdcpSupportState + ioSlot]);
|
||||
|
||||
trilist.UShortInput[joinMap.HdcpSupportCapability + ioSlot].UShortValue = (ushort)dmChassis.InputCardHdcpCapabilityTypes[ioSlot];
|
||||
if(dmChassis.InputCardHdcpCapabilityTypes.ContainsKey(ioSlot))
|
||||
trilist.UShortInput[joinMap.HdcpSupportCapability + ioSlot].UShortValue = (ushort)dmChassis.InputCardHdcpCapabilityTypes[ioSlot];
|
||||
else
|
||||
trilist.UShortInput[joinMap.HdcpSupportCapability + ioSlot].UShortValue = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
inputPort = dmChassis.InputPorts[string.Format("inputCard{0}--dmIn", ioSlot)];
|
||||
|
||||
if(inputPort != null)
|
||||
{
|
||||
var port = inputPort.Port;
|
||||
|
||||
if (port is DMInputPortWithCec)
|
||||
{
|
||||
Debug.Console(1, "Port is DMInputPortWithCec");
|
||||
|
||||
var dmInPortWCec = port as DMInputPortWithCec;
|
||||
|
||||
if (dmInPortWCec != null)
|
||||
{
|
||||
SetHdcpStateAction(dmChassis.PropertiesConfig.InputSlotSupportsHdcp2[ioSlot], dmInPortWCec, joinMap.HdcpSupportState + ioSlot, trilist);
|
||||
}
|
||||
|
||||
dmChassis.InputCardHdcpCapabilityFeedbacks[ioSlot].LinkInputSig(trilist.UShortInput[joinMap.HdcpSupportState + ioSlot]);
|
||||
|
||||
if (dmChassis.InputCardHdcpCapabilityTypes.ContainsKey(ioSlot))
|
||||
trilist.UShortInput[joinMap.HdcpSupportCapability + ioSlot].UShortValue = (ushort)dmChassis.InputCardHdcpCapabilityTypes[ioSlot];
|
||||
else
|
||||
trilist.UShortInput[joinMap.HdcpSupportCapability + ioSlot].UShortValue = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -120,7 +160,7 @@ namespace PepperDash.Essentials.Bridges
|
||||
|
||||
if (hdmiPort != null)
|
||||
{
|
||||
SetHdcpCapabilityAction(true, hdmiPort, joinMap.HdcpSupportState + ioSlot, trilist);
|
||||
SetHdcpStateAction(true, hdmiPort, joinMap.HdcpSupportState + ioSlot, trilist);
|
||||
dmChassis.InputCardHdcpCapabilityFeedbacks[ioSlot].LinkInputSig(trilist.UShortInput[joinMap.HdcpSupportState + ioSlot]);
|
||||
}
|
||||
}
|
||||
@@ -128,18 +168,19 @@ namespace PepperDash.Essentials.Bridges
|
||||
if (dmChassis.RxDictionary.ContainsKey(ioSlot))
|
||||
{
|
||||
Debug.Console(2, "Creating Rx Feedbacks {0}", ioSlot);
|
||||
var RxKey = dmChassis.RxDictionary[ioSlot];
|
||||
var RxDevice = DeviceManager.GetDeviceForKey(RxKey) as DmRmcControllerBase;
|
||||
var rxKey = dmChassis.RxDictionary[ioSlot];
|
||||
var rxDevice = DeviceManager.GetDeviceForKey(rxKey) as DmRmcControllerBase;
|
||||
var hdBaseTDevice = DeviceManager.GetDeviceForKey(rxKey) as DmHdBaseTControllerBase;
|
||||
if (dmChassis.Chassis is DmMd8x8Cpu3 || dmChassis.Chassis is DmMd8x8Cpu3rps
|
||||
|| dmChassis.Chassis is DmMd16x16Cpu3 || dmChassis.Chassis is DmMd16x16Cpu3rps
|
||||
|| dmChassis.Chassis is DmMd32x32Cpu3 || dmChassis.Chassis is DmMd32x32Cpu3rps)
|
||||
|| dmChassis.Chassis is DmMd32x32Cpu3 || dmChassis.Chassis is DmMd32x32Cpu3rps || hdBaseTDevice != null)
|
||||
{
|
||||
dmChassis.OutputEndpointOnlineFeedbacks[ioSlot].LinkInputSig(trilist.BooleanInput[joinMap.OutputEndpointOnline + ioSlot]);
|
||||
}
|
||||
else if (RxDevice != null)
|
||||
else if (rxDevice != null)
|
||||
{
|
||||
RxDevice.IsOnline.LinkInputSig(trilist.BooleanInput[joinMap.OutputEndpointOnline + ioSlot]);
|
||||
}
|
||||
rxDevice.IsOnline.LinkInputSig(trilist.BooleanInput[joinMap.OutputEndpointOnline + ioSlot]);
|
||||
}
|
||||
}
|
||||
|
||||
// Feedback
|
||||
@@ -156,7 +197,7 @@ namespace PepperDash.Essentials.Bridges
|
||||
}
|
||||
}
|
||||
|
||||
static void SetHdcpCapabilityAction(bool hdcpTypeSimple, HdmiInputWithCEC port, uint join, BasicTriList trilist)
|
||||
static void SetHdcpStateAction(bool hdcpTypeSimple, HdmiInputWithCEC port, uint join, BasicTriList trilist)
|
||||
{
|
||||
if (hdcpTypeSimple)
|
||||
{
|
||||
@@ -176,14 +217,14 @@ namespace PepperDash.Essentials.Bridges
|
||||
else
|
||||
{
|
||||
trilist.SetUShortSigAction(join,
|
||||
new Action<ushort>(s =>
|
||||
new Action<ushort>(u =>
|
||||
{
|
||||
port.HdcpReceiveCapability = (eHdcpCapabilityType)s;
|
||||
port.HdcpReceiveCapability = (eHdcpCapabilityType)u;
|
||||
}));
|
||||
}
|
||||
}
|
||||
|
||||
static void SetHdcpCapabilityAction(bool hdcpTypeSimple, EndpointHdmiInput port, uint join, BasicTriList trilist)
|
||||
static void SetHdcpStateAction(bool hdcpTypeSimple, EndpointHdmiInput port, uint join, BasicTriList trilist)
|
||||
{
|
||||
if (hdcpTypeSimple)
|
||||
{
|
||||
@@ -203,9 +244,36 @@ namespace PepperDash.Essentials.Bridges
|
||||
else
|
||||
{
|
||||
trilist.SetUShortSigAction(join,
|
||||
new Action<ushort>(s =>
|
||||
new Action<ushort>(u =>
|
||||
{
|
||||
port.HdcpCapability = (eHdcpCapabilityType)s;
|
||||
port.HdcpCapability = (eHdcpCapabilityType)u;
|
||||
}));
|
||||
}
|
||||
}
|
||||
|
||||
static void SetHdcpStateAction(bool supportsHdcp2, DMInputPortWithCec port, uint join, BasicTriList trilist)
|
||||
{
|
||||
if (!supportsHdcp2)
|
||||
{
|
||||
trilist.SetUShortSigAction(join,
|
||||
new Action<ushort>(s =>
|
||||
{
|
||||
if (s == 0)
|
||||
{
|
||||
port.HdcpSupportOff();
|
||||
}
|
||||
else if (s > 0)
|
||||
{
|
||||
port.HdcpSupportOn();
|
||||
}
|
||||
}));
|
||||
}
|
||||
else
|
||||
{
|
||||
trilist.SetUShortSigAction(join,
|
||||
new Action<ushort>(u =>
|
||||
{
|
||||
port.HdcpReceiveCapability = (eHdcpCapabilityType)u;
|
||||
}));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -107,7 +107,6 @@ namespace PepperDash.Essentials.Bridges
|
||||
OutputAudio = 300; //301-499
|
||||
OutputUsb = 500; //501-699
|
||||
InputUsb = 700; //701-899
|
||||
VideoSyncStatus = 100; //101-299
|
||||
HdcpSupportState = 1000; //1001-1199
|
||||
HdcpSupportCapability = 1200; //1201-1399
|
||||
|
||||
@@ -118,8 +117,6 @@ namespace PepperDash.Essentials.Bridges
|
||||
OutputCurrentVideoInputNames = 2000; //2001-2199
|
||||
OutputCurrentAudioInputNames = 2200; //2201-2399
|
||||
InputCurrentResolution = 2400; // 2401-2599
|
||||
InputEndpointOnline = 500; //501-699
|
||||
OutputEndpointOnline = 700; //701-899
|
||||
}
|
||||
|
||||
public override void OffsetJoinNumbers(uint joinStart)
|
||||
|
||||
@@ -71,9 +71,9 @@
|
||||
<HintPath>..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SSPDevices\Crestron.SimplSharpPro.UI.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="mscorlib" />
|
||||
<Reference Include="PepperDash_Core, Version=1.0.3.27452, Culture=neutral, processorArchitecture=MSIL">
|
||||
<Reference Include="PepperDash_Core, Version=1.0.26.30384, Culture=neutral, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\essentials-framework\references\PepperDash_Core.dll</HintPath>
|
||||
<HintPath>..\essentials-framework\pepperdashcore-builds\PepperDash_Core.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="PepperDash_Essentials_DM, Version=1.0.0.19343, Culture=neutral, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
@@ -183,6 +183,7 @@
|
||||
<Compile Include="HttpApiHandler.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<Compile Include="Room\Behaviours\RoomOnToDefaultSourceWhenOccupied.cs" />
|
||||
<Compile Include="Room\Config\EssentialsNDisplayRoomPropertiesConfig.cs" />
|
||||
<Compile Include="Room\Config\DDVC01RoomPropertiesConfig.cs" />
|
||||
<Compile Include="Room\Config\EssentialsPresentationPropertiesConfig.cs" />
|
||||
<Compile Include="Room\Config\EssentialsHuddleRoomPropertiesConfig.cs" />
|
||||
@@ -206,6 +207,7 @@
|
||||
<Compile Include="AppServer\Volumes.cs" />
|
||||
<Compile Include="Room\Emergency\EsentialsRoomEmergencyContactClosure.cs" />
|
||||
<Compile Include="Room\Types\EssentialsHuddleVtc1Room.cs" />
|
||||
<Compile Include="Room\Types\EssentialsNDisplayRoomBase.cs" />
|
||||
<Compile Include="Room\Types\EssentialsPresentationRoom.cs" />
|
||||
<Compile Include="Room\Types\EssentialsRoomBase.cs" />
|
||||
<Compile Include="Room\Config\EssentialsRoomConfig.cs" />
|
||||
|
||||
@@ -4,5 +4,5 @@
|
||||
[assembly: AssemblyCompany("PepperDash Technology Corp")]
|
||||
[assembly: AssemblyProduct("PepperDashEssentials")]
|
||||
[assembly: AssemblyCopyright("Copyright © PepperDash Technology Corp 2018")]
|
||||
[assembly: AssemblyVersion("1.4.444.*")]
|
||||
[assembly: AssemblyVersion("1.4.0.*")]
|
||||
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using Crestron.SimplSharp;
|
||||
|
||||
namespace PepperDash.Essentials.Room.Config
|
||||
{
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public class EssentialsNDisplayRoomPropertiesConfig : EssentialsRoomPropertiesConfig
|
||||
{
|
||||
public string DefaultAudioBehavior { get; set; }
|
||||
public string DefaultAudioKey { get; set; }
|
||||
public string DefaultVideoBehavior { get; set; }
|
||||
public Dictionary<string, string> Displays { get; set; }
|
||||
public string SourceListKey { get; set; }
|
||||
|
||||
public EssentialsNDisplayRoomPropertiesConfig()
|
||||
{
|
||||
Displays = new Dictionary<string, string>();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using Crestron.SimplSharp;
|
||||
|
||||
using Newtonsoft.Json;
|
||||
|
||||
using PepperDash.Core;
|
||||
using PepperDash.Essentials.Core;
|
||||
using PepperDash.Essentials.Core.Devices;
|
||||
using PepperDash.Essentials.Core.Config;
|
||||
using PepperDash.Essentials.Room.Config;
|
||||
|
||||
namespace PepperDash.Essentials.Room.Types
|
||||
{
|
||||
/// <summary>
|
||||
/// Base class for rooms with more than a single display
|
||||
/// </summary>
|
||||
public abstract class EssentialsNDisplayRoomBase : EssentialsRoomBase
|
||||
{
|
||||
public event SourceInfoChangeHandler CurrentSingleSourceChange;
|
||||
|
||||
public Dictionary<string, IRoutingSinkWithSwitching> Displays { get; protected set; }
|
||||
|
||||
protected override Func<bool> IsWarmingFeedbackFunc { get { return () => false; ; } }
|
||||
protected override Func<bool> IsCoolingFeedbackFunc { get { return () => false; } }
|
||||
|
||||
public EssentialsNDisplayRoomBase(DeviceConfig config)
|
||||
: base (config)
|
||||
{
|
||||
Displays = new Dictionary<string, IRoutingSinkWithSwitching>();
|
||||
|
||||
var propertiesConfig = JsonConvert.DeserializeObject<EssentialsNDisplayRoomPropertiesConfig>(config.Properties.ToString());
|
||||
|
||||
foreach (var display in propertiesConfig.Displays)
|
||||
{
|
||||
var displayDevice = DeviceManager.GetDeviceForKey(display.Value) as IRoutingSinkWithSwitching;
|
||||
|
||||
if (displayDevice != null)
|
||||
Displays.Add(display.Key, displayDevice);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -33,7 +33,7 @@
|
||||
// public Dictionary<uint, IRoutingSinkNoSwitching> Displays { get; private set; }
|
||||
|
||||
// public IRoutingSinkNoSwitching DefaultAudioDevice { get; private set; }
|
||||
// public IBasicVolumeControls DefaultVolumeControls { get; private set; }
|
||||
// public IBasicVolumeControls DefaultVolumeControls { get; private set; }C:\Working Directories\PD\essentials\PepperDashEssentials\Room\Types\EssentialsPresentationRoom.cs
|
||||
|
||||
// /// <summary>
|
||||
// /// The config name of the source list
|
||||
|
||||
@@ -71,9 +71,9 @@
|
||||
<HintPath>..\..\..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SSPDevices\Crestron.SimplSharpPro.UI.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="mscorlib" />
|
||||
<Reference Include="PepperDash_Core, Version=1.0.1.26313, Culture=neutral, processorArchitecture=MSIL">
|
||||
<Reference Include="PepperDash_Core, Version=1.0.26.30384, Culture=neutral, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\..\references\PepperDash_Core.dll</HintPath>
|
||||
<HintPath>..\..\pepperdashcore-builds\PepperDash_Core.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="SimplSharpCustomAttributesInterface, Version=1.0.0.0, Culture=neutral, PublicKeyToken=1099c178b3b54c3b, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
|
||||
@@ -23,6 +23,8 @@ namespace PepperDash.Essentials.DM
|
||||
/// </summary>
|
||||
public class DmChassisController : CrestronGenericBaseDevice, IRoutingInputsOutputs, IRouting, IHasFeedback
|
||||
{
|
||||
public DMChassisPropertiesConfig PropertiesConfig { get; set; }
|
||||
|
||||
public DmMDMnxn Chassis { get; private set; }
|
||||
|
||||
// Feedbacks for EssentialDM
|
||||
@@ -91,10 +93,10 @@ namespace PepperDash.Essentials.DM
|
||||
else if (type == "dmmd32x32cpu3") { chassis = new DmMd32x32Cpu3(ipid, Global.ControlSystem); }
|
||||
else if (type == "dmmd32x32cpu3rps") { chassis = new DmMd32x32Cpu3rps(ipid, Global.ControlSystem); }
|
||||
|
||||
if (chassis == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
if (chassis == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
var controller = new DmChassisController(key, name, chassis);
|
||||
// add the cards and port names
|
||||
@@ -126,6 +128,7 @@ namespace PepperDash.Essentials.DM
|
||||
|
||||
controller.InputNames = properties.InputNames;
|
||||
controller.OutputNames = properties.OutputNames;
|
||||
controller.PropertiesConfig = properties;
|
||||
return controller;
|
||||
}
|
||||
catch (System.Exception e)
|
||||
@@ -177,104 +180,154 @@ namespace PepperDash.Essentials.DM
|
||||
{
|
||||
var tempX = x;
|
||||
|
||||
VideoOutputFeedbacks[tempX] = new IntFeedback(() => {
|
||||
if (Chassis.Outputs[tempX].VideoOutFeedback != null) { return (ushort)Chassis.Outputs[tempX].VideoOutFeedback.Number;}
|
||||
else { return 0; };
|
||||
});
|
||||
AudioOutputFeedbacks[tempX] = new IntFeedback(() => {
|
||||
if (Chassis.Outputs[tempX].AudioOutFeedback != null) { return (ushort)Chassis.Outputs[tempX].AudioOutFeedback.Number; }
|
||||
else { return 0; };
|
||||
});
|
||||
UsbOutputRoutedToFeebacks[tempX] = new IntFeedback(() => {
|
||||
if(Chassis.Outputs[tempX].USBRoutedToFeedback != null) { return (ushort)Chassis.Outputs[tempX].USBRoutedToFeedback.Number; }
|
||||
else {return 0; };
|
||||
});
|
||||
UsbInputRoutedToFeebacks[tempX] = new IntFeedback(() => {
|
||||
if(Chassis.Inputs[tempX].USBRoutedToFeedback != null) { return (ushort)Chassis.Inputs[tempX].USBRoutedToFeedback.Number; }
|
||||
else {return 0; };
|
||||
});
|
||||
VideoInputSyncFeedbacks[tempX] = new BoolFeedback(() => {
|
||||
return Chassis.Inputs[tempX].VideoDetectedFeedback.BoolValue;
|
||||
});
|
||||
InputNameFeedbacks[tempX] = new StringFeedback(() => {
|
||||
if (Chassis.Inputs[tempX].NameFeedback != null)
|
||||
{
|
||||
return Chassis.Inputs[tempX].NameFeedback.StringValue;
|
||||
}
|
||||
else
|
||||
{
|
||||
return "";
|
||||
}
|
||||
});
|
||||
OutputNameFeedbacks[tempX] = new StringFeedback(() => {
|
||||
if (Chassis.Outputs[tempX].NameFeedback != null)
|
||||
{
|
||||
return Chassis.Outputs[tempX].NameFeedback.StringValue;
|
||||
}
|
||||
else
|
||||
{
|
||||
return "";
|
||||
}
|
||||
});
|
||||
OutputVideoRouteNameFeedbacks[tempX] = new StringFeedback(() =>
|
||||
{
|
||||
if (Chassis.Outputs[tempX].VideoOutFeedback != null)
|
||||
{
|
||||
return Chassis.Outputs[tempX].VideoOutFeedback.NameFeedback.StringValue;
|
||||
}
|
||||
else
|
||||
{
|
||||
return "";
|
||||
}
|
||||
});
|
||||
OutputAudioRouteNameFeedbacks[tempX] = new StringFeedback(() =>
|
||||
if (Chassis.Outputs[tempX] != null)
|
||||
{
|
||||
VideoOutputFeedbacks[tempX] = new IntFeedback(() =>
|
||||
{
|
||||
if (Chassis.Outputs[tempX].AudioOutFeedback != null)
|
||||
if (Chassis.Outputs[tempX].VideoOutFeedback != null) { return (ushort)Chassis.Outputs[tempX].VideoOutFeedback.Number; }
|
||||
else { return 0; };
|
||||
});
|
||||
AudioOutputFeedbacks[tempX] = new IntFeedback(() =>
|
||||
{
|
||||
if (Chassis.Outputs[tempX].AudioOutFeedback != null) { return (ushort)Chassis.Outputs[tempX].AudioOutFeedback.Number; }
|
||||
else { return 0; };
|
||||
});
|
||||
UsbOutputRoutedToFeebacks[tempX] = new IntFeedback(() =>
|
||||
{
|
||||
if (Chassis.Outputs[tempX].USBRoutedToFeedback != null) { return (ushort)Chassis.Outputs[tempX].USBRoutedToFeedback.Number; }
|
||||
else { return 0; };
|
||||
});
|
||||
|
||||
OutputNameFeedbacks[tempX] = new StringFeedback(() =>
|
||||
{
|
||||
if (Chassis.Outputs[tempX].NameFeedback != null)
|
||||
{
|
||||
return Chassis.Outputs[tempX].AudioOutFeedback.NameFeedback.StringValue;
|
||||
return Chassis.Outputs[tempX].NameFeedback.StringValue;
|
||||
}
|
||||
else
|
||||
{
|
||||
return "";
|
||||
}
|
||||
});
|
||||
OutputVideoRouteNameFeedbacks[tempX] = new StringFeedback(() =>
|
||||
{
|
||||
if (Chassis.Outputs[tempX].VideoOutFeedback != null)
|
||||
{
|
||||
return Chassis.Outputs[tempX].VideoOutFeedback.NameFeedback.StringValue;
|
||||
}
|
||||
else
|
||||
{
|
||||
return "";
|
||||
}
|
||||
});
|
||||
OutputAudioRouteNameFeedbacks[tempX] = new StringFeedback(() =>
|
||||
{
|
||||
if (Chassis.Outputs[tempX].AudioOutFeedback != null)
|
||||
{
|
||||
return Chassis.Outputs[tempX].AudioOutFeedback.NameFeedback.StringValue;
|
||||
}
|
||||
else
|
||||
{
|
||||
return "";
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
OutputEndpointOnlineFeedbacks[tempX] = new BoolFeedback(() =>
|
||||
{
|
||||
return Chassis.Outputs[tempX].EndpointOnlineFeedback;
|
||||
});
|
||||
}
|
||||
|
||||
if (Chassis.Inputs[tempX] != null)
|
||||
{
|
||||
UsbInputRoutedToFeebacks[tempX] = new IntFeedback(() =>
|
||||
{
|
||||
if (Chassis.Inputs[tempX].USBRoutedToFeedback != null) { return (ushort)Chassis.Inputs[tempX].USBRoutedToFeedback.Number; }
|
||||
else { return 0; };
|
||||
});
|
||||
VideoInputSyncFeedbacks[tempX] = new BoolFeedback(() =>
|
||||
{
|
||||
if (Chassis.Inputs[tempX].VideoDetectedFeedback != null)
|
||||
return Chassis.Inputs[tempX].VideoDetectedFeedback.BoolValue;
|
||||
else
|
||||
return false;
|
||||
});
|
||||
InputNameFeedbacks[tempX] = new StringFeedback(() =>
|
||||
{
|
||||
if (Chassis.Inputs[tempX].NameFeedback != null)
|
||||
{
|
||||
return Chassis.Inputs[tempX].NameFeedback.StringValue;
|
||||
}
|
||||
else
|
||||
{
|
||||
return "";
|
||||
}
|
||||
});
|
||||
|
||||
InputEndpointOnlineFeedbacks[tempX] = new BoolFeedback(() => { return Chassis.Inputs[tempX].EndpointOnlineFeedback; });
|
||||
|
||||
OutputEndpointOnlineFeedbacks[tempX] = new BoolFeedback(() => { return Chassis.Outputs[tempX].EndpointOnlineFeedback; });
|
||||
|
||||
InputCardHdcpCapabilityFeedbacks[tempX] = new IntFeedback(() =>
|
||||
{
|
||||
var inputCard = Chassis.Inputs[tempX];
|
||||
|
||||
if (inputCard.Card is DmcHd)
|
||||
InputEndpointOnlineFeedbacks[tempX] = new BoolFeedback(() =>
|
||||
{
|
||||
InputCardHdcpCapabilityTypes[tempX] = eHdcpCapabilityType.HdcpAutoSupport;
|
||||
return Chassis.Inputs[tempX].EndpointOnlineFeedback;
|
||||
});
|
||||
|
||||
if ((inputCard.Card as DmcHd).HdmiInput.HdcpSupportOnFeedback.BoolValue)
|
||||
return 1;
|
||||
InputCardHdcpCapabilityFeedbacks[tempX] = new IntFeedback(() =>
|
||||
{
|
||||
var inputCard = Chassis.Inputs[tempX];
|
||||
|
||||
if (inputCard.Card is DmcHd)
|
||||
{
|
||||
InputCardHdcpCapabilityTypes[tempX] = eHdcpCapabilityType.HdcpAutoSupport;
|
||||
|
||||
if ((inputCard.Card as DmcHd).HdmiInput.HdcpSupportOnFeedback.BoolValue)
|
||||
return 1;
|
||||
else
|
||||
return 0;
|
||||
}
|
||||
else if (inputCard.Card is DmcHdDsp)
|
||||
{
|
||||
InputCardHdcpCapabilityTypes[tempX] = eHdcpCapabilityType.HdcpAutoSupport;
|
||||
|
||||
if ((inputCard.Card as DmcHdDsp).HdmiInput.HdcpSupportOnFeedback.BoolValue)
|
||||
return 1;
|
||||
else
|
||||
return 0;
|
||||
}
|
||||
else if (inputCard.Card is Dmc4kHdBase)
|
||||
{
|
||||
InputCardHdcpCapabilityTypes[tempX] = eHdcpCapabilityType.Hdcp2_2Support;
|
||||
|
||||
return (int)(inputCard.Card as Dmc4kHdBase).HdmiInput.HdcpReceiveCapability;
|
||||
}
|
||||
else if (inputCard.Card is Dmc4kCBase)
|
||||
{
|
||||
if (PropertiesConfig.InputSlotSupportsHdcp2[tempX])
|
||||
{
|
||||
InputCardHdcpCapabilityTypes[tempX] = eHdcpCapabilityType.HdcpAutoSupport;
|
||||
|
||||
return (int)(inputCard.Card as Dmc4kCBase).DmInput.HdcpReceiveCapability;
|
||||
}
|
||||
else if ((inputCard.Card as Dmc4kCBase).DmInput.HdcpSupportOnFeedback.BoolValue)
|
||||
return 1;
|
||||
else
|
||||
return 0;
|
||||
}
|
||||
else if (inputCard.Card is Dmc4kCDspBase)
|
||||
{
|
||||
if (PropertiesConfig.InputSlotSupportsHdcp2[tempX])
|
||||
{
|
||||
InputCardHdcpCapabilityTypes[tempX] = eHdcpCapabilityType.HdcpAutoSupport;
|
||||
|
||||
return (int)(inputCard.Card as Dmc4kCDspBase).DmInput.HdcpReceiveCapability;
|
||||
}
|
||||
else if ((inputCard.Card as Dmc4kCDspBase).DmInput.HdcpSupportOnFeedback.BoolValue)
|
||||
return 1;
|
||||
else
|
||||
return 0;
|
||||
}
|
||||
else
|
||||
return 0;
|
||||
}
|
||||
else if (inputCard.Card is DmcHdDsp)
|
||||
{
|
||||
InputCardHdcpCapabilityTypes[tempX] = eHdcpCapabilityType.HdcpAutoSupport;
|
||||
|
||||
if ((inputCard.Card as DmcHdDsp).HdmiInput.HdcpSupportOnFeedback.BoolValue)
|
||||
return 1;
|
||||
else
|
||||
return 0;
|
||||
}
|
||||
else if (inputCard.Card is Dmc4kHdBase)
|
||||
{
|
||||
InputCardHdcpCapabilityTypes[tempX] = eHdcpCapabilityType.Hdcp2_2Support;
|
||||
|
||||
return (int)(inputCard.Card as Dmc4kHdBase).HdmiInput.HdcpReceiveCapability;
|
||||
}
|
||||
else
|
||||
return 0;
|
||||
});
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -327,33 +380,39 @@ namespace PepperDash.Essentials.DM
|
||||
}
|
||||
else if (type == "dmcc")
|
||||
{
|
||||
new DmcC(number, this.Chassis);
|
||||
AddDmInCardPorts(number);
|
||||
var inputCard = new DmcC(number, this.Chassis);
|
||||
var cecPort = inputCard.DmInput as ICec;
|
||||
AddDmInCardPorts(number, cecPort);
|
||||
}
|
||||
else if (type == "dmccdsp")
|
||||
{
|
||||
new DmcCDsp(number, this.Chassis);
|
||||
AddDmInCardPorts(number);
|
||||
var inputCard = new DmcCDsp(number, this.Chassis);
|
||||
var cecPort = inputCard.DmInput as ICec;
|
||||
AddDmInCardPorts(number, cecPort);
|
||||
}
|
||||
else if (type == "dmc4kc")
|
||||
{
|
||||
new Dmc4kC(number, this.Chassis);
|
||||
AddDmInCardPorts(number);
|
||||
var inputCard = new Dmc4kC(number, this.Chassis);
|
||||
var cecPort = inputCard.DmInput as ICec;
|
||||
AddDmInCardPorts(number, cecPort);
|
||||
}
|
||||
else if (type == "dmc4kcdsp")
|
||||
{
|
||||
new Dmc4kCDsp(number, this.Chassis);
|
||||
AddDmInCardPorts(number);
|
||||
var inputCard = new Dmc4kCDsp(number, this.Chassis);
|
||||
var cecPort = inputCard.DmInput as ICec;
|
||||
AddDmInCardPorts(number, cecPort);
|
||||
}
|
||||
else if (type == "dmc4kzc")
|
||||
{
|
||||
new Dmc4kzC(number, this.Chassis);
|
||||
AddDmInCardPorts(number);
|
||||
var inputCard = new Dmc4kzC(number, this.Chassis);
|
||||
var cecPort = inputCard.DmInput as ICec;
|
||||
AddDmInCardPorts(number, cecPort);
|
||||
}
|
||||
else if (type == "dmc4kzcdsp")
|
||||
{
|
||||
new Dmc4kzCDsp(number, this.Chassis);
|
||||
AddDmInCardPorts(number);
|
||||
var inputCard = new Dmc4kzCDsp(number, this.Chassis);
|
||||
var cecPort = inputCard.DmInput as ICec;
|
||||
AddDmInCardPorts(number, cecPort);
|
||||
}
|
||||
else if (type == "dmccat")
|
||||
{
|
||||
@@ -453,6 +512,11 @@ namespace PepperDash.Essentials.DM
|
||||
AddInputPortWithDebug(number, "dmIn", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.DmCat);
|
||||
AddInCardHdmiAndAudioLoopPorts(number);
|
||||
}
|
||||
void AddDmInCardPorts(uint number, ICec cecPort)
|
||||
{
|
||||
AddInputPortWithDebug(number, "dmIn", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.DmCat, cecPort);
|
||||
AddInCardHdmiAndAudioLoopPorts(number);
|
||||
}
|
||||
|
||||
void AddHdmiInCardPorts(uint number, ICec cecPort)
|
||||
{
|
||||
@@ -536,7 +600,7 @@ namespace PepperDash.Essentials.DM
|
||||
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "hdmiOut1", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.Hdmi, 2 * (number - 1) + 1, cecPort1);
|
||||
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "dmOut2", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.DmSmFiber, 2 * (number - 1) + 2);
|
||||
}
|
||||
else if (type == "dmcStro")
|
||||
else if (type == "dmcstro")
|
||||
{
|
||||
var outputCard = new DmcStroSingle(number, Chassis);
|
||||
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "streamOut", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.Streaming, 2 * (number - 1) + 1);
|
||||
@@ -583,10 +647,15 @@ namespace PepperDash.Essentials.DM
|
||||
Debug.Console(2, this, "Adding input port '{0}'", portKey);
|
||||
var inputPort = new RoutingInputPort(portKey, sigType, portType, cardNum, this);
|
||||
|
||||
if (cecPort != null)
|
||||
inputPort.Port = cecPort;
|
||||
if (inputPort != null)
|
||||
{
|
||||
if (cecPort != null)
|
||||
inputPort.Port = cecPort;
|
||||
|
||||
InputPorts.Add(inputPort);
|
||||
InputPorts.Add(inputPort);
|
||||
}
|
||||
else
|
||||
Debug.Console(2, this, "inputPort is null");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -31,7 +31,15 @@ namespace PepperDash.Essentials.DM.Config
|
||||
|
||||
[JsonProperty("outputNames")]
|
||||
public Dictionary<uint, string> OutputNames { get; set; }
|
||||
}
|
||||
|
||||
[JsonProperty("inputSlotSupportsHdcp2")]
|
||||
public Dictionary<uint, bool> InputSlotSupportsHdcp2 { get; set; }
|
||||
|
||||
public DMChassisPropertiesConfig()
|
||||
{
|
||||
InputSlotSupportsHdcp2 = new Dictionary<uint, bool>();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
|
||||
@@ -21,6 +21,8 @@ namespace PepperDash.Essentials.DM
|
||||
{
|
||||
public DmTx401C Tx { get; private set; }
|
||||
|
||||
|
||||
|
||||
public RoutingInputPortWithVideoStatuses HdmiIn { get; private set; }
|
||||
public RoutingInputPortWithVideoStatuses DisplayPortIn { get; private set; }
|
||||
public RoutingInputPortWithVideoStatuses VgaIn { get; private set; }
|
||||
|
||||
@@ -59,9 +59,9 @@
|
||||
<HintPath>..\..\..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SSPDevices\Crestron.SimplSharpPro.UI.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="mscorlib" />
|
||||
<Reference Include="PepperDash_Core, Version=1.0.4.20530, Culture=neutral, processorArchitecture=MSIL">
|
||||
<Reference Include="PepperDash_Core, Version=1.0.26.30384, Culture=neutral, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\..\references\PepperDash_Core.dll</HintPath>
|
||||
<HintPath>..\..\pepperdashcore-builds\PepperDash_Core.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="SimplSharpCustomAttributesInterface, Version=1.0.0.0, Culture=neutral, PublicKeyToken=1099c178b3b54c3b, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
|
||||
@@ -63,9 +63,9 @@
|
||||
<HintPath>..\..\..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SSPDevices\Crestron.SimplSharpPro.Lighting.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="mscorlib" />
|
||||
<Reference Include="PepperDash_Core, Version=1.0.4.20530, Culture=neutral, processorArchitecture=MSIL">
|
||||
<Reference Include="PepperDash_Core, Version=1.0.26.30384, Culture=neutral, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\..\references\PepperDash_Core.dll</HintPath>
|
||||
<HintPath>..\..\pepperdashcore-builds\PepperDash_Core.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="SimplSharpCustomAttributesInterface, Version=1.0.0.0, Culture=neutral, PublicKeyToken=1099c178b3b54c3b, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
|
||||
1
essentials-framework/pepperdashcore-builds
Submodule
1
essentials-framework/pepperdashcore-builds
Submodule
Submodule essentials-framework/pepperdashcore-builds added at de8b9f592e
Binary file not shown.
Reference in New Issue
Block a user