Hi,
I'm trying to do a projection of my part to 2D so that I can export it to
DXF for lasercutting. However, when I include the projection() call at the
end of the script there is no output.
Can you see what I'm doing wrong?
$fn=100;
module sensor()
{
width = 8;
translate([0,-2.5,-5])
union() {
cube([5.5,5,10]);
translate([5,-1.5,-3]) cube([1,width,19]);
}
}
module curve(diameter, width)
{
difference()
{
circle(diameter);
circle(diameter-width);
translate([-25,0,0]) cube([100,150,3], center=true);
}
}
module part()
{
difference()
{
curve(diameter=60, width=10);
for (a = [-180 : 26 : 180])
rotate(a) translate([60-12, 0, 0]) sensor();
}
}
//projection(cut=false)
part();
--
View this message in context: http://forum.openscad.org/No-object-when-doing-projection-tp20456.html
Sent from the OpenSCAD mailing list archive at Nabble.com.
On Wed, Feb 15, 2017 at 1:58 PM, Scalpel78 frode@lillerud.no wrote:
$fn=100;
module sensor()
{
width = 8;
translate([0,-2.5,-5])
union() {
cube([5.5,5,10]);
translate([5,-1.5,-3]) cube([1,width,19]);
}
}
module curve(diameter, width)
{
difference()
{
circle(diameter);
circle(diameter-width);
translate([-25,0,0]) cube([100,150,3], center=true);
}
}
module part()
{
difference()
{
curve(diameter=60, width=10);
for (a = [-180 : 26 : 180])
rotate(a) translate([60-12, 0, 0]) sensor();
}
}
//projection(cut=false)
part();
according to the errors: you are mixing 2D and 3D operations
just put this before your circles:
linear_extrude(height=3)
so linear_extrude(height=3) circle(....)
--
Extra Ham Operator: K7AZJ
Registered Linux User: 275424
Raspberry Pi and Openscad developer
The most exciting phrase to hear in science - the one that heralds new
discoveries - is not "Eureka!" but "That's funny...".- Isaac. Asimov