Compare commits

...

27 Commits

Author SHA1 Message Date
Andrew Welker
061109c901 add method to create a rmc for DMPS chassis 2020-10-21 10:05:19 -06:00
Andrew Welker
f95b50c99d Merge pull request #445 from PepperDash/feature/I18N-Support
Add interfaces for I18N support
2020-10-20 09:56:27 -06:00
Andrew Welker
def5cc273c Merge branch 'development' into feature/I18N-Support 2020-10-19 17:04:39 -06:00
Andrew Welker
e01d2c9569 Merge pull request #450 from PepperDash/bugfix/fix-docker-image
Update docker.yml
2020-10-19 17:04:11 -06:00
Andrew Welker
415dbbb195 Update docker.yml 2020-10-16 08:16:47 -06:00
Andrew Welker
765d90214d Merge branch 'feature/I18N-Support' of https://github.com/PepperDash/Essentials into feature/I18N-Support 2020-10-15 17:00:01 -06:00
Andrew Welker
36fd1dcda9 file name change 2020-10-15 16:59:39 -06:00
Andrew Welker
812b9b731b Merge branch 'development' into feature/I18N-Support 2020-10-15 16:59:20 -06:00
Andrew Welker
e80a68485d Merge pull request #449 from PepperDash/bugfix/zoom-room-incomingcall
Fix for Incoming Call issues
2020-10-15 16:58:37 -06:00
Andrew Welker
535f4ccb8e Merge branch 'development' into bugfix/zoom-room-incomingcall 2020-10-15 16:39:51 -06:00
Andrew Welker
7bbdf43452 add full implementation for LanguageLabel 2020-10-15 16:37:41 -06:00
Andrew Welker
59881d6b3b fix for unanticipated messages from Zoom 2020-10-15 16:14:27 -06:00
Andrew Welker
085e198409 fix for incoming call stuff 2020-10-15 13:34:47 -06:00
Neil Dorin
81f27fcbde Merge branch 'development' into feature/I18N-Support 2020-10-15 12:41:49 -06:00
Neil Dorin
50dae0ef69 Merge pull request #447 from PepperDash/bugfix/card-cage-iteration-fix
Bugfix/card cage iteration fix
2020-10-15 12:41:35 -06:00
Alex Johnson
e0fdefa28e Fix to allow card cage creation loop to continue even if a previous card encountered an issue 2020-10-15 12:36:14 -04:00
Andrew Welker
f6a826505c Merge branch 'development' into feature/I18N-Support 2020-10-13 23:39:12 -06:00
Andrew Welker
68ac506a25 Merge pull request #444 from PepperDash/feature/add-encoding-overload
Add SetString Overload to allow for setting encoding on a sig
2020-10-13 18:11:45 -05:00
Andrew Welker
1150d9e497 add IKeyed to ILanguageLabel to easily get the key 2020-10-13 15:18:31 -06:00
Andrew Welker
633a946f26 Merge branch 'development' into feature/add-encoding-overload 2020-10-13 16:15:04 -05:00
Andrew Welker
8e01455140 Merge pull request #442 from PepperDash/feature/zoom-room-feature-add
Zoom Room Updates & Adds
2020-10-13 16:14:49 -05:00
Andrew Welker
b373ab8708 #443 Add SetString Overload 2020-10-13 14:06:48 -06:00
Andrew Welker
cb752850ff correct interfaces 2020-10-13 13:30:29 -06:00
Andrew Welker
08c929699f #440 Updates for csproj file 2020-10-13 10:29:30 -06:00
Andrew Welker
1862090a89 #440 add interfaces 2020-10-13 09:53:18 -06:00
Alex Johnson
1ea80c3fab Adds phone call ringing status to zoom phone status enum 2020-10-12 12:58:22 -04:00
Andrew Welker
1676f5a956 add phone call logic and commands to Zoom Room 2020-10-08 17:09:59 -06:00
13 changed files with 329 additions and 17 deletions

View File

