Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.

First time visiting? Here are some places to start:
  1. Looking for a certain topic? Check out the categories filter or use Search (upper right).
  2. Need support? Ask a question to our Community Support category.
  3. Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
  4. Be respectful, on topic and if you see a problem, Flag it.

If you would like to contact our Community Manager personally, feel free to send a private message or an email.

Why doesn't Onshape support sketch blocks or sketch scaling?

mogplus8mogplus8 Member Posts: 20 ✭✭
Just idle curiosity I guess. I've played with quite a few CAD packages, and most, if not all, support the concept of blocks for drawings. So why doesn't OS have this functionality? Is it on the to-do list?
Same comment for scaling sketch items. Several times I've found I wanted to create a copy of a group of sketch items, but make it a different size; 10% bigger, 25% smaller, whatever. I have not been able to discover a way of doing it. Well I have. I export the .dxf then import it into Librecad, and do the scaling and copying there. Not ideal but it's the only workaround I've found.
I'm not a power user or anything, just a hobbyist amateur. So maybe I'm missing something or just haven't explored OS deeply enough? Apologies if these are stupid questions.
One reason for this question is that I've recently acquired a laser engraver/cutter, and the software to drive it (I'm using Lightburn under Linux) can import .dxf files. Maybe OS isn't the right tool for this job and I should be using a 2D CAD package like Librecad, but I'm used to OS now and I'd prefer to do everything in OS, and it is perfectly capable of producing 2D sketches and exporting them in .dxf format. With these bits of functionality missing...

:-\

