chiark / gitweb /
cf6f8cf50ad0c38dc7d599ecb1cee3687ac4931a
[dl-things.git] / th-8317 / FilamentSpool.scad
1 /*      Makerbottable Filament Spool v2.0
2                 by Randy Young <dadick83@hotmail.com>
3                 2010, 2011.   License, GPL v2 or later
4 **************************************************/
5
6 include <Libs.scad> //  Libs.scad is @ http://www.thingiverse.com/thing:6021
7
8 displayMode = rezPrinter();  // (rezPrinter | rezScreen)
9
10 // *** Arm Assembly Plate ***
11 //translate([-5,-19,0])
12 //      ExtensionArm();
13 //translate([0,-37,0])
14 //      ArmEnd();
15 //translate([30,-9,0]) rotate(loosen())
16 //      ForkClip();
17
18
19 // *** Hub Assembly Plate ***
20 //Hub();
21 //translate([-45,45,0]) rotate(tighten())
22 //      Spindle();
23 //translate([45,35,0]) rotate(tighten(180))
24 //      FilamentGuide();
25 //translate([35,15,0]) rotate(tighten())
26 //      FilamentGuide(drop=6, outrigger=0);
27
28
29 //-------------------------------------------------
30
31 module Hub(holeRadius =         5.5, ringThickness =    4){
32         union(){
33                 tube(holeRadius+ringThickness,ringThickness,10);
34                 tube(28,ringThickness,10);              
35                 for (i= [0:2])
36                         rotate (tighten(i*120+0))
37                         difference(){
38                                 translate(push (20+holeRadius/2)+lift(5))
39                                         cube([16,40-holeRadius,10], center=true);
40                                 translate(push((30+holeRadius)/2)+lift(10))
41                                         roundRect (size=[7.5,30-holeRadius-2*ringThickness,10], round=2, center=true);
42                                 translate(push(40)+lift(5)) rotate(tighten())
43                                         dovetail(height=10.1);
44 }       }       }
45
46 //-------------------------------------------------
47
48 module ExtensionArm (length=70,height=10){
49         translate(lift(5))
50         difference(){
51                 union(){
52                         cube([length,16,height], center=true);
53                         translate(slide(length/2)) dovetail(height=height);
54                 }
55                 translate(slide(2)) rotate(tighten())   slot([8,length-16,height+0.05], centerXYZ=[1,1,1]);
56                 translate(slide(-length/2-0.01)) dovetail(height=height+0.1,male=false);
57 }       }
58
59 //-------------------------------------------------
60
61 module ArmEnd(length=60){
62         translate(lift(5))
63                 difference(){
64                 union(){
65                         rotate(tighten()) slot([16,length,10], endRound=false, centerXYZ=[1,1,1]);
66                         translate(slide(length/2)) dovetail();
67                 }
68                 difference(){
69                         rotate(tighten())       slot([8,length-10,10.05], centerXYZ=[1,1,1]);
70                         translate([0, 4,0]) cube([3,2.8,11],center=true);
71                         translate([0,-4,0]) cube([3,2.8,11],center=true);
72                 }
73 }       }
74
75 //-------------------------------------------------
76
77 // Note: the ForkClip press fits into the slots on the ArmEnds.  Default settings match
78 //              the sizes of old MBI and Ultimaker (spoolless) 1lb rolls
79
80
81
82 module ForkClip(
83                         forkSize = [40,50,5],   // width, length, thickness
84                         armLength = 60,                 // This should be same as the ArmEnd length you chose
85                         filamentSize = 3,               // for filament holding tabs
86                         slotSize = [8,10],              // width, depth.  length derived from armLength
87                         forkOffset = 6.5)               // moves the fork up on the clip to fine tune filament diameter 
88
89         difference() {
90                 union(){
91                         translate(slide(slotSize[1]+1)+push(slotSize[0]+4.5+forkOffset)){
92                                 slot(forkSize, endRound=false,centerXYZ=0);
93                                 cube([forkSize[0]/2,forkSize[1],forkSize[2]]);
94                         }
95                         translate(lift(slotSize[0]/2-0.5)+push(slotSize[0]/2)){
96                                 rotate(righty()) 
97                                         cylinder(r1=slotSize[0]/2-0.5, r2=slotSize[0]/2+0.5, h=slotSize[1]-0.5, 
98                                                 $fn=resolution(slotSize[0]/2));
99                                 translate(push(armLength-10-slotSize[0]))
100                                         rotate(righty()) 
101                                         cylinder(r1=slotSize[0]/2-0.5, r2=slotSize[0]/2+0.5, h=slotSize[1]-0.5, 
102                                                 $fn=resolution(slotSize[0]/2));
103                         }
104                         translate(push(slotSize[0]/2))
105                                 cube([slotSize[1]-0.5,armLength-10-slotSize[0],1.51]); // spring
106                         translate(push(slotSize[0]+2.5)) 
107                                 cube([slotSize[1]+forkSize[2],armLength-15-2*slotSize[0],forkSize[2]]);
108                 }
109                 translate(slide(slotSize[1]+1+forkSize[2])+push(slotSize[0]+4.5+forkOffset+forkSize[2]))
110                                 slot([forkSize[0]-2*forkSize[2],forkSize[1],forkSize[2]*2.1], endRound=false,centerXYZ=[0,0,1]);
111                 translate([-ep,0,-5]) 
112                         cube([slotSize[1]+2*ep,armLength-10,5+ep]);
113                 translate([slotSize[1]+forkSize[2]-1.1,slotSize[0]+3.5+filamentSize*0.33,-ep]) 
114                         cube([1.2,filamentSize*0.77,forkSize[2]+1]);
115                 translate([slotSize[1],slotSize[0]+3.5,-0.01]) rotate(tighten())
116                         slot([filamentSize*1.1,forkSize[2]-1,forkSize[2]+0.1], endRound=false, centerXYZ=[2,0,0]);
117         }
118
119 //-------------------------------------------------
120
121 module Spindle(
122         postDiameter =  10.5,                           // matched to size of hole in hub
123         hubThickness =  11,                             // length of post before flange
124         drop =                  30,                             // distance hook hangs down from edge it's clipped to
125         overhang =              6,                              // length hook overlaps edge
126         plywood =               5,                              // thickness of wall hook is attached to
127         outrigger =             8,                              // standoff distance from hook
128         girth =                         5,                              // beefiness, thickness of hook (width governed by postDiameter)
129         springTab =             0,                              // use 0 for none.  tensioner that presses against hub to provide friction
130         springSize =            [1.5,18,5])             // if springTab is used.  Only needed if you're using a hub with bearing
131
132         difference(){
133                 translate(lift(-0.75)) difference(){
134                         union(){
135                                 cube([2*girth+plywood+outrigger, drop+girth, postDiameter]);
136                                 translate([2*girth+plywood+outrigger-ep,postDiameter/2+1,postDiameter/2])
137                                 rotate(righty()){ 
138                                         cylinder(r=postDiameter/2, h=hubThickness*2);
139                                         translate(lift(hubThickness))
140                                                 cylinder(r1=postDiameter/2+1.3, r2=postDiameter/2, h=hubThickness);
141                                 }
142                                 if (springTab>0){
143                                         translate([2*girth+plywood+outrigger-springTab-1,ep-springSize[1],0.75]) {
144                                                 cube(springSize);
145                                                 cube([springTab+1,springTab*2,springSize[2]]);
146                                                 translate([springTab+1,springTab,springSize[2]/2]) sphere(springTab);
147                                 }       }
148                         }
149                         translate([-ep,-ep,-ep]){
150                                 cube([girth+plywood,drop-overhang,postDiameter+1]);
151                                 translate([2*girth+plywood+ep,postDiameter+2,0])
152                                         cube([outrigger+ep,drop,postDiameter+1]);
153                                 translate([girth,0,0])
154                                         cube([plywood,drop,postDiameter+1]);
155                                 translate([2*girth+plywood+outrigger+ep,postDiameter/2+1,0])    linear_extrude(2)
156                                         polygon(points=[        [-outrigger/2,0],
157                                                                         [hubThickness*2,postDiameter/4],
158                                                                         [hubThickness*2,-postDiameter/4]]);
159                         }
160                 }
161                 translate([-ep,-ep,-5]) cube([100,100,5]);
162                 translate([-ep,-ep,postDiameter-1.5]) cube([100,100,5]);
163 }
164
165
166 //-------------------------------------------------
167
168 module FilamentGuide(
169         tubeDiameter =  0.25*in,                        // size of filament hole
170         tubeThickness = 1.5,                            // thickness of gude tube
171         drop =                  10,                             // distance hook hangs down from edge it's clipped to
172         overhang =              6,                              // length hook overlaps edge
173         plywood =               5,                              // thickness of wall hook is attached to
174         outrigger =             15,                             // standoff distance from hook
175         girth =                         4)                              // beefiness, thickness/width of hook
176
177         difference(){
178                 union(){
179                         cube([2*girth+plywood, drop+girth, girth]);
180                         cube([2*girth+plywood+outrigger, girth, girth]);
181                         translate([girth*2+plywood+outrigger+tubeDiameter/2,girth/2,0])
182                                 tube(tubeDiameter/2+tubeThickness,tubeThickness,girth);
183
184                 }
185                 translate([-ep,-ep,-ep]){
186                         cube([girth+plywood,drop-overhang,girth+2*ep]);
187                 translate([girth,0,0])
188                         cube([plywood,drop+ep,girth+2*ep]);
189                 translate([girth*2+plywood+outrigger+tubeDiameter/1.5,girth/2-tubeDiameter/4,0])
190                         cube([plywood,tubeDiameter/2,girth+2*ep]);
191                 }
192 }
193
194
195