Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Video Mute feature #6

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file not shown.
Binary file modified PDT.PanasonicDisplay.EPI/PDT.PanasonicDisplay.EPI.suo
Binary file not shown.
Binary file modified PDT.PanasonicDisplay.EPI/PDT.PanasonicDisplay.projectinfo
Binary file not shown.
21 changes: 11 additions & 10 deletions PDT.PanasonicDisplay.EPI/PanasonicDisplay.cs
Original file line number Diff line number Diff line change
Expand Up @@ -94,10 +94,10 @@ public class PanasonicDisplay : TwoWayDisplayBase, IBasicVolumeWithFeedback, ICo
public const string SelectIrCmd = "";
public const string ExitIrCmd = "";

public const string VideoMuteOnCmd = "\02VMT:1\03";
public const string VideoMuteOffCmd = "\02VMT:0\03";
public const string VideoMuteOnCmd = "\x02VMT:1\x03";
public const string VideoMuteOffCmd = "\x02VMT:0\x03";
public const string VideoMutePartialCmd = "\x02VMT:";
public const string VideoMutePoll = "\02QVM\03";
public const string VideoMutePoll = "\x02QVM\x03";

public const string PollInput = "\x02QMI\x03";
#endregion
Expand All @@ -118,7 +118,7 @@ public bool VideoIsMuted
set
{
_VideoIsMuted = value;

VideoIsMutedFeedback.FireUpdate();
}
}
public BoolFeedback VideoIsMutedFeedback;
Expand Down Expand Up @@ -215,7 +215,7 @@ void Port_LineReceived(object dev, GenericCommMethodReceiveTextArgs args)
{
if (Debug.Level == 2)
Debug.Console(2, this, "Received: '{0}'", ComTextHelper.GetEscapedText(args.Text));
char[] trimChars = { '\x02', '\x03' };
char[] trimChars = { '\x02', '\x03' }; //QVM:0
var FB = args.Text.Trim(trimChars);
Debug.Console(2, this, "Received cmd: '{0}'", FB);
switch (FB)
Expand Down Expand Up @@ -288,12 +288,12 @@ void Port_LineReceived(object dev, GenericCommMethodReceiveTextArgs args)
}
case "QVM:1":
{
VideoIsMuted = true;
VideoIsMuted = true;
break;
}
case "QVM:0":
{
VideoIsMuted = false;
VideoIsMuted = false;
break;
}
}
Expand Down Expand Up @@ -658,14 +658,15 @@ public void LinkToApi(BasicTriList trilist, uint joinStart, string joinMapKey, E

PowerIsOnFeedback.LinkInputSig(trilist.BooleanInput[joinMap.PowerOn.JoinNumber]);

int count = 1;
int count = 0;
var displayBase = this as PepperDash.Essentials.Core.DisplayBase;
foreach (var input in InputPorts)
{
//displayDevice.InputKeys.Add(input.Key.ToString());
//var tempKey = InputKeys.ElementAt(count - 1);
trilist.SetSigTrueAction((ushort)(joinMap.InputSelectOffset.JoinNumber + count), () => { ExecuteSwitch(InputPorts[input.Key.ToString()].Selector); });
Debug.Console(2, this, "Setting Input Select Action on Digital Join {0} to Input: {1}", joinMap.InputSelectOffset.JoinNumber + count, InputPorts[input.Key.ToString()].Key.ToString());
var port = InputPorts[input.Key.ToString()];
trilist.SetSigTrueAction((ushort)(joinMap.InputSelectOffset.JoinNumber + count), () => { ExecuteSwitch(port.Selector); });
Debug.Console(2, this, "Setting Input Select Action on Digital Join {0} to Input: {1}", joinMap.InputSelectOffset.JoinNumber + count, port.Key.ToString());
trilist.StringInput[(ushort)(joinMap.InputNamesOffset.JoinNumber + count)].StringValue = input.Key.ToString();
count++;
}
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.
Loading