From f1d1ce9722f56146d9a5f1961b07fd1381119466 Mon Sep 17 00:00:00 2001 From: jdevito Date: Tue, 6 Sep 2022 14:04:19 -0500 Subject: [PATCH 01/11] fix: added OnPasswordRequired event call in SubmitPassword method to clear popup when bridged --- .../Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs | 1 + 1 file changed, 1 insertion(+) diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs index 32415d1d..21048d56 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs @@ -3357,6 +3357,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom { Debug.Console(2, this, "Password Submitted: {0}", password); Dial(_lastDialedMeetingNumber, password); + OnPasswordRequired(false, false, true, ""); } void OnPasswordRequired(bool lastAttemptIncorrect, bool loginFailed, bool loginCancelled, string message) From f1590aeec8772920cb5d0d8195817e9226472bfa Mon Sep 17 00:00:00 2001 From: jdevito Date: Tue, 6 Sep 2022 14:10:21 -0500 Subject: [PATCH 02/11] fix: added 'CancelPasswordPrompt' join, updated linkToZoomApi --- .../VideoCodec/ZoomRoom/ZoomRoom.cs | 2 ++ .../VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs | 14 ++++++++++++++ 2 files changed, 16 insertions(+) diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs index 21048d56..8de58c23 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs @@ -2495,6 +2495,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom trilist.SetStringSigAction(joinMap.SubmitPassword.JoinNumber, SubmitPassword); + trilist.SetStringSigAction(joinMap.CancelPasswordPrompt.JoinNumber, + delegate { OnPasswordRequired(false, false, true, ""); }); PasswordRequired += (devices, args) => { if (args.LoginAttemptCancelled) diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs index 48b2c039..b0b497de 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs @@ -23,6 +23,20 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom JoinType = eJoinType.Digital }); + [JoinName("CancelPasswordPrompt")] + public JoinDataComplete CancelPasswordPrompt = new JoinDataComplete( + new JoinData + { + JoinNumber = 7, + JoinSpan = 1 + }, + new JoinMetadata + { + Description = "cancels password prompt", + JoinCapabilities = eJoinCapabilities.FromSIMPL, + JoinType = eJoinType.Digital + }); + // TODO [ ] Issue #868 [JoinName("PasswordIncorrect")] public JoinDataComplete PasswordIncorrect = new JoinDataComplete( From c557400f383b5c5450c856c5baef93e1c2fd4a69 Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Fri, 26 Aug 2022 15:07:57 -0600 Subject: [PATCH 03/11] fix(essentials): updates ZoomRoom mute state to report muted when not in call --- .../VideoCodec/VideoCodecBase.cs | 2 ++ .../VideoCodec/ZoomRoom/ZoomRoom.cs | 18 +++++++++++++++++- 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/VideoCodecBase.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/VideoCodecBase.cs index 6e577c59..1270b690 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/VideoCodecBase.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/VideoCodecBase.cs @@ -214,6 +214,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec handler(this, new CodecCallStatusItemChangeEventArgs(item)); } + PrivacyModeIsOnFeedback.FireUpdate(); + if (AutoShareContentWhileInCall) { StartSharing(); diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs index 32415d1d..a8b413a8 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs @@ -214,7 +214,23 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom protected override Func PrivacyModeIsOnFeedbackFunc { - get { return () => Configuration.Call.Microphone.Mute; } + get + { + return () => + { + Debug.Console(2, this, "PrivacyModeIsOnFeedbackFunc. IsInCall: {0} muteState: {1}", IsInCall, Configuration.Call.Microphone.Mute); + if (IsInCall) + { + Debug.Console(2, this, "reporting muteState: ", Configuration.Call.Microphone.Mute); + return Configuration.Call.Microphone.Mute; + } + else + { + Debug.Console(2, this, "muteState: true", IsInCall); + return true; + } + }; + } } protected override Func StandbyIsOnFeedbackFunc From 215cf6696e379c15222a512d54d98c06e159857b Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Thu, 8 Sep 2022 14:22:53 -0600 Subject: [PATCH 04/11] fix(essentials): Set not in call state to report as unmuted --- .../VideoCodec/ZoomRoom/ZoomRoom.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs index a8b413a8..d3c0cd0f 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs @@ -218,16 +218,16 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom { return () => { - Debug.Console(2, this, "PrivacyModeIsOnFeedbackFunc. IsInCall: {0} muteState: {1}", IsInCall, Configuration.Call.Microphone.Mute); + //Debug.Console(2, this, "PrivacyModeIsOnFeedbackFunc. IsInCall: {0} muteState: {1}", IsInCall, Configuration.Call.Microphone.Mute); if (IsInCall) { - Debug.Console(2, this, "reporting muteState: ", Configuration.Call.Microphone.Mute); + //Debug.Console(2, this, "reporting muteState: ", Configuration.Call.Microphone.Mute); return Configuration.Call.Microphone.Mute; } else { - Debug.Console(2, this, "muteState: true", IsInCall); - return true; + //Debug.Console(2, this, "muteState: true", IsInCall); + return false; } }; } From 939afb7aae78d3af755391f52785ef539155fa55 Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Wed, 14 Sep 2022 16:40:26 -0600 Subject: [PATCH 05/11] fix(essentials): Fixes SharingSourceFeedback value to actually read FB state instead of which on screen instructions are shown --- .../VideoCodec/ZoomRoom/ZoomRoom.cs | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs index 223d3bb4..30ec50c8 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs @@ -240,7 +240,18 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom protected override Func SharingSourceFeedbackFunc { - get { return () => Status.Sharing.dispState; } + get + { + return () => + { + if (Status.Sharing.isAirHostClientConnected) + return "Airplay"; + else if (Status.Sharing.isDirectPresentationConnected || Status.Sharing.isBlackMagicConnected) + return "Laptop"; + else return "None"; + + }; + } } protected override Func SharingContentIsOnFeedbackFunc @@ -743,15 +754,11 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom Status.Sharing.PropertyChanged += (o, a) => { + SharingSourceFeedback.FireUpdate(); switch (a.PropertyName) { - case "dispState": - SharingSourceFeedback.FireUpdate(); - break; case "password": break; - case "isAirHostClientConnected": - case "isDirectPresentationConnected": case "isSharingBlackMagic": { Debug.Console(2, this, "Updating sharing status: {0}", a.PropertyName); From ee735388bbf5676581156103655a3921b57df4b2 Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Thu, 15 Sep 2022 12:44:17 -0600 Subject: [PATCH 06/11] fix(essentials): reworks SIMPL bridging logic for hiding password prompt --- .../VideoCodec/ZoomRoom/ZoomRoom.cs | 25 +++++++++++-------- .../VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs | 14 ----------- 2 files changed, 14 insertions(+), 25 deletions(-) diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs index 30ec50c8..ea1b35b4 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs @@ -2509,17 +2509,20 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom trilist.SetSigTrueAction(joinMap.ShareOnlyMeeting.JoinNumber, StartSharingOnlyMeeting); trilist.SetSigTrueAction(joinMap.StartNormalMeetingFromSharingOnlyMeeting.JoinNumber, StartNormalMeetingFromSharingOnlyMeeting); - // not sure if this would be needed here, should be handled by VideoCodecBase.cs LinkToApi methods - //DirectoryResultReturned += (device, args) => - //{ - // // add logic here if necessary when event fires - - //}; - - trilist.SetStringSigAction(joinMap.SubmitPassword.JoinNumber, SubmitPassword); - trilist.SetStringSigAction(joinMap.CancelPasswordPrompt.JoinNumber, - delegate { OnPasswordRequired(false, false, true, ""); }); + //trilist.SetSigFalseAction(joinMap.CancelPasswordPrompt.JoinNumber, () => + // OnPasswordRequired(false, false, true, "")); + + // Subscribe to call status to clear ShowPasswordPrompt when in meeting + this.CallStatusChange += (o, a) => + { + if (IsInCall) + { + trilist.SetBool(joinMap.ShowPasswordPrompt.JoinNumber, false); + } + + }; + PasswordRequired += (devices, args) => { if (args.LoginAttemptCancelled) @@ -3382,7 +3385,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom { Debug.Console(2, this, "Password Submitted: {0}", password); Dial(_lastDialedMeetingNumber, password); - OnPasswordRequired(false, false, true, ""); + //OnPasswordRequired(false, false, true, ""); } void OnPasswordRequired(bool lastAttemptIncorrect, bool loginFailed, bool loginCancelled, string message) diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs index b0b497de..48b2c039 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs @@ -23,20 +23,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom JoinType = eJoinType.Digital }); - [JoinName("CancelPasswordPrompt")] - public JoinDataComplete CancelPasswordPrompt = new JoinDataComplete( - new JoinData - { - JoinNumber = 7, - JoinSpan = 1 - }, - new JoinMetadata - { - Description = "cancels password prompt", - JoinCapabilities = eJoinCapabilities.FromSIMPL, - JoinType = eJoinType.Digital - }); - // TODO [ ] Issue #868 [JoinName("PasswordIncorrect")] public JoinDataComplete PasswordIncorrect = new JoinDataComplete( From bda46eb1b9c324c33254d0a476aba7a5c62f3eb0 Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Thu, 22 Sep 2022 13:05:09 -0600 Subject: [PATCH 07/11] fix(essentials): adds cancel method for password prompt and adds wireless share instructions --- .../DeviceTypeInterfaces/IPasswordPrompt.cs | 7 +- .../IZoomWirelessShareInstructions.cs | 28 ++++ .../VideoCodec/ZoomRoom/ResponseObjects.cs | 13 +- .../VideoCodec/ZoomRoom/ZoomRoom.cs | 64 +++++++- .../VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs | 144 ++++++++++++++++-- 5 files changed, 236 insertions(+), 20 deletions(-) create mode 100644 essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/IZoomWirelessShareInstructions.cs diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/DeviceTypeInterfaces/IPasswordPrompt.cs b/essentials-framework/Essentials Core/PepperDashEssentialsBase/DeviceTypeInterfaces/IPasswordPrompt.cs index 6ecdd775..6b3bae57 100644 --- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/DeviceTypeInterfaces/IPasswordPrompt.cs +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/DeviceTypeInterfaces/IPasswordPrompt.cs @@ -20,7 +20,12 @@ namespace PepperDash.Essentials.Core /// Submits the password /// /// - void SubmitPassword(string password); + void SubmitPassword(string password); + + /// + /// Cancels the password submission + /// + void CancelPasswordPrompt(); } public class PasswordPromptEventArgs : EventArgs diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/IZoomWirelessShareInstructions.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/IZoomWirelessShareInstructions.cs new file mode 100644 index 00000000..58690d3b --- /dev/null +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/IZoomWirelessShareInstructions.cs @@ -0,0 +1,28 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using Crestron.SimplSharp; +using PepperDash.Essentials.Core; + +using PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom; + +namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom +{ + public class ShareInfoEventArgs : EventArgs + { + public zStatus.Sharing SharingStatus { get; private set; } + + public ShareInfoEventArgs(zStatus.Sharing status) + { + SharingStatus = status; + } + } + + public interface IZoomWirelessShareInstructions + { + event EventHandler ShareInfoChanged; + + zStatus.Sharing SharingState { get; } + } +} \ No newline at end of file diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ResponseObjects.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ResponseObjects.cs index b5296410..66b7fb1e 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ResponseObjects.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ResponseObjects.cs @@ -434,9 +434,16 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom public bool supports_Web_Settings_Push { get; set; } } + public enum eDisplayState + { + None, + Laptop, + IOS, + } + public class Sharing : NotifiableObject { - private string _dispState; + private eDisplayState _dispState; private string _password; private bool _isAirHostClientConnected; private bool _isSharingBlackMagic; @@ -448,7 +455,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom /// Laptop client sharing key /// public string directPresentationSharingKey { get; set; } - public string dispState + public eDisplayState dispState { get { @@ -506,8 +513,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom } } - - /// /// IOS Airplay code /// diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs index ea1b35b4..b753b3fc 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs @@ -27,7 +27,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom IHasScheduleAwareness, IHasCodecCameras, IHasParticipants, IHasCameraOff, IHasCameraMuteWithUnmuteReqeust, IHasCameraAutoMode, IHasFarEndContentStatus, IHasSelfviewPosition, IHasPhoneDialing, IHasZoomRoomLayouts, IHasParticipantPinUnpin, IHasParticipantAudioMute, IHasSelfviewSize, IPasswordPrompt, IHasStartMeeting, IHasMeetingInfo, IHasPresentationOnlyMeeting, - IHasMeetingLock, IHasMeetingRecordingWithPrompt + IHasMeetingLock, IHasMeetingRecordingWithPrompt, IZoomWirelessShareInstructions { public event EventHandler VideoUnmuteRequested; @@ -47,12 +47,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom private const string JsonDelimiter = "\x0D\x0A\x7D\x0D\x0A"; private string[] Delimiters = new string[] { EchoDelimiter, JsonDelimiter, "OK\x0D\x0A", "end\x0D\x0A" }; - //"echo off\x0D\x0A\x0A\x0D\x0A" private readonly GenericQueue _receiveQueue; - //private readonly CrestronQueue _receiveQueue; - - - //private readonly Thread _receiveThread; private readonly ZoomRoomSyncState _syncState; public bool CommDebuggingIsOn; @@ -64,6 +59,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom private CameraBase _selectedCamera; private string _lastDialedMeetingNumber; + private readonly ZoomRoomPropertiesConfig _props; public ZoomRoom(DeviceConfig config, IBasicCommunication comm) @@ -754,6 +750,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom Status.Sharing.PropertyChanged += (o, a) => { + OnShareInfoChanged(Status.Sharing); SharingSourceFeedback.FireUpdate(); switch (a.PropertyName) { @@ -2523,8 +2520,12 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom }; + trilist.SetSigFalseAction(joinMap.CancelPasswordPrompt.JoinNumber, () => CancelPasswordPrompt()); + PasswordRequired += (devices, args) => { + Debug.Console(0, this, "***********************************PaswordRequired. Message: {0} Cancelled: {1} Last Incorrect: {2} Failed: {3}", args.Message, args.LoginAttemptCancelled, args.LastAttemptWasIncorrect, args.LoginAttemptFailed); + if (args.LoginAttemptCancelled) { trilist.SetBool(joinMap.ShowPasswordPrompt.JoinNumber, false); @@ -2559,8 +2560,31 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom pinCodec.NumberOfScreensFeedback.FireUpdate(); layoutSizeCodec.SelfviewPipSizeFeedback.FireUpdate(); }; + + var wirelessInfoCodec = this as IZoomWirelessShareInstructions; + if (wirelessInfoCodec != null) + { + SetSharingStateJoins(Status.Sharing, trilist, joinMap); + + wirelessInfoCodec.ShareInfoChanged += (o, a) => + { + SetSharingStateJoins(a.SharingStatus, trilist, joinMap); + }; + } } + void SetSharingStateJoins(zStatus.Sharing state, BasicTriList trilist, ZoomRoomJoinMap joinMap) + { + trilist.SetBool(joinMap.IsSharingAirplay.JoinNumber, state.isAirHostClientConnected); + trilist.SetBool(joinMap.IsSharingHdmi.JoinNumber, state.isBlackMagicConnected || state.isDirectPresentationConnected); + + trilist.SetString(joinMap.DisplayState.JoinNumber, state.dispState.ToString()); + trilist.SetString(joinMap.AirplayShareCode.JoinNumber, state.password); + trilist.SetString(joinMap.LaptopShareKey.JoinNumber, state.directPresentationSharingKey); + trilist.SetString(joinMap.WifiName.JoinNumber, state.wifiName); + trilist.SetString(joinMap.ServerName.JoinNumber, state.serverName); + } + public override void ExecuteSwitch(object selector) { var action = selector as Action; @@ -3388,6 +3412,11 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom //OnPasswordRequired(false, false, true, ""); } + public void CancelPasswordPrompt() + { + OnPasswordRequired(false, false, true, "Login Cancelled"); + } + void OnPasswordRequired(bool lastAttemptIncorrect, bool loginFailed, bool loginCancelled, string message) { var handler = PasswordRequired; @@ -3521,6 +3550,29 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom } #endregion + + #region IZoomWirelessShareInstructions Members + + public event EventHandler ShareInfoChanged; + + public zStatus.Sharing SharingState + { + get + { + return Status.Sharing; + } + } + + void OnShareInfoChanged(zStatus.Sharing status) + { + var handler = ShareInfoChanged; + if (handler != null) + { + handler(this, new ShareInfoEventArgs(status)); + } + } + + #endregion } /// diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs index 48b2c039..d6ffb903 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs @@ -8,7 +8,20 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom { #region Digital - // TODO [ ] Issue #868 + [JoinName("CancelPasswordPrompt")] + public JoinDataComplete CancelPasswordPrompt = new JoinDataComplete( + new JoinData + { + JoinNumber = 5, + JoinSpan = 1 + }, + new JoinMetadata + { + Description = "Pulse to hide the password prompt", + JoinCapabilities = eJoinCapabilities.FromSIMPL, + JoinType = eJoinType.Digital + }); + [JoinName("ShowPasswordPrompt")] public JoinDataComplete ShowPasswordPrompt = new JoinDataComplete( new JoinData @@ -23,7 +36,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom JoinType = eJoinType.Digital }); - // TODO [ ] Issue #868 [JoinName("PasswordIncorrect")] public JoinDataComplete PasswordIncorrect = new JoinDataComplete( new JoinData @@ -38,8 +50,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom JoinType = eJoinType.Digital }); - // TODO [ ] Issue #868 - [JoinName("PassowrdLoginFailed")] + [JoinName("PasswordLoginFailed")] public JoinDataComplete PasswordLoginFailed = new JoinDataComplete( new JoinData { @@ -53,7 +64,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom JoinType = eJoinType.Digital }); - // TODO [ ] Issue #868 [JoinName("WaitingForHost")] public JoinDataComplete WaitingForHost = new JoinDataComplete( new JoinData @@ -68,7 +78,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom JoinType = eJoinType.Digital }); - // TODO [ ] Issue #868 [JoinName("IsHost")] public JoinDataComplete IsHost = new JoinDataComplete( new JoinData @@ -83,7 +92,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom JoinType = eJoinType.Digital }); - // TODO [ ] Issue #868 [JoinName("StartMeetingNow")] public JoinDataComplete StartMeetingNow = new JoinDataComplete( new JoinData @@ -98,7 +106,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom JoinType = eJoinType.Digital }); - // TODO [ ] Issue #868 [JoinName("ShareOnlyMeeting")] public JoinDataComplete ShareOnlyMeeting = new JoinDataComplete( new JoinData @@ -113,7 +120,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom JoinType = eJoinType.Digital }); - // TODO [ ] Issue #868 [JoinName("StartNormalMeetingFromSharingOnlyMeeting")] public JoinDataComplete StartNormalMeetingFromSharingOnlyMeeting = new JoinDataComplete( new JoinData @@ -367,6 +373,40 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom JoinType = eJoinType.Digital }); + + #region Sharing Status + + [JoinName("IsSharingAirplay")] + public JoinDataComplete IsSharingAirplay = new JoinDataComplete( + new JoinData + { + JoinNumber = 250, + JoinSpan = 1 + }, + new JoinMetadata + { + Description = "Indicates an Airplay source is sharing", + JoinCapabilities = eJoinCapabilities.ToSIMPL, + JoinType = eJoinType.Digital + }); + + [JoinName("IsSharingHdmi")] + public JoinDataComplete IsSharingHdmi = new JoinDataComplete( + new JoinData + { + JoinNumber = 251, + JoinSpan = 1 + }, + new JoinMetadata + { + Description = "Indicates an HDMI source is sharing", + JoinCapabilities = eJoinCapabilities.ToSIMPL, + JoinType = eJoinType.Digital + }); + + + + #endregion //[JoinName("ParticipantAudioMuteToggleStart")] //public JoinDataComplete ParticipantAudioMuteToggleStart = new JoinDataComplete( // new JoinData @@ -551,6 +591,92 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom JoinType = eJoinType.DigitalSerial }); + [JoinName("DisplayState")] + public JoinDataComplete DisplayState = new JoinDataComplete( + new JoinData + { + JoinNumber = 250, + JoinSpan = 1 + }, + new JoinMetadata + { + Description = "Reports the instructions the ZoomRoom is displaying on the monitor. ", + JoinCapabilities = eJoinCapabilities.ToSIMPL, + JoinType = eJoinType.Serial + }); + + [JoinName("AirplayShareCode")] + public JoinDataComplete AirplayShareCode = new JoinDataComplete( + new JoinData + { + JoinNumber = 251, + JoinSpan = 1 + }, + new JoinMetadata + { + Description = "Reports the current code for Airplay Sharing.", + JoinCapabilities = eJoinCapabilities.ToSIMPL, + JoinType = eJoinType.Serial + }); + + [JoinName("LaptopShareKey")] + public JoinDataComplete LaptopShareKey = new JoinDataComplete( + new JoinData + { + JoinNumber = 252, + JoinSpan = 1 + }, + new JoinMetadata + { + Description = "The alpha-only sharing key that users type into a laptop client to share with the Zoom Room.", + JoinCapabilities = eJoinCapabilities.ToSIMPL, + JoinType = eJoinType.Serial + }); + + [JoinName("LaptopSharePairingCode")] + public JoinDataComplete LaptopSharePairingCode = new JoinDataComplete( + new JoinData + { + JoinNumber = 253, + JoinSpan = 1 + }, + new JoinMetadata + { + Description = "This is the paring code that is broadcast via an ultrasonic signal from the ZRC. It is different than the user-supplied paring code. The ZRC uses a Zoom-proprietary method of advertizing the ultrasonic pairing code, so it\'s not possible to advertize it using commonly available libraries.", + JoinCapabilities = eJoinCapabilities.ToSIMPL, + JoinType = eJoinType.Serial + }); + + [JoinName("WifiName")] + public JoinDataComplete WifiName = new JoinDataComplete( + new JoinData + { + JoinNumber = 254, + JoinSpan = 1 + }, + new JoinMetadata + { + Description = "Reports the Wifi SSID used by the ZoomRoom.", + JoinCapabilities = eJoinCapabilities.ToSIMPL, + JoinType = eJoinType.Serial + }); + + [JoinName("ServerName")] + public JoinDataComplete ServerName = new JoinDataComplete( + new JoinData + { + JoinNumber = 255, + JoinSpan = 1 + }, + new JoinMetadata + { + Description = "Reports the namne of the the ZoomRoom.", + JoinCapabilities = eJoinCapabilities.ToSIMPL, + JoinType = eJoinType.Serial + }); + + + #endregion public ZoomRoomJoinMap(uint joinStart) From b48859d202fff6f074cca166b6f6483b4acd7471 Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Thu, 22 Sep 2022 13:06:00 -0600 Subject: [PATCH 08/11] adds missing .csproj update --- .../Essentials Devices Common/Essentials Devices Common.csproj | 1 + 1 file changed, 1 insertion(+) diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj b/essentials-framework/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj index fe4d5f61..c2782532 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj @@ -184,6 +184,7 @@ + From eae089cdf58e20d806ac4ac46126a7d938e9022a Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Thu, 22 Sep 2022 15:38:11 -0600 Subject: [PATCH 09/11] fix(essentials): updates to password prompt logic --- .../VideoCodec/ZoomRoom/ZoomRoom.cs | 10 +++++----- .../VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs | 8 ++++---- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs index b753b3fc..5aeb3be0 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs @@ -2513,14 +2513,14 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom // Subscribe to call status to clear ShowPasswordPrompt when in meeting this.CallStatusChange += (o, a) => { - if (IsInCall) + if (a.CallItem.Status == eCodecCallStatus.Connected || a.CallItem.Status == eCodecCallStatus.Disconnected) { - trilist.SetBool(joinMap.ShowPasswordPrompt.JoinNumber, false); + trilist.SetBool(joinMap.MeetingPasswordRequired.JoinNumber, false); } }; - trilist.SetSigFalseAction(joinMap.CancelPasswordPrompt.JoinNumber, () => CancelPasswordPrompt()); + trilist.SetSigFalseAction(joinMap.CancelJoinAttempt.JoinNumber, () => trilist.SetBool(joinMap.MeetingPasswordRequired.JoinNumber, false)); PasswordRequired += (devices, args) => { @@ -2528,7 +2528,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom if (args.LoginAttemptCancelled) { - trilist.SetBool(joinMap.ShowPasswordPrompt.JoinNumber, false); + trilist.SetBool(joinMap.MeetingPasswordRequired.JoinNumber, false); return; } @@ -2544,7 +2544,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom } trilist.SetBool(joinMap.PasswordIncorrect.JoinNumber, args.LastAttemptWasIncorrect); - trilist.SetBool(joinMap.ShowPasswordPrompt.JoinNumber, true); + trilist.SetBool(joinMap.MeetingPasswordRequired.JoinNumber, true); }; trilist.OnlineStatusChange += (device, args) => diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs index d6ffb903..c377a664 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoomJoinMap.cs @@ -8,8 +8,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom { #region Digital - [JoinName("CancelPasswordPrompt")] - public JoinDataComplete CancelPasswordPrompt = new JoinDataComplete( + [JoinName("CancelJoinAttempt")] + public JoinDataComplete CancelJoinAttempt = new JoinDataComplete( new JoinData { JoinNumber = 5, @@ -22,8 +22,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom JoinType = eJoinType.Digital }); - [JoinName("ShowPasswordPrompt")] - public JoinDataComplete ShowPasswordPrompt = new JoinDataComplete( + [JoinName("MeetingPasswordRequired")] + public JoinDataComplete MeetingPasswordRequired = new JoinDataComplete( new JoinData { JoinNumber = 6, From c3d07fe4fdeda01792f19e045638c2f00d7defab Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Fri, 23 Sep 2022 08:28:32 -0600 Subject: [PATCH 10/11] fix(essentials): Adds EndAllCalls to CancelJoinAttempt action --- .../VideoCodec/ZoomRoom/ZoomRoom.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs index 5aeb3be0..d491fa59 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/ZoomRoom/ZoomRoom.cs @@ -2520,7 +2520,10 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom }; - trilist.SetSigFalseAction(joinMap.CancelJoinAttempt.JoinNumber, () => trilist.SetBool(joinMap.MeetingPasswordRequired.JoinNumber, false)); + trilist.SetSigFalseAction(joinMap.CancelJoinAttempt.JoinNumber, () => { + trilist.SetBool(joinMap.MeetingPasswordRequired.JoinNumber, false); + EndAllCalls(); + }); PasswordRequired += (devices, args) => { From 05ec0ebac35a6c23a6f92ebfeefb0bc19b12edee Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Fri, 23 Sep 2022 12:27:55 -0600 Subject: [PATCH 11/11] fix(essentials): Adds ability to dial up to 10 calls from SIMPL bridge --- .../JoinMaps/VideoCodecControllerJoinMap.cs | 36 ++------------- .../VideoCodec/VideoCodecBase.cs | 46 +++++++------------ 2 files changed, 20 insertions(+), 62 deletions(-) diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Bridges/JoinMaps/VideoCodecControllerJoinMap.cs b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Bridges/JoinMaps/VideoCodecControllerJoinMap.cs index d1b383b0..7fc0626a 100644 --- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Bridges/JoinMaps/VideoCodecControllerJoinMap.cs +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Bridges/JoinMaps/VideoCodecControllerJoinMap.cs @@ -776,44 +776,16 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps JoinType = eJoinType.Digital }); - [JoinName("DialMeeting1")] - public JoinDataComplete DialMeeting1 = new JoinDataComplete( + [JoinName("DialMeetingStart")] + public JoinDataComplete DialMeetingStart = new JoinDataComplete( new JoinData { JoinNumber = 161, - JoinSpan = 1 + JoinSpan = 10 }, new JoinMetadata { - Description = "Join first meeting", - JoinCapabilities = eJoinCapabilities.FromSIMPL, - JoinType = eJoinType.Digital - }); - - [JoinName("DialMeeting2")] - public JoinDataComplete DialMeeting2 = new JoinDataComplete( - new JoinData - { - JoinNumber = 162, - JoinSpan = 1 - }, - new JoinMetadata - { - Description = "Join second meeting", - JoinCapabilities = eJoinCapabilities.FromSIMPL, - JoinType = eJoinType.Digital - }); - - [JoinName("DialMeeting3")] - public JoinDataComplete DialMeeting3 = new JoinDataComplete( - new JoinData - { - JoinNumber = 163, - JoinSpan = 1 - }, - new JoinMetadata - { - Description = "Join third meeting", + Description = "Join meeting", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital }); diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/VideoCodecBase.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/VideoCodecBase.cs index 1270b690..0626044d 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/VideoCodecBase.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/VideoCodecBase.cs @@ -804,35 +804,22 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec codec.CodecSchedule.MeetingWarningMinutes = i; }); - trilist.SetSigFalseAction(joinMap.DialMeeting1.JoinNumber, () => - { - var mtg = 1; - var index = mtg - 1; - Debug.Console(1, this, "Meeting {0} Selected (EISC dig-o{1}) > _currentMeetings[{2}].Id: {3}, Title: {4}", - mtg, joinMap.DialMeeting1.JoinNumber, index, _currentMeetings[index].Id, _currentMeetings[index].Title); - if (_currentMeetings[index] != null) - Dial(_currentMeetings[index]); - }); - - trilist.SetSigFalseAction(joinMap.DialMeeting2.JoinNumber, () => - { - var mtg = 2; - var index = mtg - 1; - Debug.Console(1, this, "Meeting {0} Selected (EISC dig-o{1}) > _currentMeetings[{2}].Id: {3}, Title: {4}", - mtg, joinMap.DialMeeting2.JoinNumber, index, _currentMeetings[index].Id, _currentMeetings[index].Title); - if (_currentMeetings[index] != null) - Dial(_currentMeetings[index]); - }); - - trilist.SetSigFalseAction(joinMap.DialMeeting3.JoinNumber, () => - { - var mtg = 3; - var index = mtg - 1; - Debug.Console(1, this, "Meeting {0} Selected (EISC dig-o{1}) > _currentMeetings[{2}].Id: {3}, Title: {4}", - mtg, joinMap.DialMeeting3.JoinNumber, index, _currentMeetings[index].Id, _currentMeetings[index].Title); - if (_currentMeetings[index] != null) - Dial(_currentMeetings[index]); - }); + + for (uint i = 0; i < joinMap.DialMeetingStart.JoinSpan; i++) + { + Debug.Console(1, this, "Setting action to Dial Meeting {0} to digital join {1}", i + 1, joinMap.DialMeetingStart.JoinNumber + i); + var joinNumber = joinMap.DialMeetingStart.JoinNumber + i; + var mtg = i + 1; + var index = (int)i; + + trilist.SetSigFalseAction(joinNumber, () => + { + Debug.Console(1, this, "Meeting {0} Selected (EISC dig-o{1}) > _currentMeetings[{2}].Id: {3}, Title: {4}", + mtg, joinMap.DialMeetingStart.JoinNumber + i, index, _currentMeetings[index].Id, _currentMeetings[index].Title); + if (_currentMeetings[index] != null) + Dial(_currentMeetings[index]); + }); + } codec.CodecSchedule.MeetingsListHasChanged += (sender, args) => UpdateMeetingsList(codec, trilist, joinMap); codec.CodecSchedule.MeetingEventChange += (sender, args) => @@ -843,7 +830,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec } }; - // TODO [ ] hotfix/videocodecbase-max-meeting-xsig-set trilist.SetUShortSigAction(joinMap.MeetingsToDisplay.JoinNumber, m => MeetingsToDisplay = m); MeetingsToDisplayFeedback.LinkInputSig(trilist.UShortInput[joinMap.MeetingsToDisplay.JoinNumber]);