--- source: kcl-lib/src/simulation_tests.rs description: Operations executed shepherds-hook-bolt.kcl --- { "public/kcl-samples/shepherds-hook-bolt/main.kcl": [ { "type": "VariableDeclaration", "name": "boltDiameter", "value": { "type": "Number", "value": 5.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 0 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "hookRadius", "value": { "type": "Number", "value": 12.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 1 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "shankLength", "value": { "type": "Number", "value": 5.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 2 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "threadedEndLength", "value": { "type": "Number", "value": 30.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 3 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "nutDistance", "value": { "type": "Number", "value": 20.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 4 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "hookStartAngle", "value": { "type": "Number", "value": 290.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 5 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "hookEndAngle", "value": { "type": "Number", "value": 150.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 6 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "approximatePitch", "value": { "type": "Number", "value": 0.75, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 7 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "threadDepth", "value": { "type": "Number", "value": 0.46004999999999996, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 8 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "innerRadius", "value": { "type": "Number", "value": 2.03995, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 9 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "boltNumberOfRevolutions", "value": { "type": "Number", "value": 40.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 10 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "hypotenuse", "value": { "type": "Number", "value": 12.770133269710945, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 11 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "side", "value": { "type": "Number", "value": 4.3676428111944245, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 12 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "shankOffset", "value": { "type": "Number", "value": 17.13777608090537, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 13 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "StdLibCall", "name": "startSketchOn", "unlabeledArg": { "value": { "type": "Plane", "artifact_id": "[uuid]" }, "sourceRange": [] }, "labeledArgs": {}, "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 15 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "GroupBegin", "group": { "type": "FunctionCall", "name": "polarToCartesian", "functionSourceRange": [], "unlabeledArg": null, "labeledArgs": { "angle": { "value": { "type": "Number", "value": 290.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "sourceRange": [] }, "radius": { "value": { "type": "Number", "value": 12.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "sourceRange": [] } } }, "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 16 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" }, { "type": "PipeBodyItem", "index": 2 }, { "type": "CallKwArg", "index": 0 } ] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "x", "value": { "type": "Number", "value": 4.104241719908028, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 14 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" }, { "type": "FunctionExpressionBody" }, { "type": "FunctionExpressionBodyItem", "index": 0 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "y", "value": { "type": "Number", "value": -11.2763114494309, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 14 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" }, { "type": "FunctionExpressionBody" }, { "type": "FunctionExpressionBodyItem", "index": 1 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "GroupEnd" }, { "type": "GroupBegin", "group": { "type": "FunctionCall", "name": "polarToCartesian", "functionSourceRange": [], "unlabeledArg": null, "labeledArgs": { "angle": { "value": { "type": "Number", "value": 150.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "sourceRange": [] }, "radius": { "value": { "type": "Number", "value": 12.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "sourceRange": [] } } }, "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 16 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" }, { "type": "PipeBodyItem", "index": 3 }, { "type": "CallKwArg", "index": 0 } ] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "x", "value": { "type": "Number", "value": -10.392304845413264, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 14 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" }, { "type": "FunctionExpressionBody" }, { "type": "FunctionExpressionBodyItem", "index": 0 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "y", "value": { "type": "Number", "value": 5.999999999999999, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "visibility": "default", "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 14 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" }, { "type": "FunctionExpressionBody" }, { "type": "FunctionExpressionBodyItem", "index": 1 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "GroupEnd" }, { "type": "StdLibCall", "name": "offsetPlane", "unlabeledArg": { "value": { "type": "Plane", "artifact_id": "[uuid]" }, "sourceRange": [] }, "labeledArgs": { "offset": { "value": { "type": "Number", "value": -22.13777608090537, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "sourceRange": [] } }, "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 17 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "StdLibCall", "name": "sweep", "unlabeledArg": { "value": { "type": "Sketch", "value": { "artifactId": "[uuid]" } }, "sourceRange": [] }, "labeledArgs": { "path": { "value": { "type": "Sketch", "value": { "artifactId": "[uuid]" } }, "sourceRange": [] }, "sectional": { "value": { "type": "Bool", "value": true }, "sourceRange": [] } }, "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 19 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "StdLibCall", "name": "startSketchOn", "unlabeledArg": { "value": { "type": "Solid", "value": { "artifactId": "[uuid]" } }, "sourceRange": [] }, "labeledArgs": { "face": { "value": { "type": "String", "value": "end" }, "sourceRange": [] } }, "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 20 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "StdLibCall", "name": "extrude", "unlabeledArg": { "value": { "type": "Sketch", "value": { "artifactId": "[uuid]" } }, "sourceRange": [] }, "labeledArgs": { "length": { "value": { "type": "Number", "value": 6.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "sourceRange": [] }, "tagEnd": { "value": { "type": "TagDeclarator", "name": "capEnd001" }, "sourceRange": [] }, "tagStart": { "value": { "type": "TagDeclarator", "name": "startTag" }, "sourceRange": [] } }, "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 22 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" }, { "type": "PipeBodyItem", "index": 0 } ] }, "sourceRange": [] }, { "type": "StdLibCall", "name": "fillet", "unlabeledArg": { "value": { "type": "Solid", "value": { "artifactId": "[uuid]" } }, "sourceRange": [] }, "labeledArgs": { "radius": { "value": { "type": "Number", "value": 1.25, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "sourceRange": [] }, "tags": { "value": { "type": "Array", "value": [ { "type": "Uuid", "value": "[uuid]" } ] }, "sourceRange": [] } }, "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 22 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" }, { "type": "PipeBodyItem", "index": 1 } ] }, "sourceRange": [] }, { "type": "StdLibCall", "name": "startSketchOn", "unlabeledArg": { "value": { "type": "Plane", "artifact_id": "[uuid]" }, "sourceRange": [] }, "labeledArgs": {}, "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 23 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] }, { "type": "StdLibCall", "name": "revolve", "unlabeledArg": { "value": { "type": "Sketch", "value": { "artifactId": "[uuid]" } }, "sourceRange": [] }, "labeledArgs": { "angle": { "value": { "type": "Number", "value": 360.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, "sourceRange": [] }, "axis": { "value": { "type": "Object", "value": { "direction": { "type": "Array", "value": [ { "type": "Number", "value": 0.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, { "type": "Number", "value": 1.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } } ] }, "origin": { "type": "Array", "value": [ { "type": "Number", "value": 0.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } }, { "type": "Number", "value": 0.0, "ty": { "type": "Default", "len": { "type": "Mm" }, "angle": { "type": "Degrees" } } } ] } } }, "sourceRange": [] } }, "nodePath": { "steps": [ { "type": "ProgramBodyItem", "index": 25 }, { "type": "VariableDeclarationDeclaration" }, { "type": "VariableDeclarationInit" } ] }, "sourceRange": [] } ], "std::appearance": [], "std::array": [], "std::math": [ { "type": "VariableDeclaration", "name": "PI", "value": { "type": "Number", "value": 3.141592653589793, "ty": { "type": "Unknown" } }, "visibility": "export", "nodePath": { "steps": [] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "E", "value": { "type": "Number", "value": 2.718281828459045, "ty": { "type": "Known", "type": "Count" } }, "visibility": "export", "nodePath": { "steps": [] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "TAU", "value": { "type": "Number", "value": 6.283185307179586, "ty": { "type": "Known", "type": "Count" } }, "visibility": "export", "nodePath": { "steps": [] }, "sourceRange": [] } ], "std::prelude": [ { "type": "VariableDeclaration", "name": "START", "value": { "type": "String", "value": "start" }, "visibility": "export", "nodePath": { "steps": [] }, "sourceRange": [] }, { "type": "VariableDeclaration", "name": "END", "value": { "type": "String", "value": "end" }, "visibility": "export", "nodePath": { "steps": [] }, "sourceRange": [] } ], "std::sketch": [], "std::solid": [], "std::sweep": [], "std::transform": [], "std::turns": [], "std::types": [], "std::units": [] }