mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-04-14 13:07:18 +00:00
feat(essentials): Adds IEnvironmentalControls interface and updates some room config properties
This commit is contained in:
parent
8945398cd7
commit
e152250363
4 changed files with 46 additions and 1 deletions
|
|
@ -11,6 +11,8 @@ using PepperDash.Essentials.Core.Config;
|
|||
using PepperDash.Essentials.Core.Devices;
|
||||
using PepperDash.Essentials.Core.DeviceTypeInterfaces;
|
||||
|
||||
using Newtonsoft.Json;
|
||||
|
||||
namespace PepperDash.Essentials.Core
|
||||
{
|
||||
/// <summary>
|
||||
|
|
@ -18,6 +20,8 @@ namespace PepperDash.Essentials.Core
|
|||
/// </summary>
|
||||
public abstract class EssentialsRoomBase : ReconfigurableDevice, IEssentialsRoom
|
||||
{
|
||||
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
|
|
@ -35,6 +39,16 @@ namespace PepperDash.Essentials.Core
|
|||
|
||||
public bool OccupancyStatusProviderIsRemote { get; private set; }
|
||||
|
||||
public List<EssentialsDevice> EnvironmentalControlDevices { get; protected set; }
|
||||
|
||||
public bool HasEnvironmentalControlDevices
|
||||
{
|
||||
get
|
||||
{
|
||||
return EnvironmentalControlDevices != null && EnvironmentalControlDevices.Count > 0;
|
||||
}
|
||||
}
|
||||
|
||||
protected abstract Func<bool> IsWarmingFeedbackFunc { get; }
|
||||
protected abstract Func<bool> IsCoolingFeedbackFunc { get; }
|
||||
|
||||
|
|
@ -119,6 +133,9 @@ namespace PepperDash.Essentials.Core
|
|||
public EssentialsRoomBase(DeviceConfig config)
|
||||
: base(config)
|
||||
{
|
||||
|
||||
|
||||
|
||||
// Setup the ShutdownPromptTimer
|
||||
ShutdownPromptTimer = new SecondsCountdownTimer(Key + "-offTimer");
|
||||
ShutdownPromptTimer.IsRunningFeedback.OutputChange += (o, a) =>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue