Adds LinkToApi method

This commit is contained in:
Andrew Welker
2020-04-14 16:14:42 -06:00
parent 894a6a70bb
commit 0e211e02b8

View File

@@ -3,9 +3,12 @@ using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
using Crestron.SimplSharpPro.DeviceSupport;
using PepperDash.Core;
using PepperDash.Essentials.Core;
using PepperDash.Essentials.Core.Bridges;
using PepperDash.Essentials.Core.Lighting;
using LightingBase = PepperDash.Essentials.Core.Lighting.LightingBase;
namespace PepperDash.Essentials.Devices.Common.Environment.Lutron
{
@@ -77,6 +80,14 @@ namespace PepperDash.Essentials.Devices.Common.Environment.Lutron
return true;
}
public override void LinkToApi(BasicTriList trilist, uint joinStart, string joinMapKey, EiscApi bridge)
{
var joinMap = LinkLightingToApi(this, trilist, joinStart, joinMapKey, bridge);
CommunicationMonitor.IsOnlineFeedback.LinkInputSig(trilist.BooleanInput[joinMap.IsOnline]);
trilist.SetStringSigAction(joinMap.IntegrationIdSet, s => IntegrationId = s);
}
void socket_ConnectionChange(object sender, GenericSocketStatusChageEventArgs e)
{
Debug.Console(2, this, "Socket Status Change: {0}", e.Client.ClientStatus.ToString());