mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-04-12 03:57:27 +00:00
ECS-838 Add method to set lighting integrationID from Bridge.
This commit is contained in:
parent
7b4aad3516
commit
4a69207038
2 changed files with 8 additions and 1 deletions
|
|
@ -66,11 +66,16 @@ namespace PepperDash.Essentials
|
|||
{
|
||||
comm.CommunicationMonitor.IsOnlineFeedback.LinkInputSig(ApiEisc.Eisc.BooleanInput[ApiMap.Online]);
|
||||
}
|
||||
|
||||
var lutronLights = Lights as PepperDash.Essentials.Devices.Common.Environment.Lutron.LutronQuantumArea;
|
||||
|
||||
ApiEisc.Eisc.SetUShortSigAction(ApiMap.CallPreset, u => Lights.SelectScene(Lights.LightingScenes[u]));
|
||||
ApiEisc.Eisc.SetStringSigAction(ApiMap.integrationID, (s) => { lutronLights.IntegrationId = s; });
|
||||
int sceneIndex = 1;
|
||||
foreach (var scene in Lights.LightingScenes)
|
||||
{
|
||||
var tempIndex = sceneIndex - 1;
|
||||
|
||||
ApiEisc.Eisc.SetSigTrueAction((uint)(ApiMap.LightingSceneOffset + sceneIndex), () => Lights.SelectScene(Lights.LightingScenes[tempIndex]));
|
||||
scene.IsActiveFeedback.LinkInputSig(ApiEisc.Eisc.BooleanInput[(uint)(ApiMap.LightingSceneOffset + sceneIndex)]);
|
||||
ApiEisc.Eisc.StringInput[(uint)(ApiMap.LightingSceneOffset + sceneIndex)].StringValue = scene.Name;
|
||||
|
|
@ -108,6 +113,8 @@ namespace PepperDash.Essentials
|
|||
public ushort LightingSceneOffset = 10;
|
||||
public ushort ButtonVisibilityOffset = 40;
|
||||
public ushort CallPreset = 1;
|
||||
|
||||
public ushort integrationID = 1;
|
||||
public EssentialsLightsBridgeApiMap()
|
||||
{
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue