Gas station without pumps

2019 October 15

Extruded clamp

Filed under: Uncategorized — gasstationwithoutpumps @ 16:51
Tags: , ,

A few years ago, I found a little (6.5cm long) aluminum clamp on the street, probably fallen out of someone’s truck. I liked the design of the clamp(though the original rubber band has died):

Although the “Taylor” brand name is clearly stamped on the extrusion, I have been unable to find clamps by Taylor for sale online.

Extrusions are particularly easy to copy with a 3D printer, and so I decided to make my own clamps. I took off the rubber band, put the extruded aluminum pieces on my flatbed scanner and scanned them at 600dpi. I then used Inkscape to manually draw a Bézier-curve outline of each piece. I used the circle tool in Inkscape behind the curve to tweak the hinge contacts to be very close to circular.

I imported the SVG files into OpenSCAD and extruded the pieces to 12.5mm (the thickness of the original clamp). The first printing was not entirely successful:

The first few layers warped on the end of the handle—apparently the thin end of the handle did not adhere well to glass plate and warped up.

I fixed the problem in two ways: I made the handle a little beefier (it seemed a little thin on the original anyway) and I printed with a brim. While I was at it, I increased the extrusion from 12.5mm to 15mm to make a slightly fatter clamp. The resulting clamp was successful:

Here are the two pieces of the clamp separately.

The clamp assembled. By using three wraps of the rubber band, twists in the rubber band can be avoided.

The difference in the handles between the first print (on the left) and the second print (on the right) is clear in this image.

Removing the brim was a bit of a hassle—I need to think about applying a brim only to the handle part. I don’t think that the Cura slicer makes that easy, so I’d probably have to design it into the model (union with a 0.14mm thick plate around each handle).

Now that I have the basic model working, I can play around with different jaw shapes and different sizes of clamps.  With the jaw all the way open the clamping force seems to be about 15N, though that obviously depends on the rubber band used.

2019 September 19

Printed 3DBenchy

Filed under: Uncategorized — gasstationwithoutpumps @ 13:32
Tags: , ,

One of the standard test pieces for 3D printers is 3DBenchy, a design with several somewhat difficult features created by Creative-Tools.com (licensed CC-4.0-By-No).  I finally got around to printing it earlier this week on my Monoprice Delta Mini using Hatchbox Gold PLA with a layer height of 0.07mm and the 0.4mm brass nozzle that came with the printer. It took 4 hours and 25 minutes to print at that resolution.

I’ve been trying to figure out how to get Cura 4.2 to dump the entire settings used to generate the Gcode, but I’ve been unable to do that—it seems to record only the differences from the standard settings. So far the best I’ve been able to do is to extract settings from the output G-code:

;FLAVOR:Marlin
;TIME:10855
;Filament used: 3.85238m
;Layer height: 0.07
;MINX:-29.8
;MINY:-16.122
;MINZ:0.14
;MAXX:29.798
;MAXY:16.113
;MAXZ:47.95
;Generated with Cura_SteamEngine 4.2.0

M82 ;absolute extrusion mode
G21;(metric values)
G90;(absolute positioning)
M82;(set extruder to absolute mode)
M107;(start with the fan off)
G28;(Home)
G29 P5 Z0.3 V4; (Level the bed with 5x5 array)
G1 X55 Y0 Z5 F3000;(Move to the outside of the bed.)
G92 E0;(reset extrusion distance)
G1 E5 F500;(Prime.)
G92 E0;(zero the extruded length)
G1 Z0;(Down to printing height.)
G2 X0 Y55 I-55 J0 E20 F2000;(Draw a priming arc.)
G92 E0;(zero the extruded length)

adhesion_type = none
build_volume_temperature = 0
default_material_bed_temperature = 50
layer_height = 0.07
layer_height_0 = 0.14
material_bed_temperature = 40
material_bed_temperature_layer_0 = 50

alternate_extra_perimeter = True
brim_width = 3
cool_min_layer_time = 3
fill_outline_gaps = True
infill_sparse_density = 25
line_width = 0.35
material_initial_print_temperature = 195
optimize_wall_printing_order = True
top_bottom_thickness = 0.42
xy_offset_layer_0 = -0.05
zig_zaggify_infill = True

That is enough to recreate the settings in Cura 4.2, but if the default values change in later versions of Cura, I won’t know which to reset. Some of these settings are irrelevant, also, as the brim_width doesn’t matter since I didn’t use a brim, for example.

Print speed is the default 60mm/s with walls and top/bottom at the default 30 mm/s and travel at the default 120mm/s.

I chose to print at 0.07mm (70 µm), since I read somewhere that multiples of that thickness are best for the Monoprice Delta Mini.

Bottom view shows the shiny surface from using a glass plate with hairspray as an adhesive.

The top surface looks pretty clean, but stringing can be seen from the stern and between the uprights of the wheelhouse.

The top view looks pretty good from this angle also, but some blobbing can be seen inside the bow.

The port bow shows smooth sides, but some stringing on the hawsepipes and poor bridging at the top of front window of the bridge.

The view from the stern shows bad stringing for the rear window. The 0.1mm writing on the stern is barely legible with angled lighting (not really with this flash).

The starboard view shows bad stringing between the uprights of the bridge and some blobbing on the back of the bridge, as well as some layer marks near the top of the arch.

Many of the calibration checks (measured/ideal) are hard to do with calipers, because there are not well-defined measurement points or other parts of the print interfere with placement of the calipers. I skipped some measurements entirely as impossible to measure with the calipers.
roof length 22.9mm/23mm
chimney cap diameter 6.4mm/7mm
depth of chimney hole 11mm/11mm (hard to measure accurately)
chimney inside diameter 2.4mm/3mm (hard to measure accurately)
length 60mm/60mm (hard to measure accurately)
width 29mm/30mm (hard to measure accurately)
height 48.2mm/48mm
box height 15.65mm/15.5mm
box width 11.8mm/12mm
box inside width 7.8mm/8mm
box depth 9.1mm/9mm
box length 10.75mm/10.81mm
hawsepipe diameter 3.95mm/4mm
front window width 9.95mm/10.5mm
rear window outer diameter 11.35mm/12mm (horizontally)
rear window inner diameter 8.9mm/9mm

The z-heights look about 0.5% too big and the x-y dimensions about 2% small (though I don’t trust the measurements—I’d want to use a rectangular block for re-calibrating).

I think that the biggest problem is stringing, which may be fixable by increasing the retraction, though bridging at the top of the front window is also flawed. Retraction is enabled and is the default 6.5mm @ 25mm/s.

I’ll be asking for advice on the 3D-printing subreddit, since asking for help on Benchy prints seems to be common there.

2019 September 17

Spacers for electric outlet box

Filed under: Uncategorized — gasstationwithoutpumps @ 12:34
Tags: ,

Yesterday I printed some functional (rather than decorative) parts. The problem I was addressing was one that had been bothering me in a low-key way for several years—an electrical outlet in the living room that was wobbly. The problem started when I had the front wall insulated. Because the wall is self-formed concrete, sheets of foam insulation were added on the inside of the wall, sheet rock put over the insulation, and then a skim coat of plaster added to match the original texturing of the walls. The outlet box for the electrical outlet was now rather deeply recessed in the wall, and the carpenters move the outlet forward by using longer screws.

Unfortunately the spacers they used to hold the outlet in the new position were not real spacers, but plastic wall anchors, which did not hold the outlet firmly in the right place—they were relying on the strength of the plastic wall plate to hold the outlet forward. This was never very secure, and this summer the wall plate broke while plugging in an extension cord, so I decided to print some properly sized spacers to hold the outlet securely in place.

I turned off the power and measured the spacing needed with the depth gauge of my calipers, as well as measuring the room available for the spacer. I printed two spacers that were 13mm long and replaced the outlet, only to find out that outlet was still too deep in the wall for the new cover plate to be screwed to the outlet. I tried measuring how much further out the outlet needed to be (estimated at 9mm) and printed a pair of 22mm long spacers.

These are the 13mm and 22mm spacers that ended up being extra. The ears on the spacer are not necessary—I put them on to match the outlet, to make alignment easer, as the hole was initially not centered vertically. I later changed the design so that the hole was centered, so the orientation is now irrelevant and a simple rectangular spacer would suffice. The parts are printed with 0.14mm layers in Hatchbox Gold PLA, with 25% infill.

