-
Global Variables - Feature Script
Can anyone offer advise on the possibility / components for / method of making a global variable using FeatureScript?
-
"Essential Mathematics for computational design" - but for Onshape?
It would be really great if there were an Onshape/Parasolid/FeatureScript version of documentation like this that exists for Rhino. It's been released as a PDF book in 4 editions over the years, and also as the linked website. Much of the math and concepts are basically the same for Onshape as for Rhino (both being 3D CAD…
-
Delete internal volume featurescripts
Hello, I am calculating buoyancy of an assembly and I am wondering if there are existing featurescripts that can help automate my process. I begin with my assembly and use Create part studio in context using the assembly origin as the origin of the new part studio. I then use Transform -> Copy in place to grab all the…
-
New FeatureScript - Point Derive
Hello all, I'm happy to release my latest FeatureScript, Point Derive. Point derive allows users to quickly derive parts into new positions in a part studio in a manner similar to @ilya_baran's Super Derive feature, but also adds powerful Point functionality. When a part is selected to be derived, any mate connectors which…
-
FeatureScript that generates a cube by specifying desired mass (carbon steel)
Hi everyone, This is my first FS ever and I developped it just for the fun of learning FS. The feature builds a cube by specifying the desired mass (in kg). The density used is for carbon steel. There is an option to center the cube on the center point in the PS. I already have improvements ideas such as: * * Units…
-
How would you design an SVG export app/script/tool?
Step 1: The user selects a number of parallel faces in the Onshape UI Step 2: ??? Step 3: Profit! (Get an SVG you can take to your CNC workflow of choice) The standard workflow recommendation for small CNCs is "Export DXF, import into Inkscape, merge the paths, re-export to SVG" but frankly that's a pain in my ass. There…
-
Having difficulties finding the "other end" of a selection of edges...
Here's the situation, I have a path that I am using to sweep a simple profile. The path can be either a spline generated by the FS or some existing edges. What I'm trying to do is (optionally) add some straight sections tangent to the ends of the path before doing the sweep. It works fine for the "start" of the path as I…
-
Coordinate/Vector input parameter
Hi! Novice featurescripter here, what's the best way to have a UI that lets you input points in comma-separated coordinate form (for now cartesian is enough)? A [bad] approach I think might work is asking for a string input, then parsing that string and converting to a vector, but that makes typechecking much harder.…
-
How to check if an edge is a straight line?
This is probably obvious but I'm struggling with figuring out if something is "straight"... I'm computing the min radius of curvature of a sweep path and got it working (I stole/repurposed the code from @NeilCooke 's cable/wire routing) but i would like to do a check first so I don't sample curvature a bunch of times if…
-
Understanding opLoft with Path Guides (and opSweep)
I am currently working on a feature that will generate a belt profile following a path that will contain sketch edges as well as 3d splines. Using the loft feature, you are able to generate a object by selecting the profile and then the guide path that forms a closed loop. I am having trouble understanding how to replicate…
-
Degree 1 bSplineSurface?
Is there a fundamental reason we can't make a degree 1 bSplineSurface? It could be handy to make some interesting faceted designs. It works in Rhino, and gives the result on the right.
-
Point Pattern (Request Update)
@cody_armstrong @TimRice I love the point pattern, but can you add functionality to ignore the seed? That way we can use an entire sketch for a 'location' without it failing overlapping faces. Rather than independently selecting each point when doing a feature or face pattern (For when this feature ever become part of the…
-
Highlight a mate connector using an entity in a table row
I'm creating mate connectors with attributes that I'll display in a table. I'd like to highlight the mate connector corresponding to the table row. I've done this with other bodies. When I select a row in the table where I've set the mate connector as the relevant entity, the mate connector doesn't respond. I can make…
-
Creating an extrusion using dimensions of face parallel to sketch plane.
Hello. I am trying to learn FS, and as a step in a larger project, I am trying to get my feature to create an extrusion with the same sketch dimensions as a face parallel to the sketch surface but I am at a loss as to how to best go about this. Do you have any suggestions? So far I have managed to create a sketch plane…
-
Ace Editor Short Cuts (including To Upper/Lower)?
I know that in general, the FeatureScript text editor is based on Ace. I also know that most of the keyboard commands work. However, some are overridden by standard Onshape things. In this case, I wanted to use the "to upper case" command (normally ctrl-U), but it triggers the contact support pop-up. Is there an official…
-
Extruding in for loop
I am working on a mortise and tendon joint in feature script. I know there is already one that exists, but it does not do exactly what I want. This also pushes me to finally learn FS. FeatureScript 543;
import(path : "onshape/std/geometry.fs", version : "543.0"); annotation { "Feature Type Name" : "MortisetAndTennon"…
-
Featurescript Wiring
Hello @jon_sorrells @Noa_Flaherty ,I´m using your Wiring Featureskript and I would like to know if I can access the automatically detected length of the cable to automatically load it into my cabling table in the drawing.