@@ -60,7 +60,7 @@ jobs:
- name: Build Solution
shell: powershell
run: |
Invoke-Expression "docker run --rm --mount type=bind,source=""$($Env:GITHUB_WORKSPACE)"",target=""c:/project"" pepperdash/sspbuilder:v1.4.1 c:\cihelpers\vsidebuild.exe -Solution ""c:\project\$($Env:SOLUTION_FILE).sln"" -BuildSolutionConfiguration $($ENV:BUILD_TYPE)"
Invoke-Expression "docker run --rm --mount type=bind,source=""$($Env:GITHUB_WORKSPACE)"",target=""c:/project"" pepperdash/sspbuilder c:\cihelpers\vsidebuild.exe -Solution ""c:\project\$($Env:SOLUTION_FILE).sln"" -BuildSolutionConfiguration $($ENV:BUILD_TYPE)"
# Zip up the output files as needed
- name: Zip Build Output
shell: powershell

View File

@@ -760,6 +760,46 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
JoinType = eJoinType.Digital
});
[JoinName("DialPhoneCall")]
public JoinDataComplete DialPhone =
new JoinDataComplete(new JoinData { JoinNumber = 72, JoinSpan = 1 },
new JoinMetadata
{
Description = "Dial Phone",
JoinCapabilities = eJoinCapabilities.FromSIMPL,
JoinType = eJoinType.Digital
});
[JoinName("PhoneHookState")]
public JoinDataComplete PhoneHookState =
new JoinDataComplete(new JoinData { JoinNumber = 72, JoinSpan = 1 },
new JoinMetadata
{
Description = "Dial Phone",
JoinCapabilities = eJoinCapabilities.ToSIMPL,
JoinType = eJoinType.Digital
});
[JoinName("EndPhoneCall")]
public JoinDataComplete HangUpPhone =
new JoinDataComplete(new JoinData { JoinNumber = 73, JoinSpan = 1 },
new JoinMetadata
{
Description = "Hang Up PHone",
JoinCapabilities = eJoinCapabilities.FromSIMPL,
JoinType = eJoinType.Digital
});
[JoinName("PhoneString")]
public JoinDataComplete PhoneDialString =
new JoinDataComplete(new JoinData { JoinNumber = 2, JoinSpan = 1 },
new JoinMetadata
{
Description = "Phone Dial String",
JoinCapabilities = eJoinCapabilities.FromSIMPL,
JoinType = eJoinType.Serial
});
public VideoCodecControllerJoinMap(uint joinStart) : base(joinStart, typeof (VideoCodecControllerJoinMap))
{
}

View File

@@ -73,21 +73,21 @@ namespace PepperDash.Essentials.Core.CrestronIO.Cards
string cardType;
if (!_config.Cards.TryGetValue(i, out cardType))
{
Debug.Console(1, this, "No card found for slot {0}", i);
Debug.Console(0, this, "No card found for slot {0}", i);
continue;
}
if (String.IsNullOrEmpty(cardType))
{
Debug.Console(0, this, "No card specified for slot {0}", i);
return;
continue;
}
Func<uint, C3CardControllerBase> cardBuilder;
if (!_cardDict.TryGetValue(cardType.ToLower(), out cardBuilder))
{
Debug.Console(0, "Unable to find factory for 3-Series card type {0}.", cardType);
return;
continue;
}
try

View File

@@ -0,0 +1,14 @@
using PepperDash.Essentials.Core;
namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
{
public interface IHasPhoneDialing
{
BoolFeedback PhoneOffHookFeedback { get; }
StringFeedback CallerIdNameFeedback { get; }
StringFeedback CallerIdNumberFeedback { get; }
void DialPhoneCall(string number);
void EndPhoneCall();
void SendDtmfToPhone(string digit);
}
}

View File

@@ -0,0 +1,15 @@
using System;
using System.Collections.Generic;
namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
{
public interface ILanguageDefinition
{
string LocaleName { get; set; }
string FriendlyName { get; set; }
bool Enable { get; set; }
List<LanguageLabel> UiLabels { get; set; }
List<LanguageLabel> Sources { get; set; }
List<LanguageLabel> Destinations { get; set; }
}
}

View File

@@ -0,0 +1,13 @@
using System;
using System.Collections.Generic;
namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
{
public interface ILanguageProvider
{
ILanguageDefinition CurrentLanguage { get; set; }
event EventHandler CurrentLanguageChanged;
}
}

View File

@@ -0,0 +1,12 @@
using PepperDash.Core;
namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
{
public class LanguageLabel
{
public string Key { get; set; }
public string Description { get; set; }
public string DisplayText { get; set; }
public uint JoinNumber { get; set; }
}
}

