Beispiel #1
0
 /// <summary>
 /// Specifies a specific M Code action to be performed for a encountered
 /// MCodeSet. Parameters and data are specific to the action type
 /// </summary>
 /// <param name="num">MCode Mapping Number</param>
 /// <param name="type">type of action to be performed</param>
 /// <param name="p1">parameter #1</param>
 /// <param name="p2">parameter #3</param>
 /// <param name="p3">parameter #3</param>
 /// <param name="p4">parameter #4</param>
 /// <param name="p5">parameter #5</param>
 /// <param name="data">string parameter - typically a file name</param>
 public void SetMCodeAction(int num, MCODE_TYPE type,
                            double p1, double p2, double p3, double p4, double p5, string data)
 {
     _Controller.CoordMotion.Interpreter.SetMcodeAction(num, type, p1, p2, p3, p4, p5, data);
 }
Beispiel #2
0
 /// <summary>
 /// Sets an MCode Action definition
 /// </summary>
 /// <param name="index">mcode ex(M6 = 6)</param>
 /// <param name="type">MCODE_TYPE for this action</param>
 /// <param name="val1">double param 1 for action</param>
 /// <param name="val2">double param 2 for action</param>
 /// <param name="val3">double param 3 for action</param>
 /// <param name="val4">double param 4 for action</param>
 /// <param name="val5">double param 5 for action</param>
 /// <param name="name">mcode name</param>
 public void SetMcodeAction(int index, MCODE_TYPE type, double val1, double val2, double val3, double val4, double val5, string name)
 {
     try
     {
         KM_dotnet_Interop_GCodeInterpreter_Set_M_CodeAction(_InstanceHandle, index, (int)type, val1, val2, val3, val4, val5, name);
     }
     catch (DllNotFoundException e)
     {
         throw new DMException(this, e, String.Format("Dll Not Found Exception thrown :  Caller - [{0}] :: Member - [{1}]",
             this.ToString(), "SetMcodeAction"));
     }
     catch (EntryPointNotFoundException e)
     {
         throw new DMException(this, e, String.Format("Entry Point Not Found Exception thrown :  Caller - [{0}] :: Member - [{1}]",
            this.ToString(), "SetMcodeAction"));
     }
     catch (Exception e)
     {
         throw new DMException(this, e, String.Format("General Exception thrown :  Caller - [{0}] :: Member - [{1}]",
           this.ToString(), "SetMcodeAction"));
     }
 }
Beispiel #3
0
 /// <summary>
 /// Gets an MCode Action definition
 /// </summary>
 /// <param name="index">mcode ex(M6 = 6)</param>
 /// <param name="type">MCODE_TYPE for this action</param>
 /// <param name="val1">double param 1 for action</param>
 /// <param name="val2">double param 2 for action</param>
 /// <param name="val3">double param 3 for action</param>
 /// <param name="val4">double param 4 for action</param>
 /// <param name="val5">double param 5 for action</param>
 /// <param name="name">mcode name</param>
 public void GetMcodeAction(int index, ref MCODE_TYPE type, ref double val1, ref  double val2, ref  double val3, ref double val4, ref  double val5, ref  string name)
 {
     try
     {
         int mcodetype = 0;
         KM_dotnet_Interop_GCodeInterpreter_Get_M_CodeAction(_InstanceHandle, index, ref mcodetype, ref val1, ref val2, ref val3, ref  val4, ref val5, ref name);
         type = (MCODE_TYPE)mcodetype;
     }
     catch (DllNotFoundException e)
     {
         throw new DMException(this, e, String.Format("Dll Not Found Exception thrown :  Caller - [{0}] :: Member - [{1}]",
             this.ToString(), "GetMcodeAction"));
     }
     catch (EntryPointNotFoundException e)
     {
         throw new DMException(this, e, String.Format("Entry Point Not Found Exception thrown :  Caller - [{0}] :: Member - [{1}]",
            this.ToString(), "GetMcodeAction"));
     }
     catch (Exception e)
     {
         throw new DMException(this, e, String.Format("General Exception thrown :  Caller - [{0}] :: Member - [{1}]",
           this.ToString(), "GetMcodeAction"));
     }
 }
Beispiel #4
0
 /// <summary>
 /// Specifies a specific M Code action to be performed for a encountered
 /// MCodeSet. Parameters and data are specific to the action type
 /// </summary>
 /// <param name="num">MCode Mapping Number</param>
 /// <param name="type">type of action to be performed</param>
 /// <param name="p1">parameter #1</param>
 /// <param name="p2">parameter #3</param>
 /// <param name="p3">parameter #3</param>
 /// <param name="p4">parameter #4</param>
 /// <param name="p5">parameter #5</param>
 /// <param name="data">string parameter - typically a file name</param>
 public void SetMCodeAction(int num, MCODE_TYPE type, 
     double p1, double p2, double p3, double p4, double p5, string data)
 {
     _Controller.CoordMotion.Interpreter.SetMcodeAction(num, type, p1, p2, p3, p4, p5, data);
 }