Answers

  • alnisalnis Member, Developers Posts: 452 EDU
    edited July 2021
    Generally, Onshape approaches modeling differently for 2D objects than 2D CAD packages do. Instead of repeating features in sketches, you can write a custom feature or derive components to save on design time. For scaling, you can scale a whole part at once with the transform feature, but admittedly, this doesn't work for parts within sketches.

    What sorts of things are you modeling that require sketch blocks and sketch scaling?
    Perhaps there are some other workflows that would be even more efficient. If you're doing laser cutting, here are some useful things to know:

    Laser Joint - custom feature that automates laser-cut finger joints:
    https://cad.onshape.com/documents/578830e4e4b0e65410f9c34e/v/64dbc32dae444548a578ff56/e/dfd5effddfd7f2ecce4b0246

    Auto Layout - simple layout tool for 2D cutting. Does not do nesting (uses bounding boxes of parts), but saves tons of time flattening things out:
    https://cad.onshape.com/documents/576e01dbe4b0cc2e7f46a55d/v/731e73ac0b7b1e4334f13106/e/887d6e2324589bfd2058c3e1

    Create drawing -> custom template -> no border or title block -> insert part studio filter -> select your part studio with the layout feature already run -> top view -> export as DXF -> ready to send to laser cutter!

    Here's a video I made that features more info about how to use these workflows:
    https://www.youtube.com/watch?v=YPoJ484-7tI

    Get in touch: contact@alnis.dev | My personal site: https://alnis.dev
    @alnis is my personal account. @alnis_ptc is my official PTC account.
  • mogplus8mogplus8 Member Posts: 20 ✭✭
    Hello Alnis, thanks for the very quick reply!
    My main interest is radio control model planes. I've been using Onshape for a while to create parts to print with my 3D printer (like wheel wells and servo holders), and it's brilliant for that. I've also tried printing wing ribs and fuselage formers, which works fine, but now with the laser cutter I am looking at using it to cut ribs and formers from balsa and/or ply. Bit more old school I guess, and the plastic part will always be heavier than a wood part.
    So one thing I would like to do is generate a set of wing ribs from a "root" rib and a "tip" rib, which may be different sizes and maybe different airfoils. I have found a plugin that does something similar, but it generates the intermediate ribs as 3d parts, not 2d drawings, so I can't export them as .dxfs. I've tried exporting them to a drawing and exporting the drawing as a .dxf, but that seems a bit kludgy to me, when I can directly export drawing items as .dxf without going through the intermediate step of creating a drawing.
    I also do a lot of moving around of fuselage formers too, so useful to have them as a block item. I try to set them up in order and loft between them to check that everything looks okay. I've discovered lots of interesting errors this way... Of course that means exploding the block, fixing the problem then blocking again, but in the end I think using blocks for this sort of stuff makes life a bit easier.
    I've read about featurescript, but am nowhere near competent enough to actually write one. Well, maybe a simple basic one (I was a programmer in a past life, but that was Cobol on IBM mainframes). C++ terrifies me. I'm okay with C and Python, but that's about it.
    I'm looking forward to checking out those other tools you mentioned. I have another project that they may be ideal for :-)

    Thanks again,
    Ian
  • alnisalnis Member, Developers Posts: 452 EDU
    edited July 2021
    It's always fun to help solve a problem :)

    If you already have 3D parts generated for the formers or ribs, Auto Layout should be able to get things to a state where you can make the drawing of the part studio and export to DXF.

    What I would recommend is rather than modeling formers and lofting between them to produce the body, instead try making the body as a surface loft and then modeling the formers within that body. That way, they will adapt if you need to tweak the shape rather than having to manually tweak them to get the shape you want.

    Here is one approach for that method:
    https://cad.onshape.com/documents/c0dfc369204d5486c422ba94/w/d266b880492ea06612a5418a/e/c0e89a8d475f794d3ef33108



    As for writing FeatureScript, it's not as bad as it sounds! You can make one almost entirely just by clicking the buttons to prefill blocks of code. If you're okay with C and Python, then FeatureScript should not be too bad. I would recommend looking at some simple custom features to get a sense for how they work, such as multi-plane:
    https://cad.onshape.com/documents/575857fae4b06a2590ec9d29/w/7a682d53abc1dbd6192f8299/e/5ac3fd64f34d310bc3e94a73

    Plus, the documentation is great:
    https://cad.onshape.com/FsDoc/index.html
    Get in touch: contact@alnis.dev | My personal site: https://alnis.dev
    @alnis is my personal account. @alnis_ptc is my official PTC account.
  • michael3424michael3424 Member Posts: 689 ✭✭✭✭

  • michael3424michael3424 Member Posts: 689 ✭✭✭✭

    So one thing I would like to do is generate a set of wing ribs from a "root" rib and a "tip" rib, which may be different sizes and maybe different airfoils. I have found a plugin that does something similar, but it generates the intermediate ribs as 3d parts, not 2d drawings, so I can't export them as .dxfs. I've tried exporting them to a drawing and exporting the drawing as a .dxf, but that seems a bit kludgy to me, when I can directly export drawing items as .dxf without going through the intermediate step of creating a drawing.

    I frequently use a laser to cut out flat parts designed in Onshape.  Once the part is finished just right-click on a part face and select "export as DXF/DWG..." from the resulting drop down.
  • tim_hess427tim_hess427 Member Posts: 648 ✭✭✭✭
    @ian_harris952 - One tip you may find useful is that you can select a face and then right-click to export the profile for that face as a .dxf. So, you can sketch and extrude to get your base part. Then, copy/scale as much as you want. Then, just select the faces you want to export. Hope that can help your workflow a bit. 
  • mogplus8mogplus8 Member Posts: 20 ✭✭
    @tim_hess427 thank for the tip. I didn't know that was possible. I'll definitely have a look at that. Still a bit roundabout; sketch -> part -> face -> dxf, rather than sketch -> dxf, but hey, whatever works! It's better than my solution...

    @alnis_smidchens I really like that idea! I'll definitely be trying that! Thanks.

    ;-)
  • bruce_williamsbruce_williams Member, Developers Posts: 842 EDU
    @alnis_smidchens
    great tips!
    your 'Loft Section Demo' is not public. Did you mean to make it so?
    www.accuratepattern.com
  • alnisalnis Member, Developers Posts: 452 EDU
    edited July 2021
    @bruce_williams Thanks! That's weird about the sharing. I turned the public & link sharing off and on again. Could you please try again? Thanks!
    Get in touch: contact@alnis.dev | My personal site: https://alnis.dev
    @alnis is my personal account. @alnis_ptc is my official PTC account.
  • bruce_williamsbruce_williams Member, Developers Posts: 842 EDU
    @alnis_smidchens
    mmm.  that is working now.  Maybe it was me...
    www.accuratepattern.com
  • mogplus8mogplus8 Member Posts: 20 ✭✭
    @Evan_Reese that's the functionality I'd like succinctly and clearly defined. Is implementing it on somebody's to-do list?

    :-\
  • alnisalnis Member, Developers Posts: 452 EDU
    @Evan_Reese I think that would make a great improvement request! I can definitely see real use cases for the functionality you mention.

    @ian_harris952 I don't believe there's an IR for this for sketches yet. There's a similar one for drawings here:
    https://forum.onshape.com/discussion/comment/35462
    Get in touch: contact@alnis.dev | My personal site: https://alnis.dev
    @alnis is my personal account. @alnis_ptc is my official PTC account.
  • tim_hess427tim_hess427 Member Posts: 648 ✭✭✭✭
    I've never found myself wanting this functionality, but hearing it described by Evan does make me want it. I can already think of several use cases where I'm either deriving a sketch from another part studio or creating a "base" sketch, and then scaling it based on configurations. Currently, I'm having to do the workaround where I create a surface, scale the surface, then create new sketches based on that. 

    I'd love a "sketch block" that I can define once, and then configure a scale factor and be done with it. 

    I'll gladly vote for that!
  • shawn_crockershawn_crocker Member, OS Professional Posts: 866 PRO
    @ian_harris952
    This is how I have adapted an alternate way of accomplishing sketch blocks.  If your looking to use sketch blocks as a way to visualize movement of components while sketching, it doesn't solve that problem.  For me, I mainly use sketch blocks for standardizing different cutouts in material and such so this derived surface method works extremely well.  In fact, I prefer it to solidworks answer to sketch blocks because the derived surface is forever linked back to the geometry that needs to fit the cutout and can be updated very easily.


  • don_williams909don_williams909 Member Posts: 142 PRO
    @Evan_Reese - Creo has the ability to save a library of sketches, and then you can bring them into a sketch and scale them in the process.
    One can only hope that this kind of functionality will happen eventually.

    In my case, I often have to add our company logo to an object, and the best way to do that is with a scalable sketch.
  • rocketbobrocketbob Member Posts: 5 ✭✭
    I'm sort of shocked sketch blocks arent available in Onshape.  Been using them for many years in AutoCAD and SolidWorks.
  • DavidvanderMeerDavidvanderMeer Member Posts: 15 ✭✭
    Another vote for sketch blocks from me. I remember when this was added to Inventor 2009, and was an absolute game changer for the type of design I was working on at the time. Being able to define a self-contained sketch entity that can be used many times over in other sketches, or even derived to other part files while still linked to its source, proved to be extremely powerful.

    IMO this is not one of those "let go of your 2D AutoCAD mindset and embrace the power of 3D" things, or "in Onshape you can approach things differently" arguments, there are some very good use cases for sketchblocks.
  • eric_pestyeric_pesty Member Posts: 1,926 PRO
    edited March 2022
    You can copy and paste a sketch and behaves pretty similarly to a "sketch block", except that it isn't "linked" to the source anymore. You can use the transform tool to scale and move things around but it's easy to "break" it inadvertently...

    You can also derive sketches in but they aren't free to move around, but you can use something like "super derive" to place a bunch of them at once if needed (having another sketch defining the locations can make this pretty quick). I guess if you could derive something in but make it "float" that would pretty much do it...

    Depending what you are trying to do, you can also insert sketches in an assembly and that's the closest to behavior you will get to "traditional" sketch blocks, except that you are not in a part studio environment so you can't extrude them etc. If you make them into surfaces instead of sketch you can then create a context.

    Basically nothing "quite" like a sketch block but there is some functionality that can get you pretty close (depending on what you are using the sketch blocks for)
  • jerry_berns465jerry_berns465 Member Posts: 5 EDU
    I am an assistant coach for a FIRST Robotics Competition team. We have used Autodesk Inventor for nearly eight years.
    We use sketch blocks to define major and common components such as the frame, elevator, climber, collector, wheels, motors, etc.
    We can then create sketch layouts by placing the blocks and then adding 2D constraints. It is a great way to conceptualize and visualize motion without having to make 3D components initially.



    Not having sketch blocks will definitely be a challenge for us to adopt OnShape.
    However, we recognize the benefits of cloud storage, simultaneous editing, and improved file management, so we are going to give OnShape a try.

    Regards,
    Jerry

  • eric_pestyeric_pesty Member Posts: 1,926 PRO
    @jerry_berns465
    You should be able to do this by inserting and mating the sketches in an assembly. I guess it is might require a few more steps than throwing them in a 2d sketch, but it also means you can have 3D motion as well (with just 2D "parts") so it's also more flexible...

  • edward_petrilloedward_petrillo Member Posts: 81 EDU
    @jerry_berns465.  Greetings from FRC Team 293- we're just finishing up (late as usual) the 6th FRC robot we've designed using Onshape after prior experience with Inventor and Solidworks.  Our preferred workflow is consistent with @eric_pesty's guidance- to start designing a mechanism, we populate an assembly with COTS components such as wheels, shafts, sprockets, bearings and the like and constrain them with judiciously-placed mate connectors and limits to mates as needed . We can usually visualize the full range of rotary and linear motion of the mechanism within the assembly and make necessary adjustments to dimensions.  Next phase is to create a parts studio in context to sketch the supporting framework, with critical geometry projected from the COTS components with the Use tool.  With a parts studio and assembly that are parametrically linked, the inevitable revisions are simple to make.  

    Switching to a more general plug for Onshape, I've been astonished how quickly new team members can master OS fundamentals using the self-paced curriculum that was rolled out in the past year or so. Good luck with your transition- you won't regret it.  
Sign In or Register to comment.