Skip to content

Commit

Permalink
feat: adds isSnowbox config property
Browse files Browse the repository at this point in the history
  • Loading branch information
aknous committed May 24, 2024
1 parent f10e70f commit d50338e
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 6 deletions.
12 changes: 6 additions & 6 deletions epi-display-samsung-mdc/PepperDashPluginSamsungMdcDisplay.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
<ItemGroup>
<Reference Include="Crestron.SimplSharpPro.DeviceSupport, Version=1.0.0.0, Culture=neutral, PublicKeyToken=1099c178b3b54c3b, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\ProgramData\Crestron\SDK\SSPDevices\Crestron.SimplSharpPro.DeviceSupport.dll</HintPath>
<HintPath>..\..\..\..\..\..\ProgramData\Crestron\SDK\SSPDevices\Crestron.SimplSharpPro.DeviceSupport.dll</HintPath>
</Reference>
<Reference Include="Essentials Devices Common, Version=1.9.7.31145, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
Expand All @@ -73,17 +73,17 @@
</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">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\ProgramData\Crestron\SDK\SimplSharpNewtonsoft.dll</HintPath>
<HintPath>..\..\..\..\..\..\ProgramData\Crestron\SDK\SimplSharpNewtonsoft.dll</HintPath>
</Reference>
<Reference Include="SimplSharpPro, Version=1.5.3.17, Culture=neutral, PublicKeyToken=1099c178b3b54c3b, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
Expand All @@ -92,11 +92,11 @@
</Reference>
<Reference Include="SimplSharpReflectionInterface, Version=1.0.5583.25238, Culture=neutral, PublicKeyToken=1099c178b3b54c3b, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\ProgramData\Crestron\SDK\SimplSharpReflectionInterface.dll</HintPath>
<HintPath>..\..\..\..\..\..\ProgramData\Crestron\SDK\SimplSharpReflectionInterface.dll</HintPath>
</Reference>
<Reference Include="SimplSharpTimerEventInterface, Version=1.0.6197.20052, Culture=neutral, PublicKeyToken=1099c178b3b54c3b, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\ProgramData\Crestron\SDK\SimplSharpTimerEventInterface.dll</HintPath>
<HintPath>..\..\..\..\..\..\ProgramData\Crestron\SDK\SimplSharpTimerEventInterface.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
Expand Down
6 changes: 6 additions & 0 deletions epi-display-samsung-mdc/SamsungMdc.cs
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ public void ListInputPorts()
private bool _isMuted;

private readonly bool _showVolumeControls;
private readonly bool _isSnowbox;
private ActionIncrementer _volumeIncrementer;


Expand Down Expand Up @@ -196,6 +197,7 @@ public SamsungMdcDisplayController(string key, string name, SamsungMdcDisplayPro
_coolingTimeMs = _config.CoolingTimeMs;
_warmingTimeMs = _config.WarmingTimeMs;
_showVolumeControls = _config.ShowVolumeControls;
_isSnowbox = _config.IsSnowbox;
_pollLedTemps = config.PollLedTemps;
_customInputs = config.CustomInputs;

Expand Down Expand Up @@ -323,6 +325,9 @@ public void LinkToApi(BasicTriList trilist, uint joinStart, string joinMapKey, E
// Show Volume Controls
trilist.SetBool(joinMap.VolumeControlsVisibleFb.JoinNumber, _showVolumeControls);

// Is Snowbox
trilist.SetBool(joinMap.IsSnowboxFb.JoinNumber, _isSnowbox);

// LED temperature analog feedback
CurrentLedTemperatureCelsiusFeedback.LinkInputSig(
trilist.UShortInput[joinMap.LedTemperatureCelsius.JoinNumber]);
Expand All @@ -349,6 +354,7 @@ public void LinkToApi(BasicTriList trilist, uint joinStart, string joinMapKey, E
InputNumberFeedback.FireUpdate();
trilist.SetBool(joinMap.VolumeControlsVisibleFb.JoinNumber, _showVolumeControls);
trilist.SetBool(joinMap.IsSnowboxFb.JoinNumber, _isSnowbox);
VolumeLevelFeedback.FireUpdate();
MuteFeedback.FireUpdate();
Expand Down
3 changes: 3 additions & 0 deletions epi-display-samsung-mdc/SamsungMdcConfigObject.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,9 @@ public class SamsungMdcDisplayPropertiesConfig
[JsonProperty("showVolumeControls")]
public bool ShowVolumeControls { get; set; }

[JsonProperty("isSnowbox")]
public bool IsSnowbox { get; set; }

[JsonProperty("pollLedTemps")]
public bool PollLedTemps { get; set; }

Expand Down
17 changes: 17 additions & 0 deletions epi-display-samsung-mdc/SamsungMdcControllerJoinMap.cs
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,23 @@ public class SamsungDisplayControllerJoinMap : DisplayControllerJoinMap
JoinType = eJoinType.Digital
});

/// <summary>
/// High when IsSnowbox is true
/// </summary>
[JoinName("IsSnowboxFb")]
public JoinDataComplete IsSnowboxFb = new JoinDataComplete(
new JoinData
{
JoinNumber = 41,
JoinSpan = 1
},
new JoinMetadata
{
Description = "Enable Visibility of Volume Controls",
JoinCapabilities = eJoinCapabilities.ToSIMPL,
JoinType = eJoinType.Digital
});


/// <summary>
/// Display controller join map
Expand Down

0 comments on commit d50338e

Please sign in to comment.