예제 #1
0
 public string Action(string actionName, string actionParameters)
 {
     if (MyDriverType == 0)
     {
         return(MySSFocuser.Action(actionName, actionParameters));
     }
     else
     {
         LogMessage("", "Action {0}, parameters {1} not implemented", actionName, actionParameters);
         throw new ASCOM.ActionNotImplementedException("Action " + actionName + " is not implemented by this driver");
     }
 }
예제 #2
0
파일: Form1.cs 프로젝트: mtodman/EasyFocus
 private void SetUIState()
 {
     buttonConnect.Enabled = !string.IsNullOrEmpty(Properties.Settings.Default.DriverId);
     buttonChoose.Enabled  = !IsConnected;
     buttonConnect.Text    = IsConnected ? "Disconnect" : "Connect";
     if (IsConnected)
     {
         textCurrentPos.Text = driver.Position.ToString();
         textMaxPos.Text     = driver.MaxStep.ToString();
         textMinPos.Text     = driver.Action("MinStep", "Get");
     }
 }