+
+
+
+
+Class RuntimeApi
+
+
+
+
- Namespace
- Hi.MachiningProcs
+
- Assembly
- HiNc.dll
+
+
+
+
+
+
+
public class RuntimeApi : ICsScriptApi
+
+
+
+
+
+
+ - Inheritance
+ -
+
+
RuntimeApi
+
+
+
+
+ - Implements
+ -
+
+
+
+
+
+
+ - Inherited Members
+ -
+
+
+
+
+
+
+
+
+
+
+ - Extension Methods
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Constructors
+
+
+
+
+
+
+ RuntimeApi(IMachiningProjectGetter)
+
+
+
+ Initializes a new instance.
+
+
+
+
+
public RuntimeApi(IMachiningProjectGetter machiningProjectGetter)
+
+
+ Parameters
+
+ machiningProjectGetter
IMachiningProjectGetter
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Properties
+
+
+
+
+
+
+ DiffVisualRadius_mm
+
+
+
+ Gets or sets the visual radius in millimeters for difference visualization.
+Controls the radius used for highlighting differences between workpiece states.
+
+
+
+
+
[JsAce]
+public double DiffVisualRadius_mm { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - double
+
+
+
+
+
+
+
+
+
+
+
+
+
+ DispCacheMb
+
+
+
+ Gets or sets the display cache size in megabytes.
+
+
+
+
+
public long DispCacheMb { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - long
+
+
+
+
+
+
+
+
+
+
+
+
+
+ DispCache_Mb
+
+
+
+ Gets or sets the display cache size in megabytes.
+
+
+
+
+
[JsAce]
+public long DispCache_Mb { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - long
+
+
+
+
+
+
+
+
+
+
+
+
+
+ EnableAutoMapOnSelectionEnd
+
+
+
+ Gets or sets whether to automatically map selections when they end.
+
+
+
+
+
[JsAce]
+public bool EnableAutoMapOnSelectionEnd { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - bool
+
+
+
+
+
+
+
+
+
+
+
+
+
+ EnableCollisionDetection
+
+
+
+ Gets or sets whether collision detection is enabled.
+
+
+
+
+
[JsAce(DocContentHtml = "Enable Collision Detection.")]
+public bool EnableCollisionDetection { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - bool
+
+
+
+
+
+
+
+
+
+
+
+
+
+ EnablePauseOnCollision
+
+
+
+ Obsoleted.
+
Gets or sets whether to pause execution when a collision is detected.
+This property only has an effect if collision detection is enabled.
+
+
+
+
+
public bool EnablePauseOnCollision { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - bool
+
+
+
+
+
+
+
+
+
+
+
+
+
+ EnablePauseOnFailure
+
+
+
+
+
+
+
+
[JsAce(DocContentHtml = "Enable Pause On Failure.")]
+public bool EnablePauseOnFailure { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - bool
+
+
+
+
+
+
+
+
+
+
+
+
+
+ EnablePhysics
+
+
+
+ Gets or sets whether milling force evaluation is enabled.
+
+
+
+
+
[JsAce(DocContentHtml = "Enable milling force evaluation.")]
+public bool EnablePhysics { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - bool
+
+
+
+
+
+
+
+
+
+
+
+
+
+ EnableWearEffect
+
+
+
+ Gets or sets whether tool wear effects are enabled in simulation.
+
+
+
+
+
[JsAce]
+public bool EnableWearEffect { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - bool
+
+
+
+
+
+
+
+
+
+
+
+
+
+ FeedPerCycle
+
+
+
+ Gets a new feed per cycle machining motion resolution instance.
+
+
+
+
+
[JsAce]
+public FeedPerCycleMachiningMotionResolution FeedPerCycle { get; }
+
+
+
+
+
+
+ Property Value
+
+ - FeedPerCycleMachiningMotionResolution
+
+
+
+
+
+
+
+
+
+
+
+
+
+ FeedPerTooth
+
+
+
+ Gets a new feed per tooth machining motion resolution instance.
+
+
+
+
+
[JsAce]
+public FeedPerToothMachiningMotionResolution FeedPerTooth { get; }
+
+
+
+
+
+
+ Property Value
+
+ - FeedPerToothMachiningMotionResolution
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Global
+
+
+
+
+
+
+
+
[JsAce("Global[$1key]")]
+public Dictionary<object, object> Global { get; }
+
+
+
+
+
+
+ Property Value
+
+ - Dictionary<object, object>
+
+
+
+
+
+
+
+
+
+
+
+
+
+ InitSpindleTemperature_C
+
+
+
+ Gets or sets the initial spindle temperature in degrees Celsius.
+
+
+
+
+
[JsAce(DocContentHtml = "Spindle Temperature on initialization.")]
+public double InitSpindleTemperature_C { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - double
+
+
+
+
+
+
+
+
+
+
+
+
+
+ JsAceCompletionProfileJsonArray
+
+
+
+
+
+
+
+
public static JsonArray JsAceCompletionProfileJsonArray { get; }
+
+
+
+
+
+
+ Property Value
+
+ - JsonArray
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MachiningMotionResolution
+
+
+
+ Gets or sets the machining motion resolution.
+
+
+
+
+
[JsAce]
+public IMachiningMotionResolution MachiningMotionResolution { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - IMachiningMotionResolution
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MachiningResolution
+
+
+
+ Gets or sets the machining resolution in millimeters.
+For legacy compatable.
+
+
+
+
+
[JsAce]
+[Obsolete]
+public double MachiningResolution { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - double
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MachiningResolution_mm
+
+
+
+ Gets or sets the machining resolution in millimeters.
+
+
+
+
+
[JsAce]
+public double MachiningResolution_mm { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - double
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MachiningSession
+
+
+
+
+
+
+
+
public MachiningSession MachiningSession { get; }
+
+
+
+
+
+
+ Property Value
+
+ - MachiningSession
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MapTask
+
+
+
+ Task tracking the status of mapping operations.
+
+
+
+
+
public Task MapTask { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - Task
+
+
+
+
+
+
+
+
+
+
+
+
+
+ MillingForceCycleDivisionNum
+
+
+
+
+
+
+
+
[JsAce]
+public static int MillingForceCycleDivisionNum { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - int
+
+
+
+
+
+
+
+
+
+
+
+
+
+ NcOptOption
+
+
+
+
+
+
+
+
[JsAce]
+public NcOptOption NcOptOption { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - NcOptOption
+
+
+
+
+
+
+
+
+
+
+
+
+
+ OptEnableDepthCompensation
+
+
+
+ Enables or disables depth compensation during optimization.
+
+
+
+
+
[JsAce]
+public bool OptEnableDepthCompensation { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - bool
+
+
+
+
+
+
+
+
+
+
+
+
+
+ OptEnableFeedrate
+
+
+
+ Gets or sets whether to enable feed rate optimization in NC optimization.
+
+
+
+
+
[JsAce]
+public bool OptEnableFeedrate { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - bool
+
+
+
+
+
+
+
+
+
+
+
+
+
+ OptEnableForwardCompensation
+
+
+
+ Enables or disables forward compensation during optimization.
+
+
+
+
+
[JsAce]
+public bool OptEnableForwardCompensation { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - bool
+
+
+
+
+
+
+
+
+
+
+
+
+
+ OptEnableInterpolation
+
+
+
+ Enables or disables reinterpolation for optimization.
+
+
+
+
+
[JsAce]
+public bool OptEnableInterpolation { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - bool
+
+
+
+
+
+
+
+
+
+
+
+
+
+ OptEnableSideCompensation
+
+
+
+ Enables or disables side compensation during optimization.
+
+
+
+
+
[JsAce]
+public bool OptEnableSideCompensation { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - bool
+
+
+
+
+
+
+
+
+
+
+
+
+
+ OptExtendedPostDistance_mm
+
+
+
+ Gets or sets the extended post-distance in millimeters for NC optimization.
+This is the distance after the current segment that will be considered for optimization.
+
+
+
+
+
[JsAce]
+public double OptExtendedPostDistance_mm { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - double
+
+
+
+
+
+
+
+
+
+
+
+
+
+ OptExtendedPreDistance_mm
+
+
+
+ Gets or sets the extended pre-distance in millimeters for NC optimization.
+This is the distance before the current segment that will be considered for optimization.
+
+
+
+
+
[JsAce]
+public double OptExtendedPreDistance_mm { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - double
+
+
+
+
+
+
+
+
+
+
+
+
+
+ OptMaxAcceleration_mmds2
+
+
+
+ Maximum acceleration in mm/s² during optimization. Only takes effect on reinterpolated section.
+
+
+
+
+
[JsAce(DocContentHtml = "Only take effect on reinterpolated section.")]
+public double OptMaxAcceleration_mmds2 { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - double
+
+
+
+
+
+
+
+
+
+
+
+
+
+ OptMaxFeedrate_mmdmin
+
+
+
+ Maximum feed rate in mm/min for cutting movements during optimization.
+
+
+
+
+
[JsAce]
+public double OptMaxFeedrate_mmdmin { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - double
+
+
+
+
+
+
+
+
+
+
+
+
+
+ OptMaxJerk_mmds3
+
+
+
+ Maximum jerk in mm/s³ during optimization. Only takes effect on reinterpolated section.
+
+
+
+
+
[JsAce(DocContentHtml = "Only take effect on reinterpolated section.")]
+public double OptMaxJerk_mmds3 { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - double
+
+
+
+
+
+
+
+
+
+
+
+
+
+ OptMinFeedrate_mmdmin
+
+
+
+ Minimum feed rate in mm/min for cutting movements during optimization.
+
+
+
+
+
[JsAce]
+public double OptMinFeedrate_mmdmin { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - double
+
+
+
+
+
+
+
+
+
+
+
+
+
+ OptPreferedForce_N
+
+
+
+ Preferred force in N for optimization.
+
+
+
+
+
[JsAce]
+public double OptPreferedForce_N { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - double
+
+
+
+
+
+
+
+
+
+
+
+
+
+ OptRapidFeed_mmdmin
+
+
+
+ Rapid feed rate in mm/min for non-cutting movements during optimization.
+
+
+
+
+
[JsAce]
+public double OptRapidFeed_mmdmin { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - double
+
+
+
+
+
+
+
+
+
+
+
+
+
+ OptSpindlePowerSafetyFactor
+
+
+
+ Safety factor for spindle power during optimization.
+
+
+
+
+
[JsAce]
+public double OptSpindlePowerSafetyFactor { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - double
+
+
+
+
+
+
+
+
+
+
+
+
+
+ OptSpindleTorqueSafetyFactor
+
+
+
+ Safety factor for spindle torque during optimization.
+
+
+
+
+
[JsAce]
+public double OptSpindleTorqueSafetyFactor { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - double
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ParaTemplateDimension
+
+
+
+
+
+
+
+
[JsAce]
+public int ParaTemplateDimension { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - int
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ScriptOptions
+
+
+
+
+
+
+
+
public ScriptOptions ScriptOptions { get; set; }
+
+
+
+
+
+
+ Property Value
+
+ - ScriptOptions
+
+
+
+
+
+
+
+
+
+
+
+
+
+ SessionMessageHost
+
+
+
+
+
+
+
+
[JsAce]
+public SessionMessageHost SessionMessageHost { get; }
+
+
+
+
+
+
+ Property Value
+
+ - SessionMessageHost
+
+
+
+
+
+
+
+
+
+
+
+
+
+ StepCount
+
+
+
+ Gets the total number of milling steps.
+
+
+
+
+
[JsAce]
+public int StepCount { get; }
+
+
+
+
+
+
+ Property Value
+
+ - int
+
+
+
+
+
+
+
+
+
+
+ Methods
+
+
+
+
+
+
+ AddTimeDataByFile(string, string, double, double)
+
+
+
+ Adds time-based data from a file to the time mapping dictionary with specified time bounds in seconds.
+
+
+
+
+
[JsAce("AddTimeDataByFile($1key, $2relFile, $3beginTime, $4endTime)")]
+public bool AddTimeDataByFile(string key, string relFile, double beginTime, double endTime)
+
+
+ Parameters
+
+ key
string
+ Key to identify the data
+
+ relFile
string
+ Relative path to the data file
+
+ beginTime
double
+ Beginning time in seconds
+
+ endTime
double
+ Ending time in seconds
+
+
+
+ Returns
+
+ - bool
+ True if the data was successfully added, false otherwise
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ AddTimeDataByFile(string, string, string, string)
+
+
+
+ Adds time-based data from a file to the time mapping dictionary with specified time bounds.
+
+
+
+
+
[JsAce("AddTimeDataByFile($1key, $2relFile, $3beginTime, $4endTime)")]
+public bool AddTimeDataByFile(string key, string relFile, string beginTimeText, string endTimeText)
+
+
+ Parameters
+
+ key
string
+ Key to identify the data
+
+ relFile
string
+ Relative path to the data file
+
+ beginTimeText
string
+ Beginning time as text (seconds or TimeSpan format)
+
+ endTimeText
string
+ Ending time as text (seconds or TimeSpan format)
+
+
+
+ Returns
+
+ - bool
+ True if the data was successfully added, false otherwise
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ AppendMessagesToFile(string, params string[])
+
+
+
+ Appends messages to a file, optionally filtered by tags.
+
+
+
+
+
[JsAce("AppendMessagesToFile(\"dstRelFile\",flags)")]
+public void AppendMessagesToFile(string dstRelFile, params string[] flags)
+
+
+ Parameters
+
+ dstRelFile
string
+ Destination relative file path
+
+ flags
string[]
+ Optional flags to filter messages by tags
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ BeginPreserve()
+
+
+
+ Begin Preserve section in optimzation process.
+
+
+
+
+
[JsAce("BeginPreserve()")]
+public void BeginPreserve()
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ BeginSelection(string, AnchorMode, IStepShift)
+
+
+
+ Begin mark on current line.
+milling step() has not triggered yet.
+
+
+
+
+
public void BeginSelection(string key, AnchorMode anchorMode = AnchorMode.LineBegin, IStepShift shift = null)
+
+
+ Parameters
+
+ key
string
+ Identifier key for the selection
+
+ anchorMode
AnchorMode
+ Mode for anchoring the beginning of selection
+
+ shift
IStepShift
+ Step shift to apply
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ BeginSession()
+
+
+
+
+
+
+
+
public void BeginSession()
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ClearTimeMappingData()
+
+
+
+ Clears all time mapping data.
+
+
+
+
+
[JsAce]
+public void ClearTimeMappingData()
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Diff(double)
+
+
+
+ Performs a difference analysis on the workpiece geometry to detect variations.
+
+
+
+
+
[JsAce("Diff($1detectionRadius_mm)")]
+public void Diff(double detectionRadius_mm)
+
+
+ Parameters
+
+ detectionRadius_mm
double
+ Radius for detecting differences
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ EndPreserve()
+
+
+
+ End Preserve section in optimzation process.
+
+
+
+
+
[JsAce("EndPreserve()")]
+public void EndPreserve()
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ EndSelection(string, AnchorMode, IStepShift)
+
+
+
+ End mark on current line for selection.
+
+
+
+
+
public void EndSelection(string key, AnchorMode anchorMode = AnchorMode.LineEnd, IStepShift shift = null)
+
+
+ Parameters
+
+ key
string
+ Identifier key for the selection
+
+ anchorMode
AnchorMode
+ Mode for anchoring the end of selection
+
+ shift
IStepShift
+ Step shift to apply
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ EndSession()
+
+
+
+
+
+
+
+
public void EndSession()
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ErrorMessage(string)
+
+
+
+ Displays an error message in the message host.
+
+
+
+
+
[JsAce("ErrorMessage($1message)")]
+public void ErrorMessage(string message)
+
+
+ Parameters
+
+ message
string
+ The error message to display
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ FixedPace(double, double)
+
+
+
+ Creates a fixed machining motion resolution with specified parameters.
+
+
+
+
+
[JsAce("FixedPace($1linearResolution_mm, $2rotaryResolution_deg)")]
+public FixedMachiningMotionResolution FixedPace(double linearResolution_mm, double rotaryResolution_deg)
+
+
+ Parameters
+
+ linearResolution_mm
double
+ Linear resolution in millimeters
+
+ rotaryResolution_deg
double
+ Rotary resolution in degrees
+
+
+
+ Returns
+
+ - FixedMachiningMotionResolution
+ A new fixed machining motion resolution instance
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ GetMillingStep(int)
+
+
+
+ Retrieves a milling step at the specified index.
+
+
+
+
+
[JsAce(Snippet = "GetMillingStep($1\"stepIndex\")")]
+public MachiningStep GetMillingStep(int stepIndex)
+
+
+ Parameters
+
+ stepIndex
int
+ Index of the milling step to retrieve
+
+
+
+ Returns
+
+ - MachiningStep
+ The milling step at the specified index
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Gets the observation height in millimeters for the specified stick machining tool.
+
+
+
+
+
[JsAce("GetStickMachiningToolObservationHeight_mm($1toolId)")]
+public double GetStickMachiningToolObservationHeight_mm(int toolId)
+
+
+ Parameters
+
+ toolId
int
+ The ID of the tool
+
+
+
+ Returns
+
+ - double
+ The observation height in millimeters
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Gets the shift angle in degrees for the uniform contour tray of the specified tool.
+
+
+
+
+
[JsAce("GetUniformContourTrayShiftAngle_deg($1toolId)")]
+public double GetUniformContourTrayShiftAngle_deg(int toolId)
+
+
+ Parameters
+
+ toolId
int
+ The ID of the tool
+
+
+
+ Returns
+
+ - double
+ The shift angle in degrees
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ LineSelection(string, AnchorMode, IStepShift, AnchorMode, IStepShift)
+
+
+
+ Create a line selection from begin to end mark.
+
+
+
+
+
public void LineSelection(string key, AnchorMode beginAnchorMode = AnchorMode.LineBegin, IStepShift beginShift = null, AnchorMode endAnchorMode = AnchorMode.LineEnd, IStepShift endShift = null)
+
+
+ Parameters
+
+ key
string
+ Identifier key for the selection
+
+ beginAnchorMode
AnchorMode
+ Mode for anchoring the beginning of selection
+
+ beginShift
IStepShift
+ Step shift to apply at beginning
+
+ endAnchorMode
AnchorMode
+ Mode for anchoring the end of selection
+
+ endShift
IStepShift
+ Step shift to apply at end
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Map(string, FileTimeSection, CycleSamplingMode?)
+
+
+
+ Maps selection data to time section.
+
+
+
+
+
public Task Map(string key, FileTimeSection fileTimeSection = null, StepTimeShotUtil.CycleSamplingMode? cycleSamplingMode = CycleSamplingMode.SpindleCycle)
+
+
+ Parameters
+
+ key
string
+ Identifier key for the selection
+
+ fileTimeSection
FileTimeSection
+ File time section, or null to use the one associated with the key
+
+ cycleSamplingMode
StepTimeShotUtil.CycleSamplingMode?
+ Cycle sampling mode
+
+
+
+ Returns
+
+ - Task
+ Task representing the asynchronous mapping operation
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Message(string)
+
+
+
+ Displays a message in the message host.
+
+
+
+
+
[JsAce("Message($1message)")]
+public void Message(string message)
+
+
+ Parameters
+
+ message
string
+ The message to display
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ OptimizeToFiles(string)
+
+
+
+ Optimizes NC files and saves results using the specified file template.
+
+
+
+
+
[JsAce(Snippet = "OptimizeToFiles(\"Output/Opt-[NcName]\")", DocContentHtml = "Optimize To Files by substitude template keywoard \"[NcName]\"")]
+public void OptimizeToFiles(string relFileTemplate = "Output/Opt-[NcName]")
+
+
+ Parameters
+
+ relFileTemplate
string
+ Template for output file path, can include [NcName] placeholder
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Pace()
+
+
+
+ Controls the pace of machining operations during execution.
+
+
+
+
+
[JsAce("Pace();")]
+public void Pace()
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Pause()
+
+
+
+
+
+
+
+
[JsAce(DocContentHtml = "Pause Player")]
+public void Pause()
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ PlayAct(IAct, ISourceCommand, CancellationToken?)
+
+
+
+
+
+
+
+
[JsAce]
+public void PlayAct(IAct act, ISourceCommand sourceCommand = null, CancellationToken? cancellationToken = null)
+
+
+ Parameters
+
+ act
IAct
+
+ sourceCommand
ISourceCommand
+
+ cancellationToken
CancellationToken?
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ PlayClTeleport(double, double, double, double, double, double)
+
+
+
+
+
+
+
+
[JsAce]
+public void PlayClTeleport(double x, double y, double z, double i, double j, double k)
+
+
+ Parameters
+
+ x
double
+
+ y
double
+
+ z
double
+
+ i
double
+
+ j
double
+
+ k
double
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ PlayNc(string, string)
+
+
+
+ Plays NC code directly from a string, executing each action and pacing between them.
+
+
+
+
+
[JsAce(Snippet = "PlayNc($1\"ncCommand\",$2\"\"(Direct Command)\"\");", DocContentHtml = "Play NC. second parameter is the file name alternative shows in the log.")]
+public void PlayNc(string ncText, string fileNameAlternative = "--")
+
+
+ Parameters
+
+ ncText
string
+ NC code as a string
+
+ fileNameAlternative
string
+ Alternative name to display in logs
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ PlayNcFile(string)
+
+
+
+ Plays an NC file with the specified relative path.
+
+
+
+
+
[JsAce("PlayNcFile($1\"ncFile\");")]
+public void PlayNcFile(string relNcFilePath)
+
+
+ Parameters
+
+ relNcFilePath
string
+ Relative path to the NC file
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
[JsAce]
+public void PlayToolingTeleport(int toolId)
+
+
+ Parameters
+
+ toolId
int
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Preserve()
+
+
+
+ Preserve one line NC code in optimzation process.
+
+
+
+
+
[JsAce("Preserve()")]
+public void Preserve()
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ProgressMessage(string)
+
+
+
+ Displays a progress message in the message host.
+
+
+
+
+
[JsAce("ProgressMessage($1message)")]
+public void ProgressMessage(string message)
+
+
+ Parameters
+
+ message
string
+ The progress message to display
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ReTrainMillingPara(SampleFlag, string, double)
+
+
+
+ Re-trains milling parameters using the specified sample flag.
+
+
+
+
+
[JsAce("ReTrainMillingPara(Fx|Fy|Fz, $1dstFile)")]
+public void ReTrainMillingPara(SampleFlag sampleFlag, string dstRelFile, double outlierRatio = 2)
+
+
+ Parameters
+
+ sampleFlag
SampleFlag
+ Sample flag indicating which components to train
+
+ dstRelFile
string
+ Destination relative file path
+
+ outlierRatio
double
+ Outlier ratio for data filtering
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ReadCsvByTimeInterpolation(string)
+
+
+
+ Reads a CSV file and performs time-based interpolation to map data to milling steps.
+
+
+
+
+
[JsAce(Snippet = "ReadCsvByTimeInterpolation($1\"csvFile\")")]
+public void ReadCsvByTimeInterpolation(string csvFile)
+
+
+ Parameters
+
+ csvFile
string
+ Path to the CSV file relative to the base directory
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ReadRuntimeGeom(string)
+
+
+
+ Reads runtime geometry from a file.
+
+
+
+
+
[JsAce("ReadRuntimeGeom($1\"srcFile\")")]
+public void ReadRuntimeGeom(string relFile)
+
+
+ Parameters
+
+ relFile
string
+ Relative path to the input file
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ RegisterStepVariable(string, string, string, string, Func<MachiningStep, object>)
+
+
+
+ Registers a step variable for tracking during execution.
+
+
+
+
+
[JsAce(Snippet = "RegisterStepVariable(\"$1key\",\"$2name\",\"$3unit\",\"$4formatString\",\"$5variableFunc\")", DocContentHtml = "<p>Register Step Variable.</p> <p>\"unit\" is nullable</p> <p>\"formatString\" is nullable</p>")]
+public void RegisterStepVariable(string key, string name, string unit, string formatString, Func<MachiningStep, object> variableFunc = null)
+
+
+ Parameters
+
+ key
string
+ Unique key to identify the variable
+
+ name
string
+ Human-readable name of the variable
+
+ unit
string
+ Physical unit of the variable (can be null)
+
+ formatString
string
+ Format string for displaying the variable (can be null)
+
+ variableFunc
Func<MachiningStep, object>
+ Function to compute the variable value from a milling step (can be null)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ RemoveFlyPiece()
+
+
+
+ Removes any disconnected or “flying” pieces from the workpiece geometry.
+
+
+
+
+
[JsAce]
+public void RemoveFlyPiece()
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Reset()
+
+
+
+
+
+
+
+
[JsAce(DocContentHtml = "Reset Player")]
+public void Reset()
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ResetRuntime()
+
+
+
+ Clears internal buffers.
+
+
+
+
+
[JsAce]
+public void ResetRuntime()
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ RunNc(string, string)
+
+
+
+ Runs NC code directly from a string.
+
+
+
+
+
[JsAce(Snippet = "RunNc($1\"ncCommand\",$2\"\"(Direct Command)\"\");", DocContentHtml = "Run NC. second parameter is the file name alternative shows in the log.")]
+public IEnumerable<Action> RunNc(string ncText, string fileNameAlternative = "--")
+
+
+ Parameters
+
+ ncText
string
+ NC code as a string
+
+ fileNameAlternative
string
+ Alternative name to display in logs
+
+
+
+ Returns
+
+ - IEnumerable<Action>
+ Enumerable sequence of actions to be executed
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ RunNcFile(string)
+
+
+
+ Runs an NC file with the specified relative path.
+
+
+
+
+
[JsAce("RunNcFile($1\"ncFile\");")]
+public IEnumerable<Action> RunNcFile(string relNcFilePath)
+
+
+ Parameters
+
+ relNcFilePath
string
+ Relative path to the NC file
+
+
+
+ Returns
+
+ - IEnumerable<Action>
+ Enumerable sequence of actions to be executed
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ SetNcResolutionFeedPerCycle()
+
+
+
+ Sets NC resolution to feed per cycle mode.
+
+
+
+
+
public void SetNcResolutionFeedPerCycle()
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ SetNcResolutionFeedPerTooth()
+
+
+
+ Sets NC resolution to feed per tooth mode.
+
+
+
+
+
public void SetNcResolutionFeedPerTooth()
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ SetNcResolutionFixed(double, double)
+
+
+
+ Sets NC resolution to fixed mode with specified resolution values.
+
+
+
+
+
public void SetNcResolutionFixed(double linearResolution_mm, double rotaryResolution_deg)
+
+
+ Parameters
+
+ linearResolution_mm
double
+ Linear resolution in millimeters.
+
+ rotaryResolution_deg
double
+ Rotary resolution in degrees.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Sets the observation height in millimeters for the specified stick machining tool.
+
+
+
+
+
[JsAce("SetStickMachiningToolObservationHeight_mm($1toolId,$2height_mm)")]
+public void SetStickMachiningToolObservationHeight_mm(int toolId, double height)
+
+
+ Parameters
+
+ toolId
int
+ The ID of the tool
+
+ height
double
+ The observation height in millimeters to set
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Sets the shift angle in degrees for the uniform contour tray of the specified tool.
+
+
+
+
+
[JsAce("SetUniformContourTrayShiftAngle_deg($1toolId,$2angle_deg)")]
+public void SetUniformContourTrayShiftAngle_deg(int toolId, double angle_deg)
+
+
+ Parameters
+
+ toolId
int
+ The ID of the tool
+
+ angle_deg
double
+ The shift angle in degrees to set
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ShiftDistance_mm(double)
+
+
+
+ Creates a distance shift object representing the specified distance in millimeters.
+
+
+
+
+
public DistanceShift ShiftDistance_mm(double distanceShift_mm)
+
+
+ Parameters
+
+ distanceShift_mm
double
+ Distance shift in millimeters
+
+
+
+ Returns
+
+ - DistanceShift
+ Distance shift object
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ShiftTime_s(double)
+
+
+
+ Creates a time shift object representing the specified time in seconds.
+
+
+
+
+
public TimeShift ShiftTime_s(double seconds)
+
+
+ Parameters
+
+ seconds
double
+ Time in seconds
+
+
+
+ Returns
+
+ - TimeShift
+ Time shift object
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ TrainMillingPara(SampleFlag, string, double)
+
+
+
+ Trains milling parameters using the specified sample flag.
+
+
+
+
+
[JsAce("TrainMillingPara(Fx|Fy|Fz, $1dstFile)")]
+public void TrainMillingPara(SampleFlag sampleFlag, string dstRelFile, double outlierRatio = 2)
+
+
+ Parameters
+
+ sampleFlag
SampleFlag
+ Sample flag indicating which components to train
+
+ dstRelFile
string
+ Destination relative file path
+
+ outlierRatio
double
+ Outlier ratio for data filtering
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ WarningMessage(string)
+
+
+
+ Displays a warning message in the message host.
+
+
+
+
+
[JsAce("WarningMessage($1message)")]
+public void WarningMessage(string message)
+
+
+ Parameters
+
+ message
string
+ The warning message to display
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ WriteRuntimeGeom(string)
+
+
+
+ Writes the current runtime geometry to a file.
+
+
+
+
+
[JsAce("WriteRuntimeGeom($1\"dstFile\")")]
+public void WriteRuntimeGeom(string relFile)
+
+
+ Parameters
+
+ relFile
string
+ Relative path to the output file
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ WriteRuntimeGeomToStl(string, double)
+
+
+
+ Writes the current runtime geometry to an STL file.
+
+
+
+
+
[JsAce("WriteRuntimeGeomToStl($1\"dstFile\",$2resolution_mm)")]
+public void WriteRuntimeGeomToStl(string relFile, double resolution_mm = 0)
+
+
+ Parameters
+
+ relFile
string
+ Relative path to the output STL file
+
+ resolution_mm
double
+ Resolution in millimeters (0 for default)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ WriteShotFiles(double, string)
+
+
+
+ Writes time-series data to shot files with the specified resolution period (alternative parameter order).
+
+
+
+
+
public void WriteShotFiles(double resolutionPeroid_ms, string relFileTemplate)
+
+
+ Parameters
+
+ resolutionPeroid_ms
double
+ Resolution period in milliseconds
+
+ relFileTemplate
string
+ Template for output file path, can include [NcName] placeholder
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ WriteShotFiles(string, double)
+
+
+
+ Writes time-series data to shot files with the specified resolution period.
+
+
+
+
+
[JsAce(Snippet = "WriteShotFiles(\"Output/[NcName].shot.csv\",resolutionPeroid_ms)", DocContentHtml = "Write time series data by resolutionPeroid_ms")]
+public void WriteShotFiles(string relFileTemplate = "Output/[NcName].shot.csv", double resolutionPeroid_ms = 1)
+
+
+ Parameters
+
+ relFileTemplate
string
+ Template for output file path, can include [NcName] placeholder
+
+ resolutionPeroid_ms
double
+ Resolution period in milliseconds
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ WriteStepFiles(string)
+
+
+
+ Writes step-series data to files with the specified file template.
+
+
+
+
+
[JsAce(Snippet = "WriteStepFiles(\"Output/[NcName].step.csv\")", DocContentHtml = "Write step series data.")]
+public void WriteStepFiles(string relFileTemplate = "Output/[NcName].step.csv")
+
+
+ Parameters
+
+ relFileTemplate
string
+ Template for output file path, can include [NcName] placeholder
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Events
+
+
+
+
+
+ MachiningStepBuilt
+
+
+
+ Gets or sets the action to configure steps during execution.
+
+
+
+
+
[JsAce(Snippet = "MachiningStepBuilt+=($1preStep,$2curStep)=>{$3Command};", DocContentHtml = "Runtime Step Configuration action. preStep is the Previous Milling Step; curStep is the Current Milling Step. preStep is null if no previous step existed.")]
+public event MachiningActRunner.MachiningStepBuiltDelegate MachiningStepBuilt
+
+
+
+
+
+
+
+ Event Type
+
+ - MachiningActRunner.MachiningStepBuiltDelegate
+
+
+
+
+
+
+
+
+
+
+
+ MachiningStepSelected
+
+
+
+ Event that is triggered when a milling step is selected.
+
+
+
+
+
[JsAce(Snippet = "MachiningStepSelected+=($1millingStep)=>{$2Command};")]
+public event Action<MachiningStep> MachiningStepSelected
+
+
+
+
+
+
+
+ Event Type
+
+ - Action<MachiningStep>
+
+
+
+
+
+
+
+
+
+
+