View File

@@ -195,8 +195,12 @@
<Compile Include="Devices\PC\Laptop.cs" />
<Compile Include="Devices\ReconfigurableDevice.cs" />
<Compile Include="Devices\VolumeDeviceChangeEventArgs.cs" />
<Compile Include="DeviceTypeInterfaces\LanguageLabel.cs" />
<Compile Include="DeviceTypeInterfaces\ILanguageProvider.cs" />
<Compile Include="DeviceTypeInterfaces\IHasBranding.cs" />
<Compile Include="DeviceTypeInterfaces\ILanguageDefinition.cs" />
<Compile Include="DeviceTypeInterfaces\IHasFarEndContentStatus.cs" />
<Compile Include="DeviceTypeInterfaces\IHasPhoneDialing.cs" />
<Compile Include="DeviceTypeInterfaces\IMobileControl.cs" />
<Compile Include="Factory\DeviceFactory.cs" />
<Compile Include="Factory\IDeviceFactory.cs" />

View File

@@ -251,6 +251,12 @@ namespace PepperDash.Essentials.Core
tl.StringInput[sigNum].StringValue = value;
}
public static void SetString(this BasicTriList tl, uint sigNum, string value, eStringEncoding encoding)
{
tl.StringInput[sigNum].StringEncoding = encoding;
tl.StringInput[sigNum].StringValue = value;
}
/// <summary>
/// Returns bool value of trilist sig
/// </summary>

View File

@@ -221,6 +221,10 @@ namespace PepperDash.Essentials.DM
DmRmcPropertiesConfig props, string pKey, uint ipid)
{
var parentDev = DeviceManager.GetDeviceForKey(pKey);
if (parentDev is DmpsRoutingController)
{
return GetDmRmcControllerForDmps(key, name, typeName, parentDev as DmpsRoutingController, props.ParentOutputNumber);
}
if (!(parentDev is IDmSwitch))
{
Debug.Console(0, "Cannot create DM device '{0}'. '{1}' is not a DM Chassis.",
@@ -285,6 +289,26 @@ namespace PepperDash.Essentials.DM
return null;
}
private static CrestronGenericBaseDevice GetDmRmcControllerForDmps(string key, string name, string typeName,
DmpsRoutingController controller, uint num)
{
Func<string, string, DMOutput, CrestronGenericBaseDevice> dmpsHandler;
if (ChassisCpu3Dict.TryGetValue(typeName.ToLower(), out dmpsHandler))
{
var output = controller.Dmps.SwitcherOutputs[num] as DMOutput;
if (output != null)
{
return dmpsHandler(key, name, output);
}
Debug.Console(0, Debug.ErrorLogLevel.Error, "Cannot attach DM-RMC of type '{0}' to output {1} on DMPS chassis. Output is not a DM Output", typeName, num);
return null;
}
Debug.Console(0, Debug.ErrorLogLevel.Error, "Cannot create DM-RMC of type '{0}' to output {1} on DMPS chassis", typeName, num);
return null;
}
private static CrestronGenericBaseDevice GetDmRmcControllerForProcessor(string key, string name, string typeName, uint ipid)
{
try
@@ -305,6 +329,8 @@ namespace PepperDash.Essentials.DM
return null;
}
}
}
public class DmRmcControllerFactory : EssentialsDeviceFactory<DmRmcControllerBase>

View File

