roland78
2018-10-18 18:05:34 UTC
Hi. I need help with this code for a flange-- looks like is empty inside( i
need to be full) and is not totally through the ellipse and holes. Or a
better code for such a flange?
module make_ring_of (radius, count)
{
for (a = [0: count -1])
{
angle = a * 360 /count;
translate (radius * [sin(angle), -cos(angle), 0])
rotate ([0, 0, angle])
children ();
}
}
Thank you.
module oval()
{
scale([2.5,1,1])
circle(10);
}
difference ()
{
cylinder (h=8, r=50);//big flange
{
difference();
cylinder (h=8, r=50);
$fn = 36;// how fine to be the ellipse
translate ([0, 0, 0]);
{offset(r=0.15, h=10)oval();}
make_ring_of (radius = 30, count = 4)// outside small holes and
how many
cylinder (r = 4, h = 10, centre = true);// dimension of the
outside holes
}
}
--
Sent from: http://forum.openscad.org/
need to be full) and is not totally through the ellipse and holes. Or a
better code for such a flange?
module make_ring_of (radius, count)
{
for (a = [0: count -1])
{
angle = a * 360 /count;
translate (radius * [sin(angle), -cos(angle), 0])
rotate ([0, 0, angle])
children ();
}
}
Thank you.
module oval()
{
scale([2.5,1,1])
circle(10);
}
difference ()
{
cylinder (h=8, r=50);//big flange
{
difference();
cylinder (h=8, r=50);
$fn = 36;// how fine to be the ellipse
translate ([0, 0, 0]);
{offset(r=0.15, h=10)oval();}
make_ring_of (radius = 30, count = 4)// outside small holes and
how many
cylinder (r = 4, h = 10, centre = true);// dimension of the
outside holes
}
}
--
Sent from: http://forum.openscad.org/