On the first attempt to print a pair of 22mm spacers, one printed fine, but the other ended up with a long trail of tangled spaghetti after printing halfway just fine. Reprinting just one 22mm spacer failed again, this time with a blobby mess. The problem, however, was clear—the print had gotten detached from the baseplate and was moved around by the printhead. Using some hairspray on the bed increased the adhesion enough that it printed fine, without needing to add a brim.

These two prints were supposed to be 22mm spacers. The one on the right was printed at the same time as one of the successful prints, and the one on the left was an attempt to reprint just one spacer. For both, the failure was insufficient adhesion to the glass bed—I fixed the problem by using hairspray to increase the adhesion.

When I put the 22mm spacers in place, the outlet stuck out too far (my measuring skills clearly need some improvement). The outlet stuck out much more on the bottom than on the top, so I put on the cover plate and measured the clearance from the wall on both the top and the bottom. I decided that I could use the smaller 13mm spacer on top, but I would need an 18mm spacer on the bottom. After printing an 18mm spacer, I assembled the outlet once more, and everything fit perfectly, with the cover plate flush against the wall as desired.

2019 September 1

Cat drinking fountain completed

Filed under: Uncategorized — gasstationwithoutpumps @ 13:38
Tags: , , ,

In Beginning design of a cat drinking fountain I wrote

One of our cats likes to drinking from running water (a bathroom sink on a trickle setting), so my wife challenged me to make a drinking fountain for the cat that recirculates water in a water dish.  This project will be mainly physical design (3D printing, gluing things together) with a little electronics to control the pump.

I finished the cat fountain this week—the amazing thing is that I only had to print each part once, with the first design working!  (Well, that’s almost true—I printed a bunch of 2mm-thick test pieces for the hose clip, to try to get something that would hold firmly to the rim of the bowl, and I aborted one print of the hose clip after a couple of layers, when I realized that one part had not been made level on the bed before slicing.)  All the big pieces went together on the first try, and the first fully printed hose clip worked.

Unfortunately, the cats have not show any interest in the fountain yet.

Here is a top view of the fountain running. The rocks serve two purposes—to make the fountain quiet (avoiding the trickling noise of faucet left running) and providing some weight to keep the bowl from tipping. I don’t know whether the weight is enough if a cat rests both front paws on the rim—that has not been tested yet.

Here is a side view of the fountain, showing the base with the control knob for adjusting the flow rate.

Here is a side view of the fountain, showing the hose clip, which is glued together from two pieces, to avoid having to print any overhangs. The rounded-triangle bolt holes are visible on the side of the base.

Here is a bottom view of the fountain, showing the barrel jack for power, the support for the pump, and the hose from the pump.

Here is a top view of the base, showing how it is divided into 4 parts so that each part is small enough to be printed in the 110mm-diameter print area of the Monoprice Delta Mini. The parts are bolted together with M3-18mm bolts

I printed a nozzle for fountain also. I’ve been thinking of printing some other nozzle shapes, to see what produces the nicest stream. I was pleased by how well the nozzle fit into the ¼” ID hose—I had expected to end up with something either too large to fit or with barbs too small so that the nozzle fell out, but everything worked ok.  I would make the barbs slightly larger if I wanted something that would hold under pressure, though.

I’ve started using rounded-triangle holes for horizontal bolt holes.  The edges of the holes are three circular arcs, with the centers of the circles at the points of an equilateral triangle, and the radius being the side length of the triangle.  I make one of the vertices be in the positive z direction.  The arched shape is a little easier for the printer to print than the flat top of a circular hole, though for holes this small even circular holes print ok.

I designed in a little clearance between the parts, so that I would not need to sand things to make them fit.  The 0.15mm clearance I allowed seems to be about right—the pieces bolted together without problems and the fit seems to be pretty tight.

I drilled the melamine bowl with a 3/8″ Forstner bit, as that seemed to be exactly the right size for the 9.5mm inlet of the pump. Before drilling with the drill press, I covered both sides of the bowl where I was going to drill with transparent tape and taped a piece of MDF below the bowl to support the surface.  I got no cracking and the pump outlet fit tightly in the resulting hole.  I glued the pump to the bottom of the bowl with FlexEpox, which I also used to glue the two halves of the hose clamp together.