@@ -19,6 +19,7 @@ using PepperDash.Essentials.Devices.Common.Cameras;
using PepperDash.Essentials.Devices.Common.Codec;
using PepperDash.Essentials.Devices.Common.VideoCodec.Interfaces;
using PepperDash_Essentials_Core.Bridges.JoinMaps;
using PepperDash_Essentials_Core.DeviceTypeInterfaces;
using Feedback = PepperDash.Essentials.Core.Feedback;
namespace PepperDash.Essentials.Devices.Common.VideoCodec
@@ -348,6 +349,11 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
(codec as IHasFarEndContentStatus).ReceivingContent.LinkInputSig(trilist.BooleanInput[joinMap.RecievingContent.JoinNumber]);
}
if (codec is IHasPhoneDialing)
{
LinkVideoCodecPhoneToApi(codec as IHasPhoneDialing, trilist, joinMap);
}
trilist.OnlineStatusChange += (device, args) =>
{
if (!args.DeviceOnLine) return;
@@ -389,6 +395,11 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
(codec as IHasCameraOff).CameraIsOffFeedback.FireUpdate();
}
if (codec is IHasPhoneDialing)
{
(codec as IHasPhoneDialing).PhoneOffHookFeedback.FireUpdate();
}
SharingContentIsOnFeedback.FireUpdate();
trilist.SetBool(joinMap.HookState.JoinNumber, IsInCall);
@@ -397,6 +408,16 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
};
}
private void LinkVideoCodecPhoneToApi(IHasPhoneDialing codec, BasicTriList trilist, VideoCodecControllerJoinMap joinMap)
{
codec.PhoneOffHookFeedback.LinkInputSig(trilist.BooleanInput[joinMap.PhoneHookState.JoinNumber]);
trilist.SetSigFalseAction(joinMap.DialPhone.JoinNumber,
() => codec.DialPhoneCall(trilist.StringOutput[joinMap.PhoneDialString.JoinNumber].StringValue));
trilist.SetSigFalseAction(joinMap.HangUpPhone.JoinNumber, codec.EndPhoneCall);
}
private void LinkVideoCodecSelfviewPositionToApi(IHasSelfviewPosition codec, BasicTriList trilist, VideoCodecControllerJoinMap joinMap)
{
trilist.SetSigFalseAction(joinMap.SelfviewPosition.JoinNumber, codec.SelfviewPipPositionToggle);
@@ -791,8 +812,10 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
CallStatusChange += (sender, args) =>
{
trilist.SetBool(joinMap.HookState.JoinNumber, IsInCall);
trilist.SetBool(joinMap.IncomingCall.JoinNumber, args.CallItem.Direction == eCodecCallDirection.Incoming);
Debug.Console(1, this, "Call Direction: {0}", args.CallItem.Direction);
Debug.Console(1, this, "Call is incoming: {0}", args.CallItem.Direction == eCodecCallDirection.Incoming);
trilist.SetBool(joinMap.IncomingCall.JoinNumber, args.CallItem.Direction == eCodecCallDirection.Incoming && args.CallItem.Status != eCodecCallStatus.Disconnected);
if (args.CallItem.Direction == eCodecCallDirection.Incoming)
{

View File

@@ -58,6 +58,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
public List<zStatus.AudioVideoInputOutputLineItem> AudioInputs { get; set; }
public List<zStatus.AudioVideoInputOutputLineItem> AudioOuputs { get; set; }
public List<zStatus.AudioVideoInputOutputLineItem> Cameras { get; set; }
public zEvent.PhoneCallStatus PhoneCall { get; set; }
public ZoomRoomStatus()
{
@@ -74,6 +75,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
AudioInputs = new List<zStatus.AudioVideoInputOutputLineItem>();
AudioOuputs = new List<zStatus.AudioVideoInputOutputLineItem>();
Cameras = new List<zStatus.AudioVideoInputOutputLineItem>();
PhoneCall = new zEvent.PhoneCallStatus();
}
}
@@ -700,6 +702,86 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
[JsonProperty("why_cannot_pin_share")]
public string WhyCannotPinShare { get; set; }
}
public class PhoneCallStatus:NotifiableObject
{
private bool _isIncomingCall;
private string _peerDisplayName;
private string _peerNumber;
private bool _offHook;
public string CallId { get; set; }
public bool IsIncomingCall {
get { return _isIncomingCall; }
set
{
if(value == _isIncomingCall) return;
_isIncomingCall = value;
NotifyPropertyChanged("IsIncomingCall");
} }
public string PeerDisplayName
{
get { return _peerDisplayName; }
set
{
if (value == _peerDisplayName) return;
_peerDisplayName = value;
NotifyPropertyChanged("PeerDisplayName");
}
}
public string PeerNumber
{
get { return _peerNumber; }
set
{
if (value == _peerNumber) return;
_peerNumber = value;
NotifyPropertyChanged("PeerNumber");
}
}
public string PeerUri { get; set; }
private ePhoneCallStatus _status;
public ePhoneCallStatus Status
{
get { return _status; }
set
{
_status = value;
OffHook = _status == ePhoneCallStatus.PhoneCallStatus_Accepted ||
_status == ePhoneCallStatus.PhoneCallStatus_InCall ||
_status == ePhoneCallStatus.PhoneCallStatus_Init ||
_status == ePhoneCallStatus.PhoneCallStatus_Ringing;
}
}
public bool OffHook
{
get { return _offHook; }
set
{
if (value == _offHook) return;
_offHook = value;
NotifyPropertyChanged("OffHook");
}
}
}
public enum ePhoneCallStatus
{
PhoneCallStatus_Ringing,
PhoneCallStatus_Terminated,
PhoneCallStatus_Accepted,
PhoneCallStatus_InCall,
PhoneCallStatus_Init,
}
}
/// <summary>

