Workplan Executable Object

The executable objects describe a STEP-NC process. A process is composed of a nested series of executables. Each object has a type field that identifies the kind of executable the object represents. The values are:

The full set of object fields are as follows:

{
  'id': 	string,
  'name': 	string,
  'type': 	string,
  'baseTime': 	double,
  'timeUnits': 	string,
  'distance': 	double,
  'distanceUnits': string,
  'setupID': 	int,
  'asIs': 	workpieceref,
  'toBe': 	workpieceref,
  'delta': 	workpieceref,
  'children': 	Executable[],
  'enabled':  	bool
}

// When type === "workingstep", there will be additional properties:
{
  tool: 	string,
  feedRate: 	double,
  feedUnits: 	string,
  speed: 	double,
  speedUnits:	string,
  color:	double[3]
}
Property Type Description
id string The unique identifier for the Executable.
name string The executable’s name, if any.
type string The specific type of the executable. The type string will be one of "Nc Function", "workingstep", "selective", "workplan", or "workplan-setup". The leaf nodes of the executable tree are of type "Nc Function" or "workingstep"
baseTime double The expected amount of time to complete this operation (and its children, if any).
timeUnits string The unit of baseTime. Usually Seconds?
distance double The total length the tool moves in this operation (and its children, if any).
distanceUnits string The name of the units the distance property is measured in.
setupID int The ID of the enclosing workplan with setup that this executable is in. (The setup endpoint just returns the setup ID. This should become a UUID by the time a proper setup endpoint is made.)
asIs workpieceref A reference to the As Is (Initial) workpiece for this executable
toBe workpieceref A reference to the To Be (Final) workpiece for this executable
delta workpieceref A reference to the delta (Removed) workpiece for this executable
children Executable[] An array of Executables beneath this one in the workplan.
enabled bool Whether or not this Executable is Enabled. If false, all children should also be disabled.

When type === "workingstep"

tool string The ID for the tool this workingstep uses. See Tool Endpoint.
feedRate double The rate which the tool moves for this workingstep.
feedUnits string The unit feedRate is in.
speed double The spindle speed for this workingstep.
speedUnits string The unit speed is in.
color double[3] The RGB color assigned to the workingstep for identifying faces machined by that step. The color is represented as three values using (0..1) ranges.

Example Process

The sample data below describes a workplan named "Operation 1" with three workingsteps named "WS 1", "WS 2", and "WS 3".

{
  "id": 86957,
  "name": "Operation 1",
  "baseTime": 296.9719054465057,
  "timeUnits": "second",
  "distance": 55130.487150696106,
  "distanceUnits": "mm",
  "setupID": 0,
  "asIs": { "id": 8373, "inherited": true },
  "toBe": { "id": 8052, "inherited": true },
  "delta": null,
  "children": [
    {
      "id": 84140,
      "name": "WS 1",
      "baseTime": 31.842456700803915,
      "timeUnits": "second",
      "distance": 6048.203187781216,
      "distanceUnits": "mm",
      "setupID": 0,
      "asIs": { "id": 8373, "inherited": true },
      "toBe": { "id": 8052, "inherited": true },
      "delta": null,
      "enabled": true,
      "type": "workingstep",
      "tool": 85473,
      "feedRate": 8355.9,
      "feedUnits": "mm/min",
      "speed": -7958,
      "speedUnits": "rpm",
      "color": [0.250980, 0.250980, 0.250980]
    },
    {
      "id": 84154,
      "name": "WS 2",
      "baseTime": 0.7953522517506468,
      "timeUnits": "second",
      "distance": 304.9935507459534,
      "distanceUnits": "mm",
      "setupID": 0,
      "asIs": { "id": 87198, "inherited": false },
      "toBe": { "id": 8052, "inherited": true },
      "delta": null,
      "enabled": true,
      "type": "workingstep",
      "tool": 85473,
      "feedRate": 8355.9,
      "feedUnits": "mm/min",
      "speed": -7958,
      "speedUnits": "rpm",
      "color": [0.250980, 0.250980, 0.250980]
    },
    {
      "id": 84161,
      "name": "WS 3",
      "baseTime": 59.973562186600205,
      "timeUnits": "second",
      "distance": 11951.802248441392,
      "distanceUnits": "mm",
      "setupID": 0,
      "asIs": { "id": 87289, "inherited": false },
      "toBe": { "id": 8052, "inherited": true },
      "delta": null,
      "enabled": true,
      "type": "workingstep",
      "tool": 85473,
      "feedRate": 8355.9,
      "feedUnits": "mm/min",
      "speed": -7958,
      "speedUnits": "rpm",
      "color": [0.250980, 0.250980, 0.250980]
    }],
  "enabled": true,
  "type": "workplan"
}