Compare commits

..

4 Commits
1.0.1 ... 1.0.2

Author SHA1 Message Date
Neil Dorin
8a9a8ac6a7 Updated AssemblyVersion to 1.0.2.* 2017-10-31 12:01:24 -06:00
Neil Dorin
b1742675c2 Prep for merge into development for NYU deployment 2017-10-31 11:57:01 -06:00
Neil Dorin
f564a2f554 Updated PhoneNumber property name to SipPhoneNumber 2017-10-30 11:57:13 -06:00
Neil Dorin
0ede2e9973 General code cleanup and updates to Huddle UI drivers to comply with Vtc1 changes 2017-10-30 11:50:22 -06:00
20 changed files with 1427 additions and 1023 deletions

View File

@@ -0,0 +1,43 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
using Crestron.SimplSharpPro;
namespace PepperDash.Essentials.Core.Crestron_IO
{
/// <summary>
/// Represents a generic digital input deviced tied to a versiport
/// </summary>
public class GenericVersiportInputDevice
{
//Versiport InputPort {get; private set;}
//BoolFeedback InputStateFeedback {get; private set;}
//Func<bool> InputStateFeedbackFunc
//{
// get
// {
// return () => InputPort.DigitalIn;
// }
//}
//public GenericVersiportInputDevice(Versiport inputPort)
//{
// InputStateFeedback = new BoolFeedback(InputStateFeedbackFunc);
// InputPort = inputPort;
// InputPort.VersiportChange += new VersiportEventHandler(InputPort_VersiportChange);
//}
//void InputPort_VersiportChange(Versiport port, VersiportEventArgs args)
//{
// InputStateFeedback.FireUpdate();
//}
}
}

View File

@@ -0,0 +1,13 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
namespace PepperDash.Essentials.Core.Crestron_IO
{
public interface IDigitalInput
{
}
}

View File

@@ -0,0 +1,43 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
using Crestron.SimplSharpPro;
namespace PepperDash.Essentials.Core.Crestron_IO
{
/// <summary>
/// Represents a generic device controlled by relays
/// </summary>
public class GenericRelayDevice
{
//Relay RelayOutput { get; private set; }
//public boolfeedback relaystatefeedback { get; private set; }
//func<bool> relaystatefeedbackfunc
//{
// get
// {
// return () => relayoutput.state;
// }
//}
//public genericrelaydevice(relay relay)
//{
// relaystatefeedback = new boolfeedback(relaystatefeedbackfunc);
// if(relay.availableforuse)
// relayoutput = relay;
// relayoutput.statechange += new relayeventhandler(relayoutput_statechange);
//}
//void relayoutput_statechange(relay relay, relayeventargs args)
//{
// relaystatefeedback.fireupdate();
//}
}
}

View File

@@ -24,7 +24,7 @@
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\</OutputPath>
<OutputPath>..\..\Release Package\</OutputPath>
<DefineConstants>DEBUG;TRACE;</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
@@ -71,9 +71,9 @@
<HintPath>..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SSPDevices\Crestron.SimplSharpPro.UI.dll</HintPath>
</Reference>
<Reference Include="mscorlib" />
<Reference Include="PepperDash_Core, Version=1.0.0.16459, Culture=neutral, processorArchitecture=MSIL">
<Reference Include="PepperDash_Core, Version=1.0.1.26313, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\pepperdash-simplsharp-core\Pepperdash Core\CLZ Builds\PepperDash_Core.dll</HintPath>
<HintPath>..\..\..\PepperDash.Core\Pepperdash Core\Pepperdash Core\bin\PepperDash_Core.dll</HintPath>
</Reference>
<Reference Include="SimplSharpCustomAttributesInterface, Version=1.0.0.0, Culture=neutral, PublicKeyToken=1099c178b3b54c3b, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
@@ -103,6 +103,9 @@
<Reference Include="System.Data" />
</ItemGroup>
<ItemGroup>
<Compile Include="Crestron IO\Inputs\GenericVersiportInputDevice.cs" />
<Compile Include="Crestron IO\Inputs\IDigitalInput.cs" />
<Compile Include="Crestron IO\Relay\GenericRelayDevice.cs" />
<Compile Include="Devices\CodecInterfaces.cs" />
<Compile Include="Global\JobTimer.cs" />
<Compile Include="Ramps and Increments\ActionIncrementer.cs" />

View File

@@ -21,7 +21,9 @@ namespace PepperDash.Essentials.Devices.Common.Codec
{
public abstract bool MultiSiteOptionIsEnabled { get; }
public abstract string IpAddress { get; }
public abstract string PhoneNumber { get; }
public abstract string SipPhoneNumber { get; }
public abstract string E164Alias { get; }
public abstract string H323Id { get; }
public abstract string SipUri { get; }
public abstract bool AutoAnswerEnabled { get; }
}

View File

@@ -1285,7 +1285,27 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
return string.Empty;
}
}
public override string PhoneNumber
public override string E164Alias
{
get
{
if (CodecConfiguration.Configuration.H323.H323Alias.E164 != null)
return CodecConfiguration.Configuration.H323.H323Alias.E164.Value;
else
return string.Empty;
}
}
public override string H323Id
{
get
{
if (CodecConfiguration.Configuration.H323.H323Alias.ID != null)
return CodecConfiguration.Configuration.H323.H323Alias.E164.Value;
else
return string.Empty;
}
}
public override string SipPhoneNumber
{
get
{

View File

@@ -5,7 +5,10 @@ using System.Text;
using Crestron.SimplSharp;
using PepperDash.Core;
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
@@ -212,9 +215,16 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
public Mode7 Mode { get; set; }
}
public class Framerate
{
public string valueSpaceRef { get; set; }
public string Value { get; set; }
}
public class Camera
{
public string id { get; set; }
public Framerate Framerate { get; set; }
public Backlight Backlight { get; set; }
public Brightness Brightness { get; set; }
public Focus Focus { get; set; }
@@ -243,9 +253,68 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
public class Cameras
{
//[JsonConverter(typeof(CameraConverter))]
//public List<Camera> Camera { get; set; }
//[JsonConverter(typeof(CameraConverter)), JsonProperty("Camera")]
//public List<Camera> Camera { get; set; }
//[JsonProperty("SpeakerTrack")]
public SpeakerTrack SpeakerTrack { get; set; }
public Cameras()
{
//Camera = new List<Camera>();
SpeakerTrack = new SpeakerTrack();
}
}
public class CameraConverter : JsonConverter
{
// this is currently not working
public override bool CanConvert(System.Type objectType)
{
return objectType == typeof(Camera) || objectType == typeof(List<Camera>); // This should not be called but is required for implmentation
}
public override object ReadJson(JsonReader reader, System.Type objectType, object existingValue, JsonSerializer serializer)
{
try
{
if (reader.TokenType == JsonToken.StartArray)
{
var l = new List<Camera>();
reader.Read();
while (reader.TokenType != JsonToken.EndArray)
{
l.Add(reader.Value as Camera);
reader.Read();
}
Debug.Console(1, "[xConfiguration]: Cameras converted as list");
return l;
}
else
{
Debug.Console(1, "[xConfiguration]: Camera converted as single object and added to list");
return new List<Camera> { reader.Value as Camera };
}
}
catch (Exception e)
{
Debug.Console(1, "[xConfiguration]: Unable to convert JSON for camera objects: {0}", e);
return new List<Camera>();
}
}
public override bool CanWrite
{
get
{
return false;
}
}
public override void WriteJson(JsonWriter writer, object value, JsonSerializer serializer)
{
throw new NotImplementedException("Write not implemented");
}
}
public class Delay

View File

@@ -315,17 +315,70 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
public class Cameras
{
//[JsonConverter(typeof(CameraConverter))]
//public List<Camera> Camera { get; set; }
// [JsonConverter(typeof(CameraConverter))]
public List<Camera> Camera { get; set; }
public SpeakerTrack SpeakerTrack { get; set; }
public Cameras()
{
//Camera = new List<Camera>();
Camera = new List<Camera>();
SpeakerTrack = new SpeakerTrack();
}
}
//public class CameraConverter : JsonConverter
//{
// public override bool CanConvert(System.Type objectType)
// {
// return true; // objectType == typeof(Camera) || objectType == typeof(List<Camera>); // This should not be called but is required for implmentation
// }
// public override object ReadJson(JsonReader reader, System.Type objectType, object existingValue, JsonSerializer serializer)
// {
// try
// {
// if (reader.TokenType == JsonToken.StartArray)
// {
// var l = new List<Camera>();
// reader.Read();
// while (reader.TokenType != JsonToken.EndArray)
// {
// l.Add(reader.Value as Camera);
// reader.Read();
// }
// Debug.Console(1, "[xStatus]: Cameras converted as list");
// return l;
// }
// else
// {
// Debug.Console(1, "[xStatus]: Camera converted as single object and added to list");
// return new List<Camera> { reader.Value as Camera };
// }
// }
// catch (Exception e)
// {
// Debug.Console(1, "[xStatus]: Unable to convert JSON for camera objects: {0}", e);
// return new List<Camera>();
// }
// }
// public override bool CanWrite
// {
// get
// {
// return false;
// }
// }
// public override void WriteJson(JsonWriter writer, object value, JsonSerializer serializer)
// {
// throw new NotImplementedException("Write not implemented");
// }
//}
public class MaxActiveCalls
{
public string Value { get; set; }

View File

@@ -402,12 +402,22 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
get { return true; }
}
public override string IpAddress
public override string E164Alias
{
get { return "xx.xx.xx.xx"; }
get { return "someE164alias"; }
}
public override string PhoneNumber
public override string H323Id
{
get { return "someH323Id"; }
}
public override string IpAddress
{
get { return "xxx.xxx.xxx.xxx"; }
}
public override string SipPhoneNumber
{
get { return "333-444-5555"; }
}

View File

@@ -43,8 +43,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
public RoutingPortCollection<RoutingOutputPort> OutputPorts { get; private set; }
bool wasIsInCall;
/// <summary>
/// Returns true when any call is not in state Unknown, Disconnecting, Disconnected
/// </summary>

View File

@@ -79,9 +79,9 @@
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\pepperdash-portal-sync\SspPortalSync\SspPortalSync\bin\PepperDashCorePortalSync.dll</HintPath>
</Reference>
<Reference Include="PepperDash_Core, Version=1.0.0.18868, Culture=neutral, processorArchitecture=MSIL">
<Reference Include="PepperDash_Core, Version=1.0.1.26313, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\pepperdash-simplsharp-core\Pepperdash Core\CLZ Builds\PepperDash_Core.dll</HintPath>
<HintPath>..\..\..\PepperDash.Core\Pepperdash Core\Pepperdash Core\bin\PepperDash_Core.dll</HintPath>
</Reference>
<Reference Include="PepperDash_Essentials_Core, Version=1.0.0.18243, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
@@ -169,7 +169,7 @@
<Compile Include="FOR REFERENCE UI\Panels\SmartGraphicsTouchpanelControllerBase.cs" />
<Compile Include="UIDrivers\SigInterlock.cs" />
<Compile Include="UIDrivers\EssentialsHuddleVTC\EssentialsHuddlePresentationUiDriver.cs" />
<Compile Include="UIDrivers\EssentialsHuddleVTC\EssentialsHuddleTechPageDriver.cs" />
<Compile Include="UIDrivers\EssentialsHuddle\EssentialsHuddleTechPageDriver.cs" />
<Compile Include="UI\HttpLogoServer.cs" />
<Compile Include="UI\SmartObjectHeaderButtonList.cs" />
<Compile Include="UI\SubpageReferenceListCallStagingItem.cs" />
@@ -185,7 +185,7 @@
<Compile Include="UIDrivers\Page Drivers\SingleSubpageModalDriver.cs" />
<Compile Include="UIDrivers\Essentials\EssentialsPanelMainInterfaceDriver.cs" />
<Compile Include="UIDrivers\enums and base.cs" />
<Compile Include="UIDrivers\Essentials\EssentialsHuddlePanelAvFunctionsDriver.cs" />
<Compile Include="UIDrivers\EssentialsHuddle\EssentialsHuddlePanelAvFunctionsDriver.cs" />
<Compile Include="UIDrivers\Page Drivers\SingleSubpageModalAndBackDriver.cs" />
<Compile Include="UIDrivers\SmartObjectRoomsList.cs" />
<Compile Include="UI\JoinConstants\UIBoolJoin.cs" />

View File

@@ -4,5 +4,5 @@
[assembly: AssemblyCompany("PepperDash Technology Corp")]
[assembly: AssemblyProduct("PepperDashEssentials")]
[assembly: AssemblyCopyright("Copyright © PepperDash Technology Corp 2017")]
[assembly: AssemblyVersion("1.0.1.*")]
[assembly: AssemblyVersion("1.0.2.*")]

View File

@@ -24,8 +24,8 @@ namespace PepperDash.Essentials
var disp = DefaultDisplay as DisplayBase;
var val = CurrentSourceInfo != null
&& CurrentSourceInfo.Type == eSourceListItemType.Route
&& disp != null
&& disp.PowerIsOnFeedback.BoolValue;
&& disp != null;
//&& disp.PowerIsOnFeedback.BoolValue;
return val;
};
}

