diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Crestron IO/C2nRts/C2nRthsController.cs b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Crestron IO/C2nRts/C2nRthsController.cs index 4a82fe09..8416efac 100644 --- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Crestron IO/C2nRts/C2nRthsController.cs +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Crestron IO/C2nRts/C2nRthsController.cs @@ -115,17 +115,17 @@ namespace PepperDash.Essentials.Core.CrestronIO if (parentKey.Equals("processor", StringComparison.CurrentCultureIgnoreCase)) { - Debug.Console(0, "Device {0} is a valid cresnet master - creating new C2nRths"); + Debug.Console(0, "Device {0} is a valid cresnet master - creating new C2nRths", parentKey); return new C2nRths(cresnetId, Global.ControlSystem); } var cresnetBridge = DeviceManager.GetDeviceForKey(parentKey) as ICresnetBridge; if (cresnetBridge != null) { - Debug.Console(0, "Device {0} is a valid cresnet master - creating new C2nRths"); + Debug.Console(0, "Device {0} is a valid cresnet master - creating new C2nRths", parentKey); return new C2nRths(cresnetId, cresnetBridge.Branches[branchId]); } - Debug.Console(0, "Device {0} is not a valid cresnet master", branchId); + Debug.Console(0, "Device {0} is not a valid cresnet master", parentKey); return null; } #endregion diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Crestron IO/StatusSign/StatusSignController.cs b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Crestron IO/StatusSign/StatusSignController.cs index c316c9b4..b269745e 100644 --- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Crestron IO/StatusSign/StatusSignController.cs +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Crestron IO/StatusSign/StatusSignController.cs @@ -185,17 +185,17 @@ namespace PepperDash.Essentials.Core.CrestronIO if (parentKey.Equals("processor", StringComparison.CurrentCultureIgnoreCase)) { - Debug.Console(0, "Device {0} is a valid cresnet master - creating new StatusSign"); + Debug.Console(0, "Device {0} is a valid cresnet master - creating new StatusSign", parentKey); return new StatusSign(cresnetId, Global.ControlSystem); } var cresnetBridge = DeviceManager.GetDeviceForKey(parentKey) as ICresnetBridge; if (cresnetBridge != null) { - Debug.Console(0, "Device {0} is a valid cresnet master - creating new StatusSign"); + Debug.Console(0, "Device {0} is a valid cresnet master - creating new StatusSign", parentKey); return new StatusSign(cresnetId, cresnetBridge.Branches[branchId]); } - Debug.Console(0, "Device {0} is not a valid cresnet master", branchId); + Debug.Console(0, "Device {0} is not a valid cresnet master", parentKey); return null; } #endregion diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Gateways/CenRfgwController.cs b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Gateways/CenRfgwController.cs index ba185e4f..ed847747 100644 --- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Gateways/CenRfgwController.cs +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Gateways/CenRfgwController.cs @@ -113,7 +113,7 @@ namespace PepperDash.Essentials.Core if (parentKey.Equals("processor", StringComparison.CurrentCultureIgnoreCase)) { - Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsOdtCCn"); + Debug.Console(0, "Device {0} is a valid cresnet master - creating new CenRfgw", parentKey); if (type.Equals("cenerfgwpoe", StringComparison.InvariantCultureIgnoreCase)) { return new CenErfgwPoeCresnet(cresnetId, Global.ControlSystem); @@ -127,7 +127,7 @@ namespace PepperDash.Essentials.Core if (cresnetBridge != null) { - Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsOdtCCn"); + Debug.Console(0, "Device {0} is a valid cresnet master - creating new CenRfgw", parentKey); if (type.Equals("cenerfgwpoe", StringComparison.InvariantCultureIgnoreCase)) { @@ -138,7 +138,7 @@ namespace PepperDash.Essentials.Core return new CenRfgwExCresnet(cresnetId, cresnetBridge.Branches[branchId]); } } - Debug.Console(0, "Device {0} is not a valid cresnet master", branchId); + Debug.Console(0, "Device {0} is not a valid cresnet master", parentKey); return null; } diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PartitionSensor/GlsPartitionSensorController.cs b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PartitionSensor/GlsPartitionSensorController.cs index 714f729f..4fdbd2be 100644 --- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PartitionSensor/GlsPartitionSensorController.cs +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PartitionSensor/GlsPartitionSensorController.cs @@ -243,17 +243,17 @@ namespace PepperDash.Essentials.Core if (parentKey.Equals("processor", StringComparison.CurrentCultureIgnoreCase)) { - Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsPartCn"); + Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsPartCn", parentKey); return new GlsPartCn(cresnetId, Global.ControlSystem); } var cresnetBridge = DeviceManager.GetDeviceForKey(parentKey) as ICresnetBridge; if (cresnetBridge != null) { - Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsPartCn"); + Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsPartCn", parentKey); return new GlsPartCn(cresnetId, cresnetBridge.Branches[branchId]); } - Debug.Console(0, "Device {0} is not a valid cresnet master", branchId); + Debug.Console(0, "Device {0} is not a valid cresnet master", parentKey); return null; } #endregion diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/Occupancy/GlsOccupancySensorBaseController.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/Occupancy/GlsOccupancySensorBaseController.cs index 9ee0de95..e02fe7f0 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/Occupancy/GlsOccupancySensorBaseController.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/Occupancy/GlsOccupancySensorBaseController.cs @@ -67,45 +67,47 @@ namespace PepperDash.Essentials.Devices.Common.Occupancy RegisterCrestronGenericBase(OccSensor); - RegisterGlsOdtSensorBaseController(); + RegisterGlsOdtSensorBaseController(OccSensor); }); } public GlsOccupancySensorBaseController(string key, string name) : base(key, name) {} - protected void RegisterGlsOdtSensorBaseController() + protected void RegisterGlsOdtSensorBaseController(GlsOccupancySensorBase occSensor) { + OccSensor = occSensor; + RoomIsOccupiedFeedback = new BoolFeedback(RoomIsOccupiedFeedbackFunc); - PirSensorEnabledFeedback = new BoolFeedback(() => OccSensor.PirEnabledFeedback.BoolValue); + PirSensorEnabledFeedback = new BoolFeedback(() => OccSensor.PirEnabledFeedback.BoolValue); - LedFlashEnabledFeedback = new BoolFeedback(() => OccSensor.LedFlashEnabledFeedback.BoolValue); + LedFlashEnabledFeedback = new BoolFeedback(() => OccSensor.LedFlashEnabledFeedback.BoolValue); - ShortTimeoutEnabledFeedback = new BoolFeedback(() => OccSensor.ShortTimeoutEnabledFeedback.BoolValue); + ShortTimeoutEnabledFeedback = new BoolFeedback(() => OccSensor.ShortTimeoutEnabledFeedback.BoolValue); - PirSensitivityInVacantStateFeedback = - new IntFeedback(() => OccSensor.PirSensitivityInVacantStateFeedback.UShortValue); + PirSensitivityInVacantStateFeedback = + new IntFeedback(() => OccSensor.PirSensitivityInVacantStateFeedback.UShortValue); - PirSensitivityInOccupiedStateFeedback = - new IntFeedback(() => OccSensor.PirSensitivityInOccupiedStateFeedback.UShortValue); + PirSensitivityInOccupiedStateFeedback = + new IntFeedback(() => OccSensor.PirSensitivityInOccupiedStateFeedback.UShortValue); - CurrentTimeoutFeedback = new IntFeedback(() => OccSensor.CurrentTimeoutFeedback.UShortValue); + CurrentTimeoutFeedback = new IntFeedback(() => OccSensor.CurrentTimeoutFeedback.UShortValue); - LocalTimoutFeedback = new IntFeedback(() => OccSensor.LocalTimeoutFeedback.UShortValue); + LocalTimoutFeedback = new IntFeedback(() => OccSensor.LocalTimeoutFeedback.UShortValue); - GraceOccupancyDetectedFeedback = - new BoolFeedback(() => OccSensor.GraceOccupancyDetectedFeedback.BoolValue); + GraceOccupancyDetectedFeedback = + new BoolFeedback(() => OccSensor.GraceOccupancyDetectedFeedback.BoolValue); - RawOccupancyFeedback = new BoolFeedback(() => OccSensor.RawOccupancyFeedback.BoolValue); + RawOccupancyFeedback = new BoolFeedback(() => OccSensor.RawOccupancyFeedback.BoolValue); - InternalPhotoSensorValue = new IntFeedback(() => OccSensor.InternalPhotoSensorValueFeedback.UShortValue); + InternalPhotoSensorValue = new IntFeedback(() => OccSensor.InternalPhotoSensorValueFeedback.UShortValue); - ExternalPhotoSensorValue = new IntFeedback(() => OccSensor.ExternalPhotoSensorValueFeedback.UShortValue); + ExternalPhotoSensorValue = new IntFeedback(() => OccSensor.ExternalPhotoSensorValueFeedback.UShortValue); - OccSensor.BaseEvent += new Crestron.SimplSharpPro.BaseEventHandler(OccSensor_BaseEvent); + OccSensor.BaseEvent += OccSensor_BaseEvent; - OccSensor.GlsOccupancySensorChange += OccSensor_GlsOccupancySensorChange; + OccSensor.GlsOccupancySensorChange += OccSensor_GlsOccupancySensorChange; } @@ -420,17 +422,17 @@ namespace PepperDash.Essentials.Devices.Common.Occupancy if (parentKey.Equals("processor", StringComparison.CurrentCultureIgnoreCase)) { - Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsOirCCn"); + Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsOirCCn", parentKey); return new GlsOirCCn(cresnetId, Global.ControlSystem); } var cresnetBridge = DeviceManager.GetDeviceForKey(parentKey) as ICresnetBridge; if (cresnetBridge != null) { - Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsOirCCn"); + Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsOirCCn", parentKey); return new GlsOirCCn(cresnetId, cresnetBridge.Branches[branchId]); } - Debug.Console(0, "Device {0} is not a valid cresnet master", branchId); + Debug.Console(0, "Device {0} is not a valid cresnet master", parentKey); return null; } #endregion diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/Occupancy/GlsOdtOccupancySensorController.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/Occupancy/GlsOdtOccupancySensorController.cs index 4eef3d2d..3fde82b0 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/Occupancy/GlsOdtOccupancySensorController.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/Occupancy/GlsOdtOccupancySensorController.cs @@ -45,7 +45,7 @@ namespace PepperDash.Essentials.Devices.Common.Occupancy RegisterCrestronGenericBase(OccSensor); - RegisterGlsOdtSensorBaseController(); + RegisterGlsOdtSensorBaseController(OccSensor); AndWhenVacatedFeedback = new BoolFeedback(() => OccSensor.AndWhenVacatedFeedback.BoolValue); @@ -181,17 +181,17 @@ namespace PepperDash.Essentials.Devices.Common.Occupancy if (parentKey.Equals("processor", StringComparison.CurrentCultureIgnoreCase)) { - Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsOdtCCn"); + Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsOdtCCn", parentKey); return new GlsOdtCCn(cresnetId, Global.ControlSystem); } var cresnetBridge = DeviceManager.GetDeviceForKey(parentKey) as ICresnetBridge; if (cresnetBridge != null) { - Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsOdtCCn"); + Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsOdtCCn", parentKey); return new GlsOdtCCn(cresnetId, cresnetBridge.Branches[branchId]); } - Debug.Console(0, "Device {0} is not a valid cresnet master", branchId); + Debug.Console(0, "Device {0} is not a valid cresnet master", parentKey); return null; } #endregion