// private void FireBvtDirectEvent(DeviceState State, Types.BVT.TestResults Result, bool IsUdsmUrsm) // { // var message = string.Format("BVT direct test state {0}", State); // // if (State == DeviceState.Success) // message = string.Format($"BVT {(IsUdsmUrsm ? "UdsmUrsm" : "")} direct test result {0} V, {1} mA", Result.VDRM, Result.IDRM); // // SystemHost.Journal.AppendLog(ComplexParts.BVT, LogMessageType.Info, message); // m_Communication.PostBVTDirectEvent(State, Result); // } // // private void FireBvtReverseEvent(DeviceState State, Types.BVT.TestResults Result, bool IsUdsmUrsm) // { // var message = string.Format("BVT reverse test state {0}", State); // // if (State == DeviceState.Success) // message = string.Format($"BVT {(IsUdsmUrsm ? "UdsmUrsm" : "")} reverse test result {0} V, {1} mA", Result.VRRM, Result.IRRM); // // SystemHost.Journal.AppendLog(ComplexParts.BVT, LogMessageType.Info, message); // m_Communication.PostBVTReverseEvent(State, Result); // } private void FireNotificationEvent(Types.BVT.HWProblemReason Problem, Types.BVT.HWWarningReason Warning, Types.BVT.HWFaultReason Fault, Types.BVT.HWDisableReason Disable) { SystemHost.Journal.AppendLog(ComplexParts.BVT, LogMessageType.Warning, string.Format( "BVT device notification: problem {0}, warning {1}, fault {2}, disable {3}", Problem, Warning, Fault, Disable)); m_Communication.PostBVTNotificationEvent(Problem, Warning, Fault, Disable); }
public void AddBvtProblemEvent(Types.BVT.HWProblemReason Problem) { m_ActionQueue.Enqueue(delegate { if (Cache.Main.mainFrame.Content.Equals(Cache.UserTest)) { Cache.UserTest.SetBvtProblem(Problem); } else { Cache.Bvt.SetProblem(Problem); } }); }
public void PostBVTNotificationEvent(Types.BVT.HWProblemReason Problem, Types.BVT.HWWarningReason Warning, Types.BVT.HWFaultReason Fault, Types.BVT.HWDisableReason Disable) { EnumerateClients(Client => Client.BVTNotificationHandler(Problem, Warning, Fault, Disable)); }
internal void SetProblem(Types.BVT.HWProblemReason Problem) { labelWarning.Content = Problem.ToString(); labelWarning.Visibility = Visibility.Visible; }