chiark / gitweb /
yubikey-5c-nano-loop: wip
[reprap-play.git] / yubikey-5c-nano-loop.scad
1 // -*- C -*-
2
3 include <utils.scad>
4
5 base = [ 8.4, 4.1 ];
6 base_th = 0.7;
7 base_slope = 2.0;
8
9 hoop_th = 2.8;
10 hoop_inner_dia = 2.5;
11
12 // caclulated
13
14 module Base() {
15   hull(){
16     linextr(-base_th, -base_th + 0.01)
17       square(base, center=true);
18     linextr(-base_th, 0)
19       square(base - 2 * base_th * base_slope * [1,1], center=true);
20   }
21 }
22
23 module Loop() {
24   intersection(){
25     rotate([90, 0,0]){
26       rotate_extrude(){
27         translate([hoop_inner_dia/2 + hoop_th/2, 0])
28           circle(r = hoop_th/2);
29       }
30     }
31     linextr(-0.1, hoop_inner_dia*2)
32       square(hoop_inner_dia*4, center=true);
33   }
34 }
35
36 module Whole() {
37   Base();
38   Loop();
39 }
40
41 Whole();