mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-02-04 07:14:58 +00:00
Added mobileinfo command to help with mobile control debugging
This commit is contained in:
@@ -4,5 +4,5 @@
|
||||
[assembly: AssemblyCompany("PepperDash Technology Corp")]
|
||||
[assembly: AssemblyProduct("PepperDashEssentials")]
|
||||
[assembly: AssemblyCopyright("Copyright © PepperDash Technology Corp 2017")]
|
||||
[assembly: AssemblyVersion("1.0.46.*")]
|
||||
[assembly: AssemblyVersion("1.0.47.*")]
|
||||
|
||||
|
||||
@@ -74,12 +74,12 @@ namespace PepperDash.Essentials
|
||||
Config = config;
|
||||
Debug.Console(0, this, "Mobile UI controller initializing for server:{0}", config.ServerUrl);
|
||||
|
||||
CrestronConsole.AddNewConsoleCommand(DisconnectStreamClient,
|
||||
"CloseHttpClient", "Closes the active HTTP client", ConsoleAccessLevelEnum.AccessOperator);
|
||||
//CrestronConsole.AddNewConsoleCommand(DisconnectStreamClient,
|
||||
// "CloseHttpClient", "Closes the active HTTP client", ConsoleAccessLevelEnum.AccessOperator);
|
||||
CrestronConsole.AddNewConsoleCommand(AuthorizeSystem,
|
||||
"cotijaauth", "Authorizes system to talk to cotija server", ConsoleAccessLevelEnum.AccessOperator);
|
||||
|
||||
//AddPostActivationAction(() => RegisterSystemToServer());
|
||||
"mobileauth", "Authorizes system to talk to cotija server", ConsoleAccessLevelEnum.AccessOperator);
|
||||
CrestronConsole.AddNewConsoleCommand(s => ShowInfo(),
|
||||
"mobileinfo", "Shows information for current mobile control session", ConsoleAccessLevelEnum.AccessOperator);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -192,6 +192,20 @@ namespace PepperDash.Essentials
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Dumps info in response to console command.
|
||||
/// </summary>
|
||||
void ShowInfo()
|
||||
{
|
||||
CrestronConsole.ConsoleCommandResponse(@"Mobile Control Information:
|
||||
Server address: {0}
|
||||
System Name: {1}
|
||||
System UUID: {2}
|
||||
System User code: {3}
|
||||
Connected?: {4}", Config.ServerUrl, RoomBridges[0].RoomName, SystemUuid,
|
||||
RoomBridges[0].UserCode, WSClient.Connected ? "Yes" : "No");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Registers the room with the server
|
||||
/// </summary>
|
||||
@@ -224,7 +238,7 @@ namespace PepperDash.Essentials
|
||||
else
|
||||
{
|
||||
var regClient = new HttpClient();
|
||||
regClient.Verbose = true;
|
||||
regClient.Verbose = false;
|
||||
regClient.KeepAlive = true;
|
||||
|
||||
string url = string.Format("http://{0}/api/system/join/{1}", Config.ServerUrl, SystemUuid);
|
||||
|
||||
@@ -18,6 +18,8 @@ namespace PepperDash.Essentials
|
||||
|
||||
public string UserCode { get; private set; }
|
||||
|
||||
public abstract string RoomName { get; }
|
||||
|
||||
public CotijaBridgeBase(string key, string name)
|
||||
: base(key, name)
|
||||
{
|
||||
|
||||
@@ -134,6 +134,14 @@ namespace PepperDash.Essentials.Room.Cotija
|
||||
/// </summary>
|
||||
public bool ConfigIsLoaded { get; private set; }
|
||||
|
||||
public override string RoomName
|
||||
{
|
||||
get {
|
||||
var name = EISC.StringOutput[StringJoin.ConfigRoomName].StringValue;
|
||||
return string.IsNullOrEmpty(name) ? "Not Loaded" : name;
|
||||
}
|
||||
}
|
||||
|
||||
CotijaDdvc01DeviceBridge SourceBridge;
|
||||
|
||||
|
||||
|
||||
@@ -15,6 +15,17 @@ namespace PepperDash.Essentials
|
||||
|
||||
public EssentialsHuddleSpaceRoom Room { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public override string RoomName
|
||||
{
|
||||
get
|
||||
{
|
||||
return Room.Name;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Reference in New Issue
Block a user