IEC mains connector models more accurate.
Before Width: | Height: | Size: 180 KiB After Width: | Height: | Size: 179 KiB |
Before Width: | Height: | Size: 34 KiB After Width: | Height: | Size: 34 KiB |
Before Width: | Height: | Size: 122 KiB After Width: | Height: | Size: 121 KiB |
Before Width: | Height: | Size: 25 KiB After Width: | Height: | Size: 25 KiB |
Before Width: | Height: | Size: 131 KiB After Width: | Height: | Size: 130 KiB |
Before Width: | Height: | Size: 26 KiB After Width: | Height: | Size: 26 KiB |
@ -60,7 +60,7 @@ insert_length = insert_length(insert);
|
||||
insert_boss = mains_socket_insert_boss(socket);
|
||||
screw_length = screw_longer_than(mains_socket_height(socket) + insert_length(insert));
|
||||
|
||||
iec_h = iec_slot_h(iec) + 1;
|
||||
iec_h = iec_body_h(iec) + 1;
|
||||
|
||||
box_height = socket_depth + iec_h;
|
||||
base_thickness = wall;
|
||||
|
Before Width: | Height: | Size: 108 KiB After Width: | Height: | Size: 108 KiB |
BIN
libtest.png
Before Width: | Height: | Size: 657 KiB After Width: | Height: | Size: 659 KiB |
18
readme.md
@ -766,6 +766,10 @@ IEC mains inlets and outlet.
|
||||
| ```iec_bezel_r(type)``` | Bezel corner radius |
|
||||
| ```iec_bezel_t(type)``` | Bezel thickness |
|
||||
| ```iec_bezel_w(type)``` | Bezel width |
|
||||
| ```iec_body_h(type)``` | Body height |
|
||||
| ```iec_body_r(type)``` | Body corner radius |
|
||||
| ```iec_body_w(type)``` | Body width |
|
||||
| ```iec_body_w2(type)``` | Body width at the narrow part |
|
||||
| ```iec_depth(type)``` | Depth of the body below the flange |
|
||||
| ```iec_flange_h(type)``` | Flange height |
|
||||
| ```iec_flange_r(type)``` | Flange corner radius |
|
||||
@ -775,9 +779,6 @@ IEC mains inlets and outlet.
|
||||
| ```iec_part(type)``` | Description |
|
||||
| ```iec_pitch(type)``` | Screw hole pitch |
|
||||
| ```iec_screw(type)``` | Screw type |
|
||||
| ```iec_slot_h(type)``` | Body height |
|
||||
| ```iec_slot_r(type)``` | Body corner radius |
|
||||
| ```iec_slot_w(type)``` | Body width |
|
||||
| ```iec_spades(type)``` | Spade type |
|
||||
| ```iec_width(type)``` | Widest part including the lugs |
|
||||
|
||||
@ -800,14 +801,15 @@ IEC mains inlets and outlet.
|
||||
### Vitamins
|
||||
| Qty | Module call | BOM entry |
|
||||
| ---:|:--- |:---|
|
||||
| 1 | ```iec(IEC_fused_inlet)``` | IEC fused inlet |
|
||||
| 1 | ```iec(IEC_fused_inlet)``` | IEC fused inlet JR-101-1F |
|
||||
| 1 | ```iec(IEC_fused_inlet2)``` | IEC fused inlet old |
|
||||
| 1 | ```iec(IEC_inlet)``` | IEC inlet |
|
||||
| 1 | ```iec(IEC_inlet_atx)``` | IEC inlet for ATX |
|
||||
| 1 | ```iec(IEC_outlet)``` | IEC outlet |
|
||||
| 8 | ```nut(M3_nut, nyloc = true)``` | Nut M3 x 2.4mm nyloc |
|
||||
| 1 | ```iec(IEC_outlet)``` | IEC outlet RS 811-7193 |
|
||||
| 10 | ```nut(M3_nut, nyloc = true)``` | Nut M3 x 2.4mm nyloc |
|
||||
| 4 | ```screw(M3_cs_cap_screw, 10)``` | Screw M3 cs cap x 10mm |
|
||||
| 4 | ```screw(M3_cs_cap_screw, 12)``` | Screw M3 cs cap x 12mm |
|
||||
| 8 | ```washer(M3_washer)``` | Washer M3 x 7mm x 0.5mm |
|
||||
| 6 | ```screw(M3_cs_cap_screw, 12)``` | Screw M3 cs cap x 12mm |
|
||||
| 10 | ```washer(M3_washer)``` | Washer M3 x 7mm x 0.5mm |
|
||||
|
||||
|
||||
<a href="#top">Top</a>
|
||||
|
Before Width: | Height: | Size: 44 KiB After Width: | Height: | Size: 41 KiB |
Before Width: | Height: | Size: 201 KiB After Width: | Height: | Size: 201 KiB |
Before Width: | Height: | Size: 25 KiB After Width: | Height: | Size: 27 KiB |
@ -30,21 +30,22 @@ include <inserts.scad>
|
||||
function iec_part(type) = type[1]; //! Description
|
||||
function iec_screw(type) = type[2]; //! Screw type
|
||||
function iec_pitch(type) = type[3]; //! Screw hole pitch
|
||||
function iec_slot_w(type) = type[4]; //! Body width
|
||||
function iec_slot_h(type) = type[5]; //! Body height
|
||||
function iec_slot_r(type) = type[6]; //! Body corner radius
|
||||
function iec_bezel_w(type) = type[7]; //! Bezel width
|
||||
function iec_bezel_h(type) = type[8]; //! Bezel height
|
||||
function iec_bezel_r(type) = type[9]; //! Bezel corner radius
|
||||
function iec_bezel_t(type) = type[10]; //! Bezel thickness
|
||||
function iec_flange_w(type) = type[11]; //! Flange width not including the lugs
|
||||
function iec_flange_h(type) = type[12]; //! Flange height
|
||||
function iec_flange_r(type) = type[13]; //! Flange corner radius
|
||||
function iec_flange_t(type) = type[14]; //! Flange thickness
|
||||
function iec_width(type) = type[15]; //! Widest part including the lugs
|
||||
function iec_depth(type) = type[16]; //! Depth of the body below the flange
|
||||
function iec_spades(type) = type[17]; //! Spade type
|
||||
function iec_male(type) = type[18]; //! True for an outlet
|
||||
function iec_body_w(type) = type[4]; //! Body width
|
||||
function iec_body_w2(type) = type[5]; //! Body width at the narrow part
|
||||
function iec_body_h(type) = type[6]; //! Body height
|
||||
function iec_body_r(type) = type[7]; //! Body corner radius
|
||||
function iec_bezel_w(type) = type[8]; //! Bezel width
|
||||
function iec_bezel_h(type) = type[9]; //! Bezel height
|
||||
function iec_bezel_r(type) = type[10]; //! Bezel corner radius
|
||||
function iec_bezel_t(type) = type[11]; //! Bezel thickness
|
||||
function iec_flange_w(type) = type[12]; //! Flange width not including the lugs
|
||||
function iec_flange_h(type) = type[13]; //! Flange height
|
||||
function iec_flange_r(type) = type[14]; //! Flange corner radius
|
||||
function iec_flange_t(type) = type[15]; //! Flange thickness
|
||||
function iec_width(type) = type[16]; //! Widest part including the lugs
|
||||
function iec_depth(type) = type[17]; //! Depth of the body below the flange
|
||||
function iec_spades(type) = type[18]; //! Spade type
|
||||
function iec_male(type) = type[19]; //! True for an outlet
|
||||
|
||||
insert_screw_length = 10;
|
||||
function iec_insert_screw_length() = insert_screw_length; //! Screw length used for inserts
|
||||
@ -68,10 +69,10 @@ module iec(type) { //! Draw specified IEC connector
|
||||
cube([pin_w, pin_d, h - pin_chamfer], center = true);
|
||||
}
|
||||
|
||||
socket_w = 24;
|
||||
socket_w = 24.5;
|
||||
socket_w2 = 14;
|
||||
socket_h = 16.5;
|
||||
socket_h2 = 12;
|
||||
socket_h = 16.34;
|
||||
socket_h2 = socket_h - (socket_w - socket_w2);
|
||||
socket_d = 17;
|
||||
socket_r = 3;
|
||||
socket_r2 = 0.5;
|
||||
@ -83,7 +84,7 @@ module iec(type) { //! Draw specified IEC connector
|
||||
translate([side * (socket_w / 2 - socket_r), -socket_h / 2 + socket_r])
|
||||
circle(socket_r);
|
||||
|
||||
translate([side * (socket_w / 2 - socket_r2), -socket_h / 2 + socket_h2 + socket_r2])
|
||||
translate([side * (socket_w / 2 - socket_r2), socket_h2 / 2 - socket_r2])
|
||||
circle(socket_r2);
|
||||
|
||||
translate([side * (socket_w2 / 2 - socket_r2), socket_h / 2 - socket_r2])
|
||||
@ -94,7 +95,7 @@ module iec(type) { //! Draw specified IEC connector
|
||||
translate([0, socket_offset])
|
||||
if(iec_male(type))
|
||||
difference() {
|
||||
offset(3)
|
||||
offset(2)
|
||||
socket_shape();
|
||||
|
||||
difference() {
|
||||
@ -111,6 +112,28 @@ module iec(type) { //! Draw specified IEC connector
|
||||
else
|
||||
socket_shape();
|
||||
|
||||
module body_shape() {
|
||||
hull() {
|
||||
bw = iec_body_w(type);
|
||||
bh = iec_body_h(type);
|
||||
br = iec_body_r(type);
|
||||
bw2 = iec_body_w2(type);
|
||||
bh2 = bh - (bw - bw2);
|
||||
br2 = 1;
|
||||
|
||||
for(side = [-1, 1]) {
|
||||
translate([side * (bw / 2 - br), -bh / 2 + br])
|
||||
circle4n(br);
|
||||
|
||||
translate([side * (bw / 2 - br2), bh2 / 2 - br2])
|
||||
circle4n(br2);
|
||||
|
||||
translate([side * (bw2 / 2 - br2), bh / 2 - br2])
|
||||
circle4n(br2);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
color(grey20) {
|
||||
// Flange
|
||||
flange_t = iec_flange_t(type);
|
||||
@ -153,12 +176,14 @@ module iec(type) { //! Draw specified IEC connector
|
||||
translate_z(-h)
|
||||
linear_extrude(height = h)
|
||||
difference() {
|
||||
rounded_square([iec_slot_w(type), iec_slot_h(type)], iec_slot_r(type));
|
||||
body_shape();
|
||||
|
||||
oriffice_shape();
|
||||
}
|
||||
// Back
|
||||
translate_z(-iec_depth(type))
|
||||
rounded_rectangle([iec_slot_w(type), iec_slot_h(type), iec_depth(type) - h], iec_slot_r(type), center = false);
|
||||
linear_extrude(height = iec_depth(type) - h)
|
||||
body_shape();
|
||||
}
|
||||
if(!iec_male(type))
|
||||
translate([0, socket_offset, iec_flange_t(type) + iec_bezel_t(type) - socket_d]) {
|
||||
@ -175,6 +200,8 @@ module iec(type) { //! Draw specified IEC connector
|
||||
spade(spade[0], spade[1]);
|
||||
}
|
||||
|
||||
function iec_spade_depth(type) = iec_depth(type) + max([for(spade = iec_spades(type)) spade[1]]);
|
||||
|
||||
module iec_screw_positions(type) //! Position children at the screw holes
|
||||
for(side = [-1, 1])
|
||||
translate([side * iec_pitch(type) / 2, 0])
|
||||
@ -204,11 +231,11 @@ module iec_holes(type, h = 100, poly = false, horizontal = false, insert = false
|
||||
extrude_if(h)
|
||||
hull()
|
||||
for(x = [-1, 1], y = [-1, 1], sag = horizontal && y > 1 ? layer_height : 0)
|
||||
translate([x * (iec_slot_w(type) / 2 - iec_slot_r(type)), y * (iec_slot_h(type) / 2 - iec_slot_r(type) + sag )])
|
||||
translate([x * (iec_body_w(type) / 2 - iec_body_r(type)), y * (iec_body_h(type) / 2 - iec_body_r(type) + sag )])
|
||||
if(horizontal)
|
||||
teardrop(0, iec_slot_r(type) + clearance / 2 + layer_height / 4);
|
||||
teardrop(0, iec_body_r(type) + clearance / 2 + layer_height / 4);
|
||||
else
|
||||
drill(iec_slot_r(type) + clearance / 2, 0);
|
||||
drill(iec_body_r(type) + clearance / 2, 0);
|
||||
}
|
||||
|
||||
module iec_inserts(type) { //! Place the inserts
|
||||
|
@ -19,29 +19,43 @@
|
||||
include <screws.scad>
|
||||
include <spades.scad>
|
||||
|
||||
fused_spades = [[spade6p4, 14, -7, 0, 0],
|
||||
[spade6p4, 14, 7, 0, 0],
|
||||
[spade6p4, 14, 0, 11, 0],
|
||||
fused_spades = [[spade4p8, 8.5, 7, 3, 90],
|
||||
[spade4p8, 8.5, 0, 7, 90],
|
||||
[spade4p8, 8.5, 5, -7, 90]];
|
||||
|
||||
fused_spades2 = [[spade6p4, 13, -7, 0, 0],
|
||||
[spade6p4, 13, 7, 0, 0],
|
||||
[spade6p4, 13, 0, 11, 0],
|
||||
[spade4p8, 8.5, -7, -9, 90],
|
||||
[spade4p8, 8.5, 7, -9, 90]];
|
||||
|
||||
inlet_spades = [[spade6p4, 9, -7, -5.5, 0],
|
||||
[spade6p4, 9, 7, -5.5, 0],
|
||||
[spade6p4, 9, 0, 5.5, 0]];
|
||||
//
|
||||
// p s p s s s b b b b f f f f w d s m
|
||||
// a c i l l l e e e e l l l l i e p a
|
||||
// r r t o o o z z z z a a a a d p a l
|
||||
// t e c t t t e e e e n n n n t t d e
|
||||
// w h l l l l g g g g h h e
|
||||
// w h r e e e e s
|
||||
// w h r t
|
||||
// w h r t
|
||||
//
|
||||
IEC_fused_inlet = ["IEC_fused_inlet", "IEC fused inlet", M3_cs_cap_screw, 36, 27.3, 31.2, 3, 28, 31, 2, 2.5, 30, 33, 4, 2.5, 44, 21, fused_spades, false ];
|
||||
IEC_inlet = ["IEC_inlet", "IEC inlet", M3_cs_cap_screw, 40, 28.2, 20.2, 3, 28, 20.5, 4, 2.5, 37, 23, 1, 2.5, 48, 14, inlet_spades, false ];
|
||||
IEC_inlet_atx = ["IEC_inlet_atx", "IEC inlet for ATX", M3_cs_cap_screw, 40, 27.0, 19.0, 3, 30, 22, 2, 2.0, 30, 22, 2, 4.0, 50, 13, inlet_spades, false ];
|
||||
IEC_outlet = ["IEC_outlet", "IEC outlet", M3_cs_cap_screw, 40, 32, 24, 3, 28, 20.5, 2, 0.0, 29, 29, 2, 2.9, 50, 23, inlet_spades, true ];
|
||||
|
||||
iecs = [IEC_inlet, IEC_inlet_atx, IEC_fused_inlet, IEC_outlet];
|
||||
atx_spades = [[spade3p5, 8, -7, -3, 90],
|
||||
[spade3p5, 8, 7, -3, 90],
|
||||
[spade3p5, 8, 0, 3, 90]];
|
||||
|
||||
outlet_spades = [[spade4p8ll, 8, -7, -2, 90],
|
||||
[spade4p8ll, 8, 7, -2, 90],
|
||||
[spade4p8ll, 8, 0, 2, 90]];
|
||||
|
||||
//
|
||||
// p s p b b b b b b b b f f f f w d s m
|
||||
// a c i o o o o e e e e l l l l i e p a
|
||||
// r r t d d d d z z z z a a a a d p a l
|
||||
// t e c y y y y e e e e n n n n t t d e
|
||||
// w h l l l l g g g g h h e
|
||||
// w w h r e e e e s
|
||||
// 2 w h r t
|
||||
// w h r t
|
||||
IEC_fused_inlet = ["IEC_fused_inlet", "IEC fused inlet JR-101-1F", M3_cs_cap_screw, 36, 27, 16, 31, 3, 28, 31, 2, 2.0, 30, 33, 4, 3.0, 44, 15, fused_spades, false ];
|
||||
IEC_fused_inlet2= ["IEC_fused_inlet2","IEC fused inlet old", M3_cs_cap_screw, 36, 27, 14, 31, 3, 28, 31, 2, 2.5, 30, 33, 4, 2.5, 44, 18, fused_spades2, false ];
|
||||
|
||||
IEC_inlet = ["IEC_inlet", "IEC inlet", M3_cs_cap_screw, 40, 28, 18, 20, 3, 28, 20.5, 4, 2.5, 37, 23, 1, 2.5, 48, 14, inlet_spades, false ];
|
||||
IEC_inlet_atx = ["IEC_inlet_atx", "IEC inlet for ATX", M3_cs_cap_screw, 40, 27, 18, 19, 3, 30.5, 22, 2, 2.0, 30.5, 22, 2, 4.0, 50, 15, atx_spades, false ];
|
||||
IEC_outlet = ["IEC_outlet", "IEC outlet RS 811-7193", M3_cs_cap_screw, 40, 32, 18, 24, 3, 28, 20.5, 2, 0.0, 29, 29, 2, 2.8, 50, 23, outlet_spades, true ];
|
||||
|
||||
iecs = [IEC_inlet, IEC_inlet_atx, IEC_fused_inlet, IEC_fused_inlet2, IEC_outlet];
|
||||
use <iec.scad>
|
||||
|
@ -17,12 +17,13 @@
|
||||
// If not, see <https://www.gnu.org/licenses/>.
|
||||
//
|
||||
|
||||
spade3 = [3.8, 3.0, 0.4, 1.0, 3.9];
|
||||
spade6p4 = [8.3, 6.4, 0.8, 1.8, 8];
|
||||
spade4p8 = [6.4, 4.8, 0.5, 1.8, 8];
|
||||
spade4p8l = [7.0, 4.8, 0.5, 1.8, 8];
|
||||
spade4p8ll = [8.0, 4.8, 0.5, 1.8, 4.8];
|
||||
spade3 = [3.8, 3.0, 0.4, 1.0, 3.9];
|
||||
spade3p5 = [7.0, 3.5, 0.8, 1.75, 6.8];
|
||||
spade6p4 = [8.3, 6.4, 0.8, 1.8, 8];
|
||||
spade4p8 = [6.4, 4.8, 0.5, 1.8, 8];
|
||||
spade4p8l = [7.0, 4.8, 0.5, 1.8, 8];
|
||||
spade4p8ll = [8.0, 4.8, 0.5, 1.8, 4.8];
|
||||
|
||||
spades = [spade3, spade6p4, spade4p8, spade4p8l, spade4p8ll];
|
||||
spades = [spade3, spade3p5, spade6p4, spade4p8, spade4p8l, spade4p8ll];
|
||||
|
||||
use <spade.scad>
|
||||
|