The controller is the design I used for the desk lamps—I happened to have one sitting around unused.  I didn’t even change the code, though I’ve been thinking about changing the range of the PWM, and possibly raising the PWM frequency. The pump sometimes makes a quiet, but slightly annoying noise at about 2.2kHz when set to low flow rates. The PWM frequency is nominally 2.344kHz at low output and 9.375kHz at high output (with a 9.6MHz clock), and the 2.2kHz sound is within the ±10% spec for the RC oscillator in the ATtiny13 chip.  I may not need as high a precision at low levels for the motor as I do for LEDs, so a simpler program that just uses a 256-step PWM at around 9kHz may be better.

A capacitor across the motor may also help to reduce the voltage fluctuation that causes the noise.  If the motor is drawing about 300mA and the power is off for about ¾ of the period (at 2.2kHz), then we’d need about 100µC from the capacitor.  If we want the voltage to drop 9V in that time, the average voltage is 4.5V and a 22µF capacitor would be about the right size.  Of course, I’d have to go to lower duty cycles, as the average voltage across the motor would be much higher than without the capacitor. Even very short duty cycles may not be low enough, as the capacitor charges very quickly and the slow discharge may leave the pump running at too high a speed—in that case I’d need to make the capacitor smaller.

(Update 2019 Sept 1: a 10µF ceramic capacitor does seem to quiet the 2.2kHz sound while still allowing the motor to be turned down to the point where it stalls. Of course, my tinnitus is loud enough that the fountain may still be making noise, but I just can’t hear it over the tinnitus.)

