Compare commits

...

41 Commits

Author SHA1 Message Date
Neil Dorin
2677d63553 Merge pull request #1049 from PepperDash/hotfix/zoom-phonebook-issues
Fix Empty Zoom Phonebook
2022-12-22 13:52:45 -07:00
Andrew Welker
d03581fea8 fix: change contact message handling
On some occasions when the Zoom Room restarted
and Essentials did not, the directory could be
requested while the Zoom Room had no contacts
yet, as it hadn't received them from Zoom Cloud.
This caused the directory to be empty, even
though there may be valid contacts. Now,
Essentials uses the Added Contact and Updated Contact
methods to fire the directory changed event, allowing
for directory updates to be propogated as necessary.
2022-12-22 08:54:24 -07:00
Andrew Welker
decc8ed3a5 refactor: update queue error handling
On some occasions, a ThreadAbortException was being
caught on shutdown and causing exceptions to be printed
needlessly. Messaging has also been updated to remove
personal pronouns.
2022-12-22 08:52:58 -07:00
Andrew Welker
b0637288e9 refactor: move logic for updating directory to method 2022-12-21 12:21:01 -07:00
Andrew Welker
52d945fca3 Merge pull request #1044 from PepperDash/hotfix/ssh-issues
Update PD Core version to fix SSH issues
2022-12-12 12:11:55 -07:00
Andrew Welker
0ef8fcfd27 chore: Update to PD Core 1.1.4 2022-12-12 11:42:16 -07:00
Andrew Welker
042416b470 chore: update PD Core version 2022-12-12 10:01:14 -07:00
jdevito
3d27b0928f Merge pull request #1042 from PepperDash/hotfix/zoomroom-camera-selection
Send command to select camera by ID for Zoom Room
2022-12-09 09:39:33 -06:00
Andrew Welker
860182dbfc Merge branch 'main' into hotfix/zoomroom-camera-selection 2022-12-09 08:12:45 -07:00
Andrew Welker
668cbc430c Merge pull request #1038 from PepperDash/hotfix/occ-sensor-fixes
Prevent vacancy from shutting down the room when a call is active
2022-11-28 16:19:26 -07:00
Andrew Welker
e54de1f1cb Merge branch 'main' into hotfix/occ-sensor-fixes 2022-11-28 15:19:45 -07:00
Neil Dorin
f48b1a2de3 Merge pull request #1039 from PepperDash/hotfix/touchpanelBase
Fix issues with TouchpanelBase
2022-11-23 16:24:28 -07:00
Andrew Welker
8e57e7ec31 fix: add missing LoadSmartObjects call 2022-11-23 14:29:36 -07:00
Andrew Welker
1b43b44d19 fix: typo in TouchpanelBase constructor
The constructor was checking the wrong
variable, leading to it always being null
and failing to build the `EssentialsTouchpanelController`
class.
2022-11-23 13:15:41 -07:00
Andrew Welker
4306128474 refactor: fix abstract method 2022-11-21 10:45:25 -07:00
Andrew Welker
5263b16bb7 refactor: fix issues with log statments 2022-11-21 10:42:33 -07:00
Andrew Welker
a2b67798f3 refactor: add logging statements 2022-11-21 10:37:26 -07:00
Andrew Welker
1b43fba37e fix: add logic to prevent vacancy from triggering room off if room is in
a call
2022-11-21 10:28:08 -07:00
Andrew Welker
f262c1a3bb Merge pull request #1036 from PepperDash/hotfix/PD-core-update-for-vc4
Updates for VC-4
2022-11-16 11:05:40 -07:00
Andrew Welker
93ee695c57 Merge branch 'main' into hotfix/PD-core-update-for-vc4 2022-11-16 10:52:15 -07:00
Andrew Welker
ba0bae3c4e chore: update PD Core to 1.1.3 2022-11-16 10:51:48 -07:00
Trevor Payne
37a98d00af Merge pull request #1037 from PepperDash/hotfix/VideoCodec-ActiveCall-XSig
Fix error with updating call status XSigs
2022-11-14 10:25:28 -06:00
Trevor Payne
247827ac25 fix: UpdateCallStatusXsig() now properly refreshing calls 2022-11-14 10:10:22 -06:00
Andrew Welker
5e797db096 fix: add check for missing/empty roomId 2022-11-11 16:26:37 -07:00
Andrew Welker
57eeeec0fb Merge branch 'main' into hotfix/PD-core-update-for-vc4 2022-11-11 16:23:12 -07:00
Andrew Welker
db19da124c fix: set debug level to 2 on startup
Some plugins and devices are doing their own filtering based on the
debug level that's normally set using the `appdebug` console command.
On VC-4, there's no way to set that value. With this change, when
Essentials starts on a server, the debug level will be set to 2, so that
any of the messages that might be filtered based on the debug level
won't be filtered.
2022-11-11 14:37:46 -07:00
Andrew Welker
c07f52b06f feat: update VC-4 client to use correct RoomID 2022-11-10 12:51:04 -07:00
Neil Dorin
b6675477be Merge pull request #1029 from PepperDash/hotfix/zoom-passcode-and-incoming-call-prompt-states-on-cancel
Update Zoom polling/sending blocks for more scenarios
2022-11-09 09:27:07 -07:00
Andrew Welker
fc3840173e chore: Update PD Core version 2022-11-08 08:44:39 -07:00
Andrew Welker
ce51a62d97 chore: update PD Core version 2022-11-04 14:01:11 -06:00
Andrew Welker
2be42f88bc chore: update PD Core version
In order to fix issues with debug file location for VC-4, the PD Core version needs to be updated
2022-11-04 09:48:17 -06:00
jdevito
6f9a9ee255 fix: moved setting set in event before null check 2022-10-28 16:47:43 -05:00
jdevito
a09212417c fix: removed property sets as recommended in discussion; removed 'if' statements before property sets in leave and end call methods 2022-10-28 16:20:49 -05:00
jdevito
4d6da37c60 fix: added additional evaluations for prompt property tracking and set/reset to handled unknown user scenarios 2022-10-28 08:38:16 -05:00
Andrew Welker
95627df1a6 Merge pull request #1026 from PepperDash/hotfix/zoomroom-block-commands-on-incoming-call
fix(essentials): Block all commands to ZoomRoom on incoming call
2022-10-25 13:40:32 -06:00
Neil Dorin
bef07fe41b fix(essentials): Block all commands to ZoomRoom on incoming call 2022-10-25 10:30:02 -06:00
Andrew Welker
83d2497264 Merge pull request #1021 from PepperDash/hotfix/848-camera-preset-bridge-issue
fix: max number of presets now uses join span rather than join start.
2022-10-20 11:17:39 -06:00
Andrew Welker
50f5145a89 Merge branch 'main' into hotfix/848-camera-preset-bridge-issue 2022-10-20 10:58:10 -06:00
Neil Dorin
a734a869c1 Merge pull request #1023 from PepperDash/hotfix/zoomrooms-passcode-required-prohibits-polling
fix: added bool property tracking if meeting is require, added poll m…
2022-10-20 10:30:14 -06:00
Jason Alborough
70d2633eb0 fix: max number of presets now uses join span rather than join start. 2022-10-20 09:52:58 -04:00
Neil Dorin
330bb2d002 fix(essentials): #1017 -Send command to select camera by ID 2022-10-13 11:13:17 -06:00
10 changed files with 233 additions and 98 deletions

