Skip to content

Commit

Permalink
fix: add ICommunicationMonitor
Browse files Browse the repository at this point in the history
  • Loading branch information
andrew-welker committed Jun 5, 2024
1 parent bf352cb commit 607b826
Show file tree
Hide file tree
Showing 30 changed files with 10 additions and 142 deletions.
12 changes: 7 additions & 5 deletions pdt_shureMXA_epi/ShureMxwDevice.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

namespace pdt_shureMXW_epi
{
public class ShureMxwDevice : EssentialsBridgeableDevice, IPrivacy
public class ShureMxwDevice : EssentialsBridgeableDevice, IPrivacy, ICommunicationMonitor
{
public Properties Props { get; private set; }

Expand Down Expand Up @@ -79,7 +79,9 @@ public string Error

public IBasicCommunication Communication { get; private set; }
public CommunicationGather PortGather { get; private set; }
public GenericCommunicationMonitor CommunicationMonitor { get; private set; }
private GenericCommunicationMonitor _communicationMonitor;

public StatusMonitorBase CommunicationMonitor { get { return _communicationMonitor; } }

int CautionThreshold { get; set; }

Expand Down Expand Up @@ -113,7 +115,7 @@ public ShureMxwDevice(string key, string name, IBasicCommunication comm, Propert
PortGather = new CommunicationGather(Communication, ">");
PortGather.LineReceived += LineReceived;

CommunicationMonitor = new GenericCommunicationMonitor(this, Communication, 15000, 180000, 300000, DoPoll);
_communicationMonitor = new GenericCommunicationMonitor(this, Communication, 15000, 180000, 300000, DoPoll);

Init();
}
Expand Down Expand Up @@ -206,7 +208,7 @@ private void Init()
public override void Initialize()
{
Communication.Connect();
CommunicationMonitor.Start();
_communicationMonitor.Start();
}

#endregion
Expand Down Expand Up @@ -480,7 +482,7 @@ public override void LinkToApi(BasicTriList trilist, uint joinStart, string join
bridge.AddJoinMap(Key, joinMap);
}

CommunicationMonitor.IsOnlineFeedback.LinkInputSig(trilist.BooleanInput[joinMap.IsOnline.JoinNumber]);
_communicationMonitor.IsOnlineFeedback.LinkInputSig(trilist.BooleanInput[joinMap.IsOnline.JoinNumber]);
Debug.Console(2, this, "Linked Online at {0}", joinMap.IsOnline);

ErrorFeedback.LinkInputSig(trilist.StringInput[joinMap.ErrorString.JoinNumber]);
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed pdt_shureMXA_epi/bin/Debug/PepperDashEssentials.dll
Binary file not shown.
Binary file removed pdt_shureMXA_epi/bin/Debug/PepperDash_Core.dll
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed pdt_shureMXA_epi/bin/Debug/SimplSharpData.dat
Binary file not shown.
Binary file removed pdt_shureMXA_epi/bin/Debug/SimplSharpData.dat.der
Binary file not shown.
Binary file removed pdt_shureMXA_epi/bin/Debug/SimplSharpNewtonsoft.dll
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
86 changes: 0 additions & 86 deletions pdt_shureMXA_epi/bin/Debug/manifest.info

This file was deleted.

Binary file removed pdt_shureMXA_epi/bin/Debug/manifest.ser
Binary file not shown.
Binary file not shown.

This file was deleted.

Binary file removed pdt_shureMXA_epi/obj/Debug/pdt_shureMXA_epi.dll
Binary file not shown.
Binary file removed pdt_shureMXA_epi/obj/Debug/pdt_shureMXA_epi.pdb
Binary file not shown.
6 changes: 3 additions & 3 deletions pdt_shureMXA_epi/pdt_shureMXW_epi.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -69,12 +69,12 @@
</Reference>
<Reference Include="SimplSharpCustomAttributesInterface, Version=1.0.0.0, Culture=neutral, PublicKeyToken=1099c178b3b54c3b, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\..\ProgramData\Crestron\SDK\SimplSharpCustomAttributesInterface.dll</HintPath>
<HintPath>..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SimplSharpCustomAttributesInterface.dll</HintPath>
<Private>False</Private>
</Reference>
<Reference Include="SimplSharpHelperInterface, Version=1.0.0.0, Culture=neutral, PublicKeyToken=1099c178b3b54c3b, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\..\ProgramData\Crestron\SDK\SimplSharpHelperInterface.dll</HintPath>
<HintPath>..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SimplSharpHelperInterface.dll</HintPath>
<Private>False</Private>
</Reference>
<Reference Include="SimplSharpNewtonsoft, Version=1.0.0.0, Culture=neutral, PublicKeyToken=1099c178b3b54c3b, processorArchitecture=MSIL">
Expand All @@ -83,7 +83,7 @@
</Reference>
<Reference Include="SimplSharpPro, Version=1.5.3.17, Culture=neutral, PublicKeyToken=1099c178b3b54c3b, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\..\ProgramData\Crestron\SDK\SimplSharpPro.exe</HintPath>
<HintPath>..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SimplSharpPro.exe</HintPath>
<Private>False</Private>
</Reference>
<Reference Include="SimplSharpReflectionInterface, Version=1.0.5583.25238, Culture=neutral, PublicKeyToken=1099c178b3b54c3b, processorArchitecture=MSIL">
Expand Down

0 comments on commit 607b826

Please sign in to comment.