View File

@@ -17,12 +17,14 @@ using PepperDash.Essentials.Devices.Common.Cameras;
using PepperDash.Essentials.Devices.Common.Codec;
using PepperDash.Essentials.Devices.Common.VideoCodec.Cisco;
using PepperDash.Essentials.Devices.Common.VideoCodec.Interfaces;
using PepperDash_Essentials_Core.DeviceTypeInterfaces;
namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
{
public class ZoomRoom : VideoCodecBase, IHasCodecSelfView, IHasDirectoryHistoryStack, ICommunicationMonitor,
IRouting,
IHasScheduleAwareness, IHasCodecCameras, IHasParticipants, IHasCameraOff, IHasCameraAutoMode, IHasFarEndContentStatus, IHasSelfviewPosition
IHasScheduleAwareness, IHasCodecCameras, IHasParticipants, IHasCameraOff, IHasCameraAutoMode,
IHasFarEndContentStatus, IHasSelfviewPosition, IHasPhoneDialing
{
private const long MeetingRefreshTimer = 60000;
private const uint DefaultMeetingDurationMin = 30;
@@ -114,6 +116,10 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
SupportsCameraOff = _props.SupportsCameraOff;
SupportsCameraAutoMode = _props.SupportsCameraAutoMode;
PhoneOffHookFeedback = new BoolFeedback(PhoneOffHookFeedbackFunc);
CallerIdNameFeedback = new StringFeedback(CallerIdNameFeedbackFunc);
CallerIdNumberFeedback = new StringFeedback(CallerIdNumberFeedbackFunc);
}
public CommunicationGather PortGather { get; private set; }
@@ -195,7 +201,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
protected Func<bool> CameraAutoModeIsOnFeedbackFunc
{
get { return () => false; }
}
}
protected Func<string> SelfviewPipPositionFeedbackFunc
{
@@ -506,6 +512,28 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
break;
}
};
Status.PhoneCall.PropertyChanged += (o, a) =>
{
switch (a.PropertyName)
{
case "IsIncomingCall":
Debug.Console(1, this, "Incoming Phone Call: {0}", Status.PhoneCall.IsIncomingCall);
break;
case "PeerDisplayName":
Debug.Console(1, this, "Peer Display Name: {0}", Status.PhoneCall.PeerDisplayName);
CallerIdNameFeedback.FireUpdate();
break;
case "PeerNumber":
Debug.Console(1, this, "Peer Number: {0}", Status.PhoneCall.PeerNumber);
CallerIdNumberFeedback.FireUpdate();
break;
case "OffHook":
Debug.Console(1, this, "Phone is OffHook: {0}", Status.PhoneCall.OffHook);
PhoneOffHookFeedback.FireUpdate();
break;
}
};
}
private void SetUpDirectory()
@@ -555,8 +583,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
if (!_props.DisablePhonebookAutoDownload)
{
CrestronConsole.AddNewConsoleCommand(s => SendText("zCommand Phonebook List Offset: 0 Limit: 512"),
"GetZoomRoomContacts", "Triggers a refresh of the codec phonebook",
ConsoleAccessLevelEnum.AccessOperator);
"GetZoomRoomContacts", "Triggers a refresh of the codec phonebook",
ConsoleAccessLevelEnum.AccessOperator);
}
CrestronConsole.AddNewConsoleCommand(s => GetBookings(), "GetZoomRoomBookings",
@@ -1066,7 +1094,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
case "sharingstate":
{
JsonConvert.PopulateObject(responseObj.ToString(), Status.Call.Sharing);
SetLayout();
break;
@@ -1181,6 +1209,11 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
break;
}
case "phonecallstatus":
{
JsonConvert.PopulateObject(responseObj.ToString(), Status.PhoneCall);
break;
}
default:
{
break;
@@ -1294,8 +1327,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
private void SetLayout()
{
if(!_props.AutoDefaultLayouts) return;
if (!_props.AutoDefaultLayouts) return;
if (
(Status.Call.Sharing.State == zEvent.eSharingState.Receiving ||
Status.Call.Sharing.State == zEvent.eSharingState.Sending))
@@ -1354,7 +1387,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
if (ActiveCalls.Count == 0)
{
if (callStatus == zStatus.eCallStatus.CONNECTING_MEETING || callStatus == zStatus.eCallStatus.IN_MEETING )
if (callStatus == zStatus.eCallStatus.CONNECTING_MEETING ||
callStatus == zStatus.eCallStatus.IN_MEETING)
{
var newStatus = eCodecCallStatus.Unknown;
@@ -1431,6 +1465,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
SetLayout();
}
}
public override void StartSharing()
{
SendText("zCommand Call Sharing HDMI Start");
@@ -1570,6 +1605,12 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
public override void AcceptCall(CodecActiveCallItem call)
{
SendText(string.Format("zCommand Call Accept callerJID: {0}", call.Id));
call.Status = eCodecCallStatus.Connected;
OnCallStatusChange(call);
UpdateCallStatus();
}
public void RejectCall()
@@ -1584,6 +1625,12 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
public override void RejectCall(CodecActiveCallItem call)
{
SendText(string.Format("zCommand Call Reject callerJID: {0}", call.Id));
call.Status = eCodecCallStatus.Disconnected;
OnCallStatusChange(call);
UpdateCallStatus();
}
public override void Dial(Meeting meeting)
@@ -1633,7 +1680,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
public override void SendDtmf(string s)
{
throw new NotImplementedException();
SendDtmfToPhone(s);
}
/// <summary>
@@ -1713,6 +1760,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
#endregion
#region Implementation of IHasCameraAutoMode
//Zoom doesn't support camera auto modes. Setting this to just unmute video
public void CameraAutoModeOn()
{
@@ -1757,7 +1805,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
{
var nextPipPositionIndex = SelfviewPipPositions.IndexOf(_currentSelfviewPipPosition) + 1;
if (nextPipPositionIndex >= SelfviewPipPositions.Count) // Check if we need to loop back to the first item in the list
if (nextPipPositionIndex >= SelfviewPipPositions.Count)
// Check if we need to loop back to the first item in the list
nextPipPositionIndex = 0;
SelfviewPipPositionSet(SelfviewPipPositions[nextPipPositionIndex]);
@@ -1772,12 +1821,40 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
new CodecCommandWithLabel("DownLeft", "Lower Left")
};
void ComputeSelfviewPipStatus()
private void ComputeSelfviewPipStatus()
{
_currentSelfviewPipPosition =
SelfviewPipPositions.FirstOrDefault(
p => p.Command.ToLower().Equals(Configuration.Call.Layout.Position.ToString().ToLower()));
}
#endregion
#region Implementation of IHasPhoneDialing
private Func<bool> PhoneOffHookFeedbackFunc {get {return () => Status.PhoneCall.OffHook; }}
private Func<string> CallerIdNameFeedbackFunc { get { return () => Status.PhoneCall.PeerDisplayName; } }
private Func<string> CallerIdNumberFeedbackFunc { get { return () => Status.PhoneCall.PeerNumber; } }
public BoolFeedback PhoneOffHookFeedback { get; private set; }
public StringFeedback CallerIdNameFeedback { get; private set; }
public StringFeedback CallerIdNumberFeedback { get; private set; }
public void DialPhoneCall(string number)
{
SendText(String.Format("zCommand Dial PhoneCallOut Number: {0}", number));
}
public void EndPhoneCall()
{
SendText(String.Format("zCommand Dial PhoneHangUp CallId: {0}", Status.PhoneCall.CallId));
}
public void SendDtmfToPhone(string digit)
{
SendText(String.Format("zCommand SendSipDTMF CallId: {0} Key: {1}", Status.PhoneCall.CallId, digit));
}
#endregion
}