Post Cp3N and Mac server testing, with disco testing on mac server

This commit is contained in:
Heath Volmer
2016-08-03 16:43:02 -06:00
parent 433b4eba81
commit cb5d36de51
6 changed files with 17 additions and 25 deletions

View File

@@ -59,17 +59,9 @@ namespace PepperDash.Core
public ushort UStatus { get; private set; }
/// <summary>
/// Determines whether client will attempt reconnection on failure
/// Determines whether client will attempt reconnection on failure. Default is true
/// </summary>
public bool AutoReconnect { get; set; }
/// <summary>
/// S+ helper for bool value
/// </summary>
public ushort UAutoReconnect
{
set { AutoReconnect = value == 1; }
}
/// <summary>
/// Millisecond value, determines the timeout period in between reconnect attempts
@@ -85,7 +77,7 @@ namespace PepperDash.Core
base(key)
{
AutoReconnectIntervalMs = 5000;
AutoReconnect = true;
Hostname = hostname;
Port = port;
Username = username;
@@ -125,7 +117,7 @@ namespace PepperDash.Core
Debug.Console(1, this, "Connected");
TheStream = Client.CreateShellStream("PDTShell", 100, 80, 100, 200, 65534);
TheStream.DataReceived += Stream_DataReceived;
TheStream.ErrorOccurred += Stream_ErrorOccurred;
//TheStream.ErrorOccurred += Stream_ErrorOccurred;
}
return;
@@ -240,13 +232,13 @@ namespace PepperDash.Core
}
}
/// <summary>
/// Error event handler for stream events
/// </summary>
void Stream_ErrorOccurred(object sender, ExceptionEventArgs e)
{
Debug.Console(2, this, "CRITICAL: PLEASE REPORT - SSH client stream error:\r{0}", e.Exception);
}
///// <summary>
///// Error event handler for stream events
///// </summary>
//void Stream_ErrorOccurred(object sender, ExceptionEventArgs e)
//{
// Debug.Console(2, this, "CRITICAL: PLEASE REPORT - SSH client stream error:\r{0}", e.Exception);
//}
/// <summary>
/// Error event handler for client events - disconnect, etc. Will forward those events via ConnectionChange
@@ -254,12 +246,12 @@ namespace PepperDash.Core
/// </summary>
void Client_ErrorOccurred(object sender, Crestron.SimplSharp.Ssh.Common.ExceptionEventArgs e)
{
Debug.Console(0, this, "SSH client error: {0}", e.Exception);
if (e.Exception is SocketException)
if (!(e.Exception is SshConnectionException))
{
// ****LOG SOMETHING
Debug.Console(0, this, "SSH client error: {0}", e.Exception);
UStatus = 4;
}
Debug.Console(1, this, "Disconnected by remote");
IsConnected = false;
HandleConnectionFailure();
}

View File

@@ -82,7 +82,7 @@
<Programmer />
<ArchiveFilename>C:\Users\hvolm\Desktop\working\pepperdash-simplsharp-core\Pepperdash Core\Pepperdash Core\bin\PepperDash_Core.clz</ArchiveFilename>
<MinFirmwareVersion>1.007.0017</MinFirmwareVersion>
<CompiledOn>8/3/2016 3:25:15 PM</CompiledOn>
<CompiledOn>8/3/2016 4:33:09 PM</CompiledOn>
<AdditionalInfo />
<EmbedSourceArchive>False</EmbedSourceArchive>
<CopyTo />

View File

@@ -10,7 +10,7 @@
<ArchiveName />
</RequiredInfo>
<OptionalInfo>
<CompiledOn>8/3/2016 3:25:15 PM</CompiledOn>
<CompilerRev>1.0.0.25957</CompilerRev>
<CompiledOn>8/3/2016 4:33:09 PM</CompiledOn>
<CompilerRev>1.0.0.27993</CompilerRev>
</OptionalInfo>
</ProgramInfo>

View File

@@ -1,4 +1,4 @@
MainAssembly=PepperDash_Core.dll:2888e497caab5a6d6578b6174add3a96
MainAssembly=PepperDash_Core.dll:ca423b7b3c2fe76c3d6a8b9cb9ff67cd
MainAssemblyMinFirmwareVersion=1.007.0017
ü
DependencySource=Newtonsoft.Json.Compact.dll:ea996aa2ec65aa1878e7c9d09e37a896