mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-01-24 01:45:07 +00:00
Compare commits
12 Commits
1.6.8
...
1.6.9-alph
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
93a5f2e3b2 | ||
|
|
0e4edca08a | ||
|
|
f283f82bbc | ||
|
|
ab5dd5f756 | ||
|
|
e22c71853f | ||
|
|
8bf27ecbd9 | ||
|
|
d94d003050 | ||
|
|
b67424c1e1 | ||
|
|
c366ee9d12 | ||
|
|
b1aa9c3306 | ||
|
|
db6ab3ee98 | ||
|
|
2ccf4be559 |
@@ -70,6 +70,14 @@ namespace PepperDash.Essentials.Bridges
|
||||
/// Range reports the highest supported HDCP state level for the corresponding input card
|
||||
/// </summary>
|
||||
public uint HdcpSupportCapability { get; set; }
|
||||
/// <summary>
|
||||
/// DM Chassis Stream Input Start (1), Stop (2), Pause (3) with Feedback
|
||||
/// </summary>
|
||||
public uint InputStreamCardStatus { get; set; }
|
||||
/// <summary>
|
||||
/// DM Chassis Stream Output Start (1), Stop (2), Pause (3) with Feedback
|
||||
/// </summary>
|
||||
public uint OutputStreamCardStatus { get; set; }
|
||||
#endregion
|
||||
|
||||
#region Serials
|
||||
@@ -115,6 +123,8 @@ namespace PepperDash.Essentials.Bridges
|
||||
InputUsb = 700; //701-899
|
||||
HdcpSupportState = 1000; //1001-1199
|
||||
HdcpSupportCapability = 1200; //1201-1399
|
||||
InputStreamCardStatus = 1500; //1501-1532
|
||||
OutputStreamCardStatus = 1600; //1601-1632
|
||||
|
||||
|
||||
//Serial
|
||||
@@ -145,6 +155,8 @@ namespace PepperDash.Essentials.Bridges
|
||||
OutputEndpointOnline = OutputEndpointOnline + joinOffset;
|
||||
HdcpSupportState = HdcpSupportState + joinOffset;
|
||||
HdcpSupportCapability = HdcpSupportCapability + joinOffset;
|
||||
InputStreamCardStatus = InputStreamCardStatus + joinOffset;
|
||||
OutputStreamCardStatus = OutputStreamCardStatus + joinOffset;
|
||||
OutputDisabledByHdcp = OutputDisabledByHdcp + joinOffset;
|
||||
TxAdvancedIsPresent = TxAdvancedIsPresent + joinOffset;
|
||||
}
|
||||
|
||||
@@ -76,6 +76,14 @@ namespace PepperDash.Essentials.Core.Bridges
|
||||
public JoinDataComplete HdcpSupportCapability = new JoinDataComplete(new JoinData { JoinNumber = 1201, JoinSpan = 32 },
|
||||
new JoinMetadata { Description = "DM Chassis Input HDCP Support Capability", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Analog });
|
||||
|
||||
[JoinName("InputStreamCardState")]
|
||||
public JoinDataComplete InputStreamCardState = new JoinDataComplete(new JoinData { JoinNumber = 1501, JoinSpan = 32 },
|
||||
new JoinMetadata { Description = "DM Chassis Stream Input Start (1), Stop (2), Pause (3) with Feedback", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Analog });
|
||||
|
||||
[JoinName("OutputStreamCardState")]
|
||||
public JoinDataComplete OutputStreamCardState = new JoinDataComplete(new JoinData { JoinNumber = 1601, JoinSpan = 32 },
|
||||
new JoinMetadata { Description = "DM Chassis Stream Output Start (1), Stop (2), Pause (3) with Feedback", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Analog });
|
||||
|
||||
[JoinName("InputNames")]
|
||||
public JoinDataComplete InputNames = new JoinDataComplete(new JoinData { JoinNumber = 101, JoinSpan = 32 },
|
||||
new JoinMetadata { Description = "DM Chassis Input Name", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Serial });
|
||||
|
||||
@@ -402,13 +402,16 @@ namespace PepperDash.Essentials
|
||||
/// Loads a
|
||||
/// </summary>
|
||||
/// <param name="plugin"></param>
|
||||
/// <param name="loadedAssembly"></param>
|
||||
static void LoadCustomPlugin(IPluginDeviceFactory plugin, LoadedAssembly loadedAssembly)
|
||||
{
|
||||
var passed = Global.IsRunningMinimumVersionOrHigher(plugin.MinimumEssentialsFrameworkVersion);
|
||||
|
||||
if (!passed)
|
||||
{
|
||||
Debug.Console(0, Debug.ErrorLogLevel.Error, "Plugin indicates minimum Essentials version {0}. Dependency check failed. Skipping Plugin", plugin.MinimumEssentialsFrameworkVersion);
|
||||
Debug.Console(0, Debug.ErrorLogLevel.Error,
|
||||
"**********\r\nPlugin indicates minimum Essentials version {0}. Dependency check failed. Skipping Plugin {1}\r\n**********",
|
||||
plugin.MinimumEssentialsFrameworkVersion, loadedAssembly.Name);
|
||||
return;
|
||||
}
|
||||
else
|
||||
|
||||
@@ -49,7 +49,9 @@ namespace PepperDash.Essentials.DM
|
||||
public BoolFeedback EnableAudioBreakawayFeedback { get; private set; }
|
||||
public BoolFeedback EnableUsbBreakawayFeedback { get; private set; }
|
||||
|
||||
public Dictionary<uint, IntFeedback> InputCardHdcpStateFeedbacks { get; private set; }
|
||||
public Dictionary<uint, IntFeedback> InputCardHdcpStateFeedbacks { get; private set; }
|
||||
public Dictionary<uint, IntFeedback> InputStreamCardStateFeedbacks { get; private set; }
|
||||
public Dictionary<uint, IntFeedback> OutputStreamCardStateFeedbacks { get; private set; }
|
||||
|
||||
public Dictionary<uint, eHdcpCapabilityType> InputCardHdcpCapabilityTypes { get; private set; }
|
||||
|
||||
@@ -223,7 +225,9 @@ namespace PepperDash.Essentials.DM
|
||||
EnableUsbBreakawayFeedback =
|
||||
new BoolFeedback(() => (Chassis as DmMDMnxn).EnableUSBBreakawayFeedback.BoolValue);
|
||||
|
||||
InputCardHdcpStateFeedbacks = new Dictionary<uint, IntFeedback>();
|
||||
InputCardHdcpStateFeedbacks = new Dictionary<uint, IntFeedback>();
|
||||
InputStreamCardStateFeedbacks = new Dictionary<uint, IntFeedback>();
|
||||
OutputStreamCardStateFeedbacks = new Dictionary<uint, IntFeedback>();
|
||||
InputCardHdcpCapabilityTypes = new Dictionary<uint, eHdcpCapabilityType>();
|
||||
|
||||
for (uint x = 1; x <= Chassis.NumberOfOutputs; x++)
|
||||
@@ -307,6 +311,33 @@ namespace PepperDash.Essentials.DM
|
||||
// return hdMdNxMHdmiOutput.HdmiOutputPort.DisabledByHdcpFeedback.BoolValue;
|
||||
|
||||
return false;
|
||||
});
|
||||
OutputStreamCardStateFeedbacks[tempX] = new IntFeedback(() =>
|
||||
{
|
||||
try
|
||||
{
|
||||
var outputCard = Chassis.Outputs[tempX];
|
||||
|
||||
if (outputCard.Card is DmcStroAV)
|
||||
{
|
||||
Debug.Console(2, "Found output stream card in slot: {0}.", tempX);
|
||||
var streamCard = outputCard.Card as DmcStroAV;
|
||||
if (streamCard.Control.StartFeedback.BoolValue == true)
|
||||
return 1;
|
||||
else if (streamCard.Control.StopFeedback.BoolValue == true)
|
||||
return 2;
|
||||
else if (streamCard.Control.PauseFeedback.BoolValue == true)
|
||||
return 3;
|
||||
else
|
||||
return 0;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
catch (InvalidOperationException iopex)
|
||||
{
|
||||
Debug.Console(0, this, Debug.ErrorLogLevel.Warning, "Error adding output stream card in slot: {0}. Error: {1}", tempX, iopex);
|
||||
return 0;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@@ -406,6 +437,33 @@ namespace PepperDash.Essentials.DM
|
||||
Debug.Console(0, this, Debug.ErrorLogLevel.Warning, "The Input Card in slot: {0} supports HDCP 2. Please update the configuration value in the inputCardSupportsHdcp2 object to true. Error: {1}", tempX, iopex);
|
||||
return 0;
|
||||
}
|
||||
});
|
||||
InputStreamCardStateFeedbacks[tempX] = new IntFeedback(() =>
|
||||
{
|
||||
try
|
||||
{
|
||||
var inputCard = Chassis.Inputs[tempX];
|
||||
|
||||
if (inputCard.Card is DmcStr)
|
||||
{
|
||||
Debug.Console(2, "Found input stream card in slot: {0}.", tempX);
|
||||
var streamCard = inputCard.Card as DmcStr;
|
||||
if (streamCard.Control.StartFeedback.BoolValue == true)
|
||||
return 1;
|
||||
else if (streamCard.Control.StopFeedback.BoolValue == true)
|
||||
return 2;
|
||||
else if (streamCard.Control.PauseFeedback.BoolValue == true)
|
||||
return 3;
|
||||
else
|
||||
return 0;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
catch (InvalidOperationException iopex)
|
||||
{
|
||||
Debug.Console(0, this, Debug.ErrorLogLevel.Warning, "Error adding input stream card in slot: {0}. Error: {1}", tempX, iopex);
|
||||
return 0;
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -915,6 +973,19 @@ namespace PepperDash.Essentials.DM
|
||||
else
|
||||
Debug.Console(1, this, "No index of {0} found in InputCardHdcpCapabilityFeedbacks");
|
||||
break;
|
||||
}
|
||||
case DMInputEventIds.StartEventId:
|
||||
case DMInputEventIds.StopEventId:
|
||||
case DMInputEventIds.PauseEventId:
|
||||
{
|
||||
Debug.Console(2, this, "DM Input {0} Stream Status EventId", args.Number);
|
||||
if (InputStreamCardStateFeedbacks[args.Number] != null)
|
||||
{
|
||||
InputStreamCardStateFeedbacks[args.Number].FireUpdate();
|
||||
}
|
||||
else
|
||||
Debug.Console(2, this, "No index of {0} found in InputStreamCardStateFeedbacks");
|
||||
break;
|
||||
}
|
||||
default:
|
||||
{
|
||||
@@ -1043,6 +1114,19 @@ namespace PepperDash.Essentials.DM
|
||||
Debug.Console(2, this, "DM Output {0} DisabledByHdcpEventId", args.Number);
|
||||
OutputDisabledByHdcpFeedbacks[args.Number].FireUpdate();
|
||||
break;
|
||||
}
|
||||
case DMOutputEventIds.StartEventId:
|
||||
case DMOutputEventIds.StopEventId:
|
||||
case DMOutputEventIds.PauseEventId:
|
||||
{
|
||||
Debug.Console(2, this, "DM Output {0} Stream Status EventId", args.Number);
|
||||
if (OutputStreamCardStateFeedbacks[args.Number] != null)
|
||||
{
|
||||
OutputStreamCardStateFeedbacks[args.Number].FireUpdate();
|
||||
}
|
||||
else
|
||||
Debug.Console(2, this, "No index of {0} found in OutputStreamCardStateFeedbacks");
|
||||
break;
|
||||
}
|
||||
default:
|
||||
{
|
||||
@@ -1242,13 +1326,16 @@ namespace PepperDash.Essentials.DM
|
||||
}
|
||||
else
|
||||
{
|
||||
LinkHdmiInputToApi(trilist, ioSlot, joinMap, ioSlotJoin);
|
||||
}
|
||||
|
||||
if (RxDictionary.ContainsKey(ioSlot))
|
||||
{
|
||||
LinkRxToApi(trilist, ioSlot, joinMap, ioSlotJoin);
|
||||
}
|
||||
LinkHdmiInputToApi(trilist, ioSlot, joinMap, ioSlotJoin);
|
||||
LinkStreamInputToApi(trilist, ioSlot, joinMap, ioSlotJoin);
|
||||
}
|
||||
|
||||
if (RxDictionary.ContainsKey(ioSlot))
|
||||
{
|
||||
LinkRxToApi(trilist, ioSlot, joinMap, ioSlotJoin);
|
||||
}
|
||||
else
|
||||
LinkStreamOutputToApi(trilist, ioSlot, joinMap, ioSlotJoin);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1295,6 +1382,86 @@ namespace PepperDash.Essentials.DM
|
||||
{
|
||||
trilist.UShortInput[joinMap.HdcpSupportCapability.JoinNumber + ioSlotJoin].UShortValue = 1;
|
||||
}
|
||||
}
|
||||
|
||||
private void LinkStreamInputToApi(BasicTriList trilist, uint ioSlot, DmChassisControllerJoinMap joinMap, uint ioSlotJoin)
|
||||
{
|
||||
var inputPort = InputPorts[string.Format("inputCard{0}--streamIn", ioSlot)];
|
||||
if (inputPort == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
var streamCard = Chassis.Inputs[ioSlot].Card as DmcStr;
|
||||
var join = joinMap.InputStreamCardState.JoinNumber + ioSlotJoin;
|
||||
|
||||
Debug.Console(1, "Port value for input card {0} is set as a stream card", ioSlot);
|
||||
|
||||
trilist.SetUShortSigAction(join, s =>
|
||||
{
|
||||
if (s == 1)
|
||||
{
|
||||
Debug.Console(2, this, "Join {0} value {1}: Setting stream state to start", join, s);
|
||||
streamCard.Control.Start();
|
||||
}
|
||||
else if (s == 2)
|
||||
{
|
||||
Debug.Console(2, this, "Join {0} value {1}: Setting stream state to stop", join, s);
|
||||
streamCard.Control.Stop();
|
||||
}
|
||||
else if (s == 3)
|
||||
{
|
||||
Debug.Console(2, this, "Join {0} value {1}: Setting stream state to pause", join, s);
|
||||
streamCard.Control.Pause();
|
||||
}
|
||||
else
|
||||
{
|
||||
Debug.Console(2, this, "Join {0} value {1}: Ignore stream state", join, s);
|
||||
}
|
||||
});
|
||||
|
||||
InputStreamCardStateFeedbacks[ioSlot].LinkInputSig(trilist.UShortInput[join]);
|
||||
|
||||
trilist.UShortInput[join].UShortValue = InputStreamCardStateFeedbacks[ioSlot].UShortValue;
|
||||
}
|
||||
|
||||
private void LinkStreamOutputToApi(BasicTriList trilist, uint ioSlot, DmChassisControllerJoinMap joinMap, uint ioSlotJoin)
|
||||
{
|
||||
var outputPort = OutputPorts[string.Format("outputCard{0}--streamOut", ioSlot)];
|
||||
if (outputPort == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
var streamCard = Chassis.Outputs[ioSlot].Card as DmcStroAV;
|
||||
var join = joinMap.OutputStreamCardState.JoinNumber + ioSlotJoin;
|
||||
|
||||
Debug.Console(1, "Port value for output card {0} is set as a stream card", ioSlot);
|
||||
|
||||
trilist.SetUShortSigAction(join, s =>
|
||||
{
|
||||
if (s == 1)
|
||||
{
|
||||
Debug.Console(2, this, "Join {0} value {1}: Setting stream state to start", join, s);
|
||||
streamCard.Control.Start();
|
||||
}
|
||||
else if (s == 2)
|
||||
{
|
||||
Debug.Console(2, this, "Join {0} value {1}: Setting stream state to stop", join, s);
|
||||
streamCard.Control.Stop();
|
||||
}
|
||||
else if (s == 3)
|
||||
{
|
||||
Debug.Console(2, this, "Join {0} value {1}: Setting stream state to pause", join, s);
|
||||
streamCard.Control.Pause();
|
||||
}
|
||||
else
|
||||
{
|
||||
Debug.Console(2, this, "Join {0} value {1}: Ignore stream state", join, s);
|
||||
}
|
||||
});
|
||||
|
||||
OutputStreamCardStateFeedbacks[ioSlot].LinkInputSig(trilist.UShortInput[join]);
|
||||
|
||||
trilist.UShortInput[join].UShortValue = OutputStreamCardStateFeedbacks[ioSlot].UShortValue;
|
||||
}
|
||||
|
||||
private void LinkRxToApi(BasicTriList trilist, uint ioSlot, DmChassisControllerJoinMap joinMap, uint ioSlotJoin)
|
||||
|
||||
@@ -516,12 +516,16 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
SendText("xconfiguration userinterface custommessage: \"Scan the QR code with a mobile phone to get started\"");
|
||||
SendText("xconfiguration userinterface osd halfwakemessage: \"Tap the touch panel or scan the QR code with a mobile phone to get started\"");
|
||||
|
||||
var checksum = !String.IsNullOrEmpty(mcBridge.QrCodeChecksum)
|
||||
? String.Format("checksum: {0} ", mcBridge.QrCodeChecksum)
|
||||
: String.Empty;
|
||||
|
||||
SendText(String.Format(
|
||||
"xcommand userinterface branding fetch type: branding url: {0}",
|
||||
mcBridge.QrCodeUrl));
|
||||
"xcommand userinterface branding fetch {1}type: branding url: {0}",
|
||||
mcBridge.QrCodeUrl, checksum));
|
||||
SendText(String.Format(
|
||||
"xcommand userinterface branding fetch type: halfwakebranding url: {0}",
|
||||
mcBridge.QrCodeUrl));
|
||||
"xcommand userinterface branding fetch {1}type: halfwakebranding url: {0}",
|
||||
mcBridge.QrCodeUrl, checksum));
|
||||
}
|
||||
|
||||
private void SendBrandingUrl()
|
||||
|
||||
Reference in New Issue
Block a user