diff --git a/main.scad b/main.scad index 9b8dccf..4cf12d8 100644 --- a/main.scad +++ b/main.scad @@ -99,8 +99,43 @@ module inner_contour_hull(h=1, a=5.7, b=3.2, z=6.88*2, a0=4.4,b0=2.1,z0=6.88*2) } } -module inner(h=70) { +module front_text(value="220", unit="Ω") { + color([0,0,1]) { + translate([0,4,6]) + linear_extrude(8) + text(value, size=6, halign="center", font="+Jakatar"); + + translate([0,-9,0]) + linear_extrude(8) + text(unit, size=10, halign="center", font="+Jakatar"); + } +} + +module front() { + render() + difference() { + cylinder(d=26.5, h=8, $fn=6); + + translate([0,-8,2]) + cylinder(d=24, h=6, $fn=6); + + translate([0,-3,1]) + cylinder(d=20, h=5, $fn=6); + } +} + +module inner_color(value, unit, h) { + translate([0,0,h]) + render() + intersection(){ + front(); + front_text(value, unit); + } +} + +module inner(value="220", unit="Ω", h=70) { +{ render() difference() { @@ -116,16 +151,12 @@ module inner(h=70) { // front translate([0,0,h]) { - front(); - - color([0,0,1]) - { - translate([0,4,10]) - text("220", size=6, halign="center", font="+Jakatar"); - - translate([0,-8,10]) - text("Ω", size=10, halign="center", font="+Jakatar"); - } + render() + difference() + { + front(); + front_text(value, unit); + } } } } @@ -143,10 +174,17 @@ module outer(h=70) { } -color([1,1,0]) translate([0,0,10]) -inner(h=70); +{ + + color([0.22,0.2,0.2]) + inner("220", "Ω", h=70); + + color([0.7,0.8,1.0]) + inner_color("220", "Ω", h=70); +} color([0.7, 0.4, 0.4]) outer(h=70); +