discuss@lists.openscad.org

OpenSCAD general discussion Mailing-list

View all threads

Re: [OpenSCAD] Creating screw threads?

M
MichaelAtOz
Thu, Dec 4, 2014 9:03 PM

Bump - so it goes to the mailing list.


Unless specifically shown otherwise above, my contribution is in the Public Domain; To the extent possible under law, I have waived all copyright and related or neighbouring rights to this work. This work is published globally via the internet. :) Inclusion of works of previous authors is not included in the above.

The TPP is no simple “trade agreement.”  Fight it! http://www.ourfairdeal.org/

View this message in context: http://forum.openscad.org/Creating-screw-threads-tp10306p10336.html
Sent from the OpenSCAD mailing list archive at Nabble.com.

Bump - so it goes to the mailing list. ----- Unless specifically shown otherwise above, my contribution is in the Public Domain; To the extent possible under law, I have waived all copyright and related or neighbouring rights to this work. This work is published globally via the internet. :) Inclusion of works of previous authors is not included in the above. The TPP is no simple “trade agreement.” Fight it! http://www.ourfairdeal.org/ -- View this message in context: http://forum.openscad.org/Creating-screw-threads-tp10306p10336.html Sent from the OpenSCAD mailing list archive at Nabble.com.
RR
Robert Rapplea
Sun, Dec 7, 2014 2:50 AM

Try this. It's simplistic, but you should be able to adjust it to do what you're
looking for.

linear_extrude(h=20, twist=20*90)

{

union()

{

circle(r=15);

polygon([[30,0],[7.5813,13],[7.5813,-13]]);

polygon([[-30,0],[-7.5813,13],[-7.5813,-13]]);

}

}

On 12/4/2014 2:03 PM, MichaelAtOz wrote:

Bump - so it goes to the mailing list.


Unless specifically shown otherwise above, my contribution is in the Public Domain; To the extent possible under law, I have waived all copyright and related or neighbouring rights to this work. This work is published globally via the internet. :) Inclusion of works of previous authors is not included in the above.

The TPP is no simple “trade agreement.”  Fight it! http://www.ourfairdeal.org/

View this message in context: http://forum.openscad.org/Creating-screw-threads-tp10306p10336.html
Sent from the OpenSCAD mailing list archive at Nabble.com.


OpenSCAD mailing list
Discuss@lists.openscad.org
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org

Try this. It's simplistic, but you should be able to adjust it to do what you're looking for. linear_extrude(h=20, twist=20*90) { union() { circle(r=15); polygon([[30,0],[7.5813,13],[7.5813,-13]]); polygon([[-30,0],[-7.5813,13],[-7.5813,-13]]); } } On 12/4/2014 2:03 PM, MichaelAtOz wrote: > Bump - so it goes to the mailing list. > > > > ----- > Unless specifically shown otherwise above, my contribution is in the Public Domain; To the extent possible under law, I have waived all copyright and related or neighbouring rights to this work. This work is published globally via the internet. :) Inclusion of works of previous authors is not included in the above. > > The TPP is no simple “trade agreement.” Fight it! http://www.ourfairdeal.org/ > -- > View this message in context: http://forum.openscad.org/Creating-screw-threads-tp10306p10336.html > Sent from the OpenSCAD mailing list archive at Nabble.com. > > _______________________________________________ > OpenSCAD mailing list > Discuss@lists.openscad.org > http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
CL
Chow Loong Jin
Mon, Dec 8, 2014 4:16 AM

On Sat, Dec 06, 2014 at 07:50:04PM -0700, Robert Rapplea wrote:

Try this. It's simplistic, but you should be able to adjust it to do what
you're looking for.

linear_extrude(h=20, twist=20*90)

{

union()

{

circle(r=15);

polygon([[30,0],[7.5813,13],[7.5813,-13]]);

polygon([[-30,0],[-7.5813,13],[-7.5813,-13]]);

}

}

If you can plot out a polygon of the thread profile for the entire length of
rotation in a circular form, you can then linear_extrude it with a certain
amount of twist and height in order to get your screw.

Basically, take a thread profile, plot it on graph paper on an X/Y axis, and
change the X/Y labels to angle/radius, and you've gotten a proper cross-section
for your thread.

I implemented this in https://github.com/openscad/MCAD, in fasteners/thread.scad
in the dev branch.

--
Kind regards,
Loong Jin

On Sat, Dec 06, 2014 at 07:50:04PM -0700, Robert Rapplea wrote: > Try this. It's simplistic, but you should be able to adjust it to do what > you're looking for. > > > > linear_extrude(h=20, twist=20*90) > > { > > union() > > { > > circle(r=15); > > polygon([[30,0],[7.5813,13],[7.5813,-13]]); > > polygon([[-30,0],[-7.5813,13],[-7.5813,-13]]); > > } > > } If you can plot out a polygon of the thread profile for the entire length of rotation in a circular form, you can then linear_extrude it with a certain amount of twist and height in order to get your screw. Basically, take a thread profile, plot it on graph paper on an X/Y axis, and change the X/Y labels to angle/radius, and you've gotten a proper cross-section for your thread. I implemented this in https://github.com/openscad/MCAD, in fasteners/thread.scad in the dev branch. -- Kind regards, Loong Jin
CL
Chow Loong Jin
Mon, Dec 8, 2014 4:25 AM

On Mon, Dec 08, 2014 at 12:16:09PM +0800, Chow Loong Jin wrote:

[...]
If you can plot out a polygon of the thread profile for the entire length of
rotation in a circular form, you can then linear_extrude it with a certain
amount of twist and height in order to get your screw.

Basically, take a thread profile, plot it on graph paper on an X/Y axis, and
change the X/Y labels to angle/radius, and you've gotten a proper cross-section
for your thread.

I implemented this in https://github.com/openscad/MCAD, in fasteners/thread.scad
in the dev branch.

https://github.com/openscad/MCAD/blob/dev/fasteners/threads.scad#L147 for a
generic trapezoidal thread that can generate buttress, acme, and metric threads.
Doing a tapered thread this way is beyond me, though. I'm thinking of replacing
this approach with the sweep() module from the list comprehension demos, which
would be cleaner and simpler to implement.

--
Kind regards,
Loong Jin

On Mon, Dec 08, 2014 at 12:16:09PM +0800, Chow Loong Jin wrote: > [...] > If you can plot out a polygon of the thread profile for the entire length of > rotation in a circular form, you can then linear_extrude it with a certain > amount of twist and height in order to get your screw. > > Basically, take a thread profile, plot it on graph paper on an X/Y axis, and > change the X/Y labels to angle/radius, and you've gotten a proper cross-section > for your thread. > > I implemented this in https://github.com/openscad/MCAD, in fasteners/thread.scad > in the dev branch. https://github.com/openscad/MCAD/blob/dev/fasteners/threads.scad#L147 for a generic trapezoidal thread that can generate buttress, acme, and metric threads. Doing a tapered thread this way is beyond me, though. I'm thinking of replacing this approach with the sweep() module from the list comprehension demos, which would be cleaner and simpler to implement. -- Kind regards, Loong Jin