/// <summary> /// 发送FECC /// </summary> /// <param name="key">FECC Key</param> public void StartSendFECC(FECCKey key) { var errno = PlcmProxy.SendFECCKey(this.CallHandle, key, FECCAction.START); if (errno != ErrorNumber.OK) { var errMsg = string.Format("发送FECC({0}) Start失败,errno={1}", key, errno); log.Error(errMsg); throw new Exception(errMsg); } log.Info(string.Format("发送FECC({0}) Start成功.", key)); feccKey = key; feccTimer?.Dispose(); feccTimer = new Timer() { Interval = 200 }; feccTimer.Tick += (sender, args) => { errno = PlcmProxy.SendFECCKey(this.CallHandle, feccKey, FECCAction.CONTINUE); if (errno != ErrorNumber.OK) { var errMsg = string.Format("发送FECC({0}) Continue失败,errno={1}", key, errno); log.Error(errMsg); throw new Exception(errMsg); } log.Info(string.Format("发送FECC({0}) Continue成功", key)); }; feccTimer.Start(); }
public static ErrorNumber SendFECCKey(int callhandle, FECCKey key, FECCAction action) { return((ErrorNumber)PlcmHelper.sendFECCKey(callhandle, (int)key, (int)action)); }
public static ErrorNumber SendFECCKey(int callhandle, FECCKey key, FECCAction action) { return((ErrorNumber)WrapperInterface.sendFECCKey(callhandle, (int)key, (int)action)); }