diff --git a/Essentials Core/PepperDashEssentialsBase/Routing/RoutingPortNames.cs b/Essentials Core/PepperDashEssentialsBase/Routing/RoutingPortNames.cs index 7e72230b..1377c9d4 100644 --- a/Essentials Core/PepperDashEssentialsBase/Routing/RoutingPortNames.cs +++ b/Essentials Core/PepperDashEssentialsBase/Routing/RoutingPortNames.cs @@ -108,10 +108,18 @@ namespace PepperDash.Essentials.Core.Routing /// public const string HdmiIn1 = "hdmiIn1"; /// + /// hdmiIn1PC + /// + public const string HdmiIn1PC = "hdmiIn1PC"; + /// /// hdmiIn2 /// public const string HdmiIn2 = "hdmiIn2"; /// + /// hdmiIn2PC + /// + public const string HdmiIn2PC = "hdmiIn2PC"; + /// /// hdmiIn3 /// public const string HdmiIn3 = "hdmiIn3"; diff --git a/Essentials Devices Common/Essentials Devices Common/Display/SamsungMDCDisplay.cs b/Essentials Devices Common/Essentials Devices Common/Display/SamsungMDCDisplay.cs index c795ba60..217186cf 100644 --- a/Essentials Devices Common/Essentials Devices Common/Display/SamsungMDCDisplay.cs +++ b/Essentials Devices Common/Essentials Devices Common/Display/SamsungMDCDisplay.cs @@ -23,6 +23,7 @@ namespace PepperDash.Essentials.Devices.Displays public byte ID { get; private set; } + bool LastCommandSentWasVolume; bool _PowerIsOn; bool _IsWarmingUp; @@ -99,9 +100,15 @@ namespace PepperDash.Essentials.Devices.Displays AddRoutingInputPort(new RoutingInputPort(RoutingPortNames.HdmiIn1, eRoutingSignalType.AudioVideo, eRoutingPortConnectionType.Hdmi, new Action(InputHdmi1), this), 0x21); + AddRoutingInputPort(new RoutingInputPort(RoutingPortNames.HdmiIn1PC, eRoutingSignalType.AudioVideo, + eRoutingPortConnectionType.Hdmi, new Action(InputHdmi1PC), this), 0x22); + AddRoutingInputPort(new RoutingInputPort(RoutingPortNames.HdmiIn2, eRoutingSignalType.AudioVideo, eRoutingPortConnectionType.Hdmi, new Action(InputHdmi2), this), 0x23); + AddRoutingInputPort(new RoutingInputPort(RoutingPortNames.HdmiIn2PC, eRoutingSignalType.AudioVideo, + eRoutingPortConnectionType.Hdmi, new Action(InputHdmi2PC), this), 0x24); + AddRoutingInputPort(new RoutingInputPort(RoutingPortNames.HdmiIn3, eRoutingSignalType.AudioVideo, eRoutingPortConnectionType.Hdmi, new Action(InputHdmi3), this), 0x32); @@ -165,6 +172,9 @@ namespace PepperDash.Essentials.Devices.Displays IncomingBuffer.CopyTo(newBytes, 0); e.Bytes.CopyTo(newBytes, IncomingBuffer.Length); + if (Debug.Level == 2) // This check is here to prevent following string format from building unnecessarily on level 0 or 1 + Debug.Console(2, this, "Received:{0}", ComTextHelper.GetEscapedText(newBytes)); + // Need to find AA FF and have for (int i = 0; i < newBytes.Length; i++) { @@ -309,6 +319,10 @@ namespace PepperDash.Essentials.Devices.Displays /// void SendBytes(byte[] b) { + if (LastCommandSentWasVolume) // If the last command sent was volume + if (b[1] != 0x12) // Check if this command is volume, and if not, delay this command + CrestronEnvironment.Sleep(100); + b[2] = ID; // append checksum by adding all bytes, except last which should be 00 int checksum = 0; @@ -320,6 +334,12 @@ namespace PepperDash.Essentials.Devices.Displays b[b.Length - 1] = (byte)checksum; if(Debug.Level == 2) // This check is here to prevent following string format from building unnecessarily on level 0 or 1 Debug.Console(2, this, "Sending:{0}", ComTextHelper.GetEscapedText(b)); + + if (b[1] == 0x12) + LastCommandSentWasVolume = true; + else + LastCommandSentWasVolume = false; + Communication.SendBytes(b); } @@ -396,11 +416,21 @@ namespace PepperDash.Essentials.Devices.Displays SendBytes(new byte[] { 0xAA, 0x14, 0x00, 0x01, 0x21, 0x00 }); } + public void InputHdmi1PC() + { + SendBytes(new byte[] { 0xAA, 0x14, 0x00, 0x01, 0x22, 0x00 }); + } + public void InputHdmi2() { SendBytes(new byte[] { 0xAA, 0x14, 0x00, 0x01, 0x23, 0x00 }); } + public void InputHdmi2PC() + { + SendBytes(new byte[] { 0xAA, 0x14, 0x00, 0x01, 0x24, 0x00 }); + } + public void InputHdmi3() { SendBytes(new byte[] { 0xAA, 0x14, 0x00, 0x01, 0x32, 0x00 }); diff --git a/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj b/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj index ab3b8eeb..87e24f6a 100644 --- a/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj +++ b/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj @@ -61,7 +61,7 @@ False - ..\..\..\PepperDash.Core\Pepperdash Core\Pepperdash Core\bin\PepperDash_Core.dll + ..\..\..\pepperdash-simplsharp-core\Pepperdash Core\CLZ Builds\PepperDash_Core.dll False @@ -119,8 +119,6 @@ - - diff --git a/Essentials Devices Common/Essentials Devices Common/VideoCodec/CiscoCodec/CiscoSparkCodec.cs b/Essentials Devices Common/Essentials Devices Common/VideoCodec/CiscoCodec/CiscoSparkCodec.cs index 83a6898f..abe0683d 100644 --- a/Essentials Devices Common/Essentials Devices Common/VideoCodec/CiscoCodec/CiscoSparkCodec.cs +++ b/Essentials Devices Common/Essentials Devices Common/VideoCodec/CiscoCodec/CiscoSparkCodec.cs @@ -1264,7 +1264,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco public override bool MultiSiteOptionIsEnabled { - get + get { if (CodecStatus.Status.SystemUnit.Software.OptionKeys.MultiSite.Value.ToLower() == "true") return true; diff --git a/Essentials/PepperDashEssentials/UIDrivers/EssentialsHuddle/EssentialsHuddleTechPageDriver.cs b/Essentials/PepperDashEssentials/UIDrivers/EssentialsHuddle/EssentialsHuddleTechPageDriver.cs index bc03118a..9bde21af 100644 --- a/Essentials/PepperDashEssentials/UIDrivers/EssentialsHuddle/EssentialsHuddleTechPageDriver.cs +++ b/Essentials/PepperDashEssentials/UIDrivers/EssentialsHuddle/EssentialsHuddleTechPageDriver.cs @@ -269,9 +269,9 @@ namespace PepperDash.Essentials.UIDrivers { if (display is IInputHdmi2) (display as IInputHdmi2).InputHdmi2(); }); DisplayList.GetBoolFeedbackSig(i, 5).SetSigFalseAction(() => { if (display is IInputHdmi3) (display as IInputHdmi3).InputHdmi3(); }); + //DisplayList.GetBoolFeedbackSig(i, 6).SetSigFalseAction(() => + //{ if (display is IInputHdmi4) (display as IInputHdmi4).InputHdmi4(); }); DisplayList.GetBoolFeedbackSig(i, 6).SetSigFalseAction(() => - { if (display is IInputHdmi4) (display as IInputHdmi4).InputHdmi4(); }); - DisplayList.GetBoolFeedbackSig(i, 7).SetSigFalseAction(() => { if (display is IInputDisplayPort1) (display as IInputDisplayPort1).InputDisplayPort1(); }); } } diff --git a/Essentials/PepperDashEssentials/UIDrivers/VC/EssentialsVideoCodecUiDriver.cs b/Essentials/PepperDashEssentials/UIDrivers/VC/EssentialsVideoCodecUiDriver.cs index 58a7f0ae..51d0d552 100644 --- a/Essentials/PepperDashEssentials/UIDrivers/VC/EssentialsVideoCodecUiDriver.cs +++ b/Essentials/PepperDashEssentials/UIDrivers/VC/EssentialsVideoCodecUiDriver.cs @@ -195,10 +195,13 @@ namespace PepperDash.Essentials.UIDrivers.VC { string roomNumberSipUri = ""; if (!string.IsNullOrEmpty(Codec.CodecInfo.SipUri)) // If both values are present, format the string with a pipe divider - roomNumberSipUri = string.Format("{0} | {2}", GetFormattedPhoneNumber(Codec.CodecInfo.SipPhoneNumber), Codec.CodecInfo.SipUri); + roomNumberSipUri = string.Format("{0} | {1}", GetFormattedPhoneNumber(Codec.CodecInfo.SipPhoneNumber), Codec.CodecInfo.SipUri); else // If only one value present, just show the phone number roomNumberSipUri = Codec.CodecInfo.SipPhoneNumber; + if(string.IsNullOrEmpty(roomNumberSipUri)) + roomNumberSipUri = string.Format("{0} | {1}", GetFormattedPhoneNumber(Codec.CodecInfo.E164Alias), Codec.CodecInfo.H323Id); + TriList.SetString(UIStringJoin.RoomPhoneText, roomNumberSipUri); if(Parent.HeaderButtonsAreSetUp)