Skip to content

Instantly share code, notes, and snippets.

@GilesBathgate
Created April 6, 2016 20:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save GilesBathgate/9ff023bbd3a2f3b7b56e8ddc6fb51bb1 to your computer and use it in GitHub Desktop.
Save GilesBathgate/9ff023bbd3a2f3b7b56e8ddc6fb51bb1 to your computer and use it in GitHub Desktop.
duct_wall=1;
gap=6;
inner_radius=18;
outer_radius=inner_radius+gap;
height=14;
nozzle_height=6;
taper_angle=30;
skew=nozzle_height*tan(taper_angle);
top_height=height-nozzle_height;
mouth_width=12;
mouth_height=20;
pipe_length=20;
mount_width=5;
mount_depth=2.5;
module nozzle(radius)
difference(){
union(){
cylinder(r=radius,h=top_height);
translate([0,0,top_height])
cylinder(r1=radius,r2=radius-skew,h=nozzle_height);
}
cylinder(r=radius-duct_wall,h=top_height);
translate([0,0,top_height])
cylinder(r1=radius-duct_wall,r2=radius-skew-duct_wall,h=nozzle_height);
}
module pipe_part(radius,height){
difference(){
translate([0,mouth_width/2,0])
cylinder(r=radius+(mouth_width/2),h=height);
translate([0,-2*radius+mouth_width/2,0])
cube([2*radius,4*radius,height]);
cylinder(r=radius-duct_wall,h=height);
}
}
module pipe(){
difference(){
union(){
difference(){
union(){
pipe_part(outer_radius,top_height);
//neck
translate([-mouth_width+duct_wall,outer_radius-duct_wall,0])
cube([mouth_width,mouth_width+duct_wall+pipe_length,top_height]);
}
translate([0,0,duct_wall])
pipe_part(inner_radius+5,top_height-(2*duct_wall));
//neck hole
translate([-mouth_width+(2*duct_wall),outer_radius,duct_wall])
cube([mouth_width-(2*duct_wall),mouth_width+duct_wall+pipe_length,top_height-(2*duct_wall)]);
}
//end
translate([-mouth_width+duct_wall,outer_radius+mouth_width+pipe_length-duct_wall,0])
cube([mouth_width,duct_wall,top_height-duct_wall-0.3]);
}
translate([-mouth_width+(2*duct_wall),outer_radius+mouth_width+pipe_length-mouth_height,0])
cube([mouth_width-(2*duct_wall),mouth_height-duct_wall,duct_wall]);
}
}
module mount()
{
//difference(){
union(){
translate([duct_wall,outer_radius+pipe_length+mouth_width-mount_depth,0])
cube([mount_width,mount_depth,top_height]);
translate([-mouth_width-mount_width+duct_wall,outer_radius+pipe_length+mouth_width-mount_depth,0])
cube([mount_width,mount_depth,top_height]);
}
//}
}
module duct(){
difference(){
nozzle(outer_radius);
translate([-outer_radius,-outer_radius+2*duct_wall,duct_wall])
cube([outer_radius,outer_radius,top_height-(2*duct_wall)]);
}
nozzle(inner_radius);
difference(){
union(){
cylinder(r=outer_radius,h=duct_wall);
pipe(outer_radius);
}
cylinder(r=inner_radius,h=top_height);
}
//mount();
}
module heater_block(){
translate([0,0,nozzle_height])
align([0,0,-1])
cube([17.5,20,11.5],c=true);
}
//heater_block();
duct();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment