mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-02-15 20:54:55 +00:00
fix: CS LAN fixes
This commit is contained in:
@@ -190,6 +190,14 @@ namespace PepperDash.Essentials.Touchpanel
|
|||||||
|
|
||||||
RegisterForExtenders();
|
RegisterForExtenders();
|
||||||
|
|
||||||
|
if (CrestronEnvironment.DevicePlatform != eDevicePlatform.Appliance)
|
||||||
|
{
|
||||||
|
this.LogInformation("Not running on processor. Skipping CS LAN Configuration");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
var csAdapterId = CrestronEthernetHelper.GetAdapterdIdForSpecifiedAdapterType(EthernetAdapterType.EthernetCSAdapter);
|
var csAdapterId = CrestronEthernetHelper.GetAdapterdIdForSpecifiedAdapterType(EthernetAdapterType.EthernetCSAdapter);
|
||||||
var csSubnetMask = CrestronEthernetHelper.GetEthernetParameter(CrestronEthernetHelper.ETHERNET_PARAMETER_TO_GET.GET_CURRENT_IP_MASK, csAdapterId);
|
var csSubnetMask = CrestronEthernetHelper.GetEthernetParameter(CrestronEthernetHelper.ETHERNET_PARAMETER_TO_GET.GET_CURRENT_IP_MASK, csAdapterId);
|
||||||
var csIpAddress = CrestronEthernetHelper.GetEthernetParameter(CrestronEthernetHelper.ETHERNET_PARAMETER_TO_GET.GET_CURRENT_IP_ADDRESS, csAdapterId);
|
var csIpAddress = CrestronEthernetHelper.GetEthernetParameter(CrestronEthernetHelper.ETHERNET_PARAMETER_TO_GET.GET_CURRENT_IP_ADDRESS, csAdapterId);
|
||||||
@@ -197,6 +205,11 @@ namespace PepperDash.Essentials.Touchpanel
|
|||||||
this.csSubnetMask = System.Net.IPAddress.Parse(csSubnetMask);
|
this.csSubnetMask = System.Net.IPAddress.Parse(csSubnetMask);
|
||||||
this.csIpAddress = System.Net.IPAddress.Parse(csIpAddress);
|
this.csIpAddress = System.Net.IPAddress.Parse(csIpAddress);
|
||||||
}
|
}
|
||||||
|
catch (ArgumentException)
|
||||||
|
{
|
||||||
|
this.LogInformation("This processor does not have a CS LAN");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Updates the theme setting for this touchpanel controller and persists the change to configuration.
|
/// Updates the theme setting for this touchpanel controller and persists the change to configuration.
|
||||||
|
|||||||
Reference in New Issue
Block a user