View File

@@ -118,10 +118,6 @@ namespace PepperDash.Essentials
/// </summary>
public const uint RoomPhoneText = 3904;
/// <summary>
/// 3905 - SIP address for room header
/// </summary>
public const uint RoomSipText = 3905;
/// <summary>
/// 3906 - The separator for verbose-header text on addresses
/// </summary>
public const uint RoomAddressPipeText = 3906;

View File

@@ -37,10 +37,6 @@ namespace PepperDash.Essentials.UIDrivers
/// <summary>
///
/// </summary>
IAVDriver Parent;
/// <summary>
///
/// </summary>
JoinedSigInterlock PagesInterlock;
/// <summary>
@@ -63,10 +59,9 @@ namespace PepperDash.Essentials.UIDrivers
/// </summary>
/// <param name="trilist"></param>
/// <param name="parent"></param>
public EssentialsHuddleTechPageDriver(BasicTriListWithSmartObject trilist, IAVDriver parent, EssentialsRoomTechConfig config)
public EssentialsHuddleTechPageDriver(BasicTriListWithSmartObject trilist, EssentialsRoomTechConfig config)
: base(trilist)
{
Parent = parent;
Config = config;
PagesInterlock = new JoinedSigInterlock(trilist);

View File

@@ -164,7 +164,7 @@ namespace PepperDash.Essentials
get
{
if (_TechDriver == null)
_TechDriver = new PepperDash.Essentials.UIDrivers.EssentialsHuddleTechPageDriver(TriList, this, CurrentRoom.Config.Tech);
_TechDriver = new PepperDash.Essentials.UIDrivers.EssentialsHuddleTechPageDriver(TriList, CurrentRoom.Config.Tech);
return _TechDriver;
}
}
@@ -1244,15 +1244,10 @@ namespace PepperDash.Essentials
if (CurrentRoom.IsWarmingUpFeedback.BoolValue)
{
ShowNotificationRibbon("Room is powering on. Please wait...", 0);
//WarmingCoolingModal = new ModalDialog(TriList);
//WarmingCoolingModal.PresentModalDialog(0, "Powering Up", "Power", "<p>Room is powering up</p><p>Please wait</p>",
// "", "", false, false, null);
}
else
{
ShowNotificationRibbon("Room is powered on. Welcome.", 2000);
//if (WarmingCoolingModal != null)
// WarmingCoolingModal.CancelDialog();
}
}
@@ -1266,16 +1261,10 @@ namespace PepperDash.Essentials
if (CurrentRoom.IsCoolingDownFeedback.BoolValue)
{
ShowNotificationRibbon("Room is powering off. Please wait.", 0);
//WarmingCoolingModal = new ModalDialog(TriList);
//WarmingCoolingModal.PresentModalDialog(0, "Power Off", "Power", "<p>Room is powering off</p><p>Please wait</p>",
// "", "", false, false, null);
}
else
{
HideNotificationRibbon();
//if (WarmingCoolingModal != null)
// WarmingCoolingModal.CancelDialog();
}
}
@@ -1460,13 +1449,13 @@ namespace PepperDash.Essentials
void ComputeHeaderCallStatus(VideoCodecBase codec);
bool HeaderButtonsAreSetUp { get; }
SubpageReferenceList MeetingOrContactMethodModalSrl { get; }
/// <summary>
/// Exposes the ability to switch into call mode
/// </summary>
void ActivityCallButtonPressed();
/// <summary>
/// Allows the codec to trigger the main UI to clear up if call is coming in.
/// </summary>
void PrepareForCodecIncomingCall();
/// <summary>
/// Exposes the ability to switch into call mode
/// </summary>
void ActivityCallButtonPressed();
/// <summary>
/// Allows the codec to trigger the main UI to clear up if call is coming in.
/// </summary>
void PrepareForCodecIncomingCall();
}
}

