chiark / gitweb /
air-hockey-puck: wip
[reprap-play.git] / quacks-ingredients-demos.scad
1 // -*- C -*-
2
3 include <quacks-ingredients.scad>
4
5 sandingframe_gap = 0.3; // to be added to radius
6 sandingframe_nw = 5;
7 sandingframe_nl = 6;
8 sandingframe_th = thick*2/3;
9
10 module Demo(){ ////toplevel
11   $nspots = 3;
12   color("red") { Token_L3(); }
13   color("white") { Token_L1(); Token_L5(); }
14   color("black") { Token_L2(); Token_L4(); }
15 }
16
17 module SandingFrame(){ ////toplevel
18   stridel = token_dia + 5;
19   nl = sandingframe_nl;
20   nw = sandingframe_nw;
21   stridew = stridel * cos(30);
22   stride = [stridel,stridew];
23
24   linear_extrude(height = sandingframe_th) {
25     difference(){
26       translate((token_dia/2 + stridel) * 0.5 * [-1,-1])
27         square([ stridel * (nl + 0.5),
28                  stridew * nw + stridel * 0.5 ]);
29       for (j = [0 : nw-1]) {
30         eo = j % 2;
31         for (i = [0 : nl-1-0.5*eo]) {
32           translate([stridel * (i + 0.5 * eo),
33                      stridew * j])
34             circle(r = token_dia/2 + sandingframe_gap);
35         }
36       }
37     }
38   }
39 }