(Update 2019 Sept 9: the pump was still whining, even with the capacitor, so yesterday I did the right thing and reprogrammed the ATTiny13 in the controller to use a PWM of ~37.5kHz, instead of 2.2kHz.  The cats may still be able to hear it, as the cat range of hearing is about 48Hz–85kHz [https://doi.org/10.1016/0378-5955(85)90100-5], but I can’t hear it.)

The fountain takes about 2–3W (measured at the AC input to the power supply), so I’ve not looked into adding a power switch or a motion detector to turn the pump on and off.

As usual, I designed everything using OpenSCAD.

nozzle1.scad

// barbed nozzle(s) for pump
// Kevin Karplus
// 2019 August 12
//  Creative Commons Attribution-ShareAlike  (CC BY-SA 3.0)


module nozzle(ID=3, OD=6, final_OD=undef, length=undef, num_barbs=undef)
{
    $fa=5; $fs=0.1;
    barb_diam= 1.15*OD;
    barb_length= OD/3;
    thickness=(OD-ID)/2;

    assert(num_barbs!=undef || length!=undef);
    
    barb_count = num_barbs!=undef? num_barbs: max(1, min(4, length/barb_length -2));
    real_length = length!=undef? length: (barb_count+1)*barb_length;
    real_final_OD = final_OD==undef? OD: final_OD;
    
    
    flare_from = (barb_count+1)*barb_length;
    assert(flare_from < real_length || OD==real_final_OD);
    
    barbs = [for (i=[1:barb_count]) each [[barb_diam/2, i*barb_length], 
                                [OD/2, i*barb_length]] ];
    profile = concat( [[ID/2,0], [OD/2,0]], barbs,
        [   [OD/2, flare_from],
            [real_final_OD/2,real_length], 
            [real_final_OD/2-thickness,real_length],
            [ID/2,flare_from], 
            [ID/2,0]
        ]);
    echo(profile=profile);  
    rotate_extrude()
    {    polygon(profile);
    }

}

intersection()
{
    color("red")    nozzle(length=20, num_barbs=3, final_OD=10);
    color("blue",0.4) translate([0,-12,0]) rotate([30,0,0]) cube(36,center=true);
}

hose_clip_v6.scad

// cat dish hose clip
//
// Kevin Karplus 2019 Aug 25
//  Creative Commons Attribution-ShareAlike  (CC BY-SA 3.0)

//
// v1 uses linear_extrude for bowl rim, has wrong rim profile
// v2 uses rotate_extrude for bowl rim, rim profile angled wrong outside, too wide
// v3 has taller clip.  Rim profile is better, but still not right.
// v4 tweaked the rim profile, but still a little loose
// v5 tweaked the rim profile some more, but apparently in the wrong direction
// v6 seems to have an ok rim profile, though clipping it on the rim opens the 
//    fork a bit, so that the rim is only grasped near the top.

use <BOSL2/std.scad>
include <BOSL2/paths.scad>
include <BOSL2/rounding.scad>

pi=3.14159265358979;

$fa=0.3; $fs=0.1;

bowl_diam = 254;    // bowl diameter at rim


// rim profile
inside = [ [0,0], [-2,0], [-3,-0.3], [-4,-1], [-5.1,-2],  [-6.6,-4],
    [-7.2,-5], [-10,-10], [-16,-20], [-22,-30]];
L2 = reverse([for (pt=inside) pt+[0,3.4]]);
outside =  [ [0,0], [-1.9,-0.9], [-2.8,-1.4], [-4.7, -2.8], [-5.5,-3.5],[-6.5,-4.6],[-10,-9.9], [-13.6,-15], [-18.1,-21.6], [-22.3,-27.8], [-26,-33.6]
    ];

L4 = simplify2d_path(concat(outside,[outside[len(outside)-1]+[1,-3]], reverse(offset(outside,5)), 
        [[5,-5], [5,9]], 
        reverse(offset(L2,5)), [L2[0]+[-3,-1]], L2 , [[0,0]] ));


module rotate_extrude_at_origin(r=bowl_diam, arc_l=12)
// like linear_extrude but curving the extrusion by
// rotating about x=-r, to get an arc length of arc_l for point at origin
{
    angle = arc_l/r*180/pi;
    rotate([-90,0,0])
    translate([-r,0,0])rotate_extrude(angle=-angle) translate([r,0]) children();
}



module hose_clip(clip_thick=12)
{
    r= bowl_diam/2;
    angle = clip_thick/r *180/pi;
    difference()
    {    
       color("blue")rotate_extrude_at_origin(r=r, arc_l=clip_thick)
        {  polygon(L4);
            translate([0,-5])square([5,30]);
        }
        
        translate([-r,0,0]) rotate([0,-angle/2,0]) translate([r,0,0])
        {    translate([0,20,0]) rotate([0,90,0]) cylinder(d=9, h=11, center=true);
            translate([0,25,0]) cube([11,10,7.5], center=true);
        }
    }
}

module split(r=bowl_diam/2, arc_l=clip_thick, move_to=[15,0])
// split the children at the a plane through x=-r, with angle top_angle/2
//  to the xy plane, rotating so that top_angle is on xy plane, and
//  moving it over to move_to
{   
    // below cut plane
    intersection()
    {    children(); 
         rotate_extrude_at_origin(r=r, arc_l=arc_l/2)
          { translate([-r+0.001,-2*r]) square( [4*r,4*r]);
          }
    }
    
    // above cut plane
    top_angle = arc_l/r *180/pi;
    translate(point3d(move_to)) 
        rotate([0,180,0])  // rotate so top surface is now on bottom
        translate([0,0,-r*sin(top_angle/2)])  // top is xy plane
        rotate([0,top_angle/2,0])  // top is horizontal
    intersection()
    {   color("red") translate([-r,0,0]) rotate([0,top_angle/2,0]) translate([r,0,0])
                children(); 
        rotate_extrude_at_origin(r=r, arc_l=arc_l/2)
        { translate([-r+0.001,-2*r]) square( [4*r,4*r]);
        }
    }
}

// test rim shape
// hose_clip(2);

clip_thick=16;
split(arc_l=clip_thick) hose_clip(clip_thick);

cat_dish_base_v1.scad

// Base for running-water cat bowl
//
// Kevin Karplus 2019 Aug 24
//  Creative Commons Attribution-ShareAlike  (CC BY-SA 3.0)



// First some measurements and model for the pump
    pump_d=26;
    pump_h=25.7;
    outlet_d=6;
    wire_h = 15;

module pump()
{   $fa=4; $fs=0.1;
    cylinder(d=pump_d, h=pump_h-4);
    cylinder(d=21, h=pump_h);
    cylinder(d=9.5, h=35.7);
    translate([0,-3.7-6.88/2,pump_h-outlet_d/2])
       rotate([0,90,0]) 
         cylinder(d=outlet_d, h=10+pump_d/2);
    rotate([0,0,135+8.5])  translate([10,0,-wire_h]) 
       cylinder(d=1,h=wire_h);
    rotate([0,0,135-8.5])  translate([10,0,-wire_h]) 
       cylinder(d=1,h=wire_h);
}

// how much space should be left between matching surfaces?
clearance = 0.15;



module nth_circle(diam=127, thickness=18, arc=120)
// draw a part of a circular arc (no more than 180 degrees)
// with outer diameter diam and inner diam diam-2*thickness
{   $fa=1;
    intersection()
    {
        difference()
        {     circle(d=diam);
              circle(d=diam-2*thickness);
        }
        scale=diam*2;
        polygon(scale*[[0,0], [1,0], 
                [cos(arc/2), sin(arc/2)],
                [cos(arc), sin(arc)]
                ]);
    }
}


module overhanging_circle(arc=120, diam=127, outer=10, inner=8, overlap_degrees=20)
// Two circular arcs offset from one another, with thickness "outer"
// for the outer arc and "inner" for the inner arc.
// The outer arc starts on the x-axis, the inner one at "overlap_degrees".
//  
{
    color("red")
        nth_circle(arc=arc, diam=diam, thickness=outer-clearance/2);
    mid_diam = diam-2*outer-clearance;
    color("green")rotate([0,0,overlap_degrees]) 
        nth_circle(arc=arc, mid_diam, thickness=inner);
    color("purple")rotate([0,0,overlap_degrees]) 
        nth_circle(arc=arc-overlap_degrees, diam, thickness=inner+outer);
    echo ("max_dist = ", 0.5*norm([diam,0] - diam*[cos(arc),sin(arc)]),
          "or",  0.5*norm([diam,0] - mid_diam*[cos(arc+overlap_degrees),sin(arc+overlap_degrees)]) );
}


module rounded_triangle(side=1)
// intersection of three circles, centers at corners of equilateral triangle.
// On corner is on x axis.
{    intersection()
    {   translate([side/sqrt(3),0]) circle(r=side,$fn=60);
        translate([-side/(2*sqrt(3)), side/2])  circle(r=side, $fn=60);
        translate([-side/(2*sqrt(3)), -side/2])  circle(r=side, $fn=60);
   }
}

module rounded_beam(side=1, length=3, center=false)
// rounded_triangle beam from (0,0,0) to (0,0,length). 
// (0,0,-length/2) to (0,0,length/2) if center is set.
// Corners of beam as for rounded_triangle.
{    linear_extrude(height=length, center=center) rounded_triangle(side=side);
}

module screw_hole(side=3.5, cap_side=6, cap_depth=4, length=18)
// rounded_triangle screw hole, for horizontal screw holes
// Top of screw_hole at x=0, screw extends length+cap_depth along -x axis.
// Hole is oriented so that point of arch in +z direction.
// Default sizes are appropriate for M3 screws.
{
    rotate([0,-90,0])  // put beam along negative x-axis
    {
        rounded_beam(side=cap_side, length=cap_depth);
        rounded_beam(side=side, length=length+cap_depth);
    }
}

module drilled_overhang(arc=90, diam=127, outer=10, inner=8, overlap_degrees=10,
    height = 40,
    hole_d=3.5, cap_diam=6, cap_depth=4)
// make a part of the circular wall, with screw holes to line up sections
{    assert (outer> cap_depth+3, "Outer wall thick enough for screw hole");
    clearance_angle = atan(2*clearance/diam);
    difference()
    {    linear_extrude(height)
            overhanging_circle(arc=arc-clearance_angle, diam=diam, 
                outer=outer, inner=inner, 
                overlap_degrees=overlap_degrees);
        
        for (angle= [overlap_degrees/2, arc+overlap_degrees/2])
            for (z= [height/3, 2*height/3])
            {   
                translate([0,0,z])      // move beam up
                rotate([0,0,angle]) // put beam in correct orientation
                translate([diam/2+0.001,0,0]) // move out to circle
                screw_hole(side=hole_d, 
                    cap_side=cap_diam, cap_depth=cap_depth, 
                    length=outer+inner+0.1);
            }
    }
}

module controller_board()
// cut this module out of a drilled overhang to make room for the
//	controller board
{   
    $fa=2; $fs=0.1;
    hole_centers=60;
    width=36;
    mid_length=34;
    length= mid_length+ width;
    height=15;
    translate([0,0,-height])
    linear_extrude(2*height) polygon([ [length/2,0],  //point
        [mid_length/2,width/2], [-mid_length/2,width/2], // mid-length side
        [-length/2, width/4], [-length/2,0],  [-length/2, -width/4],// spread point (for wires)
        [-mid_length/2,-width/2], [mid_length/2,-width/2]
        ]);
    cylinder(d=8, h=32);
   
    translate([hole_centers/2,0,22])
        rotate([90,-90,0]) 
           screw_hole(side=3.5, cap_side=6, cap_depth=4, length=18);
    translate([-hole_centers/2,0,22])
        rotate([90,-90,0]) 
           screw_hole(side=3.5, cap_side=6, cap_depth=4, length=18);
}


module controller_panel(arc=110)
// minor bug:  the top edge has a cantilevered part that barely works---
//	the first layer of the cantilevered part does not bond to the
//	subsequent layers.
//      Possible fixes include removing the cantilevered part (cutting
//	the top back to just the front face, as was done on the power panel)
//	or tapering the cantilever so that it has a 45-degree slope to it.
{
    difference()
    {   overhang=10;
        drilled_overhang(arc=arc,overlap_degrees=overhang);
    
        rotate([0,0,overhang/2+arc/2-90])
        {
           translate([0,35,20])
            rotate([-90,0,0])  // make up be +y direction
               controller_board();
            translate([0,35+35+22,20]) cube(70,center=true);
        }
    }
}

module notch_panel(arc=80,height=40, diam=127)
// minor bug: the notch could be just a little tighter to
//  grasp the 1/4" ID vinyl tubing, rather than having it resting loose in
//  the notch.
{   
    hose_d=10;
    difference()
    {   drilled_overhang(diam=diam,arc=arc,overlap_degrees=10);
        
       translate([0,0,height-hose_d]) 
        rotate(arc/2)
        {   translate([0,-hose_d/2,0]) cube([diam+1,hose_d,hose_d+1]);
            rotate([0,90,0]) cylinder(d=hose_d,h=diam+1, $fs=0.1);
        }        
    }
    
}

module pump_panel(arc=90,height=40, diam=127)
// Bug:  There is nothing in this version to keep the pump from sliding off 
// the platform if the base rotates—a rim is needed around the pump.
// Minor bug: the platform is a little too high, as there was not enough
// clearance for the wall of the hose between the outlet of the pump and the 
// bottom of the bowl.
{
    offset=diam/2-33;

    platform_h = height-pump_h;
    scaled_offset = offset/ (pump_d/2);
    alpha=acos(1/scaled_offset);
    tangent1 = [cos(180+alpha),sin(180+alpha)];
    tangent2 = [cos(180-alpha),sin(180-alpha)];
     union()
    {
         color("blue")  drilled_overhang(arc=arc,overlap_degrees=10, height=height);
        rotate(arc/2) 
          translate([offset,0])
        difference()
        {   pump_angle=135;  // rotation to align outlet with notch
            union()
            {   cylinder(h=platform_h, d=pump_d, $fs=0.1, $fa=1);
                color("cyan") linear_extrude(platform_h) polygon(
                    [[0,0], 
                     10*[cos(135+pump_angle), sin(135+pump_angle)],
                     // tangent1*pump_d/2,
                     tangent1*pump_d+[offset,0],
                     [pump_d,0], 
                     tangent2*pump_d+[offset,0],
                     tangent2*pump_d/2
                     ]);

            } 
            // notch for pump wires
            rotate([0,0,135+pump_angle]) translate([10+1.8,0,0])
                cylinder(d=7.2,h=3*platform_h, center=true, $fa=1, $fs=0.1);
            
            // ghost of pump to check alignment---not part of model
            % translate([0,0,platform_h]) rotate([0,0,pump_angle]) pump();
        }  
    }
}


module power_panel(arc=80,diam=127,height=40)
// minor bug:  the hole for the socket for barrel adapter is 
//      slightly too small.
//      The socket can be screwed into the hole, but not slid in.  
//      Slight sanding with a riffler was enough to fix the problem.
{
    outer_face = diam/2-1;
    wall_t = 5;
    cut_w = 16;
    difference()
    {   overhang=10;
        drilled_overhang(diam=diam,arc=arc,overlap_degrees=overhang);
        
        rotate(arc/2+overhang/2)
        {  translate([0,0,height/2]) 
              rotate([0,90,0])  // drop into +x direction
                  cylinder(d=7.7, h=diam/2+1, $fs=0.1);
            translate([outer_face,-35,0]) cube(70);  // outer face
            translate([outer_face-wall_t-cut_w, -cut_w/2, 0]) // inner face
                cube([cut_w,cut_w,height+0.001]);
        }
    }
}

// comment out all but one panel for making STL files
 pump_panel();
 color("red") rotate([0,0,90])notch_panel();
 color("green") rotate([0,0,170]) controller_panel();
 color("purple") rotate([0,0,280]) power_panel();

2019 August 31

Shakespeare cookies v7

Today (2019 August 31), my son and I baked shortbread cookies using version 7 of the Shakespeare cookie cutter, which is a two-part design with a separate cutter and stamp:

Version 7 of the Shakespeare cookie cutter uses a simple outline for the cutter and a separate stamp for adding the facial features. Version 6 of the stamp failed, because I made the alignment markers too thin and they did not survive even gentle handling.

In addition to the new cutter and stamp, we also tried out the “cookie sticks” that I made for rolling the dough to a consistent 6mm thickness:

I made two different sticks: a straight one and one with a 90° corner. The OpenSCAD file also allows other angles, so I could have made 120° corners for a hexagon.  I made the sticks about as big as I could print on the Monoprice Delta Mini.

The hooks at the two end of the stick lock the sticks together.

I made enough of the sticks to make a rectangular frame almost as big as my cookie sheets. I ran out of the ugly green PLA filament after only 3 sticks, so I did the rest in the Hatchbox gold PLA filament.

I made the same shortbread dough as last time: 1 cup butter, 2 cups pastry flour, and ½ cup powdered sugar. I cleared a counter to make some workspace:

I had a cookie sheet,a rolling pin (a piece of birch dowel that I sanded and coated with mineral oil decades ago), a silicone baking mat, the cookie sticks, the cookie cutter and stamp, and a shallow bowl for flour.

The entire batch fills about 2/3 of the frame when rolled out:

For the first batch, we tried rolling the dough directly on the silicone baking mat, and removing the excess dough without moving the cookies.

The cookie sticks worked well for getting a uniform, consistent thickness to the dough, and 6mm is about the right thickness for these cookies. Having a complete frame around the dough meant that I did not have to worry about the cookie sticks shifting position, nor what the orientation of the rolling pin was.

The stamping is easily done on the cookies, but removing the excess dough from between the cookies was harder than we expected. It probably didn’t help that it was a warm afternoon and the dough got sticky quickly, even though we refrigerated it before rolling.

For the second rolling, we rolled the dough onto waxed paper, then transferred the cut-out cookies to a baking sheet lined with a silicone mat, doing the stamping only after the cookies were on the baking sheet.

We ended up with 19 cookies from the batch, and they came out pretty good:

This picture is a bit misleading as these were probably the best two of the nineteen.

The biggest problem was with dough getting stuck in the nose when stamping—it might be easier to do Tycho Brahe cookie cutters!

The second biggest problem was getting accurate alignment of the stamp with the cutter. For several of the cutters we were a millimeter off, resulting in an extraneous line at one of the alignment markers.

Despite these minor problems, the v7 cutters were much easier to use than previous versions, and I don’t have any immediate ideas for improvements (other than changing from a 3D-printed cutter to a injection-molded cutter, which would require a lot of changes and cost a few thousand dollars—something I’m not prepared for.

Next Page »

%d bloggers like this: