mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-02-15 12:44:58 +00:00
Updated Joinmaps to JoinMapBaseAdvanced
This commit is contained in:
@@ -4,34 +4,6 @@ namespace PepperDash.Essentials.Core.Bridges
|
|||||||
{
|
{
|
||||||
public class DmTxControllerJoinMap : JoinMapBaseAdvanced
|
public class DmTxControllerJoinMap : JoinMapBaseAdvanced
|
||||||
{
|
{
|
||||||
<<<<<<< HEAD
|
|
||||||
#region Digitals
|
|
||||||
/// <summary>
|
|
||||||
/// High when device is online (if not attached to a DMP3 or DM chassis with a CPU3 card
|
|
||||||
/// </summary>
|
|
||||||
public uint IsOnline { get; set; }
|
|
||||||
/// <summary>
|
|
||||||
/// High when video sync is detected
|
|
||||||
/// </summary>
|
|
||||||
public uint VideoSyncStatus { get; set; }
|
|
||||||
/// <summary>
|
|
||||||
///
|
|
||||||
/// </summary>
|
|
||||||
public uint FreeRunEnabled { get; set; }
|
|
||||||
/// <summary>
|
|
||||||
/// High when video sync is detected on input 1 of a multi-input tx
|
|
||||||
/// </summary>
|
|
||||||
public uint Input1VideoSyncStatus { get; set; }
|
|
||||||
/// <summary>
|
|
||||||
/// High when video sync is detected on input 2 of a multi-input tx
|
|
||||||
/// </summary>
|
|
||||||
public uint Input2VideoSyncStatus { get; set; }
|
|
||||||
/// <summary>
|
|
||||||
/// High when video sync is detected on input 3 of a multi-input tx
|
|
||||||
/// </summary>
|
|
||||||
public uint Input3VideoSyncStatus { get; set; }
|
|
||||||
#endregion
|
|
||||||
=======
|
|
||||||
[JoinName("IsOnline")]
|
[JoinName("IsOnline")]
|
||||||
public JoinDataComplete IsOnline = new JoinDataComplete(new JoinData() { JoinNumber = 1, JoinSpan = 1 },
|
public JoinDataComplete IsOnline = new JoinDataComplete(new JoinData() { JoinNumber = 1, JoinSpan = 1 },
|
||||||
new JoinMetadata() { Label = "DM TX Online", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Digital });
|
new JoinMetadata() { Label = "DM TX Online", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Digital });
|
||||||
@@ -44,6 +16,18 @@ namespace PepperDash.Essentials.Core.Bridges
|
|||||||
public JoinDataComplete FreeRunEnabled = new JoinDataComplete(new JoinData() { JoinNumber = 3, JoinSpan = 1 },
|
public JoinDataComplete FreeRunEnabled = new JoinDataComplete(new JoinData() { JoinNumber = 3, JoinSpan = 1 },
|
||||||
new JoinMetadata() { Label = "DM TX Enable Free Run Set / Get", JoinCapabilities = eJoinCapabilities.ToFromSIMPL, JoinType = eJoinType.Digital });
|
new JoinMetadata() { Label = "DM TX Enable Free Run Set / Get", JoinCapabilities = eJoinCapabilities.ToFromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Input1VideoSyncStatus")]
|
||||||
|
public JoinDataComplete Input1VideoSyncStatus = new JoinDataComplete(new JoinData() { JoinNumber = 4, JoinSpan = 1 },
|
||||||
|
new JoinMetadata() { Label = "Input 1 Video Sync Status", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Input2VideoSyncStatus")]
|
||||||
|
public JoinDataComplete Input2VideoSyncStatus = new JoinDataComplete(new JoinData() { JoinNumber = 5, JoinSpan = 1 },
|
||||||
|
new JoinMetadata() { Label = "Input 2 Video Sync Status", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Input3VideoSyncStatus")]
|
||||||
|
public JoinDataComplete Input3VideoSyncStatus = new JoinDataComplete(new JoinData() { JoinNumber = 6, JoinSpan = 1 },
|
||||||
|
new JoinMetadata() { Label = "Input 3 Video Sync Status", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
[JoinName("CurrentInputResolution")]
|
[JoinName("CurrentInputResolution")]
|
||||||
public JoinDataComplete CurrentInputResolution = new JoinDataComplete(new JoinData() { JoinNumber = 1, JoinSpan = 1 },
|
public JoinDataComplete CurrentInputResolution = new JoinDataComplete(new JoinData() { JoinNumber = 1, JoinSpan = 1 },
|
||||||
new JoinMetadata() { Label = "DM TX Current Input Resolution", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Serial });
|
new JoinMetadata() { Label = "DM TX Current Input Resolution", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Serial });
|
||||||
@@ -81,70 +65,5 @@ namespace PepperDash.Essentials.Core.Bridges
|
|||||||
: base(joinStart, typeof(DmTxControllerJoinMap))
|
: base(joinStart, typeof(DmTxControllerJoinMap))
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
>>>>>>> development
|
|
||||||
|
|
||||||
|
|
||||||
<<<<<<< HEAD
|
|
||||||
/// <summary>
|
|
||||||
/// Sets and reports the current VGA Brightness level
|
|
||||||
/// </summary>
|
|
||||||
public uint VgaBrightness { get; set; }
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Sets and reports the current VGA Contrast level
|
|
||||||
/// </summary>
|
|
||||||
public uint VgaContrast { get; set; }
|
|
||||||
#endregion
|
|
||||||
|
|
||||||
#region Serials
|
|
||||||
/// <summary>
|
|
||||||
/// Reports the current input resolution
|
|
||||||
/// </summary>
|
|
||||||
public uint CurrentInputResolution { get; set; }
|
|
||||||
#endregion
|
|
||||||
|
|
||||||
|
|
||||||
public DmTxControllerJoinMap()
|
|
||||||
{
|
|
||||||
// Digital
|
|
||||||
IsOnline = 1;
|
|
||||||
VideoSyncStatus = 2;
|
|
||||||
FreeRunEnabled = 3;
|
|
||||||
Input1VideoSyncStatus = 4;
|
|
||||||
Input2VideoSyncStatus = 5;
|
|
||||||
Input3VideoSyncStatus = 6;
|
|
||||||
// Serial
|
|
||||||
CurrentInputResolution = 1;
|
|
||||||
// Analog
|
|
||||||
VideoInput = 1;
|
|
||||||
AudioInput = 2;
|
|
||||||
HdcpSupportCapability = 3;
|
|
||||||
Port1HdcpState = 4;
|
|
||||||
Port2HdcpState = 5;
|
|
||||||
VgaBrightness = 6;
|
|
||||||
VgaContrast = 7;
|
|
||||||
}
|
|
||||||
|
|
||||||
public override void OffsetJoinNumbers(uint joinStart)
|
|
||||||
{
|
|
||||||
var joinOffset = joinStart - 1;
|
|
||||||
|
|
||||||
IsOnline = IsOnline + joinOffset;
|
|
||||||
VideoSyncStatus = VideoSyncStatus + joinOffset;
|
|
||||||
FreeRunEnabled = FreeRunEnabled + joinOffset;
|
|
||||||
Input1VideoSyncStatus = Input1VideoSyncStatus + joinOffset;
|
|
||||||
Input2VideoSyncStatus = Input2VideoSyncStatus + joinOffset;
|
|
||||||
Input3VideoSyncStatus = Input3VideoSyncStatus + joinOffset;
|
|
||||||
CurrentInputResolution = CurrentInputResolution + joinOffset;
|
|
||||||
VideoInput = VideoInput + joinOffset;
|
|
||||||
AudioInput = AudioInput + joinOffset;
|
|
||||||
HdcpSupportCapability = HdcpSupportCapability + joinOffset;
|
|
||||||
Port1HdcpState = Port1HdcpState + joinOffset;
|
|
||||||
Port2HdcpState = Port2HdcpState + joinOffset;
|
|
||||||
VgaBrightness = VgaBrightness + joinOffset;
|
|
||||||
VgaContrast = VgaContrast + joinOffset;
|
|
||||||
}
|
|
||||||
=======
|
|
||||||
>>>>>>> development
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -237,11 +237,11 @@ namespace PepperDash.Essentials.DM
|
|||||||
|
|
||||||
if (HdmiVideoSyncFeedback != null)
|
if (HdmiVideoSyncFeedback != null)
|
||||||
{
|
{
|
||||||
HdmiVideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input1VideoSyncStatus]);
|
HdmiVideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input1VideoSyncStatus.JoinNumber]);
|
||||||
}
|
}
|
||||||
if (VgaVideoSyncFeedback != null)
|
if (VgaVideoSyncFeedback != null)
|
||||||
{
|
{
|
||||||
VgaVideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input2VideoSyncStatus]);
|
VgaVideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input2VideoSyncStatus.JoinNumber]);
|
||||||
}
|
}
|
||||||
|
|
||||||
LinkDmTxToApi(this, trilist, joinMap, bridge);
|
LinkDmTxToApi(this, trilist, joinMap, bridge);
|
||||||
|
|||||||
@@ -239,11 +239,11 @@ namespace PepperDash.Essentials.DM
|
|||||||
|
|
||||||
if (HdmiVideoSyncFeedback != null)
|
if (HdmiVideoSyncFeedback != null)
|
||||||
{
|
{
|
||||||
HdmiVideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input1VideoSyncStatus]);
|
HdmiVideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input1VideoSyncStatus.JoinNumber]);
|
||||||
}
|
}
|
||||||
if (VgaVideoSyncFeedback != null)
|
if (VgaVideoSyncFeedback != null)
|
||||||
{
|
{
|
||||||
VgaVideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input2VideoSyncStatus]);
|
VgaVideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input2VideoSyncStatus.JoinNumber]);
|
||||||
}
|
}
|
||||||
|
|
||||||
LinkDmTxToApi(this, trilist, joinMap, bridge);
|
LinkDmTxToApi(this, trilist, joinMap, bridge);
|
||||||
|
|||||||
@@ -242,11 +242,11 @@ namespace PepperDash.Essentials.DM
|
|||||||
|
|
||||||
if (HdmiVideoSyncFeedback != null)
|
if (HdmiVideoSyncFeedback != null)
|
||||||
{
|
{
|
||||||
HdmiVideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input1VideoSyncStatus]);
|
HdmiVideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input1VideoSyncStatus.JoinNumber]);
|
||||||
}
|
}
|
||||||
if (VgaVideoSyncFeedback != null)
|
if (VgaVideoSyncFeedback != null)
|
||||||
{
|
{
|
||||||
VgaVideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input2VideoSyncStatus]);
|
VgaVideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input2VideoSyncStatus.JoinNumber]);
|
||||||
}
|
}
|
||||||
|
|
||||||
LinkDmTxToApi(this, trilist, joinMap, bridge);
|
LinkDmTxToApi(this, trilist, joinMap, bridge);
|
||||||
|
|||||||
@@ -207,11 +207,11 @@ namespace PepperDash.Essentials.DM
|
|||||||
|
|
||||||
if (Hdmi1VideoSyncFeedback != null)
|
if (Hdmi1VideoSyncFeedback != null)
|
||||||
{
|
{
|
||||||
Hdmi1VideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input1VideoSyncStatus]);
|
Hdmi1VideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input1VideoSyncStatus.JoinNumber]);
|
||||||
}
|
}
|
||||||
if (Hdmi2VideoSyncFeedback != null)
|
if (Hdmi2VideoSyncFeedback != null)
|
||||||
{
|
{
|
||||||
Hdmi2VideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input2VideoSyncStatus]);
|
Hdmi2VideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input2VideoSyncStatus.JoinNumber]);
|
||||||
}
|
}
|
||||||
|
|
||||||
LinkDmTxToApi(this, trilist, joinMap, bridge);
|
LinkDmTxToApi(this, trilist, joinMap, bridge);
|
||||||
|
|||||||
@@ -250,15 +250,15 @@ namespace PepperDash.Essentials.DM
|
|||||||
|
|
||||||
if (Hdmi1VideoSyncFeedback != null)
|
if (Hdmi1VideoSyncFeedback != null)
|
||||||
{
|
{
|
||||||
Hdmi1VideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input1VideoSyncStatus]);
|
Hdmi1VideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input1VideoSyncStatus.JoinNumber]);
|
||||||
}
|
}
|
||||||
if (Hdmi2VideoSyncFeedback != null)
|
if (Hdmi2VideoSyncFeedback != null)
|
||||||
{
|
{
|
||||||
Hdmi2VideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input2VideoSyncStatus]);
|
Hdmi2VideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input2VideoSyncStatus.JoinNumber]);
|
||||||
}
|
}
|
||||||
if (VgaVideoSyncFeedback != null)
|
if (VgaVideoSyncFeedback != null)
|
||||||
{
|
{
|
||||||
VgaVideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input3VideoSyncStatus]);
|
VgaVideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input3VideoSyncStatus.JoinNumber]);
|
||||||
}
|
}
|
||||||
|
|
||||||
LinkDmTxToApi(this, trilist, joinMap, bridge);
|
LinkDmTxToApi(this, trilist, joinMap, bridge);
|
||||||
|
|||||||
@@ -226,15 +226,15 @@ namespace PepperDash.Essentials.DM
|
|||||||
|
|
||||||
if (Hdmi1VideoSyncFeedback != null)
|
if (Hdmi1VideoSyncFeedback != null)
|
||||||
{
|
{
|
||||||
Hdmi1VideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input1VideoSyncStatus]);
|
Hdmi1VideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input1VideoSyncStatus.JoinNumber]);
|
||||||
}
|
}
|
||||||
if (Hdmi2VideoSyncFeedback != null)
|
if (Hdmi2VideoSyncFeedback != null)
|
||||||
{
|
{
|
||||||
Hdmi2VideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input2VideoSyncStatus]);
|
Hdmi2VideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input2VideoSyncStatus.JoinNumber]);
|
||||||
}
|
}
|
||||||
if (DisplayPortVideoSyncFeedback != null)
|
if (DisplayPortVideoSyncFeedback != null)
|
||||||
{
|
{
|
||||||
DisplayPortVideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input3VideoSyncStatus]);
|
DisplayPortVideoSyncFeedback.LinkInputSig(trilist.BooleanInput[joinMap.Input3VideoSyncStatus.JoinNumber]);
|
||||||
}
|
}
|
||||||
|
|
||||||
LinkDmTxToApi(this, trilist, joinMap, bridge);
|
LinkDmTxToApi(this, trilist, joinMap, bridge);
|
||||||
|
|||||||
@@ -171,10 +171,8 @@ namespace PepperDash.Essentials.DM
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected DmTxControllerJoinMap GetDmTxJoinMap(uint joinStart, string joinMapKey)
|
||||||
protected void LinkDmTxToApi(DmTxControllerBase tx, BasicTriList trilist, uint joinStart, string joinMapKey,
|
{
|
||||||
EiscApiAdvanced bridge)
|
|
||||||
{
|
|
||||||
var joinMap = new DmTxControllerJoinMap(joinStart);
|
var joinMap = new DmTxControllerJoinMap(joinStart);
|
||||||
|
|
||||||
var joinMapSerialized = JoinMapHelper.GetSerializedJoinMapForDevice(joinMapKey);
|
var joinMapSerialized = JoinMapHelper.GetSerializedJoinMapForDevice(joinMapKey);
|
||||||
@@ -182,8 +180,6 @@ namespace PepperDash.Essentials.DM
|
|||||||
if (!string.IsNullOrEmpty(joinMapSerialized))
|
if (!string.IsNullOrEmpty(joinMapSerialized))
|
||||||
joinMap = JsonConvert.DeserializeObject<DmTxControllerJoinMap>(joinMapSerialized);
|
joinMap = JsonConvert.DeserializeObject<DmTxControllerJoinMap>(joinMapSerialized);
|
||||||
|
|
||||||
bridge.AddJoinMap(Key, joinMap);
|
|
||||||
|
|
||||||
return joinMap;
|
return joinMap;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user