View File

@@ -175,7 +175,6 @@ namespace PepperDash.Essentials.UIDrivers.VC
triList.SetSigFalseAction(UIBoolJoin.VCDirectorySearchTextPress, RevealKeyboard);
//TriList.SetSigFalseAction(UIBoolJoin.VCDirectoryBackspacePress, SearchKeypadBackspacePress);
triList.SetSigHeldAction(UIBoolJoin.VCDirectoryBackspacePress, 500,
StartSearchBackspaceRepeat, StopSearchBackspaceRepeat, SearchKeypadBackspacePress);
@@ -194,8 +193,13 @@ namespace PepperDash.Essentials.UIDrivers.VC
/// <param name="e"></param>
void Codec_IsReady()
{
TriList.SetString(UIStringJoin.RoomPhoneText, GetFormattedPhoneNumber(Codec.CodecInfo.PhoneNumber));
TriList.SetString(UIStringJoin.RoomSipText, Codec.CodecInfo.SipUri);
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);
else // If only one value present, just show the phone number
roomNumberSipUri = Codec.CodecInfo.SipPhoneNumber;
TriList.SetString(UIStringJoin.RoomPhoneText, roomNumberSipUri);
if(Parent.HeaderButtonsAreSetUp)
Parent.ComputeHeaderCallStatus(Codec);