View File

@@ -195,6 +195,8 @@ namespace PepperDash.Essentials
}
else // Handles Linux OS (Virtual Control)
{
Debug.SetDebugLevel(2);
Debug.Console(0, Debug.ErrorLogLevel.Notice, "Starting Essentials v{0} on Virtual Control Server", Global.AssemblyVersion);
// Set path to User/

View File

@@ -745,6 +745,28 @@ namespace PepperDash.Essentials
{
//Implement this
}
protected override bool AllowVacancyTimerToStart()
{
bool allowVideo = true;
bool allowAudio = true;
if (VideoCodec != null)
{
Debug.Console(2,this, Debug.ErrorLogLevel.Notice, "Room {0} {1} in a video call", Key, VideoCodec.IsInCall ? "is" : "is not");
allowVideo = !VideoCodec.IsInCall;
}
if (AudioCodec != null)
{
Debug.Console(2,this, Debug.ErrorLogLevel.Notice, "Room {0} {1} in an audio call", Key, AudioCodec.IsInCall ? "is" : "is not");
allowAudio = !AudioCodec.IsInCall;
}
Debug.Console(2, this, "Room {0} allowing vacancy timer to start: {1}", Key, allowVideo && allowAudio);
return allowVideo && allowAudio;
}
/// <summary>
/// Does what it says

View File

@@ -394,35 +394,51 @@ namespace PepperDash.Essentials.Core.Bridges
var controlProperties = CommFactory.GetControlPropertiesConfig(dc);
BasicTriList eisc;
switch (dc.Type.ToLower())
{
case "eiscapiadv":
case "eiscapiadvanced":
{
var eisc = new ThreeSeriesTcpIpEthernetIntersystemCommunications(controlProperties.IpIdInt,
eisc = new ThreeSeriesTcpIpEthernetIntersystemCommunications(controlProperties.IpIdInt,
controlProperties.TcpSshProperties.Address, Global.ControlSystem);
return new EiscApiAdvanced(dc, eisc);
break;
}
case "eiscapiadvancedserver":
{
var eisc = new EISCServer(controlProperties.IpIdInt, Global.ControlSystem);
return new EiscApiAdvanced(dc, eisc);
eisc = new EISCServer(controlProperties.IpIdInt, Global.ControlSystem);
break;
}
case "eiscapiadvancedclient":
{
var eisc = new EISCClient(controlProperties.IpIdInt, controlProperties.TcpSshProperties.Address, Global.ControlSystem);
return new EiscApiAdvanced(dc, eisc);
eisc = new EISCClient(controlProperties.IpIdInt, controlProperties.TcpSshProperties.Address, Global.ControlSystem);
break;
}
case "vceiscapiadv":
case "vceiscapiadvanced":
{
var eisc = new VirtualControlEISCClient(controlProperties.IpIdInt, InitialParametersClass.RoomId,
if (string.IsNullOrEmpty(controlProperties.RoomId))
{
Debug.Console(0, Debug.ErrorLogLevel.Error, "Unable to build VC-4 EISC Client for device {0}. Room ID is missing or empty", dc.Key);
eisc = null;
break;
}
eisc = new VirtualControlEISCClient(controlProperties.IpIdInt, controlProperties.RoomId,
Global.ControlSystem);
return new EiscApiAdvanced(dc, eisc);
break;
}
default:
return null;
eisc = null;
break;
}
if (eisc == null)
{
return null;
}
return new EiscApiAdvanced(dc, eisc);
}
}

View File

@@ -1,5 +1,6 @@
using System;
using Crestron.SimplSharp;
using Crestron.SimplSharp.Reflection;
using Crestron.SimplSharpPro.CrestronThread;
using PepperDash.Core;
@@ -187,9 +188,20 @@ namespace PepperDash.Essentials.Core.Queues
if (_delayEnabled)
Thread.Sleep(_delayTime);
}
catch (System.Threading.ThreadAbortException)
{
//swallowing this exception, as it should only happen on shut down
}
catch (Exception ex)
{
Debug.Console(0, this, Debug.ErrorLogLevel.Error, "Caught an exception in the Queue {0}\r{1}\r{2}", ex.Message, ex.InnerException, ex.StackTrace);
Debug.Console(0, this, Debug.ErrorLogLevel.Error, "Caught an exception in the Queue: {1}:{0}", ex.Message, ex);
Debug.Console(2, this, Debug.ErrorLogLevel.Error, "Stack Trace: {0}", ex.StackTrace);
if (ex.InnerException != null)
{
Debug.Console(0, this, Debug.ErrorLogLevel.Error, "---\r\n{0}", ex.InnerException.Message);
Debug.Console(2, this, Debug.ErrorLogLevel.Error, "Stack Trace: {0}", ex.InnerException.StackTrace);
}
}
}
else _waitHandle.Wait();
@@ -202,7 +214,7 @@ namespace PepperDash.Essentials.Core.Queues
{
if (Disposed)
{
Debug.Console(1, this, "I've been disposed so you can't enqueue any messages. Are you trying to dispatch a message while the program is stopping?");
Debug.Console(1, this, "Queue has been disposed. Enqueuing messages not allowed while program is stopping.");
return;
}
@@ -446,7 +458,14 @@ namespace PepperDash_Essentials_Core.Queues
}
catch (Exception ex)
{
Debug.Console(0, this, Debug.ErrorLogLevel.Error, "Caught an exception in the Queue {0}\r{1}\r{2}", ex.Message, ex.InnerException, ex.StackTrace);
Debug.Console(0, this, Debug.ErrorLogLevel.Error, "Caught an exception in the Queue {0}", ex.Message);
Debug.Console(2, this, Debug.ErrorLogLevel.Error, "Stack Trace: {0}", ex.StackTrace);
if (ex.InnerException != null)
{
Debug.Console(0, this, Debug.ErrorLogLevel.Error, "Caught an exception in the Queue {0}", ex.InnerException.Message);
Debug.Console(2, this, Debug.ErrorLogLevel.Error, "Stack Trace: {0}", ex.InnerException.StackTrace);
}
}
}
else _waitHandle.Wait();

View File

@@ -343,7 +343,7 @@ namespace PepperDash.Essentials.Core
void RoomIsOccupiedFeedback_OutputChange(object sender, EventArgs e)
{
if (RoomOccupancy.RoomIsOccupiedFeedback.BoolValue == false)
if (RoomOccupancy.RoomIsOccupiedFeedback.BoolValue == false && AllowVacancyTimerToStart())
{
Debug.Console(1, this, Debug.ErrorLogLevel.Notice, "Notice: Vacancy Detected");
// Trigger the timer when the room is vacant
@@ -362,6 +362,15 @@ namespace PepperDash.Essentials.Core
/// </summary>
/// <param name="o"></param>
public abstract void RoomVacatedForTimeoutPeriod(object o);
/// <summary>
/// Allow the vacancy event from an occupancy sensor to turn the room off.
/// </summary>
/// <returns>If the timer should be allowed. Defaults to true</returns>
protected virtual bool AllowVacancyTimerToStart()
{
return true;
}
}
/// <summary>

View File

@@ -31,7 +31,7 @@ namespace PepperDash.Essentials.Core.UI
:base(key, name)
{
if (Panel == null)
if (panel == null)
{
Debug.Console(0, this, "Panel is not valid. Touchpanel class WILL NOT work correctly");
return;
@@ -71,6 +71,8 @@ namespace PepperDash.Essentials.Core.UI
return;
}
}
Panel.LoadSmartObjects(sgdName);
});
AddPostActivationAction(() =>

View File

@@ -223,7 +223,7 @@ namespace PepperDash.Essentials.Devices.Common.Cameras
SendCameraPresetNamesToApi(presetsCamera, joinMap, trilist);
for (int i = 0; i < joinMap.NumberOfPresets.JoinNumber; i++)
for (int i = 0; i < joinMap.NumberOfPresets.JoinSpan; i++)
{
int tempNum = i;

View File

@@ -1393,11 +1393,11 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
tokenArray[digitalIndex + 1] = new XSigDigitalToken(digitalIndex + 2, call.IsOnHold);
//serials
tokenArray[arrayIndex] = new XSigSerialToken(stringIndex + 1, call.Name ?? String.Empty);
tokenArray[arrayIndex + 1] = new XSigSerialToken(stringIndex + 2, call.Number ?? String.Empty);
tokenArray[arrayIndex + 2] = new XSigSerialToken(stringIndex + 3, call.Direction.ToString());
tokenArray[arrayIndex + 3] = new XSigSerialToken(stringIndex + 4, call.Type.ToString());
tokenArray[arrayIndex + 4] = new XSigSerialToken(stringIndex + 5, call.Status.ToString());
tokenArray[stringIndex] = new XSigSerialToken(stringIndex + 1, call.Name ?? String.Empty);
tokenArray[stringIndex + 1] = new XSigSerialToken(stringIndex + 2, call.Number ?? String.Empty);
tokenArray[stringIndex + 2] = new XSigSerialToken(stringIndex + 3, call.Direction.ToString());
tokenArray[stringIndex + 3] = new XSigSerialToken(stringIndex + 4, call.Type.ToString());
tokenArray[stringIndex + 4] = new XSigSerialToken(stringIndex + 5, call.Status.ToString());
if(call.Duration != null)
{
// May need to verify correct string format here
@@ -1417,12 +1417,12 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
//serials
tokenArray[arrayIndex] = new XSigSerialToken(stringIndex + 1, String.Empty);
tokenArray[arrayIndex + 1] = new XSigSerialToken(stringIndex + 2, String.Empty);
tokenArray[arrayIndex + 2] = new XSigSerialToken(stringIndex + 3, String.Empty);
tokenArray[arrayIndex + 3] = new XSigSerialToken(stringIndex + 4, String.Empty);
tokenArray[arrayIndex + 4] = new XSigSerialToken(stringIndex + 5, String.Empty);
tokenArray[arrayIndex + 5] = new XSigSerialToken(stringIndex + 6, String.Empty);
tokenArray[stringIndex] = new XSigSerialToken(stringIndex + 1, String.Empty);
tokenArray[stringIndex + 1] = new XSigSerialToken(stringIndex + 2, String.Empty);
tokenArray[stringIndex + 2] = new XSigSerialToken(stringIndex + 3, String.Empty);
tokenArray[stringIndex + 3] = new XSigSerialToken(stringIndex + 4, String.Empty);
tokenArray[stringIndex + 4] = new XSigSerialToken(stringIndex + 5, String.Empty);
tokenArray[stringIndex + 5] = new XSigSerialToken(stringIndex + 6, String.Empty);
arrayIndex += offset;
stringIndex += maxStrings;

View File

@@ -59,14 +59,18 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
private CameraBase _selectedCamera;
private string _lastDialedMeetingNumber;
private CTimer contactsDebounceTimer;
private readonly ZoomRoomPropertiesConfig _props;
private bool _meetingPasswordRequired;
private bool _waitingForUserToAcceptOrRejectIncomingCall;
public void Poll(string pollString)
{
if(_meetingPasswordRequired) return;
if(_meetingPasswordRequired || _waitingForUserToAcceptOrRejectIncomingCall) return;
SendText(string.Format("{0}{1}", pollString, SendDelimiter));
}
@@ -374,26 +378,12 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
public void SelectCamera(string key)
{
if (Cameras == null)
{
return;
}
if (CameraIsMutedFeedback.BoolValue)
{
CameraMuteOff();
}
var camera = Cameras.FirstOrDefault(c => c.Key.IndexOf(key, StringComparison.OrdinalIgnoreCase) > -1);
if (camera != null)
{
Debug.Console(1, this, "Selected Camera with key: '{0}'", camera.Key);
SelectedCamera = camera;
if (CameraIsMutedFeedback.BoolValue)
{
CameraMuteOff();
}
}
else
{
Debug.Console(1, this, "Unable to select camera with key: '{0}'", key);
}
SendText(string.Format("zConfiguration Video Camera selectedId: {0}", key));
}
public CameraBase FarEndCamera { get; private set; }
@@ -656,8 +646,27 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
{
if (a.PropertyName == "SelectedId")
{
SelectCamera(Configuration.Video.Camera.SelectedId);
// this will in turn fire the affected feedbacks
if (Cameras == null)
{
return;
}
var camera = Cameras.FirstOrDefault(c => c.Key.IndexOf(Configuration.Video.Camera.SelectedId, StringComparison.OrdinalIgnoreCase) > -1);
if (camera != null)
{
Debug.Console(1, this, "Camera selected with key: '{0}'", camera.Key);
SelectedCamera = camera;
if (CameraIsMutedFeedback.BoolValue)
{
CameraMuteOff();
}
}
else
{
Debug.Console(1, this, "No camera found with key: '{0}'", Configuration.Video.Camera.SelectedId);
}
}
};
@@ -968,6 +977,18 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
public void SendText(string command)
{
if (_meetingPasswordRequired)
{
Debug.Console(2, this, "Blocking commands to ZoomRoom while waiting for user to enter meeting password");
return;
}
if (_waitingForUserToAcceptOrRejectIncomingCall)
{
Debug.Console(2, this, "Blocking commands to ZoomRoom while waiting for user to accept or reject incoming call");
return;
}
if (CommDebuggingIsOn)
{
Debug.Console(1, this, "Sending: '{0}'", command);
@@ -1363,22 +1384,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
JsonConvert.PopulateObject(responseObj.ToString(), Status.Phonebook);
var directoryResults =
zStatus.Phonebook.ConvertZoomContactsToGeneric(Status.Phonebook.Contacts);
if (!PhonebookSyncState.InitialSyncComplete)
{
PhonebookSyncState.InitialPhonebookFoldersReceived();
PhonebookSyncState.PhonebookRootEntriesReceived();
PhonebookSyncState.SetPhonebookHasFolders(true);
PhonebookSyncState.SetNumberOfContacts(Status.Phonebook.Contacts.Count);
}
directoryResults.ResultsFolderId = "root";
DirectoryRoot = directoryResults;
CurrentDirectoryResult = directoryResults;
UpdateDirectory();
break;
}
@@ -1507,36 +1513,37 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
{
case "phonebook":
{
zStatus.Contact contact = new zStatus.Contact();
if (responseObj["Updated Contact"] != null)
{
var updatedContact =
JsonConvert.DeserializeObject<zStatus.Contact>(
responseObj["Updated Contact"].ToString());
var existingContact =
Status.Phonebook.Contacts.FirstOrDefault(c => c.Jid.Equals(updatedContact.Jid));
if (existingContact != null)
{
// Update existing contact
JsonConvert.PopulateObject(responseObj["Updated Contact"].ToString(),
existingContact);
}
{
contact = responseObj["Updated Contact"].ToObject<zStatus.Contact>();
}
else if (responseObj["Added Contact"] != null)
{
var jToken = responseObj["Updated Contact"];
if (jToken != null)
{
var newContact =
JsonConvert.DeserializeObject<zStatus.Contact>(
jToken.ToString());
// Add a new contact
Status.Phonebook.Contacts.Add(newContact);
}
contact = responseObj["Added Contact"].ToObject<zStatus.Contact>();
}
var existingContactIndex = Status.Phonebook.Contacts.FindIndex(c => c.Jid.Equals(contact.Jid));
if (existingContactIndex > 0)
{
Status.Phonebook.Contacts[existingContactIndex] = contact;
}
else
{
Status.Phonebook.Contacts.Add(contact);
}
if(contactsDebounceTimer == null)
{
contactsDebounceTimer = new CTimer(o => UpdateDirectory(), 2000);
}
else
{
contactsDebounceTimer.Reset();
}
break;
}
case "bookingslistresult":
@@ -1592,6 +1599,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
Id = incomingCall.callerJID
};
_waitingForUserToAcceptOrRejectIncomingCall = true;
ActiveCalls.Add(newCall);
OnCallStatusChange(newCall);
@@ -1618,6 +1627,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
OnCallStatusChange(existingCall);
}
_waitingForUserToAcceptOrRejectIncomingCall = false;
UpdateCallStatus();
}
@@ -2000,7 +2011,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
/// </summary>
private void GetBookings()
{
if (_meetingPasswordRequired) return;
if (_meetingPasswordRequired || _waitingForUserToAcceptOrRejectIncomingCall) return;
SendText("zCommand Bookings List");
}
@@ -2229,6 +2240,42 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
}
}
private void UpdateDirectory()
{
Debug.Console(2, this, "Updating directory");
var directoryResults = zStatus.Phonebook.ConvertZoomContactsToGeneric(Status.Phonebook.Contacts);
if (!PhonebookSyncState.InitialSyncComplete)
{
PhonebookSyncState.InitialPhonebookFoldersReceived();
PhonebookSyncState.PhonebookRootEntriesReceived();
PhonebookSyncState.SetPhonebookHasFolders(true);
PhonebookSyncState.SetNumberOfContacts(Status.Phonebook.Contacts.Count);
}
directoryResults.ResultsFolderId = "root";
DirectoryRoot = directoryResults;
CurrentDirectoryResult = directoryResults;
//
if (contactsDebounceTimer != null)
{
ClearContactDebounceTimer();
}
}
private void ClearContactDebounceTimer()
{
Debug.Console(2, this, "Clearing Timer");
if (!contactsDebounceTimer.Disposed && contactsDebounceTimer != null)
{
contactsDebounceTimer.Dispose();
contactsDebounceTimer = null;
}
}
/// <summary>
/// Will return true if the host is myself (this zoom room)
/// </summary>
@@ -2560,7 +2607,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
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);
Debug.Console(2, this, "***********************************PaswordRequired. Message: {0} Cancelled: {1} Last Incorrect: {2} Failed: {3}", args.Message, args.LoginAttemptCancelled, args.LastAttemptWasIncorrect, args.LoginAttemptFailed);
if (args.LoginAttemptCancelled)
{
@@ -2637,6 +2684,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
public void AcceptCall()
{
_waitingForUserToAcceptOrRejectIncomingCall = false;
var incomingCall =
ActiveCalls.FirstOrDefault(
c => c.Status.Equals(eCodecCallStatus.Ringing) && c.Direction.Equals(eCodecCallDirection.Incoming));
@@ -2646,6 +2695,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
public override void AcceptCall(CodecActiveCallItem call)
{
_waitingForUserToAcceptOrRejectIncomingCall = false;
SendText(string.Format("zCommand Call Accept callerJID: {0}", call.Id));
call.Status = eCodecCallStatus.Connected;
@@ -2657,6 +2708,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
public void RejectCall()
{
_waitingForUserToAcceptOrRejectIncomingCall = false;
var incomingCall =
ActiveCalls.FirstOrDefault(
c => c.Status.Equals(eCodecCallStatus.Ringing) && c.Direction.Equals(eCodecCallDirection.Incoming));
@@ -2666,6 +2719,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
public override void RejectCall(CodecActiveCallItem call)
{
_waitingForUserToAcceptOrRejectIncomingCall = false;
SendText(string.Format("zCommand Call Reject callerJID: {0}", call.Id));
call.Status = eCodecCallStatus.Disconnected;
@@ -2792,16 +2847,25 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
public void LeaveMeeting()
{
SendText("zCommand Call Leave");
_meetingPasswordRequired = false;
_waitingForUserToAcceptOrRejectIncomingCall = false;
SendText("zCommand Call Leave");
}
public override void EndCall(CodecActiveCallItem call)
{
_meetingPasswordRequired = false;
_waitingForUserToAcceptOrRejectIncomingCall = false;
SendText("zCommand Call Disconnect");
}
public override void EndAllCalls()
{
_meetingPasswordRequired = false;
_waitingForUserToAcceptOrRejectIncomingCall = false;
SendText("zCommand Call Disconnect");
}
@@ -3451,20 +3515,21 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
public void SubmitPassword(string password)
{
_meetingPasswordRequired = false;
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)
{
_meetingPasswordRequired = !loginFailed || !loginCancelled;
var handler = PasswordRequired;
if (handler != null)
{
if(!loginFailed || !loginCancelled)
_meetingPasswordRequired = true;
handler(this, new PasswordPromptEventArgs(lastAttemptIncorrect, loginFailed, loginCancelled, message));
{
Debug.Console(2, this, "Meeting Password Required: {0}", _meetingPasswordRequired);
handler(this, new PasswordPromptEventArgs(lastAttemptIncorrect, loginFailed, loginCancelled, message));
}
}

View File

@@ -1,3 +1,3 @@
<packages>
<package id="PepperDashCore" version="1.1.1" targetFramework="net35" allowedVersions="[1.0,2.0)"/>
<package id="PepperDashCore" version="1.1.4" targetFramework="net35" allowedVersions="[1.0,2.0)"/>
</packages>