sw lousy dxf file export - my solution

Discussion in 'SolidWorks' started by Zander, Aug 22, 2005.

  1. Zander

    Zander Guest

    Hi all,

    For ages SW outputs dxf files of 2d profiles from a drawing with minute
    errors. Most cnc laser or router cam software require flat 2d closed
    polylines to cut or machine. SW exports what should be a closed
    polyline as a series of lines and arcs with (sometimes) small gaps
    between the endpoints. This means you can't use pedit to join them.
    If you have express tools you can enter a fuzz factor to heal it, but
    it's obviously a work around.

    What I do now is this:

    In my part file I select the top face of what I want cut. If it's a
    split part I select all required faces. Then saveas Acis, select faces
    only option and save. You may need to create a 'proper' cartesian
    coordinate system, with Z pointing up not out.

    Open this sat file in acad with 'acisin', and all the faces appear as
    regions. If you arn't familiar with regions they are like a 2d solid.
    ie, can't have gaps in the corners because it is a body.

    If you explode a region it becomes a sequence or arcs and lines which
    can easily be pedited together to a closed polyline.

    Zander
     
    Zander, Aug 22, 2005
    #1
  2. Zander

    Rock Guy Guest

    I think PEDIT will work if you change the "fuzz distance" setting.
     
    Rock Guy, Aug 22, 2005
    #2
  3. Zander

    Brian Guest

    This may save some time and work as well for you. Create a configuration
    called laser cutting. Open a new sketch and use convert entities to get the
    profile that you desire. Open another sketch and select the geometry from
    the first. Use the tools-spline tools-fit spline funtion. Leave it as
    constrained and give it a reasonable tolerance value ( the default value
    makes no sense ). At this point I usually crate a simple planer entity from
    the profile to check it for obvious errors.

    On your drawing, create a sheet and insert a view of the cutting
    configuration. You can then export the sheet as dxf/dwg and it will give
    you a joined polyline. I suggest R12 version as I've had good luck with it
    and at this point you should not have any entities in your file that are not
    supported. I think that the use of the fit spline tool has given the user
    some control over how splines get exported, but am not sure. Using a planer
    surface also eliminates the possibility that SW will accidentally export
    extra geometry ( ie both the top and bottom profiles of an extrude, thus
    creating duplicate entities, one on top of the other ). Since using this
    method, I've had no complaints from my laser cutters/engravers. The
    engraver does not have any fancy software, so I use the same method even
    with tangent lines/arcs to convert them into continuous polylines. That
    prevents his laser from reading tangent lines/arcs in the order that they
    were written into the .dxf file, which rarely makes a good cutting path.
    Used this method on a Mitsubishi cutting laser, a Trumph, and an Epilog
    engraving laser, all with no vendor complaints.

    This also makes it possible to export ellipses to dxf. Since 2001 ellipses
    have always exported as the inverse of what they should be, regardless of
    the fact that its been "fixed" in about 10 different service packs.
     
    Brian, Aug 22, 2005
    #3
  4. Zander

    John Layne Guest

    Interesting reading, I've been using the standard save as DXF for
    several years with no complaints!

    No doubt my sheetmetal vendors are pulling their hair out every time I
    send them a DXF and haven't bothered to complain.

    Thanks for the heads up, if I have problems in the future I will refer
    to this post.


    John Layne
    www.solidengineering.co.nz
     
    John Layne, Aug 23, 2005
    #4
  5. Zander

    Cam J Guest

    Me too... and never a complaint, although I always send DWG.
     
    Cam J, Aug 23, 2005
    #5
  6. Zander

    Zander Guest

    fuzz factor is only availbable in 'express tools'. Plus, it's a little
    irksome to have to actually change the geometry of what should be a
    closed profile since it was originally drawn closed.
     
    Zander, Aug 23, 2005
    #6
  7. Zander

    Zander Guest

    Yes, a lot of fabricators strangely just fix the file and never say a
    word. But the cost will often be in the bill somewhere. Years ago I
    used to own a cnc pattern shop and I expected bad files requiring lots
    of fixup. Endless conversations with people on the phone explaining a
    'closed' pline etc. I'm really amazed that with it's touted dwg
    compatability that sw has, ever since 2000 anyways export disconnected
    loops - with errors- into dxf files. Even a rectangle will usually
    have one corner where the endpoints are seperated by .00000001" . This
    is enough for Cam software, especially the cheap stuff that ships with
    machines to not be able to tell the inside from the outside. Hence my
    region trick.

    Zander
     
    Zander, Aug 23, 2005
    #7
  8. Howdy Zander -

    I lived this one for many years of my life too, but without the high
    anguish level - perhaps just luckier or different software with higher
    gap tolerance.

    I like your trick. One trick I also use to fix this problem (once in
    2d) is a grip edit - Pull the node away and then back again - it
    healed the micro round off.

    This "millionths" round off killed me and also drove me insane. I
    recall a complicated design DXF'd out of Anvil (A heavy weight you bang
    things against) and I have to Pline every profile we were wire cutting.
    Arggg!

    Generally, you "endless conversation" statement almost invariable
    applies to people who have not felt the pain when programming. That's
    sombody else's problem.

    Cool tip.

    Later,

    SMA
     
    Sean-Michael Adams, Aug 23, 2005
    #8
  9. Zander

    Zander Guest

    I feel your pain, I have the story to end all for acad pline'ing. I
    machined years ago a 3d map based on gis contours from the government,
    it was about 10' sq. The data was in dxf format, the file was 30km
    sq. The gis software only support plines of 500 vertices max so every
    500 vertices of these squiggley contour lines there was a break with
    ---- a gap!!!! Even if you closed the gap the resulting pline chains
    were so long that back then on a 486 powerhouse it took 15 minutes to
    complete the join command for 1 pair.

    Solution was: I wrote a vb macro that matrixed all the start and
    endpoints of the plines and found nearest neighbors and fairly
    intelligently chained them together. If it couldn't solve it it
    changed the layer and color of the offendors. Net result. 20 hours
    writing 1 very long and complicated macro and 25mins to process the
    whole file at the end. I had fun and learned some stuff and prevent
    carpal tunnel again!

    Zander
     
    Zander, Aug 23, 2005
    #9
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.