Eagle/packages/packages.scad
2023-06-10 11:22:50 +02:00

4912 lines
216 KiB
OpenSCAD
Executable file

Detailgrad = Detailgrad ? Detailgrad : 10;
EnableText = EnableText ? EnableText : false;
function defined(a) = (a != undef);
Package_path = (defined(Package_path)) ? str(Package_path,"packages_STL/") : "./packages_STL/";
function downcase(str) =
str_join([for(char=str) let(code=ord(char)) code>=65 && code<=90 ? chr(code+32) : char]);
module LPV2(Name="",Value="",Library="") {translate([1*1.27,0,0]) rotate([0,0,180]) LPV(2);}
module LPV2_SN(Name="",Value="",Library="") {translate([1*1.27,0,0]) rotate([0,0,180]) LPV(2);}
module LPV2_NTR(Name="",Value="",Library="") {translate([1*1.27,0,0]) rotate([0,0,180]) LPV(2);}
module LPV3(Name="",Value="",Library="") {translate([2*1.27,0,0]) rotate([0,0,180]) LPV(3);}
module LPV3_SN(Name="",Value="",Library="") {translate([2*1.27,0,0]) rotate([0,0,180]) LPV(3);}
module LPV3_SN2(Name="",Value="",Library="") {translate([2*1.27,0,0]) rotate([0,0,180]) LPV(3);}
module LPV5_SN(Name="",Value="",Library="") {translate([4*1.27,0,0]) rotate([0,0,180]) LPV(5);}
module LPV6_SN(Name="",Value="",Library="") {translate([5*1.27,0,0]) rotate([0,0,180]) LPV(6);}
module LPV8_SN(Name="",Value="",Library="") {translate([7*1.27,0,0]) rotate([0,0,180]) LPV(8);}
module LPV9_SN(Name="",Value="",Library="") {translate([8*1.27,0,0]) rotate([0,0,180]) LPV(9);}
module LPV3L(Name="",Value="",Library="") {translate([2*1.27,0,0]) rotate([0,0,180]) LPVL(3);}
module LPV4L_SN(Name="",Value="",Library="") {translate([3*1.27,0,0]) rotate([0,0,180]) LPVL(4);}
module JST_10(Name="",Value="",Library="") {translate([12,0,0]) rotate([0,0,180]) JST(10);}
module JST_8(Name="",Value="",Library="") {translate([8,0,0]) rotate([0,0,180]) JST(8);}
module JST_7(Name="",Value="",Library="") {translate([6,0,0]) rotate([0,0,180]) JST(7);}
module JST_6(Name="",Value="",Library="") {translate([4,0,0]) rotate([0,0,180]) JST(6);}
module JST_5(Name="",Value="",Library="") {translate([4,0,0]) rotate([0,0,180]) JST(5);}
module JST_4(Name="",Value="",Library="") {translate([4,0,0]) rotate([0,0,180]) JST(4);}
module JST_3(Name="",Value="",Library="") {translate([2,0,0]) rotate([0,0,180]) JST(3);}
module JST_2(Name="",Value="",Library="") {translate([1,0,0]) rotate([0,0,180]) JST(2);}
module JST_2L(Name="",Value="",Library="") {translate([-1,0,0]) JSTL(2);}
module JST_3L(Name="",Value="",Library="") {translate([-2,0,0]) JSTL(3);}
module JST_4L(Name="",Value="",Library="") {translate([-2,0,0]) JSTL(4);}
module JST_5L(Name="",Value="",Library="") {translate([-4,0,0]) JSTL(5);}
module JST_6L(Name="",Value="",Library="") {translate([-6,0,0]) JSTL(6);}
module JST_7L(Name="",Value="",Library="") {translate([-6,0,0]) JSTL(7);}
module JST_8L(Name="",Value="",Library="") {translate([-8,0,0]) JSTL(8);}
module JST_10L(Name="",Value="",Library="") {translate([-2,0,0]) JSTL(10);}
module JST_2_SM (Name="",Value="",Library="") {JSTSMD(n=2);}
module JST_PH2P_ST90S(Name="",Value="",Library="") {translate([0,0,0]) JSTLSMD(2);}
module JSTS_14L(Name="",Value="",Library="") {translate([-2,-2.8,0]) rotate([0,0,180]) SMD_IC([16,5.6,2],pinrows=1,pitch=1);}
module JSTS_10L(Name="",Value="",Library=""){translate([-1,-2.8,0]) rotate([0,0,180]) SMD_IC([12.8,5.6,2],pinrows=1,pitch=1);}
module JST_XH_03_PACKAGE_ROUND_PAD(Name="",Value="",Library="") {translate([-2.5,0,0]) JSTXH(3);}
module JST_XH_04_PACKAGE_LONG_PAD(Name="",Value="",Library="") {translate([-2.5-1.25,0,0]) JSTXH(4);}
module JST_XH_05_PACKAGE_ROUND_PAD(Name="",Value="",Library="") {translate([-2*2.5,0,0]) JSTXH(5);}
module JST_B4B_XH_A(Name="",Value="",Library="") {translate([+5-1.25,0,0]) rotate([0,0,180])JSTXH(4);}
module MSTBV4A(Name="",Value="",Library="") {MSTBV(4,Library);BL508(4);}
module MSTBV3(Name="",Value="",Library="") {MSTBV(3,Library);}
module MSTBA4I(Name="",Value="",Library="") {translate([5.08*1.5,0,4]) rotate([90,0,180]) MSTBV(n = 4);}
module MSTBA5I(Name="",Value="",Library="") {translate([5.08*2,0,4]) rotate([90,0,180]) MSTBV(n = 5);}
module BL2(Name="",Value="",Library="") {translate([5.08*0,0,4]) rotate([90,0,180]) MSTBV(n = 2);}
// M8
module F3_S718 (Name="",Value="",Library="") {cylinder(15,7,7);}
// M12
module M12_S5A(Name="",Value="",Library="") {M12_S(Pincount=5, binder = true);}
module M12_S5A_FLAT(Name="",Value="",Library="") {translate([0,0,-3]) M12_S(Pincount=5, binder = true);}
module M12_S8(Name="",Value="",Library="") {
color("silver") difference()
{
union() { cylinder(18,13.5/2,13.5/2); cylinder(11,15/2,15/2); cylinder(2,18/2,18/2); translate([0,0,8]) cylinder(2,20/2,20/2, $fn=6); }
translate([0,0,4]) cylinder(15,12/2,12/2);
}
translate([0,0,3]) color("DarkSlateGray") difference()
{
cylinder(16,4,4);
rotate([0,0,175]) make_ring_of(radius = 2.8, count=7, pie = 330) cylinder(17,0.5,0.5);
cylinder(17,0.5,0.5);
rotate([0,0,45]) translate([4,0,-0.2]) cylinder(17,0.7,0.7);
}
color("DarkSlateGray") translate([0,0,3]) rotate_extrude() translate([8,0])circle(1);
}
module M12_S(Pincount=5, binder = true)
{
l = binder ? 25.5 : 26; // 09 3442 90 05 Else TE: T4141012051-000
hr = binder ? 3 : 4;
translate([0,0,3])
{
color("silver") difference()
{
cylinder(12,15/2,15/2);
rotate([0,0,45]){
translate([-10,0-13.5/2-5,0.8]) cube([20,5,20]);
translate([-10,13.5/2,0.8]) cube([20,5,20]);
}
}
color("silver") difference()
{
union() { cylinder(l-7,13.5/2,13.5/2); translate([0,0,hr-3]) cylinder(2,18/2,18/2, $fn=6); translate([0,0,6]) cylinder(2.8,20/2,20/2, $fn=6); }
translate([0,0,4]) cylinder(16,12/2,12/2);
}
translate([0,0,1]) color("DarkSlateGray") difference()
{
cylinder(l-7,4,4);
if (Pincount < 6)
{
make_ring_of(radius = 2.5, count=4) cylinder(l-6,0.7,0.7);
cylinder(l-6,0.7,0.7);
rotate([0,0,45]) translate([4,0,-0.2]) cylinder(l-6,1,1);
}
if (Pincount == 8)
{
rotate([0,0,175]) make_ring_of(radius = 2.8, count=7, pie = 330) cylinder(17,0.5,0.5);
cylinder(17,0.5,0.5);
rotate([0,0,45]) translate([4,0,-0.2]) cylinder(17,0.7,0.7);
}
}
color("DarkSlateGray") translate([0,0,hr]) rotate_extrude() translate([8,0])circle(1);
}
if (Pincount == 5)
{
make_ring_of(radius = 5/2, count=4) cylinderpart(size = [1.6,3]);
cylinderpart(size = [1.6,3]);
make_ring_of(radius = 5/2, count=4) LOETPIN(height = 3,dim = 1,rnd = true);
LOETPIN(height = 3, dim = 1,rnd = true);
}
}
module M12_P_SINGLE(Pincount = 5)
{
l = 23; // Binder 09 3441 90 05
// Körper
color("silver") difference()
{
union() {
cylinder(l-1,12/2,12/2);
}
translate([0,0,4]) cylinder(l,11.02/2,11.02/2);
}
union()
{
translate([0,0,1]) difference()
{
color("DarkSlateGray") cylinder(l-1,11/2,11/2);
color("DarkSlateGray") cylinder(l,4,4);
}
color("DarkSlateGray") rotate([0,0,45]) translate([4,0,1-0.2]) cylinder(l-1,1,1);
if (Pincount == 5) color("silver")
{
make_ring_of(radius = 2.5, count=4) cylinder(l-1,0.5,0.57);
cylinder(l-1,0.5,0.5);
}
}
}
module M12_P(Pincount = 5)
{
l = 23; // Binder 09 3441 90 05
hr = 3;
translate([0,0,hr])
{
// PG9 Verschraubung
color("silver") difference()
{
cylinder(l-11,15/2,15/2);
rotate([0,0,45]){
translate([-10,0-13.5/2-5,0.8]) cube([20,5,20]);
translate([-10,13.5/2,0.8]) cube([20,5,20]);
}
}
// Körper
color("silver") difference()
{
union() {
cylinder(l-1,12/2,12/2);
cylinder(2,18/2,18/2, $fn=6); // Sockelmutter
translate([0,0,6]) cylinder(2.8,20/2,20/2, $fn=6); // Mutter
}
translate([0,0,4]) cylinder(l,11.02/2,11.02/2);
}
union()
{
translate([0,0,1]) difference()
{
color("DarkSlateGray") cylinder(l-1,11/2,11/2);
color("DarkSlateGray") cylinder(l,4,4);
}
color("DarkSlateGray") rotate([0,0,45]) translate([4,0,1-0.2]) cylinder(l-1,1,1);
if (Pincount == 5) color("silver")
{
make_ring_of(radius = 2.5, count=4) cylinder(l-1,0.5,0.57);
cylinder(l-1,0.5,0.5);
}
}
// Dichtung
color("DarkSlateGray") translate([0,0,hr]) rotate_extrude() translate([8,0])circle(1);
}
// Pins
if (Pincount == 5)
{
make_ring_of(radius = 5/2, count=4) cylinderpart(size = [1.6,3]);
cylinderpart(size = [1.6,3]);
make_ring_of(radius = 5/2, count=4) LOETPIN(height = 3,dim = 1,rnd = true);
LOETPIN(height = 3, dim = 1,rnd = true);
}
}
module M12_PHOENIX_HULL(h = 6) // h = Spacing between the top edge of the PCB and the back of the front plate
{
h1 = (h == 7) ? 2.2 : 1.5;
h2 = (h == 7) ? 2.1 : 1.8;
translate([0,0,2.7])
{
color("DarkSlateGray") translate([0,0,h1+h2-0.5]) rotate_extrude() translate([8.5,0])circle(0.5);
//cube([14,14,3], center = true);
color("Silver") difference()
{
union()
{
cylinder(2.2,16/2,16/2, $fn=6);
translate([0,0,h1]) cylinder(h2-1,19/2,19/2);
translate([0,0,h1]) cylinder(h2,16.3/2,16.3/2);
translate([0,0,2.3]) cylinder(13,13.5/2,13.5/2);
translate([0,0,2.3]) cylinder(7,15.3/2,15.3/2);
}
translate([0,0,15.3-7.6]) cylinder(8.5,11/2,11/2);
translate([0,0,-1]) cylinder(16.3,9/2,9/2);
rotate([0,0,-45]) translate([-10,6.4,h1+h2]) cube([20,5,20]);
rotate([0,0,-135]) translate([-10,6.4,h1+h2]) cube([20,5,20]);
rotate([0,0,45]) translate([-10,6.4,h1+h2]) cube([20,5,20]);
}
}
}
module M12_FEMALE_X_CODED_8_TB(Name="",Value="",Library="con-harting-rnd")
{
translate([0,0,1])
color("DarkSlateGray")
{
cylinder(8.3,9/2,9/2);
cylinder(3,10/2,10/2);
cylinder(1.2,11/2,11/2);
difference()
{
cylinder(18.5,8.2/2,8.2/2); rotate([0,0,22.5]) make_ring_of(radius = 3, count=8) cylinder(19,0.6,0.6);
translate([0,0,9])
{ cubepart([0.7,10,10]); cubepart([10,0.7,10]);translate([-1,-1,0]) cubepart([1.4,1.4,10]);}
}
}
}
module M12_FEMALE_A_CODED_5_TB(Name="",Value="",Library="con-harting-rnd") // Artikelnummer: 21 03 321 2518
{
color("DarkSlateGray") difference()
{
translate([0,0,0.9]) {
cylinder(24.1,8.15/2,8.15/2);
cylinder(13.4,12.5/2,12.5/2);
cylinder(3.1,15/2,15/2);
translate([0,0,3.1]) cylinder(1.3,15/2,12.5/2);
}
translate([-10,0-5.5-5,0.8]) cube([20,5,20]);
translate([-10,4.6,0.8]) cube([20,5,4.5]);
make_ring_of(radius = 5/2, count=4) cylinderpart(size = [1.1,26]);
cylinderpart(size = [1.1,26]);
rotate([0,0,-135]) translate([0,7.5/2,14.3]) union(){cylinderpart(size = [1.3,12]); translate([0,1.3/2,0]) cubepart(size = [1.3,1.3,12]);}
}
translate([0,0,0.9]) union()
{
make_ring_of(radius = 5/2, count=4) LOETPIN(dim = 0.8,rnd = true);
LOETPIN(dim = 0.8,rnd = true);
color("DarkSlateGray") union()
{
translate([4.9,-3.4,-3]) cylinderpart(size = [2.4,3]);
translate([-4.9,3.4,-3]) cylinderpart(size = [1.8,3]);
}
}
}
module 53261_02(Name="",Value="",Library="") //Molex Picoblade
{
rotate([0,0,90]) color("LightGoldenrodYellow") linear_extrude(4.6) translate([-1.375000,-4.000000,0]) square([4.000000,8.000000]); //Board
}
// Phoenix
module _1881561(Name="",Value="",Library="")
{
color("LimeGreen") cubepart([9.4,8.1,10.1]);
}
module SCREWTERMINAL_3_5MM_2(Name="",Value="",Library="")
{
color("LimeGreen") translate([3.5/2,-0.4,0]) cubepart([7,7.6,10.1]);
}
module LP_4MM_H(Name="",Value="",Library="HAuto_CON_6")
{
module pin()
{
translate([0,0,-3.4]) linear_extrude(0.8,scale=2) square([0.4,0.4],center = true);
translate([0,0,-2.6]) linear_extrude(2.6) square([0.8,0.8],center = true);
translate([0.3,0,-0.9]) linear_extrude(1.0) square([1.4,0.8],center = true);
}
translate([0,0,0.9])
{
color(LEDCOLOR(Value))
{
translate([-13.5,-6.000,0]) cube([19,12.000,11.5]);
translate([-13.5,0,5.5]) rotate([0,-90,0])
linear_extrude(14)
{
difference() {circle(5.5); circle(4.5);}
difference() {circle(3); circle(2);}
}
}
color("Goldenrod")
{
translate([0,0,-3.1]) cylinder(3.1,1.05,1.05);
translate([0,0,-3.4]) cylinder(0.3,0.7,1.05);
translate([3.81,5.08,0]) rotate([0,0,180]) pin();
translate([3.81,-5.08,0]) rotate([0,0,180]) pin();
translate([-6.36,5.08,0]) pin();
translate([-6.36,-5.08,0]) pin();
}
}
}
module SPRING_PIN_0926_0(Name="",Value="",Library="MILL-MAX")
{
color("Goldenrod")
{
//translate([0,0,-0.5]) // push in
{
cylinder(1.778,1.07/2,1.07/2);
translate([0,0,1.778]) sphere(1.07/2);
}
translate([0,0,0.0]) cylinder(1.4,1.4986/2,1.4986/2);
translate([0,0,0.762]) cylinder(0.28,1.6256/2,1.4986/2);
translate([0,0,0.0]) cylinder(0.254,2.159/2,2.159/2);
translate([0,0,-2.032]) cylinder(2.032,1.778/2,1.778/2);
}
}
module SPRING_PIN_0926_1(Name="",Value="",Library="MILL-MAX")
{
color("Goldenrod")
{
//translate([0,0,-0.7]) // push in
{
cylinder(2.6416,1.07/2,1.07/2);
translate([0,0,2.6416]) sphere(1.07/2);
}
translate([0,0,0.0]) cylinder(1.7,1.4986/2,1.4986/2);
translate([0,0,0.762]) cylinder(0.28,1.6256/2,1.4986/2);
translate([0,0,0.0]) cylinder(0.254,2.159/2,2.159/2);
translate([0,0,-2.032]) cylinder(2.032,1.778/2,1.778/2);
}
}
module BNC_BU(Name="",Value="",Library="HAutomation_6")
{
translate([2.54,7.1-1.27,0 ])
{
color("Linen") cubepart([14.8,14.2,16]);
color("Linen") translate([0,7.1,8 ]) rotate([-90,00,0]) cylinder(8.8,11/2,11/2);
color("Silver") translate([0,7.1+8.8,8 ]) rotate([-90,00,0]) cylinder(12,9.5/2,9.5/2);
}
}
module BNC_180deg(Name="",Value="",Library="HAutomation_6")
{
translate([-2.54,8,1.6 ]) rotate([90,00,00]) translate([2.54,7.1-1.27,0 ])
{
color("Linen") cubepart([14.8,14.2,16]);
color("Linen") translate([0,7.1,8 ]) rotate([-90,00,0]) cylinder(8.8,11/2,11/2);
color("Silver") translate([0,7.1+8.8,8 ]) rotate([-90,00,0]) cylinder(12,9.5/2,9.5/2);
}
}
module DIO5_BU(Name="",Value="",Library="HAutomation_6")
{
color("DarkSlateGray")
{
translate([7.62,8.15-3.81,0 ]) cubepart([21.2,16.3,21]);
}
}
// Mischkontakt Steckverbinder 7W2 / 9W4
module M7W220A0(Name="",Value="",Library="") {
rotate([0,0,90]) union()
{
translate([0,0,8]) SUBD_HOUSE_M_EMPTY(1);
translate([-6.86,0,-2.7]) make_line_of(2*6.86,2) Hochstromstift20A(Name="",Value="",Library="");
translate([-2.74,-2.84/2,-2.7]) make_line_of(2.74,3) PIN_SUB_D(Name="",Value="",Library="");
translate([-2.74/2,2.84/2,-2.7]) make_line_of(2.74,2) PIN_SUB_D(Name="",Value="",Library="");
}
}
module M7W222A0(Name="",Value="",Library="") {M7W220A0(Name=Name,Value=Value,Library=Library);}
module F7W220A0(Name="",Value="",Library="")
{
translate([0,0,8]) rotate([0,0,90])
difference()
{
SUBD_HOUSE_F_EMPTY(1);
translate([-2.74/2,2.84/2,8]) make_line_of(2.74, 2) LOETPIN(height = 12.9, dim = 1.2, rnd = true);
translate([-2.74, -2.84/2,8]) make_line_of(2.74, 3) LOETPIN(height = 12.9, dim = 1.2, rnd = true);
translate([-6.86,0,8]) LOETPIN(height = 12.9, dim = 5.1, rnd = true);
translate([+6.86,0,8]) LOETPIN(height = 12.9, dim = 5.1, rnd = true);
}
translate([0,-6.86,-2.7]) rotate([0,0,90]) make_line_of(2*6.86,2) Hochstrombuchse20A(Name="",Value="",Library="");
}
module M7W220A9(Name="",Value="",Library="")
{
h = 7.4;
rotate([0,0,-90]) union()
{
{
translate([0,1,h]) rotate([90,0,0]) SUBD_HOUSE_M_EMPTY(1);
color("Gol") translate([-6.86,7.6,h]) make_line_of(2*6.86,2) rotate([90,0,0]) Hochstromstift20A90(Name="",Value="",Library="");
translate([-2.74,11.8-2.54/2,h-2.0-2.84/2]) make_line_of(2.74,3) rotate([0,0,90]) BendedPIN(Diameter=0.8,l=8,l2=12.4+1.6, cl="Gol");
translate([-2.74/2,11.8+2.54/2,h-2.0+2.84/2]) make_line_of(2.74,2) rotate([0,0,90]) BendedPIN(Diameter=0.8,l=10.8,l2=15+1.6, cl="Gol");
}
}
}
module NC684S7W2103L461(Name="",Value="",Library="") rotate([0,0,-90]) union()
{
h = 7.4;
{
translate([0,1,h]) rotate([90,0,0]) SUBD_HOUSE_M_EMPTY(1);
color("Gol") translate([-6.86,7.6,h]) make_line_of(2*6.86,2) rotate([90,0,0]) Hochstromstift20A90(d=3.75, l=4.5, t = 14);
translate([-2.74,11.5-2.54/2,h-2.0-2.84/2]) make_line_of(2.74,3) rotate([0,0,90]) BendedPIN(Diameter=0.8,l=8,l2=12.4+1.3, cl="Gol");
translate([-2.74/2,11.5+2.54/2,h-2.0+2.84/2]) make_line_of(2.74,2) rotate([0,0,90]) BendedPIN(Diameter=0.8,l=10.8,l2=15+1.3, cl="Gol");
}
}
module F9W4_0(Name="",Value="",Library=""){translate([0,0,8]) rotate([0,0,-90])
difference()
{
SUBD_HOUSE_F_EMPTY(2);
translate([-6.91-2.74/2,2.84/2,8]) make_line_of(2.74, 2) LOETPIN(height = 12.9, dim = 1.2, rnd = true);
translate([-6.91-2.74, -2.84/2,8]) make_line_of(2.74, 3) LOETPIN(height = 12.9, dim = 1.2, rnd = true);
translate([+14.48,0,8]) LOETPIN(height = 12.9, dim = 5.1, rnd = true);
translate([+7.7,0,8]) LOETPIN(height = 12.9, dim = 5.1, rnd = true);
translate([0,0,8]) LOETPIN(height = 12.9, dim = 5.1, rnd = true);
translate([-14.48,0,8]) LOETPIN(height = 12.9, dim = 5.1, rnd = true);
}
translate([0,-14.48,-2.7]) rotate([0,0,90]) make_line_of(2*14.48,2) Hochstrombuchse20A(Name="",Value="",Library="");
translate([0,-7.7,5]) rotate([0,0,90]) make_line_of(7.7,2) color("IndianRed") cylinder(8,2,2);
}
module M9W4_0(Name="",Value="",Library=""){rotate([0,0,90]) union()
{
translate([0,0,8]) SUBD_HOUSE_M_EMPTY(2);
translate([-14.48,0,-2.7]) make_line_of(2*14.48,2) Hochstromstift20A(Name="",Value="",Library="");
translate([-7.7,0,4.5]) make_line_of(7.7,2) KoaxSocket(Name="",Value="",Library="");
translate([6.91-2.74,-2.84/2,-2.7]) make_line_of(2.74,3) PIN_SUB_D(Name="",Value="",Library="");
translate([6.91-2.74/2,2.84/2,-2.7]) make_line_of(2.74,2) PIN_SUB_D(Name="",Value="",Library="");
}
}
module M9W421A9(Name="",Value="",Library="")
{
h = 7.4;
rotate([0,0,-90]) union()
{
{
translate([0,0,7.4]) rotate([90,0,0]) SUBD_HOUSE_M_EMPTY(2);
translate([-14.48,7.6,7.4]) make_line_of(2*14.48,2) rotate([90,0,0]) Hochstromstift20A90();
translate([-7.7,6.8-2.5,7.4]) KoaxSocket90(11.6);
translate([-0,6.8-2.5,7.4]) KoaxSocket90(11.6);
translate([6.91-2.74,11.8-2.54/2,h-2.0-2.84/2]) make_line_of(2.74,3) rotate([0,0,90]) BendedPIN(Diameter=0.8,l=8,l2=12.4+1.6);
translate([6.91-2.74/2,11.8+2.54/2,h-2.0+2.84/2]) make_line_of(2.74,2) rotate([0,0,90]) BendedPIN(Diameter=0.8,l=10,l2=15+1.6);
}
}
SUBD_WINKEL(size = 2, tiefe = 11.6);
}
module Hochstromstift20A(Name="",Value="",Library="")
{
l = 16.7;
if (Detailgrad < 20)
{
translate([0,0,4.3]) cylinder(l-4.3,3.6/2,3.6/2);
cylinder(l,2.55/2,2.55/2);
}
else
{
translate([0,0,l-1-11.4]) cylinder(1,5.5/2,5.5/2);
translate([0,0,l-5.5-5.9]) cylinder(5.5,4.8/2,4.8/2);
translate([0,0,4.3]) Phased_cylinder(l-4.3,3.6/2,3.6/2, Roundness = 0.5);
translate([0,0,0]) Phased_cylinder(l,2.55/2,2.55/2, Roundness = 0.5);
}
}
module Hochstromstift20A90(d=2.55, l=5.5,t=12.8 )
{
k = d-2.55;
translate([0,0,0]) cylinder(1,5.5/2,5.5/2);
translate([0,0,1]) cylinder(5.5,4.8/2,4.8/2);
translate([0,0,6.5]) Phased_cylinder(5.9,3.6/2,3.6/2, Roundness = 0.5);
translate([0,-2.25*d,+7.5-t]) rotate([90,90,180]) BendedPIN(Diameter=d, l=l,l2=0.1);
}
module Hochstrombuchse20A(Name="",Value="",Library="")
{
l = 17.1;
if (Detailgrad < 20)
{
translate([0,0,4.3]) cylinder(l-4.3,4.8/2,4.8/2);
cylinder(l,2.55/2,2.55/2);
}
else
{
translate([0,0,l-1-11.8]) cylinder(1,5.5/2,5.5/2);
difference()
{
translate([0,0,l-11.8]) cylinder(11.8,4.8/2,4.8/2);
translate([0,0,l-5.9]) cylinder (6,3.6/2,3.6/2);
}
translate([0,0,0]) Phased_cylinder(6,2.55/2,2.55/2, Roundness = 0.5);
}
}
module KoaxSocket(Name="",Value="",Library="")
{
cylinder(2.45,4.8/2,4.8/2, $fn = Detailgrad);
difference()
{
union()
{
cylinder(9.5,4.6/2,4.6/2, $fn = Detailgrad);
translate([0,0,8.5])cylinder(1,4.8/2,4.8/2, $fn = Detailgrad);
}
cylinder(10,3.8/2,3.8/2, $fn = Detailgrad);
}
cylinder(9.5,0.75/2,0.75/2, $fn = Detailgrad);
translate([0,0,-7]) cylinder(7,5.5/2,5.5/2, $fn = Detailgrad);
}
module KoaxSocket90(B = 9.3)
{
rotate([90,0,0]) KoaxSocket(Name="",Value="",Library="");
translate([-5.7/2,B-5.7,-7.7+5.5/2]) cube([5.7,5.7,7.7]);
translate([0,B-5.4,-6-7.7+5.5/2]) rotate([0,0,90]) make_line_of(2.54,3) translate([-0.8/4,-0.8/4,0]) cube([0.8/2,0.8/2,6]);
}
// D-SUB / SUB-D
module PIN_SUB_D(Name="",Value="",Library="")
{
l = 16.7;
color("Gold") translate([0,0,l]) LOETPIN(height = l, dim = 0.9, rnd = true);
//cylinder(l,0.9/2,0.9/2);
}
module HDF15H(Name="",Value="",Library="") {translate([0,-11.4,0]) rotate([0,0,+90]) SUBD_H_FHD(0, height = 7.3, tiefe = 11.4);}
module HDF15HG(Name="",Value="",Library="") {HDF15H(Name=Name,Value=Value,Library=Library);}
module HDF15VG(Name="",Value="",Library="") {translate([0,0,8]) SUBD_HOUSE_FHD(0);}
module HDM15VG(Name="",Value="",Library="") {translate([0,0,8]) SUBD_HOUSE_MHD(0);}
module HDF15V(Name="",Value="",Library="") {translate([0,0,8]) SUBD_HOUSE_FHD(0);}
module M09VP(Name="",Value="",Library="") {translate([0,0,8]) SUBD_HOUSE_M(0);}
module M15VP(Name="",Value="",Library="") {translate([0,0,8]) SUBD_HOUSE_M(1);}
module M25VP(Name="",Value="",Library="") {translate([0,0,8]) SUBD_HOUSE_M(2);}
module F15V(Name="",Value="",Library="") {SUBD_V_F(size = 1, height = 7.4);}
module F15VP(Name="",Value="",Library="") {SUBD_V_F(size = 1, height = 7.4);}
module M15HP(Name="",Value="",Library="") {translate([0,-10.7,0]) rotate([0,0,90]) SUBD_H_M(size = 1, height = 7.3, tiefe = 10.7);}
module F09VP(Name="",Value="",Library="") {SUBD_V_F(size = 0, height = 7.4);}
module F37VP(Name="",Value="",Library="") {SUBD_V_F(size = 3, height = 7.4);}
module F25VP(Name="",Value="",Library="") {SUBD_V_F(size = 2, height = 7.4);}
module F09HP(Name="",Value="",Library="") {translate([0,10.7,0]) rotate([0,0,-90]) SUBD_H_F(size = 0, height = 7.3, tiefe = 10.7);}
module F09H(Name="",Value="",Library="") {translate([0,10.7,0]) rotate([0,0,-90]) SUBD_H_F(size = 0, height = 7.3, tiefe = 10.7);}
module F15H(Name="",Value="",Library="") {translate([0,10.7,0]) rotate([0,0,-90]) SUBD_H_F(size = 1, height = 7.3, tiefe = 10.7);}
module F15HP(Name="",Value="",Library="") {translate([0,10.7,0]) rotate([0,0,-90]) SUBD_H_F(size = 1, height = 7.3, tiefe = 10.7);}
module F25HP(Name="",Value="",Library="") {translate([0,10.7,0]) rotate([0,0,-90]) SUBD_H_F(size = 2, height = 7.3, tiefe = 10.7);}
module DS9_SMD(Name="",Value="",Library="") {translate([0,7,-0.8]) rotate([90,0,180]) SUBD_HOUSE_M(0);}
module DS25_SMD(Name="",Value="",Library="") {translate([0,7,-0.8]) rotate([90,0,180]) SUBD_HOUSE_M(2);}
module M25D(Name="",Value="",Library="") {translate([0,1,-0.8]) rotate([90,0,180]) SUBD_HOUSE_M(2);}
module F25D(Name="",Value="",Library="") {translate([0,1,-0.8]) rotate([90,0,180]) SUBD_HOUSE_F(2);}
module MINID_H(size = 0, height = 7.3, tiefe = 10.7)
{
// Standard Height 7.3, tiefe 10.7
// Low Profile Height 3.6
// US Footprint Height 6.3
raster = (size == 0) ? 2.74 : (size == 1) ? 2.74 : 2.76;
n = (size == 0) ? 9 : (size == 1) ? 15 : (size == 2) ? 25 : 37;
translate([0,0,height]) rotate([90,0,-90]) SUBD_HOUSE_M(size);
SUBD_WINKEL(size = size, tiefe = tiefe);
translate([tiefe+1.27,-(floor(n/2)/2)*raster,0]) rotate([0,0,90]) make_line_of(raster, floor(n/2)+1) LOETPIN(height = 2.9, dim = 0.8, rnd = true);
translate([tiefe-1.27,-floor(n/2)/2*raster+raster/2,0]) rotate([0,0,90]) make_line_of(raster, floor(n/2)) LOETPIN(height = 2.9, dim = 0.8, rnd = true);
}
module SUBD_V_M(size = 0, height = 8)
{
// Standard Height 7.3, tiefe 10.7
// Low Profile Height 3.6
// US Footprint Height 6.3
raster = (size == 0) ? 2.74 : (size == 1) ? 2.74 : 2.76;
n = (size == 0) ? 9 : (size == 1) ? 15 : (size == 2) ? 25 : 37;
translate([0,0,height]) SUBD_HOUSE_M(size);
translate([-(floor(n/2)/2)*raster,1.42,height]) make_line_of(raster, floor(n/2)+1) LOETPIN(height = 2.9+height, dim = 0.8, rnd = true);
translate([-floor(n/2)/2*raster+raster/2,-1.42,height]) make_line_of(raster, floor(n/2)) LOETPIN(height = 2.9+height, dim = 0.8, rnd = true);
//
}
module SUBD_V_MHD(size = 0, height = 8)
{
// Standard Height 7.3, tiefe 10.7
// Low Profile Height 3.6
// US Footprint Height 6.3
raster = (size == 0) ? 2.74 : (size == 1) ? 2.74 : 2.76;
n = (size == 0) ? 9 : (size == 1) ? 15 : (size == 2) ? 25 : 37;
translate([0,0,height]) SUBD_HOUSE_MHD(size);
translate([-(floor(n/2)/2)*raster,1.42,height]) make_line_of(raster, floor(n/2)+1) LOETPIN(height = 2.9+height, dim = 0.8, rnd = true);
translate([-floor(n/2)/2*raster+raster/2,-1.42,height]) make_line_of(raster, floor(n/2)) LOETPIN(height = 2.9+height, dim = 0.8, rnd = true);
//
}
module SUBD_V_F(size = 0, height = 8)
{
// Standard Height 7.3, tiefe 10.7
// Low Profile Height 3.6
// US Footprint Height 6.3
raster = (size == 0) ? 2.74 : (size == 1) ? 2.74 : 2.76;
n = (size == 0) ? 9 : (size == 1) ? 15 : (size == 2) ? 25 : 37;
translate([0,0,height]) SUBD_HOUSE_F(size);
translate([-(floor(n/2)/2)*raster,1.42,height]) make_line_of(raster, floor(n/2)+1) LOETPIN(height = 2.9+height, dim = 0.8, rnd = true);
translate([-floor(n/2)/2*raster+raster/2,-1.42,height]) make_line_of(raster, floor(n/2)) LOETPIN(height = 2.9+height, dim = 0.8, rnd = true);
//
}
module SUBD_H_M(size = 0, height = 7.3, tiefe = 10.7)
{
// Standard Height 7.3, tiefe 10.7
// Low Profile Height 3.6
// US Footprint Height 6.3
raster = (size == 0) ? 2.74 : (size == 1) ? 2.74 : 2.76;
n = (size == 0) ? 9 : (size == 1) ? 15 : (size == 2) ? 25 : 37;
translate([0,0,height]) rotate([90,0,-90]) SUBD_HOUSE_M(size);
SUBD_WINKEL(size = size, tiefe = tiefe);
translate([tiefe+1.27,-(floor(n/2)/2)*raster,0]) rotate([0,0,90]) make_line_of(raster, floor(n/2)+1) LOETPIN(height = 2.9, dim = 0.8, rnd = true);
translate([tiefe-1.27,-floor(n/2)/2*raster+raster/2,0]) rotate([0,0,90]) make_line_of(raster, floor(n/2)) LOETPIN(height = 2.9, dim = 0.8, rnd = true);
}
module SUBD_H_F(size = 0, height = 7.3, tiefe = 10.7)
{
// Standard Height 7.3, tiefe 10.7
// Low Profile Height 3.6
// US Footprint Height 6.3
raster = (size == 0) ? 2.74 : (size == 1) ? 2.74 : 2.76;
n = (size == 0) ? 9 : (size == 1) ? 15 : (size == 2) ? 25 : 37;
translate([0,0,height]) rotate([90,0,-90]) SUBD_HOUSE_F(size);
SUBD_WINKEL(size = size, tiefe = tiefe);
translate([tiefe+1.27,-(floor(n/2)/2)*raster,0]) rotate([0,0,90]) make_line_of(raster, floor(n/2)+1) LOETPIN(height = 2.9, dim = 0.8, rnd = true);
translate([tiefe-1.27,-floor(n/2)/2*raster+raster/2,0]) rotate([0,0,90]) make_line_of(raster, floor(n/2)) LOETPIN(height = 2.9, dim = 0.8, rnd = true);
}
module SUBD_H_FHD(size = 0, height = 7.3, tiefe = 10.7)
{
// Standard Height 7.3, tiefe 10.7
// Low Profile Height 3.6
// US Footprint Height 6.3
raster = ((size != 3) && (size != 4)) ? 2.29 : 2.41;
n = (size == 0) ? 15 : (size == 1) ? 26 : (size == 2) ? 44 : (size == 3) ? 62 : 78;
translate([0,0,height]) rotate([90,0,-90]) SUBD_HOUSE_FHD(size);
SUBD_WINKEL(size = size, tiefe = tiefe);
translate([tiefe+0,0,0]) rotate([0,0,-90]) union()
{
translate([-0.245-floor(n/3)/2*raster+raster/2, 5.1/2,2])
make_line_of(raster, floor(n/3)) LOETPIN(height = 4.9, dim = 0.8, rnd = true);
translate([-0.245-floor(n/3)/2*raster+raster/2, -5.1/2,2]) make_line_of(raster, floor(n/3)) LOETPIN(height = 4.9, dim = 0.8, rnd = true);
translate([-0.245-(floor(n/3)/2)*raster+raster,0,2]) make_line_of(raster, floor(n/3)) LOETPIN(height = 4.9, dim = 0.8, rnd = true);
}
//translate([tiefe+1.27,-(floor(n/2)/2)*raster,0]) rotate([0,0,90]) make_line_of(raster, floor(n/2)+1) LOETPIN(height = 2.9, dim = 0.8, rnd = true);
// translate([tiefe-1.27,-floor(n/2)/2*raster+raster/2,0]) rotate([0,0,90]) make_line_of(raster, floor(n/2)) LOETPIN(height = 2.9, dim = 0.8, rnd = true);
}
module SUBD_WINKEL(size = 0, tiefe = 10.7)
{
// Todo: iredwas stimmt mit höhe und tiefe nicht
height1 = 0.8;
b = (size == 0) ? 25 : (size == 1) ? 33.3 : (size == 2) ? 47 : 63.5;
color("Khaki")
{
translate([0.8,b/2-2,height1]) cube([4,4,11.4-1]);
translate([2,b/2-2,0]) rotate([90,0,90]) cube([4,3,tiefe+1]);
translate([0.8,-b/2-2,height1]) cube([4,4,11.4-1]);
translate([2,-b/2-2,0]) rotate([90,0,90]) cube([4,3,tiefe+1]);
}
translate([tiefe,b/2,0]) LOETPIN(height = 2.9, dim = 3, rnd = true);
translate([tiefe,-b/2,0]) LOETPIN(height = 2.9, dim = 3, rnd = true);
}
module MINID_HOUSE_M(size = 0)
{
MaleOffset = 1;
length = (size == 0) ? 29.5 : (size == 1) ? 33.4 : (size == 2) ? 37.2 : 43.5;
holedist = length - 5.9;
length2 = length - 15.4;
length3 = length - 12;
whidth = 9.4;
whidth2 = 8;
whidth3 = 8;
height1 = 0.8;
height2 = 6.3;
height3 = 4.5;
Offs = 2;
OffsD = 2.3;
OffsU = 1;
color("darkgray") union()
{
translate([0,0,-height1]) linear_extrude(height1)
difference() {offset_square(size = [length-Offs, whidth-Offs], r = Offs/2, center = true, $fn = Detailgrad); translate([(holedist / 2), 0]) circle(3.1/2,$fn=Detailgrad); translate([(-holedist / 2),0]) circle(3.1/2,$fn=Detailgrad);}
//linear_extrude(height2) square([24.8-0.2, whidth2],center = true);
//Front
difference() {
PAINTSUBD(size = [length2+MaleOffset,whidth2+MaleOffset,height2], Offs = OffsD);
PAINTSUBD(size = [length2,whidth2,height2+0.1], Offs = OffsD);
}
// Back
translate([0,0,-(height3+height1)]) PAINTSUBD(size = [length3,whidth3,height3], Offs = OffsU);
}
}
module SUBD_HOUSE_M_EMPTY(size = 0)
{
MaleOffset = 1;
length = (size == 0) ? 30.8 : (size == 1) ? 39.1 : (size == 2) ? 53 : 69.3;
holedist = length - 5.8;
length2 = length - 14.4;
length3 = length - 12;
whidth = 12.5;
whidth2 = 8;
whidth3 = 10;
height1 = 0.8;
height2 = 6.3;
height3 = 4.5;
Offs = 2;
OffsD = 2.3;
OffsU = 1;
raster = (size == 0) ? 2.74 : (size == 1) ? 2.74 : 2.76;
n = (size == 0) ? 9 : (size == 1) ? 15 : (size == 2) ? 25 : 37;
color("darkgray") union()
{
translate([0,0,-height1]) linear_extrude(height1) difference() {
offset_square(size = [length-Offs, whidth-Offs], r = Offs/2, center = true, $fn = Detailgrad); translate([(holedist / 2), 0]) circle(3.1/2,$fn=Detailgrad); translate([(-holedist / 2),0]) circle(3.1/2,$fn=Detailgrad);
}
//linear_extrude(height2) square([24.8-0.2, whidth2],center = true);
//Front
difference() {PAINTSUBD(size = [length2+MaleOffset,whidth2+MaleOffset,height2], Offs = OffsD); PAINTSUBD(size = [length2,whidth2,height2+0.1], Offs = OffsD);}
// Back
translate([0,0,-(height3+height1)]) PAINTSUBD(size = [length3,whidth3,height3], Offs = OffsU);
}
}
module SUBD_HOUSE_M(size = 0)
{
MaleOffset = 1;
length = (size == 0) ? 30.8 : (size == 1) ? 39.1 : (size == 2) ? 53 : 69.3;
holedist = length - 5.8;
length2 = length - 14.4;
length3 = length - 12;
whidth = 12.5;
whidth2 = 8;
whidth3 = 10;
height1 = 0.8;
height2 = 6.3;
height3 = 4.5;
Offs = 2;
OffsD = 2.3;
OffsU = 1;
raster = (size == 0) ? 2.74 : (size == 1) ? 2.74 : 2.76;
n = (size == 0) ? 9 : (size == 1) ? 15 : (size == 2) ? 25 : 37;
color("darkgray") union()
{
translate([0,0,-height1]) linear_extrude(height1)
difference() {offset_square(size = [length-Offs, whidth-Offs], r = Offs/2, center = true, $fn = Detailgrad); translate([(holedist / 2), 0]) circle(3.1/2,$fn=Detailgrad); translate([(-holedist / 2),0]) circle(3.1/2,$fn=Detailgrad);}
//linear_extrude(height2) square([24.8-0.2, whidth2],center = true);
//Front
difference() {
PAINTSUBD(size = [length2+MaleOffset,whidth2+MaleOffset,height2], Offs = OffsD);
PAINTSUBD(size = [length2,whidth2,height2+0.1], Offs = OffsD);
}
// Back
translate([0,0,-(height3+height1)]) PAINTSUBD(size = [length3,whidth3,height3], Offs = OffsU);
}
translate([-(floor(n/2)/2)*raster,1.84/2,5]) make_line_of(raster, floor(n/2)+1) LOETPIN(height = 13.9, dim = 0.8, rnd = true);
translate([-floor(n/2)/2*raster+raster/2, -1.84/2,5]) make_line_of(raster, floor(n/2)) LOETPIN(height = 13.9, dim = 0.8, rnd = true);
}
module SUBD_HOUSE_MHD(size = 0)
{
MaleOffset = 1;
length = (size == 0) ? 30.8 : (size == 1) ? 39.1 : (size == 2) ? 53 : 69.3;
holedist = length - 5.8;
length2 = length - 14.4;
length3 = length - 12;
whidth = 12.5;
whidth2 = 8;
whidth3 = 10;
height1 = 0.8;
height2 = 6.3;
height3 = 4.5;
Offs = 2;
OffsD = 2.3;
OffsU = 1;
raster = ((size != 3) && (size != 4)) ? 2.29 : 2.41;
n = (size == 0) ? 15 : (size == 1) ? 26 : (size == 2) ? 44 : (size == 3) ? 62 : 78;
color("darkgray") union()
{
translate([0,0,-height1]) linear_extrude(height1)
difference() {offset_square(size = [length-Offs, whidth-Offs], r = Offs/2, center = true, $fn = Detailgrad); translate([(holedist / 2), 0]) circle(3.1/2,$fn=Detailgrad); translate([(-holedist / 2),0]) circle(3.1/2,$fn=Detailgrad);}
//linear_extrude(height2) square([24.8-0.2, whidth2],center = true);
//Front
difference() {
PAINTSUBD(size = [length2+MaleOffset,whidth2+MaleOffset,height2], Offs = OffsD);
PAINTSUBD(size = [length2,whidth2,height2+0.1], Offs = OffsD);
}
// Back
translate([0,0,-(height3+height1)]) PAINTSUBD(size = [length3,whidth3,height3], Offs = OffsU);
}
translate([0.245-floor(n/3)/2*raster+raster/2, 3.96/2,5])
make_line_of(raster, floor(n/3)) LOETPIN(height = 15.9, dim = 0.8, rnd = true);
translate([0.245-floor(n/3)/2*raster+raster/2, -3.96/2,5]) make_line_of(raster, floor(n/3)) LOETPIN(height = 15.9, dim = 0.8, rnd = true);
translate([0.245-(floor(n/3)/2)*raster,0,5]) make_line_of(raster, floor(n/3)) LOETPIN(height = 15.9, dim = 0.8, rnd = true);
}
module SUBD_HOUSE_F(size = 0)
{
MaleOffset = 1;
length = (size == 0) ? 30.8 : (size == 1) ? 39.1 : (size == 2) ? 53 : 69.3;
holedist = length - 5.8;
length2 = length - 14.4;
length3 = length - 12;
whidth = 12.5;
whidth2 = 8;
whidth3 = 10;
height1 = 0.8;
height2 = 6.3;
height3 = 4.5;
Offs = 2;
OffsD = 2.3;
OffsU = 1;
raster = (size == 0) ? 2.74 : (size == 1) ? 2.74 : 2.76;
n = (size == 0) ? 9 : (size == 1) ? 15 : (size == 2) ? 25 : 37;
color("darkgray") union()
{
translate([0,0,-height1]) linear_extrude(height1)
difference() {offset_square(size = [length-Offs, whidth-Offs], r = Offs/2, center = true, $fn = Detailgrad); translate([(holedist / 2), 0]) circle(3.1/2,$fn=Detailgrad); translate([(-holedist / 2),0]) circle(3.1/2,$fn=Detailgrad);}
//linear_extrude(height2) square([24.8-0.2, whidth2],center = true);
//Front
difference() {
PAINTSUBD(size = [length2+MaleOffset,whidth2+MaleOffset,height2], Offs = OffsD);
// PAINTSUBD(size = [length2,whidth2,height2+0.1], Offs = OffsD);
translate([-(floor(n/2)/2)*raster,2.84/2,8])make_line_of(raster, floor(n/2)+1) LOETPIN(height = 12.9, dim = 1.2, rnd = true);
translate([-floor(n/2)/2*raster+raster/2, -2.84/2,8]) make_line_of(raster, floor(n/2)) LOETPIN(height = 12.9, dim = 1.2, rnd = true);
}
// Back
translate([0,0,-(height3+height1)]) PAINTSUBD(size = [length3,whidth3,height3], Offs = OffsU);
translate([-(floor(n/2)/2)*raster,2.84/2,0]) make_line_of(raster, floor(n/2)+1) LOETPIN(height = 7.9, dim = 0.8, rnd = true);
translate([-floor(n/2)/2*raster+raster/2, -2.84/2,0]) make_line_of(raster, floor(n/2)) LOETPIN(height = 7.9, dim = 0.8, rnd = true);
}
}
module SUBD_HOUSE_FHD(size = 0)
{
MaleOffset = 1;
length = (size == 0) ? 30.8 : (size == 1) ? 39.1 : (size == 2) ? 53 : 69.3;
holedist = length - 5.8;
length2 = length - 14.4;
length3 = length - 12;
whidth = 12.5;
whidth2 = 8;
whidth3 = 10;
height1 = 0.8;
height2 = 6.3;
height3 = 4.5;
Offs = 2;
OffsD = 2.3;
OffsU = 1;
raster = ((size != 3) && (size != 4)) ? 2.29 : 2.41;
n = (size == 0) ? 15 : (size == 1) ? 26 : (size == 2) ? 44 : (size == 3) ? 62 : 78;
color("darkgray") union()
{
translate([0,0,-height1]) linear_extrude(height1)
difference() {offset_square(size = [length-Offs, whidth-Offs], r = Offs/2, center = true, $fn = Detailgrad); translate([(holedist / 2), 0]) circle(3.1/2,$fn=Detailgrad); translate([(-holedist / 2),0]) circle(3.1/2,$fn=Detailgrad);}
//linear_extrude(height2) square([24.8-0.2, whidth2],center = true);
//Front
difference() {
PAINTSUBD(size = [length2+MaleOffset,whidth2+MaleOffset,height2], Offs = OffsD);
// PAINTSUBD(size = [length2,whidth2,height2+0.1], Offs = OffsD);
translate([-0.245-floor(n/3)/2*raster+raster/2, 3.96/2,8])
make_line_of(raster, floor(n/3)) LOETPIN(height = 12.9, dim = 1.2, rnd = true);
translate([-0.245-floor(n/3)/2*raster+raster/2, -3.96/2,8]) make_line_of(raster, floor(n/3)) LOETPIN(height = 12.9, dim = 1.2, rnd = true);
translate([-0.245-(floor(n/3)/2)*raster+raster,0,8]) make_line_of(raster, floor(n/3)) LOETPIN(height = 12.9, dim = 1.2, rnd = true);
}
// Back
translate([0,0,-(height3+height1)]) PAINTSUBD(size = [length3,whidth3,height3], Offs = OffsU);
translate([-0.245-floor(n/3)/2*raster+raster/2, 3.96/2,2])
make_line_of(raster, floor(n/3)) LOETPIN(height = 12.9, dim = 0.8, rnd = true);
translate([-0.245-floor(n/3)/2*raster+raster/2, -3.96/2,2]) make_line_of(raster, floor(n/3)) LOETPIN(height = 12.9, dim = 0.8, rnd = true);
translate([-0.245-(floor(n/3)/2)*raster+raster,0,2]) make_line_of(raster, floor(n/3)) LOETPIN(height = 12.9, dim = 0.8, rnd = true);
}
}
module SUBD_HOUSE_F_EMPTY(size = 0)
{
MaleOffset = 1;
length = (size == 0) ? 30.8 : (size == 1) ? 39.1 : (size == 2) ? 53 : 69.3;
holedist = length - 5.8;
length2 = length - 14.4;
length3 = length - 12;
whidth = 12.5;
whidth2 = 8;
whidth3 = 10;
height1 = 0.8;
height2 = 6.3;
height3 = 4.5;
Offs = 2;
OffsD = 2.3;
OffsU = 1;
raster = (size == 0) ? 2.74 : (size == 1) ? 2.74 : 2.76;
n = (size == 0) ? 9 : (size == 1) ? 15 : (size == 2) ? 25 : 37;
color("darkgray") union()
{
translate([0,0,-height1]) linear_extrude(height1)
difference() {offset_square(size = [length-Offs, whidth-Offs], r = Offs/2, center = true, $fn = Detailgrad); translate([(holedist / 2), 0]) circle(3.1/2,$fn=Detailgrad); translate([(-holedist / 2),0]) circle(3.1/2,$fn=Detailgrad);}
//linear_extrude(height2) square([24.8-0.2, whidth2],center = true);
//Front
difference() {
PAINTSUBD(size = [length2+MaleOffset,whidth2+MaleOffset,height2], Offs = OffsD);
// PAINTSUBD(size = [length2,whidth2,height2+0.1], Offs = OffsD);
}
// Back
translate([0,0,-(height3+height1)]) PAINTSUBD(size = [length3,whidth3,height3], Offs = OffsU);
}
}
module PAINTSUBD(size = [16.4,8,6.3], Offs = 2)
{
if (Detailgrad < 10)
{
points = [[(size[0]/2),(size[1]/2)-Offs/2],[(size[0]/2)-Offs/2,(size[1]/2)],
[-(size[0]/2)+Offs/2,(size[1]/2)],[-(size[0]/2),(size[1]/2)-Offs/2],
[-(size[0]/2-1),-((size[1]/2))+Offs/2],[-(size[0]/2-1)+Offs/2,-((size[1]/2))],
[(size[0]/2-1)-Offs/2,-((size[1]/2))], [(size[0]/2-1),-((size[1]/2))+Offs/2]];
linear_extrude(size[2]) polygon(points);
}
else
{
points = [[(size[0]/2-Offs),(size[1]/2)-Offs],[-(size[0]/2-Offs),(size[1]/2)-Offs],[-(size[0]/2-Offs-1),-((size[1]/2)-Offs)],[(size[0]/2-Offs-1),-((size[1]/2)-Offs)]];
linear_extrude(size[2]) offset_polygon(points , r = Offs, $fn = Detailgrad);
}
//linear_extrude(size[2]) offset(Offs, $fn=Detailgrad) polygon(points); // Import in Freecad Fails
}
// TASTER APEM
module APEM_T3(Name="",Value="",Library="")
{
translate([-3,0,5]) rotate([0,-90,0]) APEM_T3_BODY(Name="",Value="",Library="");
}
module APEM_T3_BODY(Name="",Value="",Library="")
{
Blechstaerke = 0.55;
color("DarkSlateGray")
union()
{
translate([0,0,-8.1/2])
difference()
{
cube([8.1,5,8.1],center=true);
translate([0,0,-3.8]) cube([8.3,4,1],center=true);
}
intersection(Name="",Value="",Library="") {cylinder(2,2.5,2.5,$fn=Detailgrad); cube([5,4.2,4],center = true);}
intersection(Name="",Value="",Library="") {cylinder(6.1,2.3,2.3,$fn=Detailgrad); cube([4.6,3.8,13],center = true);}
cylinder(6.1+3.55,2.5/2,2.5/2,$fn=Detailgrad);
translate([0,0,6.1+3.55-1.8]) cylinder(4,6.5/2,6.5/2,$fn=Detailgrad);
}
}
module APEM_T3L(Name="",Value="",Library="")
{
translate([-3,0,3.5]) rotate([0,-90,0]) APEM_T3L_BODY(Name="",Value="",Library="");
}
module APEM_T3L_BODY(Name="",Value="",Library="")
{
Blechstaerke = 0.55;
color("DarkSlateGray")
union()
{
translate([0,0,-8.1/2])
difference()
{
cube([5.5,8.1,8.1],center=true);
translate([0,0,-3.8]) cube([8.3,4,1],center=true);
}
intersection(Name="",Value="",Library="") {cylinder(2,2.5,2.5,$fn=Detailgrad); cube([5,4.2,4],center = true);}
intersection(Name="",Value="",Library="") {cylinder(6.1,2.3,2.3,$fn=Detailgrad); cube([4.6,3.8,13],center = true);}
cylinder(6.1+3.55,2.5/2,2.5/2,$fn=Detailgrad);
translate([0,0,6.1+3.55-1.8]) cylinder(4,6.5/2,6.5/2,$fn=Detailgrad);
}
}
// end SUB-D
//=======================================================================================
module EPG1B7(Name="",Value="",Library="") //X1 EPG1B7
{
color("silver") translate([0,6.65,7.5]) rotate([-90,0,0]) cylinder(13.76,5.5,5.5);
color("DarkKhaki") cubepart([12.6,13.3,14]);
// LOETPIN(height = 3.0, dim = 0.6);
// translate([-1.27,-1.27,0]) make_line_of(2.54,2) LOETPIN(height = 3.0, dim = 0.6);
// translate([-1.27,1.27,0]) make_line_of(2.54,2) LOETPIN(height = 3.0, dim = 0.6);
// translate([-3.81,-3.81,0]) make_line_of(2.54,4) LOETPIN(height = 3.0, dim = 0.6);
// translate([-3.81,3.81,0]) make_line_of(7.62,2) LOETPIN(height = 3.0, dim = 0.6);
}
module 3M_10214_55G3PC(Name="",Value="",Library="") //U2 F14THT
{
rotate([0,0,90]) translate([-7.813800,-3.5,0]) MINID_H(size = 0); //Board
}
// USB
module USB_B() {color("Silver")
{
translate([0,-2,0]) cubepart([12.04,16.5,10.62]);
translate([-12.04/2,0,0]) make_line_of(12.04, 2) LOETPIN(height = 3, dim = 1);
translate([-2.5/2,4.71,0]) make_line_of(2.5, 2) LOETPIN(height = 3,rnd = true);
translate([-2.5/2,2.71,0]) make_line_of(2.5, 2) LOETPIN(height = 3,rnd = true);
}
}
module PN61729(Name="",Value="",Library="SmartPrj") {USB_B();}
module USB_MINI_B(Name="",Value="",Library="")// MINI USB
{color("silver") translate([-0.48-1.27,0,0])
difference()
{
cubepart(size = [9.3,7.8,4.1]);
translate([-1,0,0.5])cubepart(size = [8.3,6.8,3.1]);
}
translate([-2,0,1]) color("DarkSlateGray") cubepart(size = [7.3,5.8,2.1]);
}
module UX60A_MB_5ST(Name="",Value="",Library="") {USB_MINI_B(); }
module USB_MINI_B_2(Name="",Value="",Library="MyCON2") {translate([1.6,2,0]) rotate([0,0,-90])USB_MINI_B(); }
module _629105136821(Name="",Value="",Library="") //Micro USB
{
color("silver")rotate([0,0,90]) linear_extrude(2.6) translate([-6.821000,-5.100000,0]) square([7.721000,10.200000]); //Board
}
module ZX62D_B_5PA8(Name="",Value="",Library="") // MICRO USB
{
translate([5,0,0]) rotate([-90,180,90]) union()
{
color("silver") union() { difference()
{
translate([-3.80,0,0])linear_extrude(5) polygon([[7.6,1.1],[7.6,1.9],[6.9,2.6],[0.7,2.6],[0,1.9],[0,1.1],[1.1,0],[6.5,0]]);
translate([-3.8+0.3,0.3,1]) linear_extrude(4.5) polygon([[0,0.9],[0,1.5],[0.5,2],[6.5,2],[7,1.5],[7,0.9],[6.1,0],[0.9,0]]);
}
translate([-3,2.3,5]) rotate([-30,0,0]) cube([6,0.3,0.6]);
translate([2.7,0.3,5]) rotate([-30,0,180]) cube([5.4,0.3,0.6]);
translate([-3.8+0.3,1.1,5]) rotate([-30,0,90]) cube([0.8,0.3,0.6]);
translate([+3.8-0.3,1.9,5]) rotate([-30,0,-90]) cube([0.8,0.3,0.6]);
}
color("DarkSlateGray") translate([-1.9,1.3,0.4]) cube([3.8,0.6,3.8]);
}
}
// Cinch
module TOBU3(Name="",Value="",Library="") //X2 TOBU3
{
d = 8.3;
color("silver") union()
{
rotate([0,0,180]) translate([-5.588,-5.5,0]) linear_extrude(12.3) square([11,8.5]);
translate([0,5.5,10.6-(d/2)]) rotate([-90,00,00]) cylinder(8.6,d/2,d/2);
}
}
// HDMI
module _685119135725(Name="",Value="",Library="USBSteckverbinderWR-COM")
{ translate([-14.5/2,0,0])
{
HDMI(width=15,length=12.15,height=5.6,pindisplace = 1.95);
translate([14.5/2,0,3]) LOETPIN(height = 5, dim = 1, rnd = false);
translate([-14.5/2,0,3]) LOETPIN(height = 5, dim = 1, rnd = false);
translate([14.5/2,-5.96,3]) LOETPIN(height = 5, dim = 1, rnd = false);
translate([-14.5/2,-5.96,3]) LOETPIN(height = 5, dim = 1, rnd = false);
}
}
//AMP10029449_111RLF();
module AMP10029449_111RLF(Name="",Value="",Library="con-amphenol-USB-HDMI-DVI")
{
translate([-14.5/2,0,0])
{
HDMI(width=15,length=9.5,height=5.6,pindisplace = 1);
translate([14.5/2,0,3]) LOETPIN(height = 5, dim = 1, rnd = false);
translate([-14.5/2,0,3]) LOETPIN(height = 5, dim = 1, rnd = false);
translate([15.7/2,-4.95,3]) LOETPIN(height = 5, dim = 1, rnd = false);
translate([-15.7/2,-4.95,3]) LOETPIN(height = 5, dim = 1, rnd = false);
}
}
module HDMI(width=15,length=12.15,height=5.6, pindisplace=1.78) //
{
breite = width; // 11.2 mini
hoehe = height; // 3.2
wand = 0.6;
tiefe = length; // 7.6
translate([0,pindisplace,0]) rotate([-90,180,180]) union()
{
color("silver") union() { difference()
{
translate([-breite/2,0,0])linear_extrude(tiefe) polygon([[hoehe*0.44,0],[breite - hoehe*0.44 ,0],[breite,hoehe*0.44],[breite,hoehe],[0,hoehe],[0,hoehe*0.44]]);
translate([-breite/2+wand/2,wand/2,1]) linear_extrude(tiefe-wand) polygon([[hoehe*0.44,0],[breite - hoehe*0.44-wand ,0],[breite-wand,hoehe*0.44],[breite-wand,hoehe-wand],[0,hoehe-wand],[0,hoehe*0.44]]);
}
}
color("DarkSlateGray") translate([-breite*0.76/2,hoehe*0.45,0.4]) cube([breite*0.76,0.6,6.5]);
}
}
// DC-Buchse
module SPC4077(Name="",Value="",Library="") //J3
{
translate([-10.8,0,0]) rotate([0,0,-90])
color("DarkSlateGray") union()
{
translate([0,3.25,10.8-(8/2)]) rotate([-90,00,00]) cylinder(10.2,8/2,8/2);
translate([-8/2,3.25,0]) cube([8,10.2,10.8-4]);
difference()
{
translate([-8.89/2,0,0]) cube([8.89,3.25,11]); //Dummy Package
translate([0,-1,3.35+6.3/2]) rotate([-90,00,0]) cylinder(10.2,6.3/2,6.3/2);
}
}
}
module DCJACK_2MM_PTH(Name="",Value="",Library="") {translate([10.8,0,0]) SPC4077(Name=Name,Value=Value,Library=Library);}
module DC_21MM(Name="",Value="",Library="") {translate([0,-4,0]) rotate([0,00,-90]) SPC4077();}
// CHINCH Buchse
module CHINCH(Name="",Value="",Library="")
{
color("Yellow") translate([10.2-7,0,0]) cubepart([14,10,13]);
color("Silver") translate([10.2-14,0,13/2]) rotate([0,-90,0]) cylinder(8.5,8.3/2,8.3/2);
}
module PG203J(Name="",Value="",Library="")
{
color("DarkSlateGray") cubepart([14.6,11,6]);
color("Silver") translate([-6,0,3]) rotate([0,270,0]) cylinder(5,5/2,5/2);
}
// Pfostensteckverbinder
module FE06(Name="",Value="",Library="con-lsta") {LSTA(n=6);}
module 1X06(Name="",Value="",Library="pinhead") {LSTA(n=6);}
module FE08(Name="",Value="",Library="con-lsta") {LSTA(n=8);}
module 1X08(Name="",Value="",Library="pinhead") {LSTA(n=8);}
module 1X08_CLEANBIG(Name="",Value="",Library="pinhead") {LSTA(n=8);}
module FE12(Name="",Value="",Library="con-lsta") {LSTA(n=12);}
module FE10(Name="",Value="",Library="con-lsta") {LSTA(n=10);}
module FE20_2(Name="",Value="",Library="con-lsta") {LSTA(n=20,m=2);}
module FE05_1(Name="",Value="",Library="con-lsta") {LSTA(n=5,m=1);}
module JP1(Name="",Value="",Library="con-lstb") {LSTB(n=1,m=2);}
module JP2(Name="",Value="",Library="con-lstb") {LSTB(n=3,m=1);}
module JP8Q(Name="",Value="",Library="con-lstb") {LSTB(n=8,m=2);}
module MA13_1W(Name="",Value="",Library="con-lstb") {translate([0,2,0]) rotate([-90,0,0]) LSTB(n=13,m=1);}
module HEAD15_NOSS(Name="",Value="",Library="MyCON2") {translate([7*2.54,0,0]) LSTB(n=15,m=1);}
module HEAD15_NOSS_1(Name="",Value="",Library="MyCON2") {translate([7*2.54,0,0]) LSTB(n=15,m=1);}
module LSTA06_1_27(Name="",Value="",Library="") {translate([+1.27/2,0,0]) LSTA05(n=6);}
module RSM_106_02_L_S(Name="",Value="",Library="") {RSM_1(n=6);}//, m=1);}
module MA04_1(Name="",Value="",Library="con-lstb") {LSTB(n=4);}
module MA08_1(Name="",Value="",Library="con-lstb") {LSTB(n=8);}
module MA05_1(Name="",Value="",Library="con-lstb") {LSTB(n=5);}
module MA02_1WI(Name="",Value="",Library="con-lstb") {LSTBW(n=2);}
module MA03_1WI(Name="",Value="",Library="con-lstb") {LSTBW(n=3);}
module MA03_1(Name="",Value="",Library="con-lstb") {LSTB(n=3);}
module MA03_2(Name="",Value="",Library="con-lstb") {LSTB(n=3, m=2);}
module 2X03(Name="",Value="",Library="pinhead") {MA03_2();}
module LSP10(Name="",Value="",Library="solpad") {LSTB(n=1);}
module MA20_2(Name="",Value="",Library="con-lstb") {LSTB(n=20,m=2);}
module SV_3_81_12(Name="",Value="",Library="") {translate([0,0,0]) SV_3_81(n=12);}
module SV_3_5_8(Name="",Value="",Library="") {translate([0,0,0]) SV_3_5(n=8);BL350(n = 8);}
module SL_3_5_2(Name="",Value="",Library="") {translate([-3.5,0,0]) SL_3_5(n=2);}
module SL_3_5_3(Name="",Value="",Library="") {translate([0,0,0]) SL_3_5(n=3);}
module SL_3_5_4(Name="",Value="",Library="") {translate([0,0,0]) SL_3_5(n=4);}
module SL_3_5_1(Name="",Value="",Library="") {translate([3.5*3,0,0]) SL_3_5(n=10);}
//module SL_3_5_6(Name="",Value="",Library="") {translate([7,0,0]) SL_3_5(n=6);}
module EDG_03(Name="",Value="",Library="") {EDG_SWITCH(3);}
module EDG_SWITCH(n = 3)
{
pitch = 2.54;
color("Red")
difference()
{
cubepart([(4.2)+(n-1)*pitch,10,5.7]);
for (a = [0 : n-1]) translate([-(pitch/2)*(n-1)+pitch*a,0,2]) cubepart([1.27,3,4]);
}
color("White") for (a = [0 : n-1]) translate([-(pitch/2)*(n-1)+pitch*a,0,2]) cubepart([1.27,3,3]);
color("White") for (a = [0 : n-1]) translate([-(pitch/2)*(n-1)+pitch*a,0.75,2])cubepart([1.27,1.5,5]);
}
// Battery
module CR2032H_SMD(Name="",Value="",Library="battery")
{
translate([-14.100,-8.000,0]) linear_extrude(10) square([28.300,16.000]); //Dummy Package
}
module BTSW_SMD(Name="",Value="",Library="DIY-Parts")
{
translate([-13.100,-4.000,0]) linear_extrude(10) square([26.200,8.000]); //Dummy Package
}
module MINIFIB4(Name="",Value="",Library="") //X1
{
rotate([0,0,180])
{
difference()
{
color("white") translate([-4.8,0.95,0]) cube([9.6,12.95,10]); //Board
if (Detailgrad > 8)
{
color("white") translate([-4.8+0.75,2,1.1+3.8+0.5]) cube([3.8,12.95,3.8]);
color("white") translate([-4.8+0.75,2,1.1]) cube([3.8,12.95,3.8]);
color("white") translate([-4.8+0.75+3.8+0.5,2,1.1+3.8+0.5]) cube([3.8,12.95,3.8]);
color("white") translate([-4.8+0.75+3.8+0.5,2,1.1]) cube([3.8,12.95,3.8]);
}
}
if (Detailgrad > 9)
{
translate([2.1,0,0]) rotate([0,0,-90]) BendedPIN(1.5, l=3.5, l2=3);
translate([-2.1,0,0]) rotate([0,0,-90]) BendedPIN(1.5, l=3.5, l2=3);
translate([2.1,-5.5,4.2]) rotate([0,0,-90]) BendedPIN(1.5, l=3.5+4.2, l2=3);
translate([-2.1,-5.5,4.2]) rotate([0,0,-90]) BendedPIN(1.5,l=3.5+4.2, l2=3);
}
}
}
module MICROFIT6(Name="",Value="",Library="") //X6
{
rotate([0,0,180]) color("DarkSlateGray") translate([-6.325000,-1.0,0]) cube([12.65,9.92,7.3]); //Board
}
module MOLEX_MICROFIT90(Name="",Value="",Library="")
{
color("DarkSlateGray") translate([0,2,4.8]) rotate([90,00,00]) MINIFIS4(Name="",Value="",Library="") ;
}
module MINIFIS6(Name="",Value="",Library="")
{
// 22-0308 mini und Microfit verwechselt
MICROFITS6(Name="",Value="",Library="") ;
}
module MINIFIS4(Name="",Value="",Library="")
{
color("white") cubepart(size = [9.6,9.6,12.8]);
color("white") translate([-0,5.5,12.8-3.1]) cubepart(size = [3.4,1.4,3.1]);
color("FloralWhite") difference()
{
translate([0,0,12.8]) cubepart(size = [10,10,13.5]);
translate([-2.1,2.75,12.8]) make_line_of(4.2, 2) cubepart(size = [3.5,3.5,14]);
translate([-2.1,-2.75,12.8]) make_line_of(4.2, 2)cubepart(size = [3.5,3.5,14]);
}
color("FloralWhite") translate([-0,6.5,12.8]) cubepart(size = [3.4,3.4,13.5]);
translate([-2.1,2.75,0]) make_line_of(4.2, 2) LOETPIN(height = 3.5, dim = 0.9);
translate([-2.1,-2.75,0]) make_line_of(4.2, 2) LOETPIN(height = 3.5, dim = 0.9);
//
}
module MICROFITS6(Name="",Value="",Library="") //X6
{
color("DarkSlateGray") translate([0,0.285,0]) cubepart(size = [12.65+0.5,7.37,9.91]);
color("DarkSlateGray") translate([-0,4.65,9.91-3.1]) cubepart(size = [3.4,1.4,3.1]);
color("DarkSlateGray") difference()
{
translate([0,0.285,9.91]) cubepart(size = [10.5,7.37,9.5]);
translate([-3,1.5,9.91]) make_line_of(3, 3) cubepart(size = [2.5,2.5,10]);
translate([-3,-1.5,9.91]) make_line_of(3, 3)cubepart(size = [2.5,2.5,10]);
}
color("DarkSlateGray") translate([-0,5.65,9.91]) cubepart(size = [3.4,3.4,9.5]);
translate([-3,1.5,0]) make_line_of(3, 3) LOETPIN(height = 3.18);
translate([-3,-1.5,0]) make_line_of(3, 3) LOETPIN(height = 3.18);
}
module ML6(Name="",Value="",Library="") { IDC_CON_180(6);}
module ML6L(Name="",Value="",Library="") { IDC_CON_90(6);}
module ML16(Name="",Value="",Library="") { IDC_CON_180(16);}
module IDC_CON_180(n = 10)
{
difference()
{
translate([-(7.58 + n * 1.27)/2,-9.2/2,0]) color("gray") cube([7.58 + n * 1.27,9.2,9.2]);
translate([-4/2,-9.3/2,1.2]) cube([4,2,9.2]);
}
translate([-(n-2)/4 *2.54-1,-9.2/2,8]) rotate([90,0,0]) linear_extrude(0.2) polygon([[-1,0],[1,0],[0,-1.5]]); // PFEIL
translate([-(4.6 + n * 1.27)/2,-6/2,1.2]) color("silver") cube([(4.6 + n * 1.27),6,13]);
color("Silver") translate([-(n-2)/4 *2.54,1.27,0]) make_line_of(2.54, n/2) cube([0.5,0.5,8.4], center = true);
color("Silver") translate([-(n-2)/4 *2.54,-1.27,0]) make_line_of(2.54, n/2) cube([0.5,0.5,8.4], center = true);
}
module IDC_CON_90(n = 10)
{
translate([0,2.35,4.6]) rotate([-90,0,0])
{
difference()
{
translate([-(7.58 + n * 1.27)/2,-9.2/2,0]) color("gray") cube([7.58 + n * 1.27,9.2,9.2]);
translate([-4/2,-9.3/2,1.2]) cube([4,2,9.2]);
}
translate([-floor(n/4) *2.54-1,-9.2/2,8]) rotate([90,0,0]) linear_extrude(0.2) polygon([[-1,0],[1,0],[0,-1.5]]); // PFEIL
translate([-(4.5 + n * 1.27)/2,-6/2,1.2]) color("silver") cube([(4.5 + n * 1.27),6,13]);
}
color("Silver") translate([-floor(n/4) *2.54,1.27,0]) make_line_of(2.54, n/2) cube([0.5,0.5,8.4], center = true);
color("Silver") translate([-floor(n/4)*2.54,-1.27,0])
make_line_of(2.54, n/2) cube([0.5,0.5,8.4], center = true);
}
module ML10(Name="",Value="",Library="")
{
difference()
{
translate([-20.3/2,-9.2/2,0]) color("blue") cube([20.3,9.2,9.2]);
translate([-4/2,-9.3/2,1.2]) cube([4,2,9.2]);
}
arrow_polygon = [[-1,0],[1,0],[0,-2.5]];
translate([-5.08,-9.2/2,8]) rotate([90,0,0]) linear_extrude(0.2) polygon(points = arrow_polygon); // PFEIL
translate([-17.3/2,-6/2,1.2]) color("silver") cube([17.3,6,13]);
color("Silver") translate([-2*2.54,1.27,0]) make_line_of(2.54, 5) cube([0.5,0.5,8.4], center = true);
color("Silver") translate([-2*2.54,-1.27,0])
make_line_of(2.54, 5) cube([0.5,0.5,8.4], center = true);
}
module ML10L(Name="",Value="",Library="")
{
translate([0,2.35,4.6]) rotate([-90,0,0])
{
difference()
{
translate([-20.3/2,-9.2/2,0]) color("blue") cube([20.3,9.2,9.2]);
translate([-4/2,-9.3/2,1.2]) cube([4,2,9.2]);
}
translate([-2*2.54,-9.2/2,8]) rotate([90,0,0]) linear_extrude(0.2) polygon([[-1,0],[1,0],[0,-1.5]]); // PFEIL
translate([-17.3/2,-6/2,1.2]) color("silver") cube([17.3,6,13]);
}
color("Silver") translate([-2*2.54,1.27,0]) make_line_of(2.54, 5) cube([0.5,0.5,8.4], center = true);
color("Silver") translate([-2*2.54,-1.27,0])
make_line_of(2.54, 5) cube([0.5,0.5,8.4], center = true);
}
module MJ_RJ45S(Name="",Value="",Library="") //X8 WE-RJ45-ST
{
size = [15.9,16.65,17];
translate([0,size[1]/2-3.45,0]) difference()
{
color("silver") union()
{
cubepart(size);
}
color("DarkSlateGray") translate([0,-1,3.1]) cubepart(size = [12.0,8.3,14]);
color("DarkSlateGray") translate([0,-3,3.1]) cubepart(size = [6.0,8.3,14]);
}
translate([-5*1.27/2,8.89+3.05,1.5]) make_line_of(2.54, 4) LOETPIN(dim = 0.4);
translate([-7*1.27/2,8.89+3.05-2.54,1.5]) make_line_of(2.54, 4) LOETPIN(dim = 0.4);
}
module MJ_RJ45O(Name="",Value="",Library="")
{
// RS: 735-0298
translate([0,2.415,0]) difference()
{
union()
{
color("silver") cubepart(size = [15.75,16.5,13.25]);
translate([-5.5,-7.5,11]) color("Yellow") cubepart(size = [3,2,1.6]);
translate([5.5,-7.5,11]) color("Green") cubepart(size = [3,2,1.6]);
}
color("DarkSlateGray") translate([0,-4,2]) cubepart(size = [12.0,14,8.3]);
color("DarkSlateGray") translate([0,-4,4]) cubepart(size = [6.0,14,8.3]);
}
translate([-5*1.02/2,2.54,1.5]) make_line_of(2.04, 4) LOETPIN(dim = 0.4);
translate([-7*1.02/2,4.32,1.5]) make_line_of(2.04, 4) LOETPIN(dim = 0.4);
translate([-16.3/2,3.43,1.0]) make_line_of(16.3, 2) LOETPIN(dim = 0.8);
translate([-12.7/2,0,-2.5]) color("DarkSlateGray") make_line_of(12.7, 2) cylinder(4,1.5,1.5);
}
module RJ45_PLUG(Name="",Value="",Library="")
{
translate([-12.700/2,-7.400/2,0]) color("DarkSlateGray") linear_extrude(10) polygon([[2.857,7.400],[2.857,8.670],[9.525,8.670],[9.525,7.400],[12.700,7.400],[12.700,0.000],[10.605,0.000],[10.605,0.600],[10.105,0.600],[10.105,0.000],[9.805,0.000],[9.805,0.600],[9.305,0.600],[9.305,0.000],[9.005,0.000],[9.005,0.600],[8.505,0.600],[8.505,0.000],[8.205,0.000],[8.205,0.600],[7.705,0.600],[7.705,0.000],[7.405,0.000],[7.405,0.600],[6.905,0.600],[6.905,0.000],[6.605,0.000],[6.605,0.600],[6.105,0.600],[6.105,0.000],[5.805,0.000],[5.805,0.600],[5.305,0.600],[5.305,0.000],[5.005,0.000],[5.005,0.600],[4.505,0.600],[4.505,0.000],[4.205,0.000],[4.205,0.600],[3.705,0.600],[3.705,0.000],[3.405,0.000],[3.405,0.600],[2.905,0.600],[2.905,0.000],[2.605,0.000],[2.605,0.600],[2.105,0.600],[2.105,0.000],[0.000,0.000],[0.000,7.400]]);
}
// TRIAD
module TRIAD_S3(Name="",Value="",Library="") {TRIAD_S(Pincount = 3);}
module TRIAD_S5(Name="",Value="",Library="") {translate([-7,0,0]) TRIAD_S(Pincount = 5);}
module TRIAD_H5(Name="",Value="",Library="") {translate([0,0, 5.5]) TRIAD_H(5);}
module TRIAD_H3(Name="",Value="",Library="") {translate([0,0, 5.5]) TRIAD_H(3);}
module TRIAD_H4(Name="",Value="",Library="") {translate([0,0, 5.5]) TRIAD_H(4);}
module TRIAD_H(Pincount = 5)
{
TRIAD_SOCKET_HOUSE(Pincount);
}
module TRIAD_S(Pincount = 3)
{
translate([0,0,8]) rotate([90,00,270]) TRIAD_SOCKET_HOUSE(Pincount);
color("RoyalBlue") translate([3.5,-6,0]) cube([8,1,11]);
color("RoyalBlue") translate([3.5,5,0]) cube([8,1,11]);
}
module TRIAD_SOCKET_HOUSE(Pincount = 5)
{
color("RoyalBlue") translate([0,0,2-5.5]) cylinderpart(size = [14.5,2.5]);
color("RoyalBlue") translate([0,0,3-5.5]) difference()
{
cylinderpart(size = [6,9.5]);
if (Pincount == 3)
{
rotate([0,0,270]) make_ring_of(radius = 1.556, count=3, pie = 270) cylinderpart(size = [1.1,13]);
}
if (Pincount == 4)
{
rotate([0,0,45]) make_ring_of(radius = 3.1/2, count=4) cylinderpart(size = [1.1,13]);
}
if (Pincount == 5)
{
make_ring_of(radius = 3.2/2, count=5) cylinderpart(size = [1.1,13]);
}
}
color("silver") translate([0,0,3-5.5]) difference()
{
union()
{
cylinderpart(size = [12,10]);
translate([0,0,1]) cylinderpart(size = [15,1.5]);
}
cylinderpart(size = [8,10.1]);
translate([0,6,2.5])cylinderpart(size = [3,10.1]);
}
}
//BTH_060_01_F_D_A(Name="",Value="",Library="");
// SAMTEC
module SIMPLE_BTH_060_01_F_D_A(Name="",Value="",Library="") // BTH-060-01-F-D-A
{
color("gray") cubepart(size = [36.27,7.24,5]); // Aussenmasse vom BSH
color("gray") translate([-16.7411,2.032]) cylinder(5.76,0.89/2,0.89/2); // Nöppelchen vom BSH
color("gray") translate([16.7411,2.032]) cylinder(5.76,0.89/2,0.89/2); // Nöppelchen vom BSH
}
module BSH_060_01_F_D_A(Name="",Value="",Library="") // BTH-060-01-F-D-A
{
color("gray") cubepart(size = [36.27,7.24,5]);
}
module QTE_020_01_XXX_D_A(Name="",Value="",Library="") //J1 QTE-020-05-XXX-D-A
{
color("gray") cubepart(size = [21,8.128,18.3]);
}
module QSE_020_01_XXX_D_A(Name="",Value="",Library="") //J1 QTE-020-05-XXX-D-A
{
w = 0.6;
size = [21.27,7.24,3.05];
color("DarkSlateGray")
{
linear_extrude(size[2]) difference()
{
polygon([[-size[0]/2,-size[1]/2],[-size[0]/2,size[1]/2], [size[0]/2,size[1]/2], [size[0]/2,-size[1]/2]]);
polygon([[w-size[0]/2,w-size[1]/2],[w-size[0]/2,-w+size[1]/2-1] ,[w-size[0]/2+1,-w+size[1]/2], [-w+size[0]/2-1,-w+size[1]/2], [-w+size[0]/2,-w+size[1]/2-1], [-w+size[0]/2,w-size[1]/2]]);
//translate([0,0,w]) cubepart(size = [21.27-2*w,7.24-2*w,3.05]);
}
cubepart(size = [size[0],size[1],0.6]);
cubepart(size = [size[0]-5,size[1]-3.5,size[2]]);
}
}
module ESQT_105_03_F_S_408(Name="",Value="",Library="SAMTEC-ESQT")
{
ESQT_10x_0x_F_x(n = 5, m=1, A=11.63, h=0.408*25.4);
}
module ESQT_10x_0x_F_x(n = 5, m=1, A=11.63, h=0.408*25.4)
{
offs = 0.4;
height = 6.35;
pitch = 2;
pin = 0.5;
translate([-(pitch/2)*n+offs,-(pitch/2)*m+offs,h-0.38]) cube(0.4);
difference()
{
union()
{
translate([-(pitch/2)*n,-(pitch/2)*m,h-height]) make_line_of(pitch, n) color("DarkSlateGray") linear_extrude(height)
square(size=[pitch,pitch]);
translate([-(pitch/2)*n,-(pitch/2)*m,0]) make_line_of(pitch, n) color("DarkSlateGray") linear_extrude(1.7)
square(size=[pitch,pitch]);
}
translate([-(pitch/2)*(n-1),-(pitch/2)*(m-1),h-2]) make_line_of(pitch, n) color("DarkSlateGray") cubepart([pin+0.2,pin+0.2,3]);
if (m>1) translate([-(pitch/2)*(n-1),+(pitch/2)*(m-1),h-2]) make_line_of(pitch, n) color("DarkSlateGray") cubepart([pin+0.2,pin+0.2,3]);
if (m>2) translate([-(pitch/2)*(n-1),0,h-2]) make_line_of(pitch, n) color("DarkSlateGray") cubepart([pin+0.2,pin+0.2,3]);
}
translate([-(pitch/2)*(n-1),-(pitch/2)*(m-1),0]) make_line_of(pitch, n) color("Silver") translate([0,0,(h-A)+(A-height)/2]) cube([pin,pin,A-height], center = true);
if (m>1) translate([-(pitch/2)*(n-1),+(pitch/2)*(m-1),0]) make_line_of(pitch, n) color("Silver") translate([0,0,(h-A)+(A-height)/2]) cube([pin,pin,A-height], center = true);
if (m>2) translate([-(pitch/2)*(n-1),0,0]) make_line_of(pitch, n) color("Silver") translate([0,0,(h-A)+(A-height)/2]) cube([pin,pin,A-height], center = true);
}
module MC_5V_38(Name="",Value="",Library="")
{
color("lightgreen") translate([-10.22,-1.2,0]) cube([20.44,18.1,10]); //Board
}
module MKS8(Name="",Value="",Library="")
{
translate([0,0,0.1]) difference()
{
color("Silver")cubepart(size = [24.7,7.5,14]);
translate([0,-3,-0.05]) cubepart(size = [20,2,15]);
}
color("Gray") translate([0,0,1]) cubepart(size = [22.4,6,14]);
color("Silver") translate([-7*2.5/2,0,0]) make_line_of(2.5, 8) cube([0.6,0.6,8.4], center = true);
if (Detailgrad > 20)
{
translate([-7*2.5/2,0,12]) color("Gray") make_line_of(2.5, 8) rotate([90,0,0]) cylinder(6,0.8,0.8);
}
}
module MKSW8(Name="",Value="",Library="")
{
translate([0,-0.5,7.5/2]) rotate([-90,0,0])
{
difference()
{
color("Silver") cubepart(size = [24.7,7.5,14.2]);
translate([0,-3,0]) cubepart(size = [20,2,15]);
}
color("Gray") translate([0,0,2.7]) cubepart(size = [22.4,6,12]);
}
color("Silver") translate([-7*2.5/2,0,0]) make_line_of(2.5, 8) cube([0.6,0.6,8.4], center = true);
}
// Mechanik
module PEPAD_M3(Name="",Value="",Library="") {DISTANZBOLZEN(dia = 5.1, h = StrToMMdef(Value,5), drill = 3.5, hole = 2.6); }
module PEPAD_M2X5(Name="",Value="",Library="") {DISTANZBOLZEN(dia = 4.35, h = StrToMMdef(Value,5), drill = 2.8, hole = 2.25); }
module PEPAD_POD_33X9(Name="",Value="",Library="") {DISTANZBOLZEN(dia = 6, h = StrToMMdef(Value,9), drill = 4.2, hole = 3.3); }
module PEPAD_POD_33X5(Name="",Value="",Library="") {DISTANZBOLZEN(dia = 6, h = StrToMMdef(Value,5), drill = 4.2, hole = 3.3);}
module PEPAD_POD_33X3(Name="",Value="",Library="") {DISTANZBOLZEN(dia = 6, h = StrToMMdef(Value,3), drill = 4.2, hole = 3.3); }
module PEPAD_POD_27X5(Name="",Value="",Library="") {DISTANZBOLZEN(dia = 5.1, h = StrToMMdef(Value,5), drill = 3.5, hole = 2.7); }
module PEPAD_POD_22X5(Name="",Value="",Library="") {DISTANZBOLZEN(dia = 4.35, h = StrToMMdef(Value,5), drill = 2.8, hole = 2.25); }
module DISTANZBOLZEN(dia = 5.1, h = 5, drill = 3.5, hole = 2.6)
{
difference()
{
color("silver") union()
{
cylinder(h,dia/2,dia/2, $fn=Detailgrad);
translate([0,0,-1.5]) cylinder(1.5,drill/2,drill/2, $fn=Detailgrad);
}
translate([0,0,-1.75]) cylinder(h+2,hole/2,hole/2, $fn=Detailgrad);
}
}
// Kühlkörper
module D03S(Name="",Value="",Library="")
{ offs = 0.8;
steg = 2;
translate([0,0,0.7]) color("DarkSlateGray")
union()
{
cubepart(size = [14,14,2]); make_line_of(4, 4) translate([-14/2+offs,14/2,offs]) rotate([90,0,0]) linear_extrude(14){offset_square(size = [steg-(2*offs),10-(2*offs)], r = offs, $fn = Detailgrad);}
}
}
module KK_172211(Name="",Value="",Library="OEM-Switch"){color("silver") cubepart([22,17,11]);}
module _693071010811(Name="",Value="",Library="") //SD Kartenhalter
{
rotate([0,0,270]) color("silver") translate([-4.5,-5.06,0]) cube([15.2,14,1.83]); //Board
}
// Spannungregler
module ICF1200XA007V(Name="",Value="",Library="") //IC2 iCF12003A007V-003R
{
rotate([0,0,90])
union()
{
color("SeaGreen") cubepart(size = [12.2,12.2,1.6]);
translate([2.5,-0.8,1.6]) rotate([0,0,90]) DROSSEL(size = [5.2,5.2,2.8]);
}
}
module ULE(Name="",Value="",Library="murata") //IC3 ULE48-1.25
{
rotate([0,0,90])
{
translate([0,0,3.81]) color ("SeaGreen") cubepart([22.6,56.4,1.6]); //Board
translate([0,0,3.81+1.6]) color ("Khaki") cubepart([21.6,55.4,2.4]);
translate([-0.5,-4.3,0]) color ("DarkSlateGray") cubepart([21,14,11]);
translate([-0.5,-20.25,3.81+1.6]) color ("DarkSlateGray") cubepart([10,10,5]);
translate([0,0,3.81-2.4]) color ("Khaki") cubepart([21.6,55.4,2.4]);
translate([7.62,25.4,5.81]) LOETPIN(height = 11, dim = 1.02);
translate([-7.62,25.4,5.81]) LOETPIN(height = 11, dim = 1.02);
translate([-7.62,-25.4,5.81]) LOETPIN(height = 11, dim = 1.02);
translate([7.62,-25.4,5.81]) LOETPIN(height = 11, dim = 1.02);
translate([0,25.4,5.81]) LOETPIN(height = 11, dim = 1.02);
}
}
module UWS(Name="",Value="",Library="murata")
{
translate([0,0,3.2]) color ("SeaGreen") cubepart([33.5,23.4,2.95]); //Board
translate([-14,7.62,3]) LOETPIN(height = 3+4.6, dim = 1.02, rnd = true);
translate([-14,0,3]) LOETPIN(height = 3+4.6, dim = 1.02, rnd = true);
translate([-14,-7.62,3]) LOETPIN(height = 3+4.6, dim = 1.02, rnd = true);
translate([2,-2.25,1]) color ("DarkSlateGray") cubepart([10,18,8.14]);
translate([-10,0.25,0.2]) color ("Khaki") cubepart([10,20,9]);
translate([12,0.25,0.2]) color ("Khaki") cubepart([8,20,9]);
translate([13.94,7.62,3]) LOETPIN(height = 3+4.6, dim = 1.5, rnd = true);
translate([13.94,3.82,3]) LOETPIN(height = 3+4.6, dim = 1.02, rnd = true);
translate([13.94,0,3]) LOETPIN(height = 3+4.6, dim = 1.02, rnd = true);
translate([13.94,-3.82,3]) LOETPIN(height = 3+4.6, dim = 1.02, rnd = true);
translate([13.94,-7.62,3]) LOETPIN(height = 3+4.6, dim = 1.5, rnd = true);
}
module MYBSS054R6EBF(Name="",Value="",Library="")
{
boardsize = [22.4,35.5,1.6];
h = 4.85;
//translate([-10,-18.8,h]) // Pickup Area
translate([0.25,0.25,h])
{
color ("SeaGreen") cube([22.4,35.5,1.6]); //Board
translate([0,0,1.6]) color ("Khaki") cube([22.4,35.5,2.3]);
translate([18,8,-4.7]) color ("DarkSlateGray") cylinder(4.7,8/2,8/2);
translate([0.2,13.8,-4]) color ("DarkSlateGray") cube([20,10,8]);
translate([3.58,boardsize[1]-2.53,-h]) cylinder(h,1.57/2,1.57/2);
translate([3.58,boardsize[1]-2.53-30.44,-h]) cylinder(h,1.57/2,1.57/2);
translate([3.58+11.43,boardsize[1]-2.53,-h]) cylinder(h,1.57/2,1.57/2);
translate([3.58+15.24,boardsize[1]-2.53-30.44,-h]) cylinder(h,1.57/2,1.57/2);
}
}
module LMZM23601V5SILR(Name="",Value="",Library="")
{
size = [3.1,3.9,0.3];
union()
translate([0.45,0,0]) rotate([0,0,270]){
translate([0,0,0]) color ("SeaGreen") cubepart(size); //Board
translate([-size[0]/2.5,-size[1]/2.5,0]) color("white") cylinder(size[2]*1.1, size[1]*0.05, size[1]*0.05, $fn=Detailgrad);
translate([-0.8,1.4,0.3])C_SMD([1.0,0.5,0.6]);
translate([0.8,1.4,0.3])C_SMD([1.0,0.5,0.6]);
translate([0,-0.3,0.3]) R_SMD([2.4,1.9,1.25]);
}
}
module STM32MP15X(Name="",Value="",Library="")
{
if (Detailgrad > 40)
{
versatzy = 0.18;
versatzx = 0.04;
translate([0,0,5]) rotate([0,0,180])
{
color ("SeaGreen") rotate([00,0,0]) translate([-40/2,-44/2,0]) import(str(Package_path,"/PHYTEC_PCM_068_PL1534.stl"));
translate([-15.168+versatzy,-2.54+versatzx]) rotate([180,0,-90]) BSH_060_01_F_D_A(Name="",Value="",Library="");
translate([14.832+versatzy,2.54+versatzx-0.08]) rotate([180,0,-90]) BSH_060_01_F_D_A(Name="",Value="",Library="");
translate([-15.168+versatzy,-2.54+versatzx,-5]) rotate([0,0,-90]) BTH_060_01_F_D_A(Name="",Value="",Library="");
translate([14.832+versatzy,2.54+versatzx-0.08,-5]) rotate([0,0,-90]) BTH_060_01_F_D_A(Name="",Value="",Library="");
}
}
else
{
translate([0,0,5])
{
color ("SeaGreen")
linear_extrude(1.65) difference()
{
translate([-40/2,-44/2]) square([40,44]);
translate([-34/2,38/2]) circle(r=1.850,$fn=$fn); //STM32MP15X P$1
translate([34/2,-38/2])circle(r=1.850,$fn=$fn); //STM32MP15X P$2
}
translate([-15.168,-2.54]) rotate([180,0,-90]) SIMPLE_BTH_060_01_F_D_A(Name="",Value="",Library="");
translate([14.832,2.54-0.08]) rotate([180,0,-90]) SIMPLE_BTH_060_01_F_D_A(Name="",Value="",Library="");
}
}
translate([-34/2,38/2]) DISTANZBOLZEN(dia = 4.35, h = 5, drill = 2.8, hole = 2.25);
translate([34/2,-38/2]) DISTANZBOLZEN(dia = 4.35, h = 5, drill = 2.8, hole = 2.25);
//34/2-4.2+2.032
//34/2+0.2-2.032
//38/2-4.8-16.7411
}
module CHINCH_V(Name="",Value="",Library="") //X3 CHINCH-V
{
difference()
{
union()
{
color("silver")
{
linear_extrude(8.5) circle(5,$fn = Detailgrad);
linear_extrude(17.5) circle(4.15,$fn = Detailgrad);
}
color("Yellow")
linear_extrude(17.6) circle(3.8,$fn = Detailgrad);
}
linear_extrude(17.7) circle(2,$fn = Detailgrad);
}
}
module MICROSD(Name="",Value="",Library="") {color("pink") translate([0,-5.50,0.5]) cube([15,11,1]);}
// RELAYS
module RELAIS(Name="",Value="",Library="") // Halbleiterrelays Crydom
{
rotate([0,0,90]) color ("DarkSlateGray") translate([-4.100,-7.500,0]) linear_extrude(20) square([10.500,43.000]); //Dummy Package
}
module REL_G2RL(Name="",Value="",Library="")
{
color ("DarkSlateGray") translate([-2.300,-2.600,0]) cube([29.000,12.700,15.7]);
}
module OA5642(Name="",Value="",Library="")
{
rotate([0,0,180]) color("Cornsilk")
{
translate([0,0,0.5]) cubepart(size = [26.6,25,9.8], phase = 1);
translate([8.4,8,0.0]) cylinder(0.45,0.45,0.5);
translate([-8.4,8,0.0]) cylinder(0.45,0.45,0.5);
translate([8.4,-8,0.0]) cylinder(0.45,0.45,0.5);
translate([-8.4,-8,0.0]) cylinder(0.45,0.45,0.5);
translate([-26.6/2,-25/2,0.0])
{
translate([1.25,3.1,0.5]) LOETPIN(5.2,0.8);
translate([1.25+15.4,3.1,0.5]) LOETPIN(5.2,0.8);
translate([1.25+15.4+7.5,3.1,0.5]) LOETPIN(5.2,0.8);
translate([1.25,3.1+17.5,0.5]) LOETPIN(5.2,0.8);
translate([1.25+15.4,3.1+15.8,0.5]) LOETPIN(5.2,0.8);
translate([1.25+15.4+7.5,3.1+15.8,0.5]) LOETPIN(5.2,0.8);
}
}
}
module SRD_05VDC_SL_C(Name="",Value="",Library="")
{
color ("blue") linear_extrude(15.3) translate([-8.89,-7.62,0]) square([18.5,15.0]); //Board
}
// POTI
module 3386P(Name="",Value="",Library="")
{
color ("blue") cubepart(size = [9.6,9.6,4.38]);
color("Linen") cylinder(7.87,3.56/2,3.56/2, $fn=Detailgrad);
}
module RJ9W(Name="",Value="",Library="")
{
color ("blue") cubepart(size = [9.1,4.7,9.1]);
}
module S64W(Name="",Value="",Library="")
{
translate([0,1.27,0]) color ("blue") cubepart(size = [9.652,5.08,9.652]);
}
module CT6(Name="",Value="",Library="")
{
color ("Linen") cubepart(size = [7.112,7.112,4.38]);
}
module TRIMPOT_BOURNS_TC33X_2(Name="",Value="",Library="") {
color("silver")
{
translate([-1.5,-2,0]) cube([3,3.75,0.5]);
translate([0,0,0.5]) cylinder(0.7, 1.8,1.8);
}
}
module RTRIM3202(Name="",Value="",Library="") {
color("silver")
{
translate([-1.5,-2,0]) cube([3,3.75,0.5]);
translate([0,0,0.5]) cylinder(0.7, 1.8,1.8);
}
}
// SMD
module _0306(Name="",Value="",Library="") {if (Name[0] == "C") C_SMD([0.8,1.6,0.6]); else R_SMD([0.8,1.6,0.6]);}
module _0402(Name="",Value="",Library="") {if (Name[0] == "C") C_SMD([1.0,0.5,0.4]); else R_SMD([1.0,0.5,0.3]);}
module R0402(Name="",Value="",Library="") {R_SMD([1.0,0.5,0.3]);}
module C0402(Name="",Value="",Library="") {C_SMD([1.0,0.5,0.3]);}
module _0603(Name="",Value="",Library="") {if (Name[0] == "C") C_SMD([1.6,0.8,0.5]); else if (Name[0] == "D") LED_0603(Name=Name,Value=Value,Library=Library); else R_SMD([1.6,0.8,0.5]);}
module R0603(Name="",Value="",Library="") {R_SMD([1.6,0.8,0.5]);}
module R0603_ROUND(Name="",Value="",Library="") {R_SMD([1.6,0.8,0.5]);}
module C0603(Name="",Value="",Library="") {C_SMD([1.6,0.8,0.5]);}
module C0603_ROUND(Name="",Value="",Library="") {C_SMD([1.6,0.8,0.5]);}
module _0805(Name="",Value="",Library="") {if (Name[0] == "C") C_SMD([2.0,1.2,0.6]); else if (Name[0] == "D") LED_0805(Name=Name,Value=Value,Library=Library); else R_SMD([2.0,1.2,0.6]);}
module C0805(Name="",Value="",Library="") {C_SMD([2.0,1.2,0.6]);}
module R0805(Name="",Value="",Library="") {R_SMD([2.0,1.2,0.6]);}
module _1206(Name="",Value="",Library="") {if (Name[0] == "C") C_SMD([3.2,1.6,0.8]); else R_SMD([3.2,1.6,0.8]);}
module C1206(Name="",Value="",Library="") {C_SMD([3.2,1.6,0.8]);}
module R1206(Name="",Value="",Library="") {R_SMD([3.2,1.6,0.8]);}
module M1206(Name="",Value="",Library="") {R_SMD([3.2,1.6,0.8]);}
module _1210(Name="",Value="",Library="") {if (Name[0] == "C") C_SMD([3.2,2.5,1.5]); else R_SMD([3.2,2.5,1.5]);}
module C1210(Name="",Value="",Library="") {C_SMD([3.2,2.5,1.5]);}
module _1812(Name="",Value="",Library="") {if (Name[0] == "C") C_SMD([4.5,3.2,3.2]); else R_SMD([4.5,3.2,3.2]);}
module _2220(Name="",Value="",Library="") {if (Name[0] == "C") C_SMD([5.7,5.0,4.2]); else R_SMD([5.7,5.0,4.2]);}
module _1020(Name="",Value="",Library="") {rotate([0,0,90]) R_SMD([2.5,5,0.55]);}
module R2010(Name="",Value="",Library="") {R_SMD([5,2.5,0.55]);}
module _2512(Name="",Value="",Library="") {if (Name[0] == "C") C_SMD([6.45,3.35,0.7]); else R_SMD([6.45,3.35,0.7]);}
module R2512(Name="",Value="",Library="") {R_SMD([6.45,3.35,0.7]);}
module _3216(Name="",Value="",Library="") {TANTAL([3.2,1.6,1.6]);}
module _3528(Name="",Value="",Library="") {TANTAL([3.5,2.8,3]);}
module _6032(Name="",Value="",Library="") {TANTAL([5.2,3.2,2.8]);}
module _7243(Name="",Value="",Library="") {TANTAL([6.8,4.3,3]);}
module 0414_15(Name="",Value="",Library="") {R_THT(4.5,7.62*2,0.9);}
module 0204_5(Name="",Value="",Library="") {R_THT(1.8,5.08*1.0,0.5); }
module 0204_7(Name="",Value="",Library="") {R_THT(1.8,7.62*1.0,0.5); }
module R_7_5(Name="",Value="",Library="") {R_THT(3,5.08*1.5,0.6); }
module R_10(Name="",Value="",Library="") {R_THT(3,5.08*2,0.6); }
module R_12_5(Name="",Value="",Library="") {R_THT(3,5.08*2.5,0.6); }
module SIL8(Name="",Value="",Library="resistor-sil"){translate([-1.27*7,0,0])R_SIL(8); }
module SIL9(Name="",Value="",Library="resistor-sil"){translate([-1.27*8,0,0])R_SIL(9); }
module CAY16(Name="",Value="",Library="resistor-dil") {EXB38V();}
module C050_025X075(Name="",Value="",Library="") {C_THT(2,5.08*1,0.6); }
module C050_024X044(Name="",Value="",Library="") {C_THT(2,5.08*1,0.6); }
module C_5(Name="",Value="",Library="") {C_THT(2,5.08*1,0.6); }
module C_2_5(Name="",Value="",Library="") {color("orange") translate([-2,-0.8,2])cube([4,1.6,3]);
translate([-1.27,0,3]) make_line_of(2.54, 2) LOETPIN(dim = 0.4);}
module C_NP7(Name="",Value="",Library="") {color("silver") Phased_cylinder(8,3.5,3.5); }
module C_NP6(Name="",Value="",Library="") {color("silver") Phased_cylinder(8,3,3); }
module C_NP5(Name="",Value="",Library="") {color("silver") Phased_cylinder(8,2.5,2.5); }
module EXB38V(Name="",Value="",Library="resistor-dil")
{ color("DarkSlateGray") cubepart([3.2,1.6,0.5]);
translate([-1.3,0,0]) color("Silver") cubepart([0.65,2.2,0.4]);
translate([1.3,0,0]) color("Silver") cubepart([0.65,2.2,0.4]);
translate([-0.4,0,0]) color("Silver") cubepart([0.45,2.2,0.4]);
translate([0.4,0,0]) color("Silver") cubepart([0.45,2.2,0.4]);
}
module LED_0603(Name="",Value="",Library="",Enable = false) {LED_SMD(size = [0.8,1.7,0.65], Enable = Enable, Value = Value);}
module LED_0805(Name="",Value="",Library="",Enable = false) {LED_SMD(size = [1.2,2.0,0.65], Enable = Enable, Value = Value);}
module CHIP_LED0805(Name="",Value="",Library="led") {rotate([0,0,90]) LED_0805(Value = Value);}
module LED4_BR0(Name="",Value="",Library="",Enable = false) {LED_SMD(size = [3,3.4,0.65], Enable = Enable, Value = Value);}
// FUSE
module FUSE2920(Name="",Value="",Library="") {R_SMD([8,5.4,1.25]);}
module ATO_FKS_20(Name="",Value="",Library="Littelfuse")
{
color("DarkSlateGray")
difference()
{
cubepart([20,6,17.5]);
translate([0,0,5]) cubepart([16,5,17.5]);
}
color("DeepPink") cubepart([19.2,5,25]);
}
module H7810(Name="",Value="",Library="Littelfuse")
{
color("DarkSlateGray")
difference()
{
cubepart([14.2,6,15.6]);
translate([0,0,5]) cubepart([12.6,5,15.6]);
}
color("DeepPink") cubepart([12,5,24]);
}
module ELKO_136X135(Name="",Value="",Library="") { color("DarkSlateGray") linear_extrude(2) polygon([[4.5,6.8],[6.8,4.5],[6.8,-6.8],[-6.8,-6.8],[-6.8,4.5],[-4.5,6.8]]);
color("silver") Phased_cylinder(13.5,12.5/2,12.5/2);}
module ELKO_FCG(Name="",Value="",Library="") { color("DarkSlateGray") linear_extrude(2) polygon([[3.5,5.5],[5.5,3.5],[5.5,-5.5],[-5.5,-5.5],[-5.5,3.5],[-3.5,5.5]]); color("silver") Phased_cylinder(10.5,5,5);}
module PANASONIC_D(Name="",Value="",Library="") { color("DarkSlateGray") translate([0,0,1/2]) cube([6.6,6.6,1], center = true); color("silver") Phased_cylinder(5.8,6.3/2,6.3/2);}
module ELCO_E(Name="",Value="",Library="") { color("DarkSlateGray") translate([0,0,1/2]) cube([8.3,8.3,1], center = true); color("silver") Phased_cylinder(6.2,4,4);}
module ELCO_F(Name="",Value="",Library="") { color("DarkSlateGray") translate([0,0,1/2]) cube([8.3,8.3,1], center = true); color("silver") Phased_cylinder(10.2,4,4);}
module ES_3_8(Name="",Value="",Library="") {translate([-0.635,0,0]) { color("DarkSlateGray") Phased_cylinder(12.5,4.3,4.3); make_line_of(3.81, 2, center=true) LOETPIN(height = 4, dim = 0.6, rnd = true);}}
module E3_5_8(Name="",Value="",Library="rcl") { color("DarkSlateGray") Phased_cylinder(12.5,4.3,4.3); make_line_of(3.5, 2, center=true) LOETPIN(height = 4, dim = 0.6, rnd = true);}
module ES_3_4(Name="",Value="",Library="") {color("DarkSlateGray") Phased_cylinder(12.5,4.3,4.3); make_line_of(3.4, 2, center=true) LOETPIN(height = 3, dim = 0.6, rnd = true);}
module ES_1_5(Name="",Value="",Library="") {color("DarkSlateGray") Phased_cylinder(6,4.4/2,4.4/2);make_line_of(1.5, 2, center=true) LOETPIN(height = 3, dim = 0.6, rnd = true);}
module ES_2_2(Name="",Value="",Library="") {color("DarkSlateGray") Phased_cylinder(12,5/2,5/2);make_line_of(2.2, 2, center=true) LOETPIN(height = 3, dim = 0.6, rnd = true);}
module ES_5L(Name="",Value="",Library="") {translate([2.5,0,0]) {color("DarkSlateGray") Phased_cylinder(20,6.3,6.3);make_line_of(5, 2, center=true) LOETPIN(height = 3, dim = 0.6, rnd = true);}}
module ES_5(Name="",Value="",Library="") {color("DarkSlateGray") Phased_cylinder(20,6.3,6.3);make_line_of(5, 2, center=true) LOETPIN(height = 3, dim = 0.6, rnd = true);}
module ES_2_5(Name="",Value="",Library="") {color("DarkSlateGray") Phased_cylinder(12,4,4);make_line_of(2.5, 2, center=true) LOETPIN(height = 3, dim = 0.6, rnd = true);}
module E2_5_5(Name="",Value="",Library="") {color("DarkSlateGray") Phased_cylinder(10,2.5,2.5);make_line_of(2.5, 2, center=true) LOETPIN(height = 3, dim = 0.6, rnd = true);}
module E2_5_6(Name="",Value="",Library="") {color("DarkSlateGray") Phased_cylinder(10,3,3);make_line_of(2.5, 2, center=true) LOETPIN(height = 3, dim = 0.6, rnd = true);}
module E2_5_7(Name="",Value="",Library="") {color("DarkSlateGray") Phased_cylinder(12,3.5,3.5);make_line_of(2.5, 2, center=true) LOETPIN(height = 3, dim = 0.6, rnd = true);}
module 10X5X0_9(Name="",Value="",Library="") {color("Red") Phased_cylinder(20,10.25/2,10.25/2);}
module L_THT_8_10(Name="",Value="",Library="") {color("DarkSlateGray") Phased_cylinder(10,4,4);make_line_of(3, 2, center=true) LOETPIN(height = 3, dim = 0.6, rnd = true);}
module 82114R(Name="",Value="",Library="") {color("DarkSlateGray") Phased_cylinder(11,3.3,3.3); rotate([0,0,90]) make_line_of(3.81, 2, center=true) LOETPIN(height = 3, dim = 0.6, rnd = true);}
module E45_18(Name="",Value="",Library=""){ELKO_THT_L(D=18,L=2.54*18);}
module E30_10(Name="",Value="",Library=""){ELKO_THT_L(D=10,L=2.54*12);}
module ELKO_THT_L(D=10,L=45){
L1 = L-2.54;
Pin = 0.8;
color("DarkSlateGray") translate([-L1/2,0,D/2]) rotate([0,90,0]) Phased_cylinder(L1,D/2,D/2);
;
color("Silver")
{
translate([L/2,0,-2.25*Pin+D/2]) BendedPIN(Pin,D/2+2,l2=2*Pin);
translate([-L/2,0,-2.25*Pin+D/2]) rotate([0,0,180]) BendedPIN(Pin,D/2+2,l2=2*Pin);
}
}
module Phased_cylinder(l,r1,r2,Roundness = 0.2)
{
if ((Detailgrad < 21))
{
cylinder(l,r1,r2);
}
else
{
round1 = r1*Roundness/2;
round2 = r2*Roundness/2;
cylinder(l,r1-round1,r2-round2);
translate([0,0,round1]) cylinder(l-round2-round1,r1,r2);
rotate_extrude(convexity = 10) translate([r1-round1, round1, 0]) circle(r = round1);
rotate_extrude(convexity = 10) translate([r2-round2, l-round2, ]) circle(r = round1);
}
}
module SIP3S(Name="",Value="",Library="")
{
rotate([0,0,180]) translate([-8.41,-1.27,0]) color("DarkSlateGray") cube([11.747500,7.302500, 10.5]);
make_line_of(2.54, 3) LOETPIN();
}
module SIP3L(Name="",Value="",Library="")
{
rotate([0,0,180]) translate([2.54,2.25,0]) color("DarkSlateGray") cubepart([11.5,8.5, 17.5]);
translate([-5.08,0,0]) make_line_of(2.54, 3) LOETPIN();
}
module SIP4(Name="",Value="",Library="") //RM0505S RM0505S
{
translate([-4.603700,-1.27,0]) color("DarkSlateGray") cube([11.747500,7.302500, 10.5]);
translate([-2.54,0,0]) make_line_of(2.54, 4) LOETPIN();
}
module SIP7(Name="",Value="",Library="")
{
Displacement = (Library == "traco_tma")?[-7.89,2.3,0]:[0,0,0];
translate(Displacement) // [-3*2.54,1*2.54,0])
{
translate([-2,-5.78,0]) color("DarkSlateGray") cube([19.6,7.05, 10.2]);
translate([0,0,0]) make_line_of(2.54, 2) LOETPIN(4.1,0.5);
translate([3*2.54,0,0]) make_line_of(2.54, 3) LOETPIN(4.1,0.5);
}
}
module SIP7L(Name="",Value="",Library="")
{
translate([-2,-5.78+7.05,0]) rotate([-90,0,0]) color("DarkSlateGray") translate([-0,-7.05,0]) cube([19.6,7.05, 10.2]);
translate([0,0,-0.5]) make_line_of(2.54, 2) rotate([0,0,-90]) BendedPIN(0.6, l2=1.2);
translate([3*2.54,0,-0.5]) make_line_of(2.54, 3)rotate([0,0,-90]) BendedPIN(0.6,l2=1.2);
}
module SIP7XP(Name="",Value="",Library="")
{
//translate([-3*2.54,1*2.54,0])
{
translate([-2.13,-(9.2-2.4),0]) color("DarkSlateGray") cube([19.5,9.2, 11.1]);
translate([0,0,0]) make_line_of(2.54, 2) LOETPIN(4.1,0.5);
translate([4*2.54,0,0]) make_line_of(2.54, 3) LOETPIN(4.1,0.5);
color("White") translate([0,-(9.2-2.4),2]) rotate([90,0,0]) cylinder(0.1,0.5,0.5);
}
}
module A1353BCD(Name="",Value="",Library="") {rotate([0,0,-90]) BCD_DIL(Name=Name,Value=Value,Library=Library);}
module P103(Name="",Value="",Library="") {rotate([0,0,-90]) BCD_DIL(Name=Name,Value=Value,Library=Library);}
module BCD_DIL(Name="",Value="",Library="")
{
gehause_polygon=[[5,-5],[5,4],[4,5],[-5,5],[-5,-5]];
color("DarkSlateGray") linear_extrude(1) polygon(gehause_polygon);
color("LemonChiffon") { translate([0,0,1]) linear_extrude(3.3) polygon(gehause_polygon);
translate([0,0,4.3]) cylinder(2.2,5,5); }
translate([-2.54,3.81,0]) make_line_of(2.54, 3) LOETPIN(4.1,0.5);
translate([-2.54,-3.81,0]) make_line_of(2.54, 3) LOETPIN(4.1,0.5);
}
// Honeywell
module HIH_4000_001(Name="",Value="",Library="Honeywell")
{
rotate([00,00,180]) translate([-2.09,-1.4,4])
{
color("DarkSlateGray") difference()
{
cube([4.18,2.03,8.6]);
translate([0.6,1,2]) cube([3,2,5]);
}
color("Silver") translate([1.3,1,3.5]) cube([1.5,1,2.8]);
}
translate([0,0,5.9]) rotate([0,0,00]) LOETPIN(dim = 0.4, height=9, displacement=0);
translate([2.54,0,5.9]) rotate([0,0,00]) LOETPIN(dim = 0.4, height=9, displacement=-1.27);
translate([-2.54,0,5.9]) rotate([0,0,180]) LOETPIN(dim = 0.4, height=9, displacement=-1.27);
}
module HIH_4000_001_H(Name="",Value="",Library="Honeywell")
{
translate([0,4,0.2]) rotate([-90,00,0]) HIH_4000_001(Name="",Value="",Library="Honeywell");
}
//RECOM
module SMD_DIL1(Name="",Value="",Library="") {
SMD_IC([15.24,10.7,9], frustum = 3);
SMD_PIN(size=[15.24,8.5,9], pinnumber = 1, pitch=2.54, pinlength=1.3 );
SMD_PIN(size=[15.24,8.5,9], pinnumber = 2, pitch=2.54, pinlength=1.3 );
SMD_PIN(size=[15.24,8.5,9], pinnumber = 4, pitch=2.54, pinlength=1.3 );
SMD_PIN(size=[15.24,8.5,9], pinnumber = 5, pitch=2.54, pinlength=1.3 );
rotate([0,0,180]) SMD_PIN(size=[15.24,8.5,9], pinnumber = 7-5, pitch=2.54, pinlength=1.3 );
rotate([0,0,180]) SMD_PIN(size=[15.24,8.5,9], pinnumber = 10-5, pitch=2.54, pinlength=1.3 );
}
module REC_RCD(Name="",Value="",Library="") {
translate([+3.5*2.54,0,0]) color("DarkSlateGray") cubepart([22.10,12.55,8.5]);
}
// WÜRTH
module MAGI3C_FISM_SMT_8(Name="",Value="",Library="") {
SMD_IC([12.75,10.7,7], frustum = 3);
SMD_PIN(size=[11.75,8.5,9], pinnumber = 1, pitch=2.54, pinlength=1.3 );
SMD_PIN(size=[11.75,8.5,9], pinnumber = 2, pitch=2.54, pinlength=1.3 );
SMD_PIN(size=[11.75,8.5,9], pinnumber = 4, pitch=2.54, pinlength=1.3 );
rotate([0,0,180]) SMD_PIN(size=[11.75,8.5,9], pinnumber = 5-4, pitch=2.54, pinlength=1.3 );
rotate([0,0,180]) SMD_PIN(size=[11.75,8.5,9], pinnumber = 8-4, pitch=2.54, pinlength=1.3 );
}
module _171021501(Name="",Value="",Library="")
{ SMD_FN(size = [11,9,2.8],pinrows=4, pitch=0.9, pinheight = 0, phase = 0);
}
module PACKAGE_A2(Name="",Value="",Library="") {translate([0,-1.27,0]) SMD_DIL1(Name=Name,Value=Value,Library=Library);}
module DC_SMD(Name="",Value="",Library="") {translate([-1.27,0,0]) SMD_DIL1(Name=Name,Value=Value,Library=Library);}
module DIP(Name="",Value="",Library="") {SMD_IC([8.3,8.3,6.8]);translate([0,2.54,0])LOETPIN();translate([2.54,2.54,0])LOETPIN();translate([-2.54,-2.54,0])LOETPIN();translate([2.54,-2.54,0])LOETPIN();}
module DIL04(Name="",Value="",Library="") {DIL(n=4,b=7.62,Text=Name);}
module DIL08(Name="",Value="",Library="") {DIL(n=8,b=7.62,Text=Name);}
module DIP08_MCU(Name="",Value="",Library="") {DIL(n=8,b=7.62,Text=Name);}
module DIL8(Name="",Value="",Library="") {DIL(n=8,b=7.62,Text=Name);}
module DIL14(Name="",Value="",Library="") {DIL(n=14,b=7.62,Text=Name);}
module DIL16(Name="",Value="",Library="") {DIL(n=16,b=7.62,Text=Name);}
module DIL18(Name="",Value="",Library="") {DIL(n=18,b=7.62,Text=Name);}
module DIL20(Name="",Value="",Library="") {DIL(n=20,b=7.62,Text=Name);}
module DIL24_6(Name="",Value="",Library="") {DIL(n=24,b=7.62*2,Text=Name);}
module DIL28(Name="",Value="",Library="") {DIL(n=28,b=7.62*2,Text=Name);}
module DIL28_6(Name="",Value="",Library="") {DIL(n=28,b=7.62*2,Text=Name);}
module DIL28_3(Name="",Value="",Library="") {DIL(n=28,b=7.62,Text=Name);}
module DIL40(Name="",Value="",Library="") {DIL(n=40,b=7.62*2,Text=Name);}
module 8PM_11_0010_02_131191(Name="",Value="",Library="") {PreciDip_8PM_11(pins = 10);}
module 8PM_11_0005_02_131191(Name="",Value="",Library="") {PreciDip_8PM_11(pins = 5);}
module 811_S1_005_10_016101(Name="",Value="",Library="") {rotate([0,0,90]) PreciDip_81X_S1(N=5, M= 1, A = 7, B = 4); }
module PreciDip_8PM_11(pins = 10, Serie = 131)
{
l1 = Serie == 131 ? 7.3 : 5.3;
l2 = Serie == 131 ? 8.95 : 7;
d = Serie == 131 ? 1.02 : 0.96;
pitch=2.54; translate([-pitch/2+pitch*pins/2,0.1,1.7/2]) rotate([90,0,180]) make_line_of(pitch, pins) { cylinder(l1,1.7/2,1.7/2); cylinder(l2-d/2,d/2,d/2); translate([0,0,l2-d/2]) sphere(d/2);
}color("DarkSlateGray") translate([0,2.5,0.85]) cubepart([pitch*pins,5,2.44-0.85]);}
module PreciDip_81X_S1(N = 5, M = 1, A = 7, B = 4)
{
offs = 0.9;
height = 11.6;
pitch = 2.54;
solderpin = 0.8;
pin = 1.07;
module aPin() { cylinder(0.5,1.83/2,1.83/2, $fn=Detailgrad); translate([0,0,-3+solderpin/2]) cylinder(3-solderpin/2,solderpin/2,solderpin/2, $fn=Detailgrad); cylinder(A-pin/2,pin/2,pin/2, $fn=Detailgrad); translate([0,0,-3+solderpin/2]) sphere(solderpin/2, $fn=Detailgrad);translate([0,0,A-pin/2]) sphere(pin/2,$fn=Detailgrad);}
translate([-(pitch/2)*N+offs,-(pitch/2)*M+offs,0.4]) make_line_of(pitch, N) color("DarkSlateGray") linear_extrude(B) offset_square(size=[pitch-2*offs,pitch*M-2*offs], delta = offs, chamfer=true);
translate([-(pitch/2)*(N-1),-(pitch/2)*(M-1),0]) make_line_of(pitch, N) color("Silver") aPin(Name="",Value="",Library="");
//if (m>1) translate([-(pitch/2)*(n-1),+(pitch/2)*(m-1),0]) make_line_of(pitch, n) color("Silver") translate([0,0,8.7-height/2]) cube([pin,pin,height], center = true);
//if (m>2) translate([-(pitch/2)*(n-1),0,0]) make_line_of(pitch, n) color("Silver") translate([0,0,8.7-height/2]) cube([pin,pin,height], center = true);
}
module 800_80_005_30_480101(Name="",Value="",Library="") {rotate([0,0,90]) PreciDip_80X_PP_30_480(N = 5, M = 1);}
module PreciDip_80X_PP_30_480(N = 5, M = 1)
{
offs = 0.9;
B = 2.8;
height = 3.5;
pitch = 2.54;
solderpin = 0.76;
pin = 1.6;
module aPin() { cylinder(0.5,1.6/2,1.6/2, $fn=Detailgrad); translate([0,0,-3.6+solderpin/2]) cylinder(3.6-solderpin/2,solderpin/2,solderpin/2, $fn=Detailgrad); translate([0,0,-3.6+solderpin/2]) sphere(solderpin/2, $fn=Detailgrad); cylinder(height,pin/2,pin/2, $fn=Detailgrad); }
translate([-(pitch/2)*N+offs,-(pitch/2)*M+offs,0.3]) make_line_of(pitch, N) color("DarkSlateGray") linear_extrude(B) offset_square(size=[pitch-2*offs,pitch*M-2*offs], delta = offs, chamfer=true);
translate([-(pitch/2)*(N-1),-(pitch/2)*(M-1),0]) make_line_of(pitch, N) color("Silver") aPin(Name="",Value="",Library="");
//if (m>1) translate([-(pitch/2)*(n-1),+(pitch/2)*(m-1),0]) make_line_of(pitch, n) color("Silver") translate([0,0,8.7-height/2]) cube([pin,pin,height], center = true);
//if (m>2) translate([-(pitch/2)*(n-1),0,0]) make_line_of(pitch, n) color("Silver") translate([0,0,8.7-height/2]) cube([pin,pin,height], center = true);
}
//Produktdetails 8PM_11_0005
//SIL-Kontakte mit Federkraftanschluss, 2,54 mm, paralleles SMD-Pad
//
//Die modularen Steckverbinder der Serie Preci-dip SIL 8PM-11 mit geringem Widerstand besitzen Kontakte mit Federkraftanschluss (SLC) mit parallelen SMD-Pads für Bestückungsmaschinen.
//Einzelheiten zu den Maßen finden Sie im Herstellerdatenblatt auf unserer Website.
//Passender SMD-SIL-Pad-Steckverbinder siehe typische Best.-Nr. 702-0360 (gerade) oder 702-5126 (parallel)
//Durchkontaktierte SIL-Steckverbinder siehe typische Best.-Nr. 701-9947 und gerade SMD-Steckverbinder siehe typische Best.-Nr. 702-0234
//
//Das Höhenmaß ergibt die gesamte Parallelhöhe des Steckverbinders über der Leiterplatte.
//Die Gesamtlänge des Steckverbinders beträgt 8,95 mm
//Die Hublänge des Stößels beträgt 1,5 mm
//Passender SMD-SIL-Pad-Steckverbinder siehe typische Best.-Nr. 702-0360 (gerade) oder 702-5126 (parallel)
//Durchkontaktierte SIL-Steckverbinder siehe typische Best.-Nr. 701-9947 und gerade SMD-Steckverbinder siehe typische Best.-Nr. 702-0234
//Normen
//
//UL 94V-0
module SMD5_2_54_ROUND(Name="",Value="",Library="") {InvisiblePart();}
// INDUKTIVITAET
// Würth Elecronic
module WE_PD_1260_1245_1280_1210(Name="",Value="",Library="") {DROSSEL(size = [12,12,10]);}
module WE_HCI_5040(Name="",Value="",Library="") {DROSSEL(size = [5.3,5.6,4]);}
module WE_HCI_1890(Name="",Value="",Library="") {DROSSEL(size = [18.5,18.5,9]);}
module WE_SL2(Name="",Value="",Library="") {DROSSEL(size = [9.4,6.2,5]);}
module WE_CNSW1812(Name="",Value="",Library="") {DROSSEL(size = [4.5,3.2,2.8]);}
module WE_CNSW(Name="",Value="",Library="") {DROSSEL(size = [3.2,1.6,1.9]);}
module L1812(Name="",Value="",Library="") {DROSSEL(size = [4.5,3.2,2.8]);}
module WE_SL_4WINDING(Name="",Value="",Library="") {DROSSEL(size = [11,10.5,5.5]);}
module WE_LHMI_4020(Name="",Value="",Library="") {DROSSEL(size = [4.45,4.06,1.8]);}
module WE_LQS_6028(Name="",Value="",Library="") {DROSSEL(size = [6,6,5]);}
module WE_LQS_3015(Name="",Value="",Library="") {DROSSEL(size = [3,3,1.5]);}
module WE_LQS_2512(Name="",Value="",Library="") {DROSSEL(size = [2.5,2.5,1.5]);}
module WE_HCI_1350_1365(Name="",Value="",Library="") {DROSSEL(size = [12.8,12.8,6.2]);}
module _749023015(Name="",Value="",Library="") {rotate([0,0,270]) SMD_IC([18.3,12.2,6.35],pinrows=2,pitch=1.27,phase = 1);}
module _749020111(Name="",Value="",Library="") {rotate([0,0,270]) SMD_IC([16.5,9,2.35],pinrows=2,pinlength=0.35,pitch=1.27,phase = 0);}
module WE_LAN_749020011A(Name="",Value="",Library="") {SMD_IC([17.5,14.2,6.5],pinrows=2,pinlength=0.52,pitch=1.27,phase = 1);}
module L3225M(Name="",Value="",Library="") {DROSSEL(size = [3.2,2.5,1.55]);}
module DR127(Name="",Value="",Library="") {rotate([0,0,0]) DROSSEL(size = [12.7,12.7,6]);}
module LSMD7X7(Name="",Value="",Library="") {rotate([0,0,90]) DROSSEL(size = [7.3,7.3,5]);}
module ALT3232M(Name="",Value="",Library="") {DROSSEL(size = [3.2,3.2,2.9]);}
module ACM2012_2P(Name="",Value="",Library="") {DROSSEL(size = [2,1.2,1.3]);}
module SFT1040(Name="",Value="",Library="") {color("Gray") translate([-6,0,12.5]) rotate([0,90,0])Ringkern(25, 16, 12);}
module SFT1030(Name="",Value="",Library="") {color("Gray") translate([-4,0,10]) rotate([0,90,0])Ringkern(20, 12, 8);}
module ED22(Name="",Value="",Library=""){color("Gray") translate([0,0,1]) Ringkern(21, 12, 8);}
module LDG_LG4801D(Name="",Value="",Library="OEM-Switch") {
color("DarkSlateGray") cubepart([28.000,11.000,11]);
translate([-0.5,2.7,0]) make_line_of(2, 12, center=true) LOETPIN(height = 3.3, dim = 0.6, rnd = true);
translate([0.5,4.45,0]) make_line_of(2, 12, center=true) LOETPIN(height = 3.3, dim = 0.6, rnd = true);
translate([0.5,-2.7,0]) make_line_of(2, 12, center=true) LOETPIN(height = 3.3, dim = 0.6, rnd = true);
translate([-0.5,-4.45,0]) make_line_of(2, 12, center=true) LOETPIN(height = 3.3, dim = 0.6, rnd = true);
}
module PTG_1841(Name="",Value="",Library="OEM-Switch") {
color("DarkSlateGray") cubepart([16.800,7.400,11]);
translate([0,2.38,0]) make_line_of(1.78, 9, center=true) LOETPIN(height = 4, dim = 0.6, rnd = true);
translate([0,-2.38,0]) make_line_of(1.78, 9, center=true) LOETPIN(height = 4, dim = 0.6, rnd = true);
}
module _68715014522(Name="",Value="",Library="") {rotate([0,0,180]) FPC_L(size = [31.6,4.5,2]);}
module _68714014522(Name="",Value="",Library="") {rotate([0,0,180]) FPC_L(size = [26.6,4.5,2]);}
module _68714014022(Name="",Value="",Library="") {rotate([0,0,180]) FPC_L(size = [26.6,4.5,2]);}
module _68712414522(Name="",Value="",Library="") {rotate([0,0,180]) FPC_L(size = [18.4,4.5,2]);}
module _687124149022(Name="",Value="",Library="") {translate([0,-1,0]) rotate([0,0,180]) FPC_L(size = [18.2,4.5,2]);}
module _68611014422(Name="",Value="",Library="Wurth_Connectors_WR-FPC"){translate([0,2.8,0]) rotate([0,0,180]) FPC_L(size = [16.90,5.4,3], pitch=1);}
module _68712014522(Name="",Value="",Library="Wurth_Connectors_WR-FPC"){translate([0,1.8,0]) rotate([0,0,180]) FPC_L(size = [16.4,4.3,2.1], pitch=0.5, pinlength = 0.8);}
module _687310124422(Name="",Value="",Library="") {rotate([0,0,180]) FPC_S(size = [11.44,2,4.5], pitch=0.5, invers = false);
;}
module _687350124422(Name="",Value="",Library="") {translate([2.3,0,0]) rotate([0,0,180]) FPC_S(size = [32.44,2,4.5], pitch=0.5, invers = false);
;}
module _686320124422(Name="",Value="",Library="") {rotate([0,0,180]) FPC_S(size = [24.44,2,4.5], pitch=0.5, invers = false);
;}
module _687320124422(Name="",Value="",Library="Wurth_Connectors_WR-FPC") {rotate([0,0,180]) FPC_S(size = [16.4,2,4.3], pitch=0.5, invers = false);
;}
module _686110183822(Name="",Value="",Library="Wurth_Connectors_WR-FPC") {rotate([0,0,180]) FPC_S(size = [16.8,2.3,3.9], pitch=1, invers = false);
;}
module FPC_LIF_V_20_1(Name="",Value="",Library="CON-SMD_6"){translate([0.0,0,0]) FPC_S(size = [26,3.5,6], pitch=1, invers = false);
;}
//
module ZF1_15S(Name="",Value="",Library="") {translate([2.5,0,0]) FPC_S(size = [23,3.5,6], pitch=1, invers = false);
;}
module FH12_53S_0_5SH(Name="",Value="",Library="") {translate([0,2.5,0]) rotate([0,0,180]) FPC_L(size = [33,5.2,2]);}
module HRSZIF2405O(Name="",Value="",Library="") {rotate([0,0,180]) FPC_L(size = [16.5,6.2,2]);}
module ZF1_10(Name="",Value="",Library="") {rotate([0,0,180]) FPC_L(size = [16.9,5.2,2], pitch=1);}
module ZF1_15(Name="",Value="",Library="") {rotate([0,0,180]) FPC_L(size = [20.9,5.2,2], pitch=1);}
module ZF1_10_4(Name="",Value="",Library="") {_687310124422(Name=Name,Value=Value,Library=Library);}
module _68711014522(Name="",Value="",Library="") {rotate([0,0,180]) FPC_L(size = [11.4,4.2,2], pitch=0.5);}
module _68710614522(Name="",Value="",Library="") {rotate([0,0,180]) FPC_L(size = [9.4,4.2,2], pitch=0.5);}
module 52746_8(Name="",Value="",Library="") // //Molex FPC
{
rotate([0,0,180]) FPC_L(size = [10.4,4.2,2], pitch=0.5);
}
module M50F_SMT(Name="",Value="",Library="") {SMD_IC([6.8,3.4,1.7],pinrows=2,pitch=1.27);
color("DarkSlateGray") translate([+1.2/2,0,3.4]) cubepart([9.6,3,4.8]);
color("Yellow") translate([-9.6/2,0,3.4]) cubepart([1.2,3,4.8]);
translate([-2.54,1.27/2,4]) make_line_of(1.27, 5) LOETPIN(height = 3.5, dim = 0.45);
translate([-2.54,-1.27/2,4]) make_line_of(1.27, 5) LOETPIN(height = 3.5, dim = 0.45);}
module M50F_SMS(Name="",Value="",Library="") {M50F_SMT(Name=Name,Value=Value,Library=Library);}
module M50F2_SM(Name="",Value="",Library="") {M50F_SMT(Name=Name,Value=Value,Library=Library);}
module M50F4_SM(Name="",Value="",Library="") {M50F_SMT(Name=Name,Value=Value,Library=Library);}
module M50F_SM2(Name="",Value="",Library="") {M50F_SMT(Name=Name,Value=Value,Library=Library);}
// Speeker
module UEB025(Name="",Value="",Library="") { color("silver") cylinder(12,12.5,12.5, $fn=Detailgrad); }
// BUTTON Switch
module BT_4025(Name="",Value="",Library="") { color("DarkSlateGray") cylinder(1.5,0.8,0.8, $fn=Detailgrad); color("silver") translate([-1.5,-1.25,0]) cube([3,2.5,1.2]);
}
module BT_6030(Name="",Value="",Library="") { color("DarkSlateGray") cylinder(2.1,0.9,0.9, $fn=Detailgrad); color("silver") translate([-2,-1.5,0]) cube([4,3,1.5]);
}
module B3F_10XX(Name="",Value="",Library="") { color("DarkSlateGray") cylinder(4.5,1.75,1.75, $fn=Detailgrad); color("silver") translate([-3,-3,0]) cube([6,6,3.25]);
}
module KMR2() { color("DarkSlateGray") cylinder(2.1,0.9,0.9, $fn=10); color("silver") translate([-2,-1.5,0]) cube([4,3,1.5]);// Button
}
// Switch
module _450301014042(Name="",Value="",Library="") { color("silver") cubepart([10,2.5,5]); color("orange") translate([0,0,5]) cubepart([8.4,2.5,1.4]);}
module 320_938(Name="",Value="",Library="")
{
color("Blue") translate([0,0,2]) cubepart([12,13.5,11]);
color("Silver") translate([0,0,2.1]) cubepart([12.1,10.5,11]);
color("Silver") translate([0,0,2.1+11]) cylinder(9,6.3/2,6.3/2);
color("Silver") translate([0,0,2.1+11]) cylinder(1,8/2,8/2);
color("Silver") translate([0,0,2.1+11+9])
difference()
{
cylinder(12,2.5/2,5/2);
translate([0,-3-1.1,-1]) cubepart([6,6,14]);
translate([0,+3+1.1,-1]) cubepart([6,6,14]);
}
translate([0,0,2]) make_line_of(4.75, 2, center=true) rotate([0,0,90]) make_line_of(4.0, 3, center=true) LOETPIN(height = 5, dim = 0.8);
}
// Quarz SMD
module Q_2X3(Name="",Value="",Library="") {color("silver") cubepart([3.2,2.5,1.2],r=0.25);}
module Q_2X25(Name="",Value="",Library="") {color("silver") cubepart([2.5,2,1.2],r=0.25);}
module Q_7X5(Name="",Value="",Library="") {color("silver") cubepart([7,5,2],r=0.25);}
// QUARZ-THT
module HC_QUARZ(h=4) //X2 CRYSTALS-NOGND-HC49
{
function bogen(point=[0,0], r = 1 ,phase = 0, winkel = 90, $fn=$fn) = [let(num=abs($fn*winkel/360)) for (i=[0:num], x=i*winkel/num) [point[0]+r*cos(x+phase),point[1]+r*sin(x+phase)]];
function winkel(a,b=[0,0]) = atan2(a[1]-b[1],a[0]-b[0]);
if (Detailgrad > 9)
{
color("silver") linear_extrude(1)
//hull(Name="",Value="",Library=""){translate([6.85/2,0,0]) circle(4.65/2,$fn=Detailgrad);translate([-6.85/2,0,0]) circle(4.65/2,$fn=Detailgrad);}
polygon(concat(bogen(point=[6.85/2,0], r=4.65/2 ,phase = winkel([6.85/2,0],[-6.85/2,0])-90, winkel = 180, $fn=Detailgrad), bogen( point=[-6.85/2,0], r=4.65/2 ,phase = winkel([-6.85/2,0],[6.85/2,0])-90, winkel = 180, $fn=Detailgrad)));
color("silver") linear_extrude(h)
// hull(Name="",Value="",Library=""){translate([6.85/2,0,0]) circle(3.5/2,$fn=Detailgrad);translate([-6.85/2,0,0]) circle(3.5/2,$fn=Detailgrad);}
polygon(concat(bogen(point=[6.85/2,0], r=3.5/2 ,phase = winkel([6.85/2,0],[-6.85/2,0])-90, winkel = 180, $fn=Detailgrad), bogen( point=[-6.85/2,0], r=3.5/2 ,phase = winkel([-6.85/2,0],[6.85/2,0])-90, winkel = 180, $fn=Detailgrad)));
//rotate([0,0,270]) linear_extrude(10) translate([-2.159000,-5.207000,0]) square([4.318000,10.414000]); //Board
}
else
color("silver") cubepart([4.65+6.85, 4.65,h]);
}
module QS(Name="",Value="",Library="special") {HC_QUARZ(h = 4);make_line_of(4.88, 2, center=true) LOETPIN(height = 3, dim = 0.6, rnd = true);}
module HC49(Name="",Value="",Library="") {HC_QUARZ(h = 4);make_line_of(4.88, 2, center=true) LOETPIN(height = 3, dim = 0.6, rnd = true);}
module HC49_S(Name="",Value="",Library="") {HC_QUARZ(h = 4);make_line_of(4.88, 2, center=true) LOETPIN(height = 3, dim = 0.6, rnd = true);}
module HC18U_V(Name="",Value="",Library="") {HC_QUARZ(h = 13.5);make_line_of(4.88, 2, center=true) LOETPIN(height = 3, dim = 0.6, rnd = true);}
// Diodes
module 1KAB(Name="",Value="",Library="") {color("DarkSlateGray") translate([0,0,0.1])difference(){translate([0,0,0.1]) cylinder(5,9.5/2,9.5/2, $fn=Detailgrad); translate([8.7,0,0]) cubepart([10,10,6]);}}
module DO15_12E(Name="",Value="",Library="") {color("white") translate([-3,0,2.25]) rotate([0,90,0])cylinder(1,2.1,2.1);
color("DarkSlateGray") translate([-4,0,2.25]) rotate([0,90,0])cylinder(8,2,2);
translate([6.38,0,0]) BendedPIN(1,l2=2);
translate([-6.38,0,0]) rotate([0,0,180]) BendedPIN(1,l2=2);
}
module DO15_12(Name="",Value="",Library="") {DO15_12E(Name="",Value="",Library="") ;}
module DO_214AA(Name="",Value="",Library="") {DIODE(size = [4.6,4,2]); }
module DO_214AC(Name="",Value="",Library="") {DIODE(size = [4.24,2.7,2.6]);}
module DO_220AA(Name="",Value="",Library="") {DIODE(size = [3.5,2,1]); }
module VARTVSP_SMB_DO_214AA_UNI(Name="",Value="",Library="") {DIODE(size = [4.32,3.62,2.4]);}
module SOD_87(Name="",Value="",Library="") {DIODE(size = [3.6,1.778,2]);}
module SOD123(Name="",Value="",Library="") { DIODE(size = [2.8,1.8,2]);}
module PDI123(Name="",Value="",Library="") {
size = [2,3,1];
color("DarkSlateGray") cubepart(size, frustum = 20);
color("white") translate([-size[0]*0.8/2,size[1]/8,0.01]) cube([size[0]*0.8,size[1]/8, size[2]]);
translate([0,+2.6-.275-1.4,0]) color("silver") cubepart([1.25,2.175,0.25]);
translate([0,-1.9+0.275,0]) color("silver") cubepart([1.25,0.775,0.25]);
//rotate([0,0,180]) SMD_IC(size = [2,3,2],pinrows=2,pitch=1.2);
}
module POWER_DI_123(Name="",Value="",Library="") {rotate([0,0,90]) PDI123(Name="",Value="",Library="") ;}
module MELF2(Name="",Value="",Library="") { translate([0,3.6/2,0.75]) // sod-80
rotate([90,0,0])
{
color("Crimson") translate([0,0,0.35]) cylinder(3.6-0.7,0.6,0.6, $fn=Detailgrad);
color("silver")
{
translate([0,0,3.6-0.35]) cylinder(0.35,0.75,0.75, $fn=Detailgrad);
translate([0,0,0]) cylinder(0.35,0.75,0.75, $fn=Detailgrad);
}
color("black") translate([0,0,0.75]) cylinder(0.35,0.65,0.65, $fn=Detailgrad);
}
}
module MELF3(Name="",Value="",Library="") {rotate([0,0,90]) MELF2(Name=Name,Value=Value,Library=Library);}
module MELF1406(Name="",Value="",Library="") {MELF2(Name=Name,Value=Value,Library=Library);}
module SOP65P640X120_14N(Name="",Value="",Library="") {rotate([0,0,270]) SMD_IC([5,4.5,0.6],pinrows=2,pitch=0.65);}
module SOT65P280X100_8N(Name="",Value="",Library="") {rotate([0,0,270]) SMD_IC([2.9,1.7,0.8],pinrows=2,pitch=0.65, pinlength=0.6);}
module SOT65P280X100_8N(Name="",Value="",Library="") {rotate([0,0,270]) SMD_IC([2.9,1.7,0.8],pinrows=2,pitch=0.65, pinlength=0.6);}
module TSOT6(Name="",Value="",Library="") {SMD_IC([2.9,1.6,1.1],pinrows=2,pitch=0.95, pinlength=0.6);}
module SOT95P280X100_6N(Name="",Value="",Library="") {rotate([0,0,270]) SMD_IC([2.9,1.6,1.1],pinrows=2,pitch=0.95, pinlength=0.6, pinheight = 0.50);}
module SOD323_ST(Name="",Value="",Library="") {DIODE([1.8,1.3,1.17]); }
module SOD_323F(Name="",Value="",Library="") {SOD323_ST(Name=Name,Value=Value,Library=Library); }
module SOD110(Name="",Value="",Library="") {DIODE([2,1.27,1.2]); }
module WE_TVS_DFN1610_2L(Name="",Value="",Library="") {DIODE([1.6,1,0.5], pinlength = 0.01); }
module SMC(Name="",Value="",Library="") {DIODE(size = [7,6,2.6]);} //
module DO_214AB(Name="",Value="",Library="") {SMC(Name=Name,Value=Value,Library=Library);}
module SMB(Name="",Value="",Library="") {DO_214AA(Name=Name,Value=Value,Library=Library);}
module SOP65P600X115_15N_V(Name="",Value="",Library="") //U?1 726-BTS72002EPAXUMA1
{
rotate([0,0,270]) SMD_IC([4.9,3.9,1],pinrows=2,pitch=0.65, pinlength=1.05);
}
module SOP4(Name="",Value="",Library="") { SMD_IC([3.85,4.4,2],pinrows=2,pitch=2.54, pinwidth = 0.4, pinlength=1.3, pinheight = 1, phase = -1);
}
module POWERPAK_1212_8(Name="",Value="",Library="microbuilder") // DFN 3x3_EP
{
SMD_IC([3.05,3.05,0.85],pinrows=2,pitch=0.65, pinlength=0.125);
color("Silver")cubepart([3.4,0.3,0.25]);
}
module POWERDI3333(Name="",Value="",Library="microbuilder") // DFN 3x3_EP
{
rotate([0,0,-90])
{
SMD_IC([3.15,3.10,0.9],pinrows=2,pitch=0.65, pinlength=0.15);
color("Silver")cubepart([3.4,0.3,0.25]);
}
}
module TO_277A(Name="",Value="",Library="") { SMD_FN(size = [4.35,6.15,0.9],pinrows=2,pitch=2.13, pinheight = 0.4); }
module 7PIN_PFM(Name="",Value="",Library="") { translate([7,0,0]) rotate([0,0,-90]) SMD_IC([10.8,10.8,2.5],pinrows=1,pitch=1.27,phase=1); }
module DPAK(Name="",Value="",Library="")
{
SMD_IC([6.4,6,2.5]);
SMD_PIN(size=[6.4,6,2.5], pinnumber = 1, pitch=2.159, pinlength=2.7, pinwidth = 0.7 );
SMD_PIN(size=[6.4,6,2.5], pinnumber = 2, pitch=2.159, pinlength=0.6, pinwidth = 0.7 );
SMD_PIN(size=[6.4,6,2.5], pinnumber = 3, pitch=2.159, pinlength=2.7, pinwidth = 0.7 );
rotate([0,0,180]) SMD_PIN(size=[6,6,2.5], pinnumber = 1, pitch=10, pinlength=0.65, pinheight = 1 );
}
module TO252_5_11(Name="",Value="",Library="") {SMD_IC([6,6,2.5],pinrows=1,pitch=1.125, pinlength=2.5);
color("silver") translate([0,2.5,0]) cubepart([5.5,2,1]); }
module TO263_5(Name="",Value="",Library="") { translate([0,2,0]) SMD_IC([10.2,9.25,4.4],pinrows=1,pitch=1.7, pinlength=4.0);
color("silver") translate([0,6.5,0]) cubepart([10,2,1]); }
module SO235LAU(Name="",Value="",Library="") {SOT_23_5(Name=Name,Value=Value,Library=Library);}
module SO235LOS(Name="",Value="",Library="") {SOT_23_5(Name=Name,Value=Value,Library=Library);}
module SO235LOR(Name="",Value="",Library="") {SOT_23_5(Name=Name,Value=Value,Library=Library);}
module SOT95P280X145_5N(Name="",Value="",Library="") {rotate([0,0,-90]) SOT_23_5(Name=Name,Value=Value,Library=Library);}
module SC70(Name="",Value="",Library="") {color("DarkSlateGray") cubepart([2,1.25,1]);
rotate([0,0,180]) SMD_PIN(size=[2,1.25,1], pinnumber = 1, pitch=0.65, pinlength=0.6 );
rotate([0,0,180]) SMD_PIN(size=[2,1.25,1], pinnumber = 3, pitch=0.65, pinlength=0.6 );
SMD_PIN(size=[2,1.25,1], pinnumber = 1, pitch=0.65, pinlength=0.6 );
SMD_PIN(size=[2,1.25,1], pinnumber = 3, pitch=0.65, pinlength=0.6 );
SMD_PIN(size=[2,1.25,1], pinnumber = 2, pitch=0.65, pinlength=0.6 );
}
module SC70_5(Name="",Value="",Library="") {SC70(Name=Name,Value=Value,Library=Library);}
module SOT23_6L(Name="",Value="",Library="") {SMD_IC(size = [3,1.5,1],pinrows=2,pitch=1,pinlength=0.6, pinheight = 0.5);}
module SOT65P210X110_5N(Name="",Value="",Library="") {SOT23_6L(Name=Name,Value=Value,Library=Library);}
module SOT23_6(Name="",Value="",Library=""){SOT23_6L(Name=Name,Value=Value,Library=Library);}
module SOT23_8(Name="",Value="",Library="") {SMD_IC(size = [2.9,1.7,1.4],pinrows=2,pitch=0.65,pinlength=0.6, pinheight = 0.5);}
module SOT95P280X145_6N(Name="",Value="",Library="") {rotate([0,0,-90]){SMD_IC(size = [3,1.5,1],pinrows=2,pitch=1,pinlength=0.6);}}
module SOT_23_5(Name="",Value="",Library="") {SOT_23(Name="",Value="",Library=""); // SC_74A
SMD_PIN(size=[3,1.5,1], pinnumber = 1, pitch=0.9, pinlength=0.60, pinheight = 0.5 );
SMD_PIN(size=[3,1.5,1], pinnumber = 3, pitch=0.9, pinlength=0.60, pinheight = 0.5 );}
module SC_74(Name="",Value="",Library="") {SOT23_6L(Name=Name,Value=Value,Library=Library);}
module SOT95P270X145_5N(Name="",Value="",Library="") {rotate([0,0,90]) SOT_23_5(Name=Name,Value=Value,Library=Library);}
module WE_TVS_SOT23_3L(Name="",Value="",Library="") {rotate([0,0,180]) SOT_23(Name=Name,Value=Value,Library=Library);}
module SOT23(Name="",Value="",Library="") {SOT_23(Name=Name,Value=Value,Library=Library);}
module SOT95P240X120_3N(Name="",Value="",Library="") {rotate([0,0,90]) SOT_23(Name=Name,Value=Value,Library=Library);}
module SOT95P237X112_3N(Name="",Value="",Library="") {rotate([0,0,180]) SOT_23(Name=Name,Value=Value,Library=Library);}
module SOT_23(Name="",Value="",Library="") {
Rotation = (Library == "diode")?[0,0,180]:[0,0,0];
rotate(Rotation){
color("DarkSlateGray") cubepart([3,1.5,1]);
rotate([0,0,180]) SMD_PIN(size=[3,1.5,1], pinnumber = 1, pitch=0.9, pinlength=0.60, pinheight = 0.5 );
rotate([0,0,180]) SMD_PIN(size=[3,1.5,1], pinnumber = 3, pitch=0.9, pinlength=0.60, pinheight = 0.5 );
SMD_PIN(size=[3,1.5,1], pinnumber = 2, pitch=0.9, pinlength=0.60, pinheight = 0.5 );
}
}
module SOT_363(Name="",Value="",Library="") { SMD_IC(size = [2.2,1.35,1],pinrows=2, pinheight = 0.40, pinlength = 0.4, pinwidth = 0.3, pitch=0.65); }
module SOT353(Name="",Value="",Library="")
{
dim = [2,1.25,1];
rotate([0,0,180]){
color("DarkSlateGray") cubepart(dim);
rotate([0,0,180]) SMD_PIN(size=dim, pinnumber = 1, pitch=0.65, pinlength=0.425, pinheight = 0.4 );
rotate([0,0,180]) SMD_PIN(size=dim, pinnumber = 2, pitch=0.65, pinlength=0.425, pinheight = 0.4 );
rotate([0,0,180]) SMD_PIN(size=dim, pinnumber = 3, pitch=0.65, pinlength=0.425, pinheight = 0.4 );
SMD_PIN(size=dim, pinnumber = 1, pitch=0.65, pinlength=0.425, pinheight = 0.4 );
SMD_PIN(size=dim, pinnumber = 3, pitch=0.65, pinlength=0.425, pinheight = 0.4 );
}
}
module SOT143_4(Name="",Value="",Library="") {SMD_IC(size = [3,1.4,1],pinrows=2,pitch=1.72, pinlength = 0.45);}
module SOT223(Name="",Value="",Library="") {if (Library == "MySMD") translate([2.3,3,0]) SOT_223(); else SOT_223();}
module SOT_223(Name="",Value="",Library="") {SMD_IC(size = [6.25,3.45,1.5],pinrows=1,pitch=2);
//color("silver") translate([0,2.5,0]) cubepart([3,2,1]);
rotate([0,0,180]) SMD_PIN(size=[6.25,3.45,1.5], pinnumber = 1, pitch=6, pinlength=2, pinheight = 1 );}
module SOT223R_INFINEON(Name="",Value="",Library="") {SOT_223(Name=Name,Value=Value,Library=Library);}
module SOD_89(Name="",Value="",Library="") {translate([0,1.3,0]) SOT_89(Name=Name,Value=Value,Library=Library);}
module SOT_89(Name="",Value="",Library="") {translate([0,1,0]) {SMD_IC(size = [4.5,2.5,1.5],pinrows=1,pitch=1.5, pinlength=1, pinheight = 0.4 ,pinwidth = 0.5, frustum = 10 , Pinsbended = false);
rotate([0,0,180]) SMD_PIN(size=[4.5,2.5,1.5], pinnumber = 1, pitch=4, pinlength=0.6, pinheight = 0.4, bended = false );}}
// Eigentlich SOT-89. SOD-89 ist eine Diode
//module SOT_89(Name="",Value="",Library="") {translate([0,1,0]){SMD_IC(size = [4.5,2.5,1.5],pinrows=1,pitch=1.5,pinlength=1, pinwidth = 0.5, frustum=15); color("silver") translate([0,1.5,0]) cubepart([1.6,0.5,0.4]);}}
module SOD_223_(Name="",Value="",Library="") {SOT_223(Name=Name,Value=Value,Library=Library);}
module OK6(Name="",Value="",Library="") {SMD_IC(size = [3.6,4.4,2.5],pinrows=2,pitch=2.54, pinwidth = 0.4, phase = -1);}
module SO_8(Name="",Value="",Library="") {translate([0.635,0,0]) SO08(Name="",Value="",Library=""); }
module SO8(Name="",Value="",Library="") {if (Library == "linear") translate([0,0.25,0]) SO08(Name="",Value="",Library=""); else if (Library != "analog-devices") translate([0.635,0,0]) SO08(Name="",Value="",Library=""); else SO08(Name="",Value="",Library=""); }
module SOIC08(Name="",Value="",Library="") { SO08(Name="",Value="",Library=""); }
module SOIC8(Name="",Value="",Library="") { SO08(Name="",Value="",Library=""); }
module 8S2(Name="",Value="",Library="") { SMD_IC(size = [5.3,5.3,2],pinrows=2,pinwidth = 0.4, pitch=1.27); } // atmel.lbr
module SOIC8W(Name="",Value="",Library="") { 8S2(Name="",Value="",Library=""); }
module R_PDSO_G8(Name="",Value="",Library="") {SO08(Name=Name,Value=Value,Library=Library);}
module SO08(Name="",Value="",Library="") {SMD_IC(size = [5,4,1.4],pinrows=2,pitch=1.27);}
module HSOIC_8(Name="",Value="",Library="") {SMD_IC(size = [5,4,1.7],pinrows=2,pitch=1.27);}
module SOIC127P600X175_8N(Name="",Value="",Library="") {rotate([0,0,270]){SMD_IC(size = [5,4,1.7],pinrows=2,pitch=1.27);}}
module SOIC127P1030X265_20N(Name="",Value="",Library="") {rotate ([0,0,270]){SMD_IC(size = [13.5,7.5,1.7],pinrows=2,pitch=1.27);}}
module SO_16(Name="",Value="",Library="") {translate([0.635,0,0]) SMD_IC(size = [10.6,4,1.4],pinrows=2,pitch=1.27);}
module SO_16L(Name="",Value="",Library="") {translate([0.635,0,0]) SMD_IC(size = [11.5,7.6,2.6],pinrows=2,pitch=1.27);}
module SO16L(Name="",Value="",Library=""){translate([-0.635,0.86,0]) SMD_IC(size = [11.5,7.6,2.6],pinrows=2,pitch=1.27);}
module SO14(Name="",Value="",Library="") {SO_14(Name=Name,Value=Value,Library=Library);}
module SO16(Name="",Value="",Library="") { if (Library=="74xx-eu" || Library=="74xxsmd") {translate([-1.27/2,0,0]) SO_16(Name=Name,Value=Value,Library=Library);} else SO_16(Name=Name,Value=Value,Library=Library);}
module SO_14(Name="",Value="",Library="") {translate([0,0,0]) SMD_IC(size = [9.3,4,1.4],pinrows=2,pitch=1.27);}
module SO24L(Name="",Value="",Library="") {translate([-1.27/2,0,0]) SMD_IC(size = [15.6,7.6,2.65],pinrows=2,pitch=1.27, phase = -1);}
module SO_28L(Name="",Value="",Library="") {translate([+1.27/2,0,0]) SMD_IC(size = [18.14,7.6,2.65],pinrows=2,pitch=1.27, phase = -1);}
module PDSO6(Name="",Value="",Library="") {SMD_FN(size = [2.1,2.1,0.65],pinrows=2,pitch=0.65);}
module VO20(Name="",Value="",Library="") {SMD_IC([7,4.5,0.7],pinrows=2,pitch=0.65);}
module MSOP8(Name="",Value="",Library="") {SMD_IC([3,2.9,0.7],pinrows=2,pitch=0.7);}
module SSOP8(Name="",Value="",Library="") {SMD_IC([3,3,1],pinrows=2,pitch=0.65, pinlength=0.55,pinheight=0.5);}
module TSSOP8(Name="",Value="",Library="") {SMD_IC([3,2.9,0.7],pinrows=2,pitch=0.65, pinlength=0.55,pinheight=0.5);}
module VSSOP8(Name="",Value="",Library="") {SMD_IC([2,2.4,0.7],pinrows=2,pitch=0.5, pinlength=0.45,pinheight=0.4);} // Prototyp
module SOT_5X3(Name="",Value="",Library="") {SMD_IC([2.2,1.3,0.6],pinrows=2,pitch=0.5, pinlength=0.3,pinheight=0.2,frustum = 10, Pinsbended = false);}
module SSOP20_DBQ(Name="",Value="",Library="") {SMD_IC([7.200,5.000,1.75],pinrows=2,pitch=0.635);}
module SSOP28(Name="",Value="",Library="") { if (Library == "MySMD2") translate([4.23,3.5,0]) SMD_IC([10.200,5.200,2],pinrows=2,pitch=0.65);
else SMD_IC([10.200,5.200,2],pinrows=2,pitch=0.65);}
module SOP50P310X90_8N(Name="",Value="",Library="") {rotate([0,0,270]){SMD_IC([2.2,2.4,0.7],pinrows=2,pitch=0.7);}}
module WSON(Name="",Value="",Library="") {rotate([0,0,270]) SMD_FN(size = [3,2,0.8],pinrows=2,pitch=0.5);}
module SON50P250X250X80_11N(Name="",Value="",Library="") {rotate([0,0,270]) SMD_FN(size = [3,2,0.8],pinrows=2,pitch=0.5);}
module MSOP10(Name="",Value="",Library="") {SMD_IC([3,3,1.1],pinrows=2,pitch=0.5);}
module TSSOP5(Name="",Value="",Library="") {SOT_23(Name="",Value="",Library="");
SMD_PIN(size=[3,1.5,1], pinnumber = 1, pitch=0.9, pinlength=0.6 );
SMD_PIN(size=[3,1.5,1], pinnumber = 3, pitch=0.9, pinlength=0.6 );}
module TSSOP14(Name="",Value="",Library="") {SMD_IC([5,4.4,0.6],pinrows=2,pitch=0.65);}
module TSSOP16(Name="",Value="",Library="") {SMD_IC([5.5,4.4,0.6],pinrows=2,pitch=0.65);}
module QSOP16(Name="",Value="",Library="") {translate([0.635/2,0,0]) SMD_IC([5.5,4.4,0.6],pinrows=2,pitch=0.635);} // SSOP
module TSSOP20(Name="",Value="",Library="74xx-eu") {translate([-0.65/2,0,0]) SMD_IC([6.9,4.4,0.6],pinrows=2,pitch=0.65);
}
module PQFP44(Name="",Value="",Library="") {rotate([0,0,-90]) SMD_IC(size = [10,10,1.6],pinrows=4,pitch=0.8);}
module VQ100(Name="",Value="",Library="") {rotate([0,0,-90]) SMD_IC(size = [14,14,1.2],pinrows=4,pitch=0.5);}
module VQ44(Name="",Value="",Library="") {SMD_IC(size = [10,10,1.2],pinrows=4,pitch=0.8);}
module LQFP64(Name="",Value="",Library="") {rotate([0,0,-90]) SMD_IC(size = [10,10,1.4],pinrows=4,pitch=0.5,phase=1);}
module TQFP64(Name="",Value="",Library="") {LQFP64(Name=Name,Value=Value,Library=Library);}
module LQFP100(Name="",Value="",Library="") {rotate([0,0,-90]) SMD_IC(size = [13.8,13.8,1.4],pinrows=4,pitch=0.5);}
module TQ144(Name="",Value="",Library="") {rotate([0,0,-90]) SMD_IC(size = [20,20,1.4],pinrows=4,pitch=0.5);}
module PQ208(Name="",Value="",Library="") {rotate([0,0,-90]) SMD_IC(size = [28.9,28.9,2.4],pinrows=4,pitch=0.5);}
module QFP_80(Name="",Value="",Library="") {rotate([0,0,-90]) SMD_IC(size = [14.2,14.2,2],pinrows=4,pitch=0.65);}
module QFN28(Name="",Value="",Library="") {SMD_FN(size = [5,5,0.8],pinrows=4,pitch=0.5, phase=1);}
module QFN_138(Name="",Value="",Library="") {SMD_FN(size = [12,12,0.8],pinrows=0,pitch=0.5, phase=1);}
module QFN32(Name="",Value="",Library="") {if (Library == "atmel") rotate([0,0,-90]) SMD_IC(size = [5,5,1]); else SMD_IC(size = [5,5,1]);}
module TQFN32(Name="",Value="",Library="") {SMD_IC(size = [5,5,1]);}
module TQFN24(Name="",Value="",Library="") {SMD_FN(size = [4,4,0.8],pinrows=4,pitch=0.5, phase = 0.5 );}
module PVQFN48(Name="",Value="",Library="") {rotate([0,0,-90]) SMD_FN(size = [6.9,6.9,1],pinrows=4,pitch=0.5);}
module ESP32_PICO_D4_1 (Name="",Value="",Library="") {rotate([0,0,-90]) SMD_FN(size = [6.9,6.9,1],pinrows=4,pitch=0.5);}
module 21_0139I_T2444_4(Name="",Value="",Library="") {rotate([0,0,270]) TQFN24(Name=Name,Value=Value,Library=Library);} // MAXIM
module QFN24(Name="",Value="",Library="") {rotate([0,0,-90]) SMD_FN(size = [4,4,1],pinrows=4,pitch=0.5,phase = 0.4);}
module QFN65P500X500X80_21N(Name="",Value="",Library="") {rotate([0,0,-90]) SMD_FN(size = [5,5,1],pinrows=4,pitch=0.7,phase = 1);}
module DFN14(Name="",Value="",Library="") {SMD_FN(size = [4,3,0.8],pinrows=2,pitch=0.5);}
module QFN_172(Name="",Value="",Library="") {rotate([0,0,90]) SMD_FN(size = [13,13,0.9],pinrows=4,pitch=0.5, phase = 0.7);}
module VFQFPN36(Name="",Value="",Library="") {SMD_FN(size = [6,6,0.9],pinrows=4,pitch=0.5);}
module DFN_3030_10(Name="",Value="",Library="") {SMD_FN(size = [3,3,0.75],pinrows=2,pitch=0.5);}
module DFN6(Name="",Value="",Library="HAutomation_6") {difference() {SMD_FN(size = [3,3,0.9],pinrows=2,pitch=1); translate([0.7,0,0.5]) cubepart([0.7,2.0,1]);}}
module DFN8_3X3(Name="",Value="",Library="") {SMD_FN(size = [3,3,0.9],pinrows=2,pitch=0.65);}
module DD10_3X3(Name="",Value="",Library="") {SMD_FN(size = [3,3,0.9],pinrows=2,pitch=0.5);}
module QFN38_5X7(Name="",Value="",Library="") {rotate([0,0,-90]) SMD_FN(size = [7,5,0.75],pinrows=4,pitch=0.5,phase = 0.2);}
module QFN28_ML_6X6MM(Name="",Value="",Library="") {rotate([0,0,-90]) SMD_FN(size = [5.9,5.9,0.75],pinrows=4,pitch=0.65,phase = 0.5);}
module 2L10_SU72(Name="",Value="",Library="") {rotate([0,0,-90]) SMD_FN(size = [20.32,20.32,1.83],pinrows=2,pitch=2.54);}
module VSONP_8(Name="",Value="",Library="") { rotate([0,0,-90]) SMD_FN(size = [3.22,3,0.9],pinrows=2,pitch=0.65);}
module MLF32(Name="",Value="",Library="") { rotate([0,0,-90]) SMD_FN(size = [5,5,0.9],pinrows=4,pitch=0.5,phase = 0.6);}
module POWERSO2(Name="",Value="",Library=""){translate([0,1.7,0]) SMD_IC([15.8,11.5,2.8],pinrows=2,pitch=1.27);}
module MB2S(Name="",Value="",Library=""){SMD_IC([5.5,4,2.8],pinrows=2,pitch=2.54,phase = 1);}
module TO220_2S(Name="",Value="",Library="") {rotate([0,0,180]) TO220_PARAM(n=2);}
module TO220(Name="",Value="",Library="") {translate([0,-3.54,0]) rotate([0,0,180]) TO220_PARAM(n=3);}
module 78XXL(Name="",Value="",Library="") {translate([0,-1,0]) rotate([0,0,180]) TO220_PARAM(n=3);}
module TO220BH(Name="",Value="",Library="") {translate([0,-6.35,0]) rotate([0,0,180]) TO220L_PARAM(n=3);}
module 78LXX(Name="",Value="",Library="") {TO92(Name=Name,Value=Value,Library=Library);}
module TO92(Name="",Value="",Library="") {translate([0,0,4]) color("DarkSlateGray") intersection(Name="",Value="",Library="") {
cylinder (h = 4.6, r=4.6/2, center = true, $fn=Detailgrad);
rotate([90,0,0]) translate([0,0,-3]) linear_extrude(4, scale=0.9) square(4.6, center = true);}
translate([-1.28,0,3.6]) LOETPIN(dim = 0.4, displacement=0.3);
translate([1.28,0,3.6]) LOETPIN(dim = 0.4, displacement=-0.3);
translate([0,1.90,3.6]) rotate([0,0,90]) LOETPIN(dim = 0.4, displacement=-0.8);
}
module E2LINE(Name="",Value="",Library="") {translate([0,0,2]) rotate([0,0,90])ELINE_THT(2);}
module E3LINE(Name="",Value="",Library="") {translate([0,0,3]) ELINE_THT(3);}
module ELINE_THT(N = 3)
{
r=1;
num = round(Detailgrad/4);
size = [2.2,0.4,4.2];
function bogen(point=[0,0],aPhase = 0) = [for (i=[0:num], x=i*90/num) [point[0]+r*sin(x+aPhase),point[1]+r*cos(x+aPhase)]];
function poli_round() = concat(bogen([0,0],180),[[0-r,size[1]+r]],[[size[0]+r,size[1]+r]],bogen([size[0],0],90));
if (N==2)
{
color("DarkSlateGray") translate([-size[0]/2,-size[1]/2,0]) linear_extrude(size[2]) polygon(poli_round());
translate([-1.27,0,0]) LOETPIN(dim = 0.4);
translate([1.27,0,0]) LOETPIN(dim = 0.4);
}
else
rotate([0,0,45]){
color("DarkSlateGray") translate([-size[0]/2,-size[1]/2,0]) linear_extrude(size[2]) polygon(poli_round());
translate([0,0,1.2]) LOETPIN(dim = 0.4);
translate([1.27,1.27,1.2]) rotate([0,0,90]) LOETPIN(dim = 0.4, displacement=-1.27);
translate([-1.27,-1.27,1.2]) rotate([0,0,-90]) LOETPIN(dim = 0.4, displacement=-1.27);
}
}
// IR-Empfänger
module TSOP38(Name="",Value="",Library="") { translate([0,0,3]) color("DarkSlateGray") { cubepart([5,2.8,6.95]); translate([0,-1,4]) sphere(2); translate([0,-1,0]) cylinder(4,2,2);} }
module EE_SX1131(Name="",Value="",Library="") {
SMD_FN(size = [4,5,1.2],pinrows=2,pitch=1.4);
difference()
{
color("DarkSlateGray") translate([0,1.75,0]) cubepart(size = [4,1.5,4]);
color("DarkSlateGray") translate([0.55,1.725,2.5]) cubepart(size = [0.3,1.6,1]);
color("DarkSlateGray") translate([-0.55,1.725,2.5]) cubepart(size = [0.3,1.6,1]);
}
difference()
{
color("DarkSlateGray") translate([0,-1.75,0]) cubepart(size = [4,1.5,4]);
color("DarkSlateGray") translate([-0.55,-1.725,2.5]) cubepart(size = [0.3,1.6,1]);
color("DarkSlateGray") translate([0.55,-1.725,2.5]) cubepart(size = [0.3,1.6,1]);
}
}
module ESP_12(Name="",Value="",Library=""){ // Eagle Adafruit
board_thicknessA = 1.000000;
eta = 0.2;
rotate([0,0,90]) translate([-12.065+1,-8.09625,0]) union(){ // PCB whith parts and text
color("DarkSlateGray")linear_extrude(height=board_thicknessA,center=false, convexity=10)
polygon(points = [[0,16.192500],[24.13,16.1925],[24.13,0],[0,0]]); //Board
color("Goldenrod",0.7) translate([0,0,board_thicknessA-0.017]) linear_extrude(height=0.035,center=false, convexity=10) difference() {
union() {
translate([17.463,3.004]) rotate([0,0,270.000]) square([1.092,1.397], center = true); //LED0805 A
translate([17.463,1.124]) rotate([0,0,270.000]) square([1.092,1.397], center = true); //LED0805 K
translate([1.558,1.318])square([1.270,2.540], center = true); //SMD1,27-2,54 1
translate([3.558,1.318])square([1.270,2.540], center = true); //SMD1,27-2,54 1
translate([5.558,1.318])square([1.270,2.540], center = true); //SMD1,27-2,54 1
translate([7.558,1.318])square([1.270,2.540], center = true); //SMD1,27-2,54 1
translate([9.558,1.318])square([1.270,2.540], center = true); //SMD1,27-2,54 1
translate([11.558,1.318])square([1.270,2.540], center = true); //SMD1,27-2,54 1
translate([13.558,1.318])square([1.270,2.540], center = true); //SMD1,27-2,54 1
translate([15.558,1.318])square([1.270,2.540], center = true); //SMD1,27-2,54 1
translate([15.558,14.953])square([1.270,2.540], center = true); //SMD1,27-2,54 1
translate([13.558,14.953])square([1.270,2.540], center = true); //SMD1,27-2,54 1
translate([11.558,14.953])square([1.270,2.540], center = true); //SMD1,27-2,54 1
translate([9.558,14.953])square([1.270,2.540], center = true); //SMD1,27-2,54 1
translate([7.558,14.953])square([1.270,2.540], center = true); //SMD1,27-2,54 1
translate([5.558,14.953])square([1.270,2.540], center = true); //SMD1,27-2,54 1
translate([3.558,14.953])square([1.270,2.540], center = true); //SMD1,27-2,54 1
translate([1.558,14.953])square([1.270,2.540], center = true); //SMD1,27-2,54 1
EagleWire([18.891,0.635],[23.336,0.635],width=0.610,$fn=8);
EagleWire([23.336,0.635],[23.336,3.334],width=0.610,$fn=8);
EagleWire([23.336,3.334],[20.320,3.334],width=0.610,$fn=8);
EagleWire([20.320,3.334],[20.320,6.033],width=0.610,$fn=8);
EagleWire([20.320,6.033],[23.336,6.033],width=0.610,$fn=8);
EagleWire([23.336,6.033],[23.336,8.731],width=0.610,$fn=8);
EagleWire([23.336,8.731],[20.320,8.731],width=0.610,$fn=8);
EagleWire([20.320,8.731],[20.320,11.430],width=0.610,$fn=8);
EagleWire([20.320,11.430],[23.336,11.430],width=0.610,$fn=8);
EagleWire([23.336,11.430],[23.336,13.494],width=0.610,$fn=8);
EagleWire([23.336,13.494],[23.336,15.558],width=0.610,$fn=8);
EagleWire([23.336,15.558],[18.574,15.558],width=0.610,$fn=8);
EagleWire([23.336,13.494],[18.574,13.494],width=0.610,$fn=8);
translate([1.510,15.000]) circle(r=0.453,$fn=fn);
translate([3.510,15.000]) circle(r=0.453,$fn=fn);
translate([5.510,15.000]) circle(r=0.453,$fn=fn);
translate([7.510,15.000]) circle(r=0.453,$fn=fn);
translate([9.510,15.000]) circle(r=0.453,$fn=fn);
translate([11.510,15.000]) circle(r=0.453,$fn=fn);
translate([13.510,15.000]) circle(r=0.453,$fn=fn);
translate([15.510,15.000]) circle(r=0.453,$fn=fn);
translate([1.525,1.143]) circle(r=0.453,$fn=fn);
translate([3.525,1.143]) circle(r=0.453,$fn=fn);
translate([5.525,1.143]) circle(r=0.453,$fn=fn);
translate([7.525,1.143]) circle(r=0.453,$fn=fn);
translate([9.525,1.143]) circle(r=0.453,$fn=fn);
translate([11.525,1.143]) circle(r=0.453,$fn=fn);
translate([13.525,1.143]) circle(r=0.453,$fn=fn);
translate([15.525,1.143]) circle(r=0.453,$fn=fn);
}
}
color("Goldenrod",0.7) translate([0,0,-0.017]) linear_extrude(height=0.035,center=false, convexity=10) difference() {
union() {
translate([1.510,15.000]) circle(r=0.453,$fn=fn);
translate([3.510,15.000]) circle(r=0.453,$fn=fn);
translate([5.510,15.000]) circle(r=0.453,$fn=fn);
translate([7.510,15.000]) circle(r=0.453,$fn=fn);
translate([9.510,15.000]) circle(r=0.453,$fn=fn);
translate([11.510,15.000]) circle(r=0.453,$fn=fn);
translate([13.510,15.000]) circle(r=0.453,$fn=fn);
translate([15.510,15.000]) circle(r=0.453,$fn=fn);
translate([1.525,1.143]) circle(r=0.453,$fn=fn);
translate([3.525,1.143]) circle(r=0.453,$fn=fn);
translate([5.525,1.143]) circle(r=0.453,$fn=fn);
translate([7.525,1.143]) circle(r=0.453,$fn=fn);
translate([9.525,1.143]) circle(r=0.453,$fn=fn);
translate([11.525,1.143]) circle(r=0.453,$fn=fn);
translate([13.525,1.143]) circle(r=0.453,$fn=fn);
translate([15.525,1.143]) circle(r=0.453,$fn=fn);
}
}
union(){ // parts
translate([8.731,8.096,board_thicknessA])rotate([0,0,90])SHIELD12X15(); //CA1 SHIELD12X15
translate([17.463,2.064,board_thicknessA])rotate([0,0,270])LED0805(); //LED1 LED0805
}
} //endunion()
module SHIELD12X15() //CA1 SHIELD12X15
{
rotate([0,0,270])
{
color ("silver")
linear_extrude(2.3) translate([-7.500000,-6.000000,0]) square([ 15.000000,12.000000]); //Board
}
}
module LED0805(Enable = false)
{
rotate([0,0,90])
{
color("gray") translate([0,0,0.125/2]) cube([1.2,2,0.125], center = true);
if (!Enable)
{
color("green") linear_extrude(0.65,scale = 0.9) square([1.2,1.8],center = true);
}
else
{
color("lightgreen") linear_extrude(0.65,scale = 0.9) square([1.2,1.8],center = true);
}
}
}
} // end ESP12
module FSMD(Name="",Value="",Library="") {
difference()
{
union()
{
color("DarkSlateGray") cubepart(size = [12,5.2,6]);
color("silver") cubepart(size = [11,2.2,6.1]);
}
color("DarkSlateGray") union()
{
translate([0,0,1]) cubepart(size = [9,4,6]);
translate([0,0,2]) cubepart(size = [3,6,6]);
}
}
color("Beige") cubepart(size = [8,3.5,5]);
}
module FSMD185(Name="",Value="",Library="") {color("silver") cubepart(size = [9.5,6.71,3]);}
//Microfone
module ELECTRET_9_7(Name="",Value="",Library="")
{
color("silver") translate([0,0,0.4]) cylinder(4.5,9.7/2,9.7/2);
color("DarkSlateGray") cylinder(5.2,7.6/2,7.6/2);
translate([-1.25,2,0.0]) make_line_of(2.5, 2) LOETPIN(height = 2, dim=0.4);
}
// IR EMpfänger
// CHQ1838, VS1838B, TL1838
module VS1838B_H(Name="",Value="",Library="")
{
color("silver") translate([-14.097,-3.556,0]) cube([7.747,7.112, 3.6]);
translate([-14.097+7.7,0,5.2-2.3]) rotate([0,-90,0])
union()
{
color("silver") cylinder(2,4.6/2,4.6/2);
translate([0,0,2]) color("DarkSlateGray") cylinder(4.6/2,4.6/2,4.6/2);
translate([0,0,2+4.6/2]) color("DarkSlateGray") sphere(4.6/2);
}
}
//Display
//OLED
module UG_2832HSWEG02_WRAPUNDER(Name="",Value="",Library="") //LCD1
{
color("DarkSlateGray") linear_extrude(1.45) translate([-30,-11.5/2,0]) square([30,11.5]); //Crystal
color("Black") translate([-30.000000+2.1,-2.1,0.01]) linear_extrude(1.45) square([22.384,5.584]); //FOV
color("White")
{ translate([-30.000000+2.1+0.1,-2.1+4.2,0.02]) linear_extrude(1.45) text("UG-2832HSWEG02",size = 1.2);
translate([-30.000000+2.1+0.1,-2.1+1.6,0.02]) linear_extrude(1.45) text("128x32 dot",size = 1.2);
translate([-30.000000+2.1+0.1,-2.1+0.1,0.02]) linear_extrude(1.45) text("21x4 char",size = 1.2);
}
}
module TEST_POINT_1MM(Name="",Value="",Library="")
{
function bogen(point=[0,0], r = 1 ,phase = 0, winkel = 90, $fn=$fn) = [let(num=abs($fn*winkel/360)) for (i=[0:num], x=i*winkel/num) [point[0]+r*cos(x+phase),point[1]+r*sin(x+phase)]];
function winkel(a,b=[0,0]) = atan2(a[1]-b[1],a[0]-b[0]);
if (Detailgrad > 15)
{
LOETPIN(height = 4);
color("silver") rotate([0,270,90]) translate([0,0,-0.4]) linear_extrude(0.8)
{
difference()
{
polygon(concat(bogen(point=[1,0], r=2.3/2 ,phase = winkel([1,0],[4.5,0])-90, winkel = 180, $fn=Detailgrad), bogen( point=[4.5,0], r=2.3/2 ,phase = winkel([4.5,0],[1,0])-90, winkel = 180, $fn=Detailgrad)));
polygon(concat(bogen(point=[1,0], r=1.8/2 ,phase = winkel([1,0],[4.5,0])-90, winkel = 180, $fn=Detailgrad), bogen( point=[4.5,0], r=1.8/2 ,phase = winkel([4.5,0],[1,0])-90, winkel = 180, $fn=Detailgrad)));
};
// hull(Name="",Value="",Library="") { translate([1,0]) circle(2.3/2, $fn=Detailgrad); translate([4.5,0]) circle(2.3/2, $fn=Detailgrad); }
// hull(Name="",Value="",Library="") { translate([1,0]) circle(1.8/2, $fn=Detailgrad); translate([4.5,0]) circle(1.8/2, $fn=Detailgrad); }
}
}
else
{
color("silver") cubepart([2,1,5.5]);
}
}
// Lichtschranke
module KRA011(Name="",Value="",Library="") //LS1
{
difference()
{
color("DarkSlateGray") cubepart(size = [5,4.2,5.2]);
color("DarkSlateGray") translate([-1,-2.5,2.4]) cube([2,5,2.81]);
color("white") translate([-1.05,-0.2,5.2-0.6-0.8]) cube([2.1,0.4,1.2]);
color("DarkSlateGray") translate([-3,0,7.3-0.5]) rotate([-45,0,0]) cube([6,5,3]);
}
translate([-2,1.25,0]) make_line_of(4, 2) LOETPIN(height = 5, dim = 0.5);translate([-2,-1.25,0])make_line_of(4, 2) LOETPIN(height = 5, dim = 0.5);
}
module DIL08S(Name="",Value="",Library="")
{color("silver") translate([0,0,0.5]) {cubepart(size = [12.8,12.8,0.8]);cubepart(size = [12.1,12.1,5.08],r = 1.5); translate([-3.81,3.81,0]) make_line_of(7.62, 2) LOETPIN(height = 6.35);translate([-3.81,-3.81,0])make_line_of(7.62, 2) LOETPIN(height = 6.35);}}
module Q_5X3(Name="",Value="",Library="") {color("silver") cubepart(size = [5.15,3.35,1]);}
module InvisiblePart()
{
rotate([0,0,0]) ;
}
module SCHRIFTF(Name="",Value="",Library="") {InvisiblePart();} // Ausblenden
module SCHRIFTA(Name="",Value="",Library="") {InvisiblePart();} // Ausblenden
module SCHRI_A5(Name="",Value="",Library="") {InvisiblePart();} // Ausblenden
module SCHRI_A6(Name="",Value="",Library="") {InvisiblePart();} // Ausblenden
module A5_LOC2(Name="",Value="",Library="") {InvisiblePart();} // Ausblenden
module A6_LOC2(Name="",Value="",Library="") {InvisiblePart();} // Ausblenden
module A4_LOC2(Name="",Value="",Library="") {InvisiblePart();} // Ausblenden
module FIDUCIAL_1MM(Name="",Value="",Library="") {InvisiblePart();} // Ausblenden
module 3_2(Name="",Value="",Library="") {InvisiblePart();} // Ausblenden
module B2_54(Name="",Value="",Library="") {InvisiblePart();} // Ausblenden
module VG32(Name="",Value="",Library="") {InvisiblePart();} // Ausblenden
module __D(Name="",Value="",Library="") {InvisiblePart();} // Ausblenden
module LOGO(Name="",Value="",Library="") {InvisiblePart();}
module LOGO2(Name="",Value="",Library="") {InvisiblePart();}
module LOGOSS40(Name="",Value="",Library="") {scale(40/35)LOGOSS35(Name=Name,Value=Value,Library=Library);}
module LOGOSS50(Name="",Value="",Library="") {scale(50/35)LOGOSS35(Name=Name,Value=Value,Library=Library);}
module LOGOSS60(Name="",Value="",Library="") {scale(60/35)LOGOSS35(Name=Name,Value=Value,Library=Library);}
module LOGOSS35(Name="",Value="",Library="") {
if (Detailgrad > 15)
{
translate([-1.257,-2.5278]) color("Goldenrod") linear_extrude(0.05) union()
{
translate([1.257,3.569]) polygon([[0.381,1.562],[0.381,0.940],[0.927,0.940],[0.927,1.562],[1.295,1.562],[1.295,0.000],[0.927,0.000],[0.927,0.635],[0.381,0.635],[0.381,0.000],[0.000,0.000],[0.000,1.562]]);
translate([2.743,2.527]) polygon([[0.660,2.603],[1.041,2.603],[2.083,0.000],[1.702,0.000],[1.156,1.397],[0.533,1.397],[0.394,1.041],[0.000,1.041],[0.839,2.197],[1.042,1.702],[0.648,1.702]],[[0,1,2,3,4,5,6,7],[8,9,10]]);
translate([3.035,4.940]) polygon([[0.229,0.191],[0.229,0.000],[0.000,0.000],[0.000,0.191]]);
translate([3.924,4.940]) polygon([[0.229,0.191],[0.229,0.000],[0.000,0.000],[0.000,0.191]]);
translate([4.420,3.569]) polygon([[1.295,1.562],[0.762,1.562],[0.597,1.549],[0.432,1.524],[0.292,1.461],[0.191,1.372],[0.102,1.257],[0.038,1.118],[0.000,0.940],[0.000,0.699],[0.013,0.508],[0.076,0.330],[0.152,0.203],[0.292,0.089],[0.419,0.025],[0.572,0.000],[1.295,0.000],[1.295,0.279],[0.724,0.279],[0.572,0.305],[0.495,0.356],[0.432,0.457],[0.394,0.584],[0.381,0.711],[0.394,0.864],[0.419,1.016],[0.470,1.130],[0.521,1.194],[0.584,1.232],[0.699,1.270],[0.775,1.283],[1.295,1.283]]);
translate([5.918,3.569]) polygon([[0.368,0.000],[0.368,0.711],[0.914,0.000],[1.384,0.000],[0.762,0.787],[1.397,1.562],[0.940,1.562],[0.368,0.851],[0.368,1.562],[0.000,1.562],[0.000,0.000]]);
translate([7.277,3.569]) polygon([[1.308,1.562],[0.673,1.562],[0.508,1.537],[0.343,1.486],[0.229,1.410],[0.140,1.308],[0.076,1.194],[0.025,1.029],[0.000,0.826],[0.000,0.648],[0.038,0.432],[0.102,0.279],[0.216,0.152],[0.330,0.064],[0.483,0.013],[0.584,0.000],[1.308,0.000],[1.308,0.279],[0.749,0.279],[0.597,0.305],[0.508,0.356],[0.457,0.419],[0.419,0.508],[0.419,0.635],[1.308,0.635],[1.308,0.940],[0.406,0.940],[0.419,1.041],[0.457,1.118],[0.521,1.194],[0.610,1.245],[0.686,1.257],[1.308,1.257]]);
translate([8.827,3.569]) polygon([[0.000,1.562],[0.902,1.562],[1.041,1.549],[1.156,1.511],[1.257,1.435],[1.334,1.334],[1.372,1.232],[1.384,1.143],[1.384,1.054],[1.372,0.940],[1.321,0.813],[1.270,0.749],[1.207,0.699],[1.118,0.648],[1.092,0.635],[1.461,0.000],[1.054,0.000],[0.711,0.584],[0.368,0.584],[0.368,0.000],[0.000,0.000],[0.368,1.257],[0.787,1.257],[0.914,1.232],[0.965,1.207],[1.003,1.168],[1.016,1.118],[1.016,1.054],[1.003,0.991],[0.978,0.953],[0.940,0.927],[0.826,0.889],[0.368,0.889]],[[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20],[21,22,23,24,25,26,27,28,29,30,31,32]]);
make_line_of(0.2286,8) translate([1.257,2.985]) polygon([[0.140,0.140],[0.140,0.000],[0.000,0.000],[0.000,0.140]]);
make_line_of(0.2286,6) translate([1.257,2.985-0.2286]) polygon([[0.140,0.140],[0.140,0.000],[0.000,0.000],[0.000,0.140]]);
make_line_of(0.2286,6) translate([1.257,2.5278]) polygon([[0.140,0.140],[0.140,0.000],[0.000,0.000],[0.000,0.140]]);
translate([4.839,2.527]) polygon([[0.000,0.165],[0.025,0.102],[0.089,0.038],[0.152,0.013],[0.229,0.000],[0.546,0.000],[0.572,0.025],[0.572,0.610],[0.381,0.610],[0.381,0.165],[0.229,0.165],[0.203,0.191],[0.203,0.610],[0.000,0.610]]);
translate([5.448,2.527]) polygon([[0.305,0.826],[0.305,0.610],[0.470,0.610],[0.470,0.470],[0.305,0.470],[0.305,0.216],[0.318,0.178],[0.330,0.165],[0.356,0.152],[0.470,0.152],[0.470,0.025],[0.445,0.000],[0.279,0.000],[0.216,0.013],[0.165,0.051],[0.127,0.102],[0.114,0.152],[0.114,0.470],[0.000,0.470],[0.000,0.610],[0.114,0.610],[0.114,0.826]]);
// o
translate([5.918,2.527]) polygon([[0.394,0.622],[0.483,0.597],[0.546,0.559],[0.610,0.495],[0.648,0.419],[0.660,0.343],[0.660,0.254],[0.648,0.191],[0.622,0.140],[0.584,0.089],[0.521,0.038],[0.445,0.013],[0.356,0.000],[0.279,0.000],[0.203,0.013],[0.127,0.051],[0.076,0.102],[0.025,0.178],[0.000,0.267],[0.000,0.356],[0.025,0.432],[0.064,0.495],[0.114,0.546],[0.178,0.597],[0.267,0.622],[0.292,0.152],[0.267,0.165],[0.229,0.203],[0.203,0.267],[0.203,0.343],[0.229,0.406],[0.254,0.445],[0.305,0.470],[0.368,0.470],[0.406,0.445],[0.432,0.419],[0.457,0.356],[0.457,0.267],[0.432,0.203],[0.394,0.165],[0.356,0.152]],[[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24],[25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40]]);
translate([6.629,2.527]) polygon([[0.000,0.610],[0.711,0.610],[0.787,0.584],[0.838,0.533],[0.864,0.483],[0.876,0.419],[0.876,0.038],[0.838,0.000],[0.673,0.000],[0.673,0.419],[0.660,0.445],[0.635,0.457],[0.533,0.457],[0.533,0.025],[0.508,0.000],[0.356,0.000],[0.330,0.025],[0.330,0.457],[0.203,0.457],[0.203,0.025],[0.178,0.000],[0.000,0.000]]);
// a
translate([7.569,2.527]) polygon([[0.470,0.610],[0.546,0.572],[0.597,0.521],[0.622,0.457],[0.635,0.406],[0.635,0.038],[0.597,0.000],[0.165,0.000],[0.089,0.025],[0.038,0.064],[0.000,0.127],[0.000,0.241],[0.025,0.305],[0.064,0.343],[0.114,0.368],[0.165,0.381],[0.419,0.381],[0.419,0.419],[0.406,0.445],[0.381,0.457],[0.038,0.457],[0.038,0.610],[0.229,0.152],[0.419,0.152],[0.419,0.241],[0.229,0.241],[0.203,0.229],[0.191,0.191],[0.203,0.165]],[[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21],[22,23,24,25,26,27,28]]);
translate([8.2423,2.527]) polygon([[0.305,0.826],[0.305,0.610],[0.470,0.610],[0.470,0.470],[0.305,0.470],[0.305,0.216],[0.318,0.178],[0.330,0.165],[0.356,0.152],[0.470,0.152],[0.470,0.025],[0.445,0.000],[0.279,0.000],[0.216,0.013],[0.165,0.051],[0.127,0.102],[0.114,0.152],[0.114,0.470],[0.000,0.470],[0.000,0.610],[0.114,0.610],[0.114,0.826]]);
// o
translate([8.992,2.527]) polygon([[0.394,0.622],[0.483,0.597],[0.546,0.559],[0.610,0.495],[0.648,0.419],[0.660,0.343],[0.660,0.254],[0.648,0.191],[0.622,0.140],[0.584,0.089],[0.521,0.038],[0.445,0.013],[0.356,0.000],[0.279,0.000],[0.203,0.013],[0.127,0.051],[0.076,0.102],[0.025,0.178],[0.000,0.267],[0.000,0.356],[0.025,0.432],[0.064,0.495],[0.114,0.546],[0.178,0.597],[0.267,0.622],[0.292,0.152],[0.267,0.165],[0.229,0.203],[0.203,0.267],[0.203,0.343],[0.229,0.406],[0.254,0.445],[0.305,0.470],[0.368,0.470],[0.406,0.445],[0.432,0.419],[0.457,0.356],[0.457,0.267],[0.432,0.203],[0.394,0.165],[0.356,0.152]],[[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24],[25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40]]);
translate([8.750,3.188]) polygon([[0.000,0.000],[0.203,0.000],[0.203,0.165],[0.000,0.165]]);
translate([8.750,2.527]) polygon([[0.000,0.000],[0.203,0.000],[0.203,0.610],[0.000,0.610]]);
translate([9.716,2.527]) polygon([[0.000,0.610],[0.406,0.610],[0.495,0.572],[0.533,0.521],[0.559,0.470],[0.559,0.000],[0.368,0.000],[0.368,0.419],[0.343,0.445],[0.318,0.457],[0.191,0.457],[0.191,0.000],[0.000,0.000]]);
}
}
else
{
InvisiblePart();
}
}
// linear_extrude(0.3) text("Häcker", size = 2);}
module ZERO_SMALL(Name="",Value="",Library="") {InvisiblePart();} // Ausblenden
module CON14S_2MM(Name="",Value="",Library="") {InvisiblePart();} // Ausblenden SmarAct Connector 2mm
module SJ(Name="",Value="",Library="") {
color("#DFDDE0")
{
translate([1.524/2,0,0]) cube([1.168,1.600,0.2], center = true);
translate([-1.524/2,0,0]) cube([1.168,1.600,0.2], center = true);
}
}
module SJ2(Name="",Value="",Library="") {
color("#DFDDE0")
{
cube([1.168,1.600,0.2], center = true);
translate([1.524,0,0]) cube([1.168,1.600,0.2], center = true);
translate([-1.524,0,0]) cube([1.168,1.600,0.2], center = true);
}
}
module SJ_2(Name="",Value="",Library="") {SJ2(Name=Name,Value=Value,Library=Library);}
//SMD_IC([7,4.5,0.7],pinrows=2,pitch=0.7);
module DIODE(size = [1,1,1], pinlength=0.2)
{
translate([-size[0]/2,-size[1]/2,0])
union()
{
color("DarkSlateGray") translate([size[0]/4,0,0]) cube([size[0]*3/4,size[1], size[2]]);
color("white") translate([size[0]/8,0,0]) cube([size[0]*1/8,size[1], size[2]]);
color("DarkSlateGray") cube([size[0]/8,size[1], size[2]]);
}
color("LightGrey") translate([-pinlength-size[0]/2,-size[0]/6,0]) cube([size[0]+2*pinlength,size[0]/3,0.3]);
}
module TANTAL(size = [1,1,1])
{
translate([-size[0]/2,-size[1]/2,0])
union()
{
color("Yellow") translate([size[0]/4,0,0]) cube([size[0]*3/4,size[1], size[2]]);
color("DarkOrange") cube([size[0]/4,size[1], size[2]]);
if (Detailgrad > 9)
{color("Silver") translate([-0.1,size[1]/6,0]) cube([size[0]+0.2,2*size[1]/3, size[2]/2]);}
}
}
module DROSSEL(size = [1,1,1])
{
Offs=size[0]*0.3;
translate([(-size[0]+Offs)/2,(-size[1]+Offs)/2,0])
color("DarkGray") linear_extrude(size[2]) offset_square(size = [size[0]-Offs,size[1]-Offs], r = Offs/2, $fn = Detailgrad);
if (Detailgrad > 15) // hier krachts immer bei FreeCAD (Plazierung)
color("LightGrey") translate([0-0.2-size[0]/2,0-size[0]/6,0]) cube([size[0]+2*0.2,size[0]/3,0.3]);
}
module Ringkern(Da=29, Di=19, H=7.5, Color = "DarkGray")
{
roundness = Di/12;
if (Detailgrad > 15)
color(Color) {
linear_extrude(H) difference()
{
circle(Da/2-roundness);
circle(Di/2+roundness);
}
translate([0,0,roundness]) linear_extrude(H-2*roundness) difference()
{
circle(Da/2);
circle(Di/2);
}
rotate_extrude(convexity = 10) translate([Da/2-roundness, roundness, 0]) circle(r = roundness);
rotate_extrude(convexity = 10) translate([Da/2-roundness, H-roundness, ]) circle(r = roundness);
rotate_extrude(convexity = 10) translate([Di/2+roundness, roundness, 0]) circle(r = roundness);
rotate_extrude(convexity = 10) translate([Di/2+roundness, H-roundness, ]) circle(r = roundness);
}
else
{
color(Color)linear_extrude(H) difference()
{
circle(Da/2);
circle(Di/2);
}
}
}
module D_SENS(Name="",Value="",Library="") {
translate([0,8.89/2-1.778,8])
{
color("DarkSlateGray") cubepart([12.7,8.89, 7.874]);
color("Silver") translate([-3*1.27,1.778-8.89/2, -15.24]) make_line_of(2.54, 4) cylinder(15.24,0.6/2,0.6/2);
color("DarkSlateGray") translate([0,8.89/2,7.874/2 ]) rotate([-90,00,0])
{
Phased_cylinder(12.954,5.08/2,5.08/2, Roundness=1);
cylinder(5,6/2,6/2);
}
}
}
module SMD_PINS(size = [1,1,1],pinrows=0, pitch=1, pinlength=0, pinheight = 0, pinwidth = 0, phase = 0 , bended = true)
{
pinlength = pinlength ? pinlength : sqrt(pitch) ;
pinheight = pinheight ? pinheight : sqrt(pitch/2) ;
pinwidth = pinwidth ? pinwidth : pitch/2;
pincount0 = round((size[0]-phase)*0.9 / pitch);
pincount1 = round((size[1]-phase)*0.9 / pitch);
if (Detailgrad > 9)
{
dotpos0 = size[0] > size[1] ? size[1]*0.25 : size[0]*0.25;
dotpos = dotpos0 > 1.5 ? 1.5 : dotpos0;
translate([-size[0]/2+dotpos,-size[1]/2+dotpos,size[2]]) color("white") cylinder(0.02, dotpos/2, dotpos/2, $fn=Detailgrad);
if (pinrows)
{
{
translate([pitch/2-pinwidth/2-(pincount0*pitch)/2,-pinlength-size[1]/2,0]) color("silver") make_line_of(pitch, pincount0) SMD_PIN_DETAIL([pinwidth,pinlength,pinheight], bended = bended);
}
if (pinrows > 1)
{
rotate([0,0,180]) translate([pitch/2-pinwidth/2-(pincount0*pitch)/2,-pinlength-size[1]/2,0]) color("silver") make_line_of(pitch, pincount0) SMD_PIN_DETAIL([pinwidth,pinlength,pinheight], bended = bended);
}
if (pinrows > 2)
{
rotate([0,0,90]) translate([pitch/2-pinwidth/2-(pincount1*pitch)/2,-pinlength-size[0]/2,0]) color("silver") make_line_of(pitch, pincount1) SMD_PIN_DETAIL([pinwidth,pinlength,pinheight], bended = bended);
}
if (pinrows > 3)
{
rotate([0,0,270]) translate([pitch/2-pinwidth/2-(pincount1*pitch)/2,-pinlength-size[0]/2,0]) color("silver") make_line_of(pitch, pincount1) SMD_PIN_DETAIL([pinwidth,pinlength,pinheight], bended = bended);
}
}
}
else {InvisiblePart();}
}
module SMD_PIN(size = [1,1,1], pinnumber = 1, pitch=1, pinlength=0, pinheight= 0, pinwidth = 0, bended = true )
{
pinheight = pinheight ? pinheight : sqrt(pitch/2) ;
pinwidth = pinwidth ? pinwidth : pitch/2;
if (Detailgrad > 9)
{
pinlength = pinlength ? pinlength : sqrt(pitch) ;
pos = pinnumber - 1;
pincount = round(size[0]*0.9 / pitch);
translate([pitch/2-pinwidth/2-(pincount*pitch)/2,-pinlength-size[1]/2,0]) color("silver") translate([pitch*pos,0,0]) SMD_PIN_DETAIL([pinwidth,pinlength,pinheight],bended = bended);
} else {InvisiblePart();}
}
module SMD_PIN_DETAIL(size = [1,1,1], bended = true)
{
if ((Detailgrad < 20) || (size[2] > size[1]) || !bended)
{
cube(size);
}
else
{
r = size[2]/2-size[2]/8;
angle = 90;
pinwidth = size[0];
pinheight = size[2] /4;
translate([pinwidth,(size[1]-size[2]*3/4),size[2]])
rotate([00,-90,-90]) translate([pinheight/2-size[2],-size[0]/2,0])
union()
{
translate([0,0,-(size[1]-size[2]*3/4 )/2]) cube([pinheight,pinwidth,size[1]-size[2]*3/4], center = true);
//translate([r,0,0]) rotate([-90,0,00]) rotate_extrude(angle=angle) translate([-r,0]) square([pinheight,pinwidth], center = true);
translate([r,0,0]) rotate([-90,00,90]) BendedRectangle([pinheight,size[0]], r=r);
translate([r*(1-cos(angle)),0,(r)*sin(angle)]) rotate([0,angle,0]) rotate([0,0,180]) translate([r,0,0]) rotate([-90,00,90]) BendedRectangle([pinheight,size[0]], r=r);
// translate([r,0,0]) rotate([-90,0,00]) rotate_extrude(angle=angle) translate([-r,0]) square([pinheight,pinwidth], center = true);
// translate([r*(1-cos(angle)),0,(r)*sin(angle)]) rotate([0,angle,0]) rotate([0,0,180]) translate([r,0,0]) rotate([-90,0,00]) rotate_extrude(angle=angle) translate([-r,0]) square([pinheight,pinwidth], center = true);
}
}
}
module SMD_IC(size = [1,1,1],pinrows=0, pitch=1, pinlength=0, pinheight = 0, pinwidth = 0, phase = 0, r = 0 , frustum = 0, Pinsbended = true )
{
posphase = (phase > 0) ? phase : 0;
frust = (Detailgrad > 20) ? frustum : 0;
color("DarkSlateGray") cubepart(size = [size[0],size[1],size[2]], phase = posphase, r = r, frustum = frust);
SMD_PINS(size = [size[0],size[1],size[2]],pinrows=pinrows, pitch=pitch, pinlength=pinlength, pinheight = pinheight, pinwidth=pinwidth, phase = phase, bended = Pinsbended ) ;
}
module SMD_FN(size = [1,1,1],pinrows=0, pitch=1, pinheight = 0, phase = 0)
{
SMD_IC(size = [size[0],size[1],size[2]],pinrows=pinrows, pitch=pitch, pinlength = 0.05, pinheight = pinheight, phase = phase );
}
module R_SMD(size = [1,1,1])
{
if (Detailgrad > 9)
{
r = Detailgrad > 19 ? 0.08 : 0;
color("DarkSlateGray") cubepart([size[0]*0.9,size[1]*0.9,size[2]*0.9]);
color("silver") translate([size[0]*3/8,0,0]) cubepart([size[0]/4,size[1],size[2]], r=r);
color("silver") translate([-size[0]*3/8,0,0]) cubepart([size[0]/4,size[1],size[2]], r=r);
} else {InvisiblePart();}
}
module R_SIL(n = 5)
{
b=1;
color("Goldenrod") translate([-b/2,0,-b/2])
{
translate([0,0,3.5])
{ sphere(b/2);
translate([b+(n-1)*2.54,0,0]) sphere(b/2);
rotate([0,90,0]) cylinder(b+(n-1)*2.54,b/2,b/2);
}
translate([0,0,6.5])
{ sphere(b/2);
translate([b+(n-1)*2.54,0,0]) sphere(b/2);
rotate([0,90,0]) cylinder(b+(n-1)*2.54,b/2,b/2);
}
translate([0,0,3.5]) cylinder(6-3,b/2,b/2);
translate([b+(n-1)*2.54,0,3.5]) cylinder(6-3,b/2,b/2);
translate([0,-b/2,3.5]) cube([b+(n-1)*2.54,b,3]);
}
translate([0,0,2.6]) make_line_of(2.54, n) LOETPIN(height =4.4, dim = 0.45);
}
module C_SMD(size = [1,1,1])
{
if (Detailgrad > 9)
{
r = Detailgrad > 19 ? 0.08 : 0;
color("Khaki") cubepart([size[0]*0.9,size[1]*0.9,size[2]*0.9]);
color("silver") translate([size[0]*3/8,0,0]) cubepart([size[0]/4,size[1],size[2]], r=r);
color("silver") translate([-size[0]*3/8,0,0]) cubepart([size[0]/4,size[1],size[2]], r=r);
} else {InvisiblePart();}
}
module 0309_12(Name="",Value="",Library="rcl")
{
R_THT(Diameter = 3, l = 6.38*2, Pin = 0.5);
}
module 0207_10(Name="",Value="",Library="rcl")
{
R_THT(Diameter = 2, l = 5.08*2, Pin = 0.4);
}
module 0411_12(Name="",Value="",Library="Resistor")
{
R_THT(Diameter = 4, l = 2.54*5, Pin = 0.4);
}
//C050-025X075
module MSR3(Name="",Value="",Library="Arcol")
{
translate([-7.620,0,1]) LOETPIN(height = 6, dim = 1.7, rnd = true);
translate([+7.620,0,1]) LOETPIN(height = 6, dim = 1.7, rnd = true);
translate([-7.620,0,1]) color("silver") cubepart([1,5,15]);
translate([+7.620,0,1]) color("silver") cubepart([1,5,15]);
color("silver") translate([0,0,15]) cubepart([15.2,5,1]);
}
module MSR1(Name="",Value="",Library="Arcol")
{
translate([-5.7,0,1]) LOETPIN(height = 6, dim = 1.7, rnd = true);
translate([+5.7,0,1]) LOETPIN(height = 6, dim = 1.7, rnd = true);
translate([-5.7,0,1]) color("silver") cubepart([1,4,7]);
translate([+5.7,0,1]) color("silver") cubepart([1,4,7]);
color("silver") translate([0,0,7]) cubepart([11.4,4,1]);
}
module R_THT(Diameter = 4.5, l = 6.38*2, Pin = 0.5)
{
Korpus = l/1.27;
if (Detailgrad < 30)
{
color("DarkKhaki") translate([-Korpus/2,0,Diameter/2])rotate([0,90,0])
union()
{
cylinder(Korpus/5,Diameter/2,Diameter/2);
cylinder(Korpus,7*Diameter/16,7*Diameter/16);
translate([0,0,4*Korpus/5]) cylinder(Korpus/5,Diameter/2,Diameter/2);
}
}
else
R_THT_DETAIL(Diameter = Diameter, l = l, Pin = Pin);
color("Silver")
{
translate([l/2,0,-2.25*Pin+Diameter/2]) BendedPIN(Pin,3,l2=2*Pin);
translate([-l/2,0,-2.25*Pin+Diameter/2]) rotate([0,0,180]) BendedPIN(Pin,3,l2=2*Pin);
}
}
module R_THT_DETAIL(Diameter = 4.5, l = 6.38*2, Pin = 0.9)
{
Resistor6_polygon = [[0.100,6.000],[0.125,5.925],[0.150,5.875],[0.200,5.800],[0.238,5.750],[0.288,5.700],[0.338,5.663],[0.400,5.625],[0.450,5.600],[0.525,5.575],[0.613,5.563],[0.675,5.550],[0.725,5.538],[0.775,5.513],[0.825,5.475],[0.850,5.450],[0.875,5.400],[0.888,5.362],[0.900,5.300],[0.900,4.525],[0.888,4.475],[0.875,4.438],[0.850,4.400],[0.775,4.325],[0.738,4.275],[0.713,4.225],[0.700,4.150],[0.700,1.850],[0.713,1.775],[0.738,1.725],[0.775,1.675],[0.850,1.600],[0.875,1.563],[0.888,1.525],[0.900,1.475],[0.900,0.700],[0.888,0.638],[0.875,0.600],[0.850,0.550],[0.825,0.525],[0.775,0.488],[0.725,0.463],[0.675,0.450],[0.613,0.438],[0.525,0.425],[0.450,0.400],[0.400,0.375],[0.338,0.338],[0.288,0.300],[0.238,0.250],[0.200,0.200],[0.150,0.125],[0.125,0.075],[0.100,0.000],[0.000,0.000],[0.000,6.000]];
Korpus = l/1.27;
translate([0,0,Diameter/2]) rotate([0,90,0]) scale([Diameter/2.5, Diameter/2.5,l/(6.38*1.3)])
{
color("DarkKhaki") rotate_extrude($fn=100) translate([0.300,-3.000]) polygon(Resistor6_polygon);
color("brown") translate([0,0,1.6])cylinder(0.5,1.201,1.201,$fn=100);
color("black") translate([0,0,0.6])cylinder(0.5,1.001,1.001,$fn=100);
color("red") translate([0,0,-0.4])cylinder(0.5,1.001,1.001,$fn=100);
color("gold") translate([0,0,-2.1])cylinder(0.5,1.201,1.201,$fn=100);
}
color("Silver")
{
translate([l/2,0,-2.25*Pin+Diameter/2]) BendedPIN(Pin,3,l2=2*Pin);
translate([-l/2,0,-2.25*Pin+Diameter/2]) rotate([0,0,180]) BendedPIN(Pin,3,l2=2*Pin);
}
}
module C_THT(Diameter = 4.5, l = 6.38*2, Pin = 0.5)
{
Korpus = l-2;
color("Orange") translate([-Korpus/2,0,Diameter/2])rotate([0,90,0])
union()
{
cylinder(Korpus,Diameter/2,Diameter/2);
}
translate([l/2,0,Diameter/2-1.25]) BendedPIN(Pin,3,l2=2*Pin);
translate([-l/2,0,Diameter/2-1.25]) rotate([0,0,180]) BendedPIN(Pin,3,l2=2*Pin);
}
module LED_BR00(Name="",Value="",Library="")
{
rotate([0,0,90]) union()
{
color("white") cubepart(size = [2.8,3.2,1.9]);
color(LEDCOLOR(Value)) cylinderpart(size = [2.5,2]);
SMD_PINS(size = [2.8,3.2,1.9],pinrows=2, pitch=3, pinlength=0.15 ) ;
}
}
module LED_1W(Name="",Value="",Library="")
{
color("white") SMD_IC([6.2,7.2,2],pinrows=2,pitch=4,r=1.5, pinlength=2, pinheight=1 );
color(LEDCOLOR(Value)) cylinderpart(size = [3,2.01]);
}
module P_LCC4_0(Name="",Value="",Library="")
{
color("white") cubepart(size = [2.8,3.2,1.9]);
color(LEDCOLOR(Value)) cylinderpart(size = [2.5,2]);
}
module LRTB_G6(Name="",Value="",Library="")
{
color("white") cubepart(size = [3.3,3,1.8]);
color(LEDCOLOR(Value)) cylinderpart(size = [2.5,2]);
SMD_PINS(size = [3.3,3,1.8],pinrows=2,pitch=1.1,pinlength = 0.2);
}
module LRTB_GVTG(Name="",Value="",Library="") {rotate([0,0,180]) LRTB_G6(Name=Name,Value=Value,Library=Library);}
module WS2812B(Name="",Value="",Library="")
{
color("white") cubepart(size = [5,5,1.8]);
color(LEDCOLOR(Value)) cylinderpart(size = [4,1.9]);
}
module LED_SMD(size = [0.8,1.7,0.65], Enable = false, Value = "")
{
rotate([0,0,90])
{
color("gray") translate([0,0,0.125/2]) cube([size[0]*0.85,size[1],size[2]/5], center = true);
if (!Enable)
{
color(LEDCOLOR(Value)) linear_extrude(size[2],scale = 0.9) square([size[0],0.75*size[1]],center = true);
}
else
{
color("lightgreen") linear_extrude(size[2],scale = 0.9) square([size[0],0.75*size[1]],center = true);
}
}
}
module LED3L(Name="",Value="",Library=""){translate([0,7,4]) rotate([-90,0,0]) LED(dia = 3, Value = Value);}
module 3MM_REAR(Name="",Value="",Library=""){translate([0,0,2]) rotate([0,180,90]) LED3(Name=Name,Value=Value,Library=Library);}
module LED_3L3(Name="",Value="",Library=""){translate([0,7,4]) rotate([90,0,0]) LED(dia = 3, Value = Value);}
module LED3MM(Name="",Value="",Library=""){LED3(Name=Name,Value=Value,Library=Library);}
module LED3E(Name="",Value="",Library=""){LED3(Name=Name,Value=Value,Library=Library);}
module LED3(Name="",Value="",Library="")
{
translate([0,0,4.5]) LED(dia = 3, Value = Value);
}
module LED(dia = 3, Value = "")
{
rotate([180,0,0]) color(LEDCOLOR(Value),0.7)
{
sphere(dia/2, $fn=Detailgrad);
cylinder(3.7,dia/2,dia/2,$fn=Detailgrad);
translate([0,0,3.7-0.5]) cylinder(0.5,dia/2+0.3,dia/2+0.3,$fn=Detailgrad);
}
translate([-2.54/2,0,-3.5]) make_line_of(2.54, 2) LOETPIN(height =3.4, dim = 0.45);
}
module ZERO(Name="",Value="",Library="HAutomation_6")
{
board_thickness = 1.600;
color("white") translate([0,0,-board_thickness-0.05]) linear_extrude(board_thickness+0.1) difference() { circle(1.3);circle(1.2);}
color("white")
{
translate([-0.8/2,+0.8/2,0]) cubepart([0.8,0.8,0.05]);
translate([+0.8/2,-0.8/2,0]) cubepart([0.8,0.8,0.05]);
}
color("white")
{
translate([+0.8/2,+0.8/2,-board_thickness-0.05]) cubepart([0.8,0.8,0.05]);
translate([-0.8/2,-0.8/2,-board_thickness-0.05]) cubepart([0.8,0.8,0.05]);
}
}
module cubestack(size = [1,1,1])
{
translate([-size[0]/2, -size[1]/2,0]) cube([size[0],size[1],size[2]], center = false);
translate([0, 0,size[2]]) children();
}
module MW15_2(Name="",Value="",Library="") { MW15(Name = Name, Value = Value, Library = Library); }
module MW15(Name="",Value="",Library="") //IC24 L298-2
{
h = 18.1;
translate([0,4.6,0]) rotate([0,0,180])
{
translate([-19.6/2,0,2.8-17.5+h]) color("silver")
difference()
{
// cube([19.6,1.6,17.5]);
rotate([90,0,0]) translate([0,0,-1.6]) linear_extrude(1.6) polygon([[0,0],[19.6,0],[19.6,17.5-2.2],[19.6-2.2,17.5],[0+2.2,17.5],[0,17.5-2.2]]);
translate([19.6/2,1.8,17.5-2.8]) rotate([90,0,0]) cylinder(2,2,2);
}
translate([-19.6/2,1.6,h-17.5+2.8]) color( "DarkSlateGray") cube([19.6,5-1.6,10.7]);
translate([-6*1.27+0.75/2,0,h-17.5+2.8])
make_line_of(2.54, 7) color("silver")
{
translate([0,2.25+2.6,-7.4]) rotate([90,0,-90]) linear_extrude(0.75) polygon([[2.225,6.297500],[0.55,4.6225],[0.55,0.0],[0.0,0.0],[0.0,4.805],[1.675,6.48],[1.675,7.4],[2.225,7.4]]); // pin
}
translate([-7*1.27+0.75/2,0,h-17.5+2.8])
make_line_of(2.54, 8) color("silver")
{
translate([0,7.35+2.6,-6.985]) rotate([90,0,-90]) linear_extrude(0.75) polygon([[7.35,5.785],[0.595,3.885],[0.595,0.0],[0.0,0.0],[0.0,4.385],[6.8,6.285],[6.8,6.985],[7.35,6.985]]); // pin
}
}
}
module TO220_PARAM(n=2)
{
h = 6;
angle = bended ? 90 : 0;
translate([-5,0,h]) rotate([angle,0,0])
{
translate([0.05,0,2.8]) color("silver")
difference()
{
cube([9.9,1.3,12]);
translate([5,1.5,12-2.8]) rotate([90,0,0]) cylinder(2,2,2);
}
translate([0,0.05,0]) color("DarkSlateGray") cube([10,4.5,8.6]);
}
translate([-2.54-0.9/2,2.5,-14.7+h]) make_line_of(5.08/(n-1), n) color("silver")
{
cube([0.9,0.6,14.73]); translate([-0.45,0,14.7-h]) cube([1.8,0.6,h]); // pin
}
}
module TO220L_PARAM(n=2)
{
h = 0.1;
translate([-5,-5.5,h]) rotate([90,0,0])
{
translate([0.05,0,2.8]) color("silver")
difference()
{
cube([9.9,1.3,12]);
translate([5,1.5,12-2.8]) rotate([90,0,0]) cylinder(2,2,2);
}
translate([0,0.05,0]) color("DarkSlateGray") cube([10,4.5,8.6]);
translate([5-2.54-0.9,2.5,-3]) make_line_of(5.08/(n-1), n) color("silver")
{
cube([1.8,0.6,3]);
translate([0.9/2,0,-1.27-0.3]) cube([0.9,0.6,3]);
translate([0.9,-0.7,-1.27-0.24]) rotate([180,0,0]) BendedRectangle(Dim=[0.6,0.9], r=1);
}
}
translate([-2.54-0.9/2,-0.3,-3.1]) make_line_of(5.08/(n-1), n) color("silver")
{
cube([0.9,0.6,5]);
}
}
module FPC_L(size = [12,4.5,2], pitch=0.5, pinlength = 1.1)
{
NB_PINS = round((size[0]-6.4) / pitch);
pinheight = 0.3;
difference()
{
color("DarkSlateGray") translate([-size[0]/2,size[1]-1.3,0]) cube([size[0],1.3,2]);
translate([-(pitch*(NB_PINS+1))/2,size[1]-1.4,-0.05]) cube([pitch*(NB_PINS+1),1.5,1.25]);
}
difference()
{
color("Beige") translate([-(size[0]-2)/2,0,0]) cube([size[0]-2,size[1]-1.3,2]);
translate([-(pitch*(NB_PINS+1))/2,0.1,0.25]) cube([pitch*(NB_PINS+1),size[1]-1.3,0.8]);
}
translate([pitch/4-(NB_PINS*pitch)/2,-pinlength,0]) color("silver") make_line_of(pitch, NB_PINS) cube([pitch/2,size[1],pinheight]);
}
module FPC_S(size = [11.44,2,4.5], pitch=0.5, invers = false)
{
NB_PINS = round((size[0]-6.4) / pitch);
pin1 = invers ? -size[0]/2+2.5 : size[0]/2-2.5;
if (Detailgrad > 9)
{
translate([pin1,0,0]) color("white") cylinder(size[2]*1.02, size[1]*0.1, size[1]*0.1, $fn=Detailgrad);
color("LemonChiffon")
difference()
{
cubepart([size[0]-1.4,size[1],size[2]*3/4]);
translate([0,0,size[2]*1/4]) cubepart([size[0]-6,size[1]/2,size[2]*3/4],r=0);
}
// Außenpins
translate([pitch/4-(NB_PINS*pitch)/2+pitch,-size[1]/2,0]) color("silver") make_line_of(pitch*2, NB_PINS/2) cube([pitch/2,size[1]+0.75,0.5]);
translate([pitch/4-(NB_PINS*pitch)/2,-0.75-size[1]/2,0]) color("silver") make_line_of(pitch*2, NB_PINS/2) cube([pitch/2,size[1]+0.75,0.5]);
translate([pitch/4-(NB_PINS*pitch)/2-2*pitch,-0.75-size[1]/2,0]) color("silver") cube([pitch/2,size[1]+1.5,0.5]);
translate([pitch/4-(-(NB_PINS*pitch)/2)+pitch,-0.75-size[1]/2,0]) color("silver") cube([pitch/2,size[1]+1.5,0.5]);
// Innenpins
translate([pitch/4-(NB_PINS*pitch)/2,size[1]/5,size[2]*1/4+0.1]) color("silver") make_line_of(pitch, NB_PINS) cube([pitch/2,size[1]/8,size[2]/2]);
// Klips
Boffset = (pitch > 0.9) ? 0.8:0.1; // Seitlich etwas breiterer Clips
poly = [[-size[0]/2,size[1]/2],[-size[0]/2,-size[1]/2],[-size[0]/2+2.8,-size[1]/2-Boffset],[size[0]/2-2.8,-size[1]/2-Boffset],[size[0]/2,-size[1]/2],[size[0]/2,size[1]/2],[size[0]/2-3,size[1]/2],[size[0]/2-3,-size[1]/4],[-size[0]/2+3,-size[1]/4],[-size[0]/2+3,size[1]/2]];
color("DarkSlateGray") translate([0,0,size[2]*3/4]) linear_extrude(size[2]*1/4) polygon(poly);
}
else
{
color("DarkSlateGray") cubepart([size[0],size[1],size[2]]);
}
}
module JST(n=4)
{
w = 0.4;
translate([-(1+1.9/2),-1.7,0]) color("Linen") difference()
{
cube([1.9+n*2,4.5,6], center = false);
translate([n*2+0.5,-2*w,4]) rotate([0,0,45]) cube([2*w,2*w,3], center = false);
if (Detailgrad > 8)
{
translate([0.75+2,-w/2,2]) cube([(n-2)*2+0.4,2*w,5], center = false);
translate([w,w,w]) cube([-2*w+1.9+n*2,-2*w+4.5,6], center = false);
translate([-w/2,1.0,4]) cube([w+1.9+n*2,0.7,3], center = false);
}
}
if (Detailgrad > 8)
{
translate([0,0,(8.4)-3.4]) make_line_of(2, n) LOETPIN(height = 8.4, dim = 0.5);
// color("Silver") translate([0,0,(8.4/2)-3.4]) make_line_of(2, n) cube([0.5,0.5,8.4], center = true);
}
}
module JSTL(n=4)
{
translate([-(1+1.9/2),-6.25,0]) color("Linen") difference()
{
union()
{
cube([1.9+n*2,6,4.8], center = false);
cube([1.9+n*2,7.6,3], center = false);
}
translate([0.5,-1,5.2]) rotate([0,45,0]) cube([1,3,1], center = false);
translate([0.75+2,-1,3.5]) cube([(n-2)*2+0.4,5,2], center = false);
if (Detailgrad > 8)
{
translate([0.5,-0.5,0.5+0.3]) cube([-1+1.9+n*2,6,-1+4.5], center = false);
}
}
if (Detailgrad > 8)
{
color("Silver") translate([0,0,(6.4/2)-3.4]) make_line_of(2, n) cube([0.5,0.5,6.4], center = true);
color("Silver") translate([0,-2.5,3.1]) make_line_of(2, n) cube([0.5,6,0.5], center = true);
}
}
module JSTSMD(n=4)
{
color("Linen");
w = 0.4;
color("Linen") difference()
{
union()
{
translate([0,-0.5,0]) cubepart([3.9+(n*2),5,6]);
}
if (Detailgrad > 8)
{
translate([0,-0.5,2.5]) cubepart([0.5+(n*2),3.5,6]);
translate([-n-0.5,1,0.6]) make_line_of(2*n, 2) cube([1,2,4], center = false);
translate([0,1,2.5]) cubepart([-3.3+(n*2),4.5, 6.3]);
translate([-n-2.9+0.5,-0.5-1,0.2]) make_line_of(3.9+2*n, 2) cube([1,2,6], center = false);
// translate([-w/2,1.0,4]) cube([w+1.9+n*2,0.7,3], center = false);
}
}
if (Detailgrad > 8)
{
translate([-(n-1),0,5]) make_line_of(2, n) LOETPIN(height = 5, dim = 0.5);
color("Silver") translate([-(n-1),-2.5,0.25]) make_line_of(2, n) cube([0.5,4,0.5], center = true);
// color("Silver") translate([0,0,(8.4/2)-3.4]) make_line_of(2, n) cube([0.5,0.5,8.4], center = true);
}
}
module JSTLSMD(n=4)
{
color("Linen")
difference()
{
union()
{
translate([0,-4.05,0]) cubepart([3.9+(n*2),6.3,5.5]);
translate([-n-1.95,-0.9,0]) make_line_of(2*n+2.9, 2) cube([1,1.3,2], center = false);
}
translate([-n-0.5,-4.5,4.5]) make_line_of(2*n, 2) cube([1,5,2], center = false);
translate([0,-4.55,0.5]) cubepart([0.5+(n*2),6.3,3.7]);
translate([0,-4.55,0.5]) cubepart([-3.3+(n*2),6.3,4.5]);
}
if (Detailgrad > 8)
{
color("Silver") translate([-(n-1),0,0.25]) make_line_of(2, n) cube([0.5,2.8,0.5], center = true);
color("Silver") translate([-(n-1),-3.7,2.5]) make_line_of(2, n) cube([0.5,5,0.5], center = true);
}
}
module JSTXH(n=4)
{
translate([-(2.54),-2.35,0]) color("Linen") difference()
{
cube([2.4+n*2.5,5.75,7], center = false);
translate([n*2.5+1.2,-1.1,4]) rotate([0,0,45]) cube([1,1,4], center = false);
translate([-0.1,1,4]) cube([2.6+n*2.5,1,6], center = false);
translate([2,-0.2,4]) cube([1.5,1,6], center = false);
translate([n*2.5-1,-0.2,4]) cube([1.5,1,6], center = false);
if (Detailgrad > 8)
{
translate([0.5,0.5,0.5]) cube([-1+2.4+n*2.5,-1+5.75,7], center = false);
}
}
if (Detailgrad > 8)
{
color("Silver") translate([0,0,(8.4/2)-3.4]) make_line_of(2.5, n) cube([0.65,0.65,8.4], center = true);
}
}
module LPV(n=4)
{
color("Linen") difference()
{
translate([-1.27,-2.92,0.01])
union()
{
cube([n*2.54,5.8,3.17], center = false);
translate([1.27,4.8,0])
{
cube([(n-1)*2.54,1,11.7], center = false);
translate([0,-0.5,5]) cube([(n-1)*2.54,1,1], center = false);
}
}
make_line_of(2.54, n) cube([1.8,6,1], center = true);
// translate([0.5,0.5,0.5]) cube([-1+1.9+n*2,-1+4.5,6], center = false);
}
color("Silver") translate([0,0,(13.69/2)-3.8]) make_line_of(2.54, n) cube([0.5,0.5,13.69], center = true);
}
module LPVL(n=4)
{
translate([0,-2.72,2.92]) rotate([90,0,0]) difference()
{
color("Linen") translate([-1.27,-2.92,0])
union()
{
cube([n*2.54,5.8,3.17], center = false);
translate([1.27,4.8,0])
{
cube([(n-1)*2.54,1,11.7], center = false);
translate([0,-0.5,5]) cube([(n-1)*2.54,1,1], center = false);
}
}
make_line_of(2.54, n) cube([1.8,6,1], center = true);
// translate([0.5,0.5,0.5]) cube([-1+1.9+n*2,-1+4.5,6], center = false);
}
color("Silver") translate([0,0,(6.0/2)-3.8]) make_line_of(2.54, n) cube([0.5,0.5,6.0], center = true);
color("Silver") translate([0,-11.40/2-0.75,2.92]) make_line_of(2.54, n) cube([0.5,11.40,0.5], center = true);
color("Silver") translate([0,-0.75,2.92-0.75]) make_line_of(2.54, n) rotate([0,0,180]) BendedSquare(Dim=0.5, r=0.75);
}
module LSTA05(n=20,m=1)
{
offs = 0.4;
height = 7.5;
pitch = 1.27;
pin = 0.4;
translate([-(pitch/2)*n+offs,-(pitch/2)*m-(pitch/2)+offs,4.6-0.38]) cube(0.4);
difference()
{
translate([-(pitch/2)*n+offs,-(pitch/2)*m-(pitch/2)+offs,0]) make_line_of(pitch, n) color("DarkSlateGray") linear_extrude(4.6) offset_square(size=[pitch-2*offs,pitch*m+(pitch)-2*offs], delta = offs, chamfer=true);
translate([-(pitch/2)*(n-1),-(pitch/2)*(m-1),2]) make_line_of(pitch, n) color("DarkSlateGray") cubepart([0.6,0.6,3]);
if (m>1) translate([-(pitch/2)*(n-1),+(pitch/2)*(m-1),2]) make_line_of(pitch, n) color("DarkSlateGray") cubepart([0.6,0.6,3]);
if (m>2) translate([-(pitch/2)*(n-1),0,2]) make_line_of(pitch, n) color("DarkSlateGray") cubepart([0.6,0.6,3]);
}
translate([-(pitch/2)*(n-1),-(pitch/2)*(m-1),0]) make_line_of(pitch, n) color("Silver") translate([0,0,-4.5+height/2]) cube([pin,pin,height-3], center = true);
if (m>1) translate([-(pitch/2)*(n-1),+(pitch/2)*(m-1),0]) make_line_of(pitch, n) color("Silver") translate([0,0,-4.5+height/2]) cube([pin,pin,height-3], center = true);
if (m>2) translate([-(pitch/2)*(n-1),0,0]) make_line_of(pitch, n) color("Silver") translate([0,0,-4.5+height/2]) cube([pin,pin,height-3], center = true);
}
module RSM_1(n=6, m=1)
{
difference()
{
union()
{
color("DarkSlateGray") translate([0,0,0.31])cubepart([0.25+1.27*n, 2.54*m,5.79]);
translate([-1.27*(n)/2,-1.27,6.1]) color("Yellow") linear_extrude(0.01) square([1.27,2.54]);
}
color("DarkSlateGray") translate([-1.27*(n-1)/2,0,0]) make_line_of(1.27, n) cubepart([0.8,0.8,6.2]);
}
r = 0.2;
h = 0.19;
l = 1.07;
b = 0.41;
translate([-1.27*(n-1)/2,-(3.94/2-l),0]) make_line_of(2.54, n/2) color("Goldenrod")
{
translate([0,0,r+h/2]) rotate([180,00,0]) BendedRectangle(Dim=[h,b], r=r);
translate([-b/2,-l,0]) cube([b,l,h]);
}
rotate([0,0,180]) translate([-1.27*(n-1)/2,-(3.94/2-l),0]) make_line_of(2.54, n/2) color("Goldenrod")
{
translate([0,0,r+h/2]) rotate([180,00,0]) BendedRectangle(Dim=[h,b], r=r);
translate([-b/2,-l,0]) cube([b,l,h]);
}
}
module LSTA(n=20,m=1,mark=true)
{
offs = 0.4;
height = 7.5;
pitch = 2.54;
pin = 0.4;
difference()
{
union()
{
if (mark)
{
translate([-(pitch/2)*n+offs,-(pitch/2)*m+offs,8.4]) color("Yellow") linear_extrude(0.01) offset_square(size=[pitch-2*offs,pitch*m-2*offs], delta = offs, chamfer=true);
}
translate([-(pitch/2)*n+offs,-(pitch/2)*m+offs,0]) make_line_of(pitch, n) color("DarkSlateGray") linear_extrude(8.4) offset_square(size=[pitch-2*offs,pitch*m-2* offs], delta = offs, chamfer=true);
}
translate([-(pitch/2)*(n-1),-(pitch/2)*(m-1),3]) make_line_of(pitch, n) color("DarkSlateGray") cubepart([0.9,0.9,6]);
if (m>1) translate([-(pitch/2)*(n-1),+(pitch/2)*(m-1),3]) make_line_of(pitch, n) color("DarkSlateGray") cubepart([0.9,0.9,6]);
if (m>2) translate([-(pitch/2)*(n-1),0,3]) make_line_of(pitch, n) color("DarkSlateGray") cubepart([0.9,0.9,6]);
}
translate([-(pitch/2)*(n-1),-(pitch/2)*(m-1),0]) make_line_of(pitch, n) color("Silver") translate([0,0,-4.5+height/2]) cube([pin,pin,height-3], center = true);
if (m>1) translate([-(pitch/2)*(n-1),+(pitch/2)*(m-1),0]) make_line_of(pitch, n) color("Silver") translate([0,0,-4.5+height/2]) cube([pin,pin,height-3], center = true);
if (m>2) translate([-(pitch/2)*(n-1),0,0]) make_line_of(pitch, n) color("Silver") translate([0,0,-4.5+height/2]) cube([pin,pin,height-3], center = true);
}
module LSTB05(n=20,m=1, mark=false)
{
offs = 0.4;
height = 11.6;
pitch = 1.27;
pin = 0.4;
if (mark)
{
translate([-(pitch/2)*n+offs,-(pitch/2)*m-(pitch/2)+offs,2.6]) color("Yellow") linear_extrude(0.01)
offset_square(size=[pitch-2*offs,pitch*m+(pitch)-2*offs], delta = offs, chamfer=true);
}
translate([-(pitch/2)*n+offs,-(pitch/2)*m-(pitch/2)+offs,0]) make_line_of(pitch, n) color("lightgreen") linear_extrude(2.6)
offset_square(size=[pitch-2*offs,pitch*m+(pitch)-2*offs], delta = offs, chamfer=true);
translate([-(pitch/2)*(n-1),-(pitch/2)*(m-1),0]) make_line_of(pitch, n) color("Silver") translate([0,0,-3+height/2]) cube([pin,pin,height], center = true);
if (m>1) translate([-(pitch/2)*(n-1),+(pitch/2)*(m-1),0]) make_line_of(pitch, n) color("Silver") translate([0,0,-3+height/2]) cube([pin,pin,height], center = true);
if (m>2) translate([-(pitch/2)*(n-1),0,0]) make_line_of(pitch, n) color("Silver") translate([0,0,-3+height/2]) cube([pin,pin,height], center = true);
}
;
module LSTB(n=20,m=1, mark=true)
{
offs = 0.9;
height = 11.6;
pitch = 2.54;
pin = 0.6;
if (mark)
{
translate([-(pitch/2)*n+offs,-(pitch/2)*m+offs,2.6]) color("Yellow") linear_extrude(0.01)
offset_square(size=[pitch-2*offs,pitch*m-2*offs], delta = offs, chamfer=true);
}
translate([-(pitch/2)*n+offs,-(pitch/2)*m+offs,0]) make_line_of(pitch, n) color("lightgreen") linear_extrude(2.6) offset_square(size=[pitch-2*offs,pitch*m-2*offs], delta = offs, chamfer=true);
translate([-(pitch/2)*(n-1),-(pitch/2)*(m-1),8.7]) make_line_of(pitch, n) LOETPIN(height = height, dim = pin, rnd = false);
if (m>1) translate([-(pitch/2)*(n-1),+(pitch/2)*(m-1),8.7]) make_line_of(pitch, n) LOETPIN(height = height, dim = pin, rnd = false);
if (m>2) translate([-(pitch/2)*(n-1),0,8.7]) make_line_of(pitch, n) LOETPIN(height = height, dim = pin, rnd = false);
}
module LSTBW(n=20)
{
offs = 0.9;
height = 8.7;
pitch = 2.54;
pin = 0.6;
translate([0,pitch/2,0])
{
translate([0,0,pitch/2]) rotate([-90,00,0])
{
translate([-(pitch/2)*n+offs,-(pitch/2)+offs,0]) make_line_of(pitch, n) color("lightgreen") linear_extrude(2.6) offset_square(size=[pitch-2*offs,pitch-2*offs], delta = offs, chamfer=true);
translate([-(pitch/2)*(n-1),0,0]) make_line_of(pitch, n) color("Silver") translate([0,0,8.7-height/2]) cube([pin,pin,height], center = true);
}
translate([-(pitch/2)*(n-1),0,0]) make_line_of(pitch, n) color("Silver") translate([0,0,0]) BendedSquare(Dim=pin, r=pitch/2);
translate([-(pitch/2)*(n-1),-pitch/2,0]) make_line_of(pitch, n) color("Silver") translate([0,0,-height/6]) cube([pin,pin,height/3], center = true);
}
}
//SV_3_81(n=10, SK=true);
// Weidmüller
module SV_3_81(n=10, SK=true)
{
length = (n-1) * 3.81 + 14.2;
color("LimeGreen")
{
translate([0,-0.635,0]) cubepart(size = [length,7.25,9.2], phase = 0);
translate([0,0.635,9.2]) cubepart(size = [(n) * 3.81,11.1,9.5], phase = 0);
}
translate([-((n-1) * 3.81)/2,0,0]) make_line_of(3.81, n) LOETPIN(height = 4);
}
module SL_3_5(n=4, SK=true) {
translate([3.5*3/2,0,0]) rotate([0,0,180])
{
translate([-(1+1.3),-10,0]) difference()
{
color("Orange") cube([1.3+n*3.5,11.1,7.5], center = false);
if (Detailgrad > 8)
{
translate([0.5,-0.5,1.25]) cube([-1+1.3+n*3.5,6,5], center = false);
}
}
//BendedPIN(Diameter=0.5,l=2,l2=1);
if (Detailgrad > 8)
{
color("Silver") translate([0,0,(6.4/2)-3.4]) make_line_of(3.5, n) cube([0.8,0.8,6.4], center = true);
color("Silver") translate([0,-4.5,3.6]) make_line_of(3.5, n) cube([0.8,8,0.8], center = true);
}
}
}
module SV_3_5(n=4, SK=true) {
w=0.5;
translate([(2*2.45+(n-1)*3.5)/2,0,0]) rotate([0,0,180])
{
color("Orange") translate([0,-3.5,0])
intersection(Name="",Value="",Library="")
{
cube([2*2.45+(n-1)*3.5,7.5,11.1], center = false);
union()
{
difference()
{
cube([2*2.45+(n-1)*3.5,7.5,11.1], center = false);
if (Detailgrad > 8) translate([w,w,4]) cube([2*(2.45-w)+(n-1)*3.5,7.5,11.1], center = false);
}
if (Detailgrad > 8)
{
translate([2.45,-0.5,0.1]) make_line_of(3.5, n) cylinder(11.1,1.6,1.6);
translate([2.45-3.5/2,7.5,0.1]) make_line_of(3.5, n+1) cylinder(11.1,1.2,1.2);
}
}
}
//BendedPIN(Diameter=0.5,l=2,l2=1);
if (Detailgrad > 8)
{
translate([2.45,0,9.8]) make_line_of(3.5, n) LOETPIN(height = 13, dim = 1);
}
}
}
module AK500(n=4, Library="con-ptr500")
{
if (Library=="con-ptr500")
{
difference()
{
union()
{
color("LimeGreen") translate([0,0.7,0]) cubepart([n*5,7.6,7.2]);
color("LimeGreen") translate([-n*5/2,-7.6/2+0.7+3,7.2]) linear_extrude(3.1, scale=[1,0.70]) translate([0,-3,0]) square([n*5,7.6]);
}
translate([-((n-1) * 5.00)/2,0,8]) make_line_of(5.00, n) cylinder(4,3.5/2,3.5/2);
translate([-((n-1) * 5.00)/2-2,-5,1]) make_line_of(5.00, n) cube([4,4,5]);
}
translate([-((n-1) * 5.00)/2,0,4]) make_line_of(5.00, n) LOETPIN(height = 4+3, dim = 1);
}
}
module MSTBV(n = 4, Library="")
{
if (Library=="con-phoenix-508")
{
rotate([0,0,180]) union()
{
color("LimeGreen")
translate([-((n) * 5.08)/2,-3.8,0])
{
translate([-1,-0.5,12-2]) cube([n*5.08+2,0.5,1]);
intersection()
{
translate([-1,0,-1]) cube([n*5.08+2,8.5,12]);
difference()
{
union()
{
translate([-1,0,0]) cube([n*5.08+2,6.0,12]);
translate([5.08/2,4,0.1]) make_line_of(5.08, n) cylinder(12,4,4);
}
translate([5.08/2,4,3]) make_line_of(5.08, n) cylinder(12.0,3,3);
translate([-5.08/2+2.125,1,3]) cube([(n)*5.08+0.75,4.5,12]);
}
}
}
translate([-((n-1) * 5.08)/2,0,12]) make_line_of(5.08, n) LOETPIN(height = 4+12, dim = 1);
}
MVSTBW508(n = n);
}
else
{ // Weidmüller
// SL 5.08/n/180
rotate([0,0,180]) union()
{
color("Orange") translate([-((n) * 5.08)/2,-3.8,0])
intersection()
{
translate([0,0,-1]) cube([n*5.08,8.5,13]);
difference()
{
union()
{
cube([n*5.08,6.5,12]);
translate([5.08/2,4,0.1]) make_line_of(5.08, n) cylinder(12,4,4);
}
translate([5.08/2,4,3]) make_line_of(5.08, n) cylinder(12.0,3,3);
translate([-5.08/2,1,3]) cube([(1+n)*5.08,4.5,12]);
}
}
translate([-((n-1) * 5.08)/2,0,12]) make_line_of(5.08, n) LOETPIN(height = 4+12, dim = 1);
}
}
}
module MVSTBW508(n = 4)
{
rotate([0,0,0]) union()
{
color("limegreen") translate([-((n) * 5.08)/2,-3.0,12-8.3])
{
cube([n*5.08,6,8.3]);
translate([0,-12.6/2+3,7.4]) difference()
{
cube([n*5.08,12.6,29.5-12]);
translate([-1,-7.4,0])rotate([-15,0,0]) cube([n*5.08+2,4,29.5-12]);
if (Detailgrad > 15)
{
translate([5.08/2,-1,6.5]) make_line_of(5.08, n) mirror([0,1,0]) rotate([90,0,0]) linear_extrude(3.5, scale=[0.6,0.6]) translate([-2,-2]) square([4,7.8]);
}
else
{
translate([5.08/2,-1,6.5]) make_line_of(5.08, n) mirror([0,1,0]) rotate([90,0,0]) cube([4,7.8,3.5], center = true);
}
translate([5.08/2,12.6/2,29.5-12-2]) make_line_of(5.08, n) cylinder(3,1.75,1.75);
}
}
}
}
module BL508(n = 4)
{
union()
{
color("Orange") translate([-((n) * 5.08)/2,-3.0,3.4])
{
cube([n*5.08,6,8.6]);
translate([0,-1,7.4]) difference()
{
cube([n*5.08,15.5,12]);
translate([5.08/2,3,12.1]) make_line_of(5.08, n) mirror([0,0,1]) linear_extrude(3.5, scale=[0.6,0.6]) translate([-2,-2]) square([4,7.8]);
translate([5.08/2,15.6,5]) make_line_of(5.08, n) rotate([90,0,0]) cylinder(3,1.75,1.75);
}
}
}
}
module BL350(n = 4)
{
Raster = 3.5;
rotate([0,0,180]) union()
{
color("Orange") translate([-((n) * Raster)/2,-2.9,3.7])
{
cube([n*Raster,5.8,8.6]);
translate([0,-6.1+1.5,7.4]) difference()
{
cube([n*Raster,13,12]);
translate([0.5+Raster/2,3,12.1]) make_line_of(Raster, n) mirror([0,0,1]) linear_extrude(3.5, scale=[0.6,0.6]) translate([-2,-2]) square([3,5.5]);
translate([Raster/2,15.6,5]) make_line_of(Raster, n) rotate([90,0,0]) cylinder(3,1.75,1.75);
}
}
}
}
// DIL Sockel
module DIL_SOCKEL(n=10,b=7.62)
{
pitch = 2.54;
height = 4.45;
rotate([0,0,-90])
{
make_line_of(b, 2) rotate([0,0,90])
{difference()
{
color("DarkSlateGray") translate([0,b/2,height-3/2]) cube([(n* pitch)/2,3,3], center = true);
translate([-((n-2)*pitch)/4,b/2,1]) make_line_of(2.54, n/2) cylinder(4.1,0.8,0.8, $fn=Detailgrad);
}
translate([-((n-2)*pitch)/4,b/2,0]) make_line_of(2.54, n/2) ROUND_DIL_SOCKET();
}
color("DarkSlateGray") translate([0,((n-2)* pitch)/4,height-4/2]) cube([b,pitch,2], center = true);
color("DarkSlateGray") translate([0,-((n-2)* pitch)/4,height-4/2])
difference() { cube([b,pitch,2], center = true); translate([0,-1.5,-2]) cylinder(4,1,1,$fn=Detailgrad);}
}
}
module DIL(n=10,b=7.62, frustum = 0, Text="")
{
pitch = 2.54;
height = 3.5;
size = [(n* pitch)/2,b-1,height];
if (EnableText && Text!="")
{
color("White") translate([-size[0]/2+1.2,-b/6,5.08-0.5]) linear_extrude(0.6) text(Text,size = b/3);
}
color("DarkSlateGray") difference()
{
translate([0,0,5.08-height]) cubepart(size = [size[0],size[1],size[2]], phase = 0, r = 0, frustum = frustum);
translate([-size[0]/2,0,5.08-1]) cylinder(2,1,1);
}
// make_line_of(2.54, n/2)
color("Silver") translate([-((n-2)*pitch)/4,b/2-0.75,6.08-height]) make_line_of(2.54, n/2)
{
rotate([0,0,180]) BendedRectangle(Dim=[0.5,1.4], r=0.75);
translate([-0.7,0.5,-2.2]) cube([1.4,0.5,2.2]);
translate([-0.3,0.5,-5]) cube([0.6,0.5,5]);
}
rotate([0,0,180]) color("Silver") translate([-((n-2)*pitch)/4,b/2-0.75,6.08-height]) make_line_of(2.54, n/2)
{
rotate([0,0,180]) BendedRectangle(Dim=[0.5,1.4], r=0.75);
translate([-0.7,0.5,-2.2]) cube([1.4,0.5,2.2]);
translate([-0.3,0.5,-5]) cube([0.6,0.5,5]);
}
}
module ROUND_DIL_SOCKET()
{
height = 4.5;
color ("silver") translate([0,0,height]) rotate([180,0,0]) difference() {
union()
{ cylinder(0.7,1,1, $fn=Detailgrad);
cylinder(4.1,0.8,0.8, $fn=Detailgrad);
translate([0,0,4.1]) cylinder(0.5,0.8,0.245, $fn=Detailgrad);
cylinder(7.155,0.245,0.245, $fn=Detailgrad);
translate([0,0,7.155]) sphere(0.245, $fn=Detailgrad);
}
translate([0,0,-0.1]) cylinder(0.5,0.8,0.49/2, $fn=Detailgrad);
}
}
module LOETPIN(height = 6, dim = 0.6, rnd = false, displacement=0)
{
color("Silver")
{
if (Detailgrad > 40)
{
if (rnd)
{
translate([0,0,-height+dim/2]) cylinder(height-dim,dim/2,dim/2, $fn = Detailgrad);
translate([0,0,-(dim/2)]) sphere(dim/2,$fn = Detailgrad);
translate([0,0,-(height-dim/2)]) sphere(dim/2,$fn = Detailgrad);
}
else
{
translate([0,0,-(height/2)]) cube([dim,dim,height-2*dim], center = true);
translate([0,0,-(dim)])linear_extrude(dim, scale=0.5) translate([-dim/2,-dim/2]) square([dim,dim]);
translate([0,0,-(height-dim)]) mirror([0,0,1]) linear_extrude(dim, scale=0.5) translate([-dim/2,-dim/2]) square([dim,dim]);
}
}
else
{
if (rnd)
{
translate([0,0,-height]) cylinder(height,dim/2,dim/2, $fn = 10);
}
else
{
if (displacement == 0)
{
translate([-dim/2,-dim/2,-height]) cube([dim,dim,height]);
}
else
{
dis = abs(displacement);
translate([-dim/2,-dim/2,-height]) cube([dim,dim,height/2-dis]);
translate([displacement-(dim/2),-dim/2,-height/2+dis]) cube([dim,dim,height/2-dis]);
translate([displacement,dim/2,-height/2+dis]) rotate([90,0,0]) cylinder(dim,dim/2,dim/2);
translate([0,dim/2,-height/2-dis]) rotate([90,0,0]) cylinder(dim,dim/2,dim/2);
translate([0,0,-height/2-dis ]) rotate([0,(dis/displacement)*atan(0.5),0]) translate([-dim/2,-dim/2,0]) cube([dim,dim,sqrt(5*dis*dis)]); // Hildeische Konstante war sin(30-3.435) = tan(30)
}
}
}
if ($children>0)
{
translate([0,0,-height]) children(0);
}
}
}
function rotate_point (coord, angle, zero = [0,0]) =
[
zero[0] + cos (-angle) * (coord[0]-zero[0]) + sin (-angle) * (coord[1]-zero[1]),
zero[1] + cos (-angle) * (coord[1]-zero[1]) - sin (-angle) * (coord[0]-zero[0])
];
function rotate_poly(p, angle, zero = [0,0]) = [
for (i=[0:len(p)-1])
rotate_point(p[i], angle = angle, zero = zero)
];
function pol_zu_kart(polvect) = [
polvect[0]*cos(polvect[1]),
polvect[0]*sin(polvect[1])
];
module make_line_of(pitch, count, center = false)
{
displacement = center ? ((count - 1) * pitch) / 2 : 0;
translate([-displacement,0,0]) for (a = [0 : count - 1]) {
pos = a*pitch;
translate([pos, 0, 0])
children();
}
}
module make_ring_of(radius, count, pie = 360)
{
for (a = [0 : floor(count) - 1]) {
angle = a * pie / floor(count);
translate(radius * [sin(angle), -cos(angle), 0])
rotate([0, 0, angle])
children();
}
}
module cubepart(size = [1,1,1], phase = 0, r = 0, frustum = 0)
{
frust = (Detailgrad > 20) ? frustum : 0;
if (!phase && !frust && !r)
{
translate([-size[0]/2,-size[1]/2,0]) cube(size=[size[0],size[1],size[2]]);
}
else
{
linear_extrude(size[2], scale = 1-(frust/100)) offset_square(size=[size[0]-(2*phase+2*r),size[1]-(2*phase+2*r)], delta = phase, r=r, chamfer=true, center = true);
}
}
module cylinderpart(size = [1,1])
{
cylinder(size[1],size[0]/2,size[0]/2, $fn = Detailgrad);
}
module offset_square(size = [1,1], r = 0, delta = 0, chamfer=false, center = false, $fn = Detailgrad)
{
num = round($fn/4);
plus = delta*0.41425;
function bogen(point=[0,0],aPhase = 0) = [for (i=[0:num], x=i*90/num) [point[0]+r*sin(x+aPhase),point[1]+r*cos(x+aPhase)]];
function poli_round() = concat(bogen([0,0],180),bogen([0,size[1]],-90),bogen([size[0],size[1]],0),bogen([size[0],0],90));
function poli_phase() = concat([[0-delta,0-plus],[0-delta,size[1]+plus],[0-plus,size[1]+delta],[size[0]+plus,size[1]+delta],[size[0]+delta,size[1]+plus],[size[0]+delta,0-plus],[size[0]+plus,-delta],[0-plus,-delta]]);
if (Detailgrad > 15)
{
if (r==0)
{
if (chamfer)
{
if (center)
translate([-size[0]/2,-size[1]/2]) polygon(poli_phase());
else
polygon(poli_phase());
}
else
{
if (center) square([size[0]+2*delta,size[1]+2*delta], center = center);
else
translate([-delta,-delta]) square([size[0]+2*delta,size[1]+2*delta], center = center);
}
}
else
{
if (center)
translate([-size[0]/2,-size[1]/2]) polygon(poli_round());
else
polygon(poli_round());
}
} else
{
if (center) square([size[0]+2*(delta+r),size[1]+2*(delta+r)], center = center);
else
translate([-(delta+r),-(delta+r)]) square([size[0]+2*(delta+r),size[1]+2*(delta+r)], center = center);
}
}
module offset_polygon(points , r = 0, delta = 0, chamfer=false, center = false, $fn = Detailgrad)
{
function bogen(point=[0,0], r = 1 ,phase = 0, winkel = 90, $fn=$fn) = [let(num=abs($fn*winkel/360)) for (i=[0:num], x=i*winkel/num) [point[0]+r*cos(x+phase),point[1]+r*sin(x+phase)]];
// (a[0] != 0) ? atan2(a[1],a[0]) : (a[1]>0) ? 90 : (a[1]<0) ? -90 : 0;
function winkel(a,b=[0,0]) = atan2(a[1]-b[1],a[0]-b[0]);
function Startwinkel(ar,i) = let(k=(i==0) ? len(ar)-1 : i-1) winkel(ar[i],ar[k]);
function Endwinkel(ar,i) = let(j=(i<(len(ar)-1)) ? i+1 : 0) winkel(ar[j],ar[i]);
function Winkellaenge(ar,i) = let(w=Endwinkel(ar,i)-Startwinkel(ar,i)) (w<= -180) ? w+360 : (w>180)? w-360 : w;
function AngleSum(array, i=0, sum=0) = (i==len(array)) ? sum : AngleSum(array, i=i+1, sum=sum) + Winkellaenge(array,i);
n = AngleSum(points);
Winkeloffset = (n < 0) ? -90 : 90;
//echo(n);
function flatten(array) = [ for (a = array) for (b = a) b ] ;
function round_poly(arr) = !(len(arr)>0) ? [] :
flatten([for (i=[0:len(arr)-1]) concat(bogen(point=arr[i], r = r, phase = Startwinkel(arr,i)-Winkeloffset, winkel = Winkellaenge(arr,i),$fn=Detailgrad))]) ;
polygon(round_poly(points));
}
module DGS_105C6(Name="",Value="",Library="OEM-Switch")
{
difference()
{
translate([92.055/2, 73.013/2,0]) color("limegreen") cubepart(size = [92.055,73.013,1.6]);
translate([6.668,68.898,-1]) cylinder(3,1.7,1.7,$fn=$fn); //Hole
translate([6.668,23.178,-1]) cylinder(3,1.7,1.7,$fn=$fn); //Hole
translate([84.773,23.178,-1]) cylinder(3,1.7,1.7,$fn=$fn); //Hole
translate([84.773,68.898,-1]) cylinder(3,1.7,1.7,$fn=$fn); //Hole
}
translate([55.245,38.894,1.6])rotate([0,0,90])KK_172211(Name="U$1",Value="",Library="OEM-Switch");
//translate([38.925,59.817,1.6])LDG_LG4801D(Name="L1",Value="LG-4801D",Library="OEM-Switch");
//translate([68.341875,59.849,1.6])LDG_LG4801D(Name="L2",Value="LG-4801D",Library="OEM-Switch");
//translate([14.446,59.690,1.6])PTG_1841(Name="L3",Value="PTG-1841",Library="OEM-Switch");
//translate([66.6,14,1.6])ES_2_5(Name="C1",Value="",Library="HAutomation_6");
//translate([54.4,13.3,1.6])L_THT_8_10(Name="C4",Value="",Library="HAutomation_6");
//translate([48,13.3,1.6])ES_2_2(Name="C2",Value="",Library="HAutomation_6");
//translate([38.2,13.5,1.6])L_THT_8_10(Name="C4",Value="",Library="HAutomation_6");
//translate([35,19.5,1.6])ES_2_2(Name="C3",Value="",Library="HAutomation_6");
translate([66.040,13.652,1.6])rotate([0,0,180])E3_5_8(Name="C1",Value="",Library="rcl");
translate([49.054,14.446,1.6])ES_1_5(Name="C2",Value="",Library="HAutomation_6");
translate([51.594,23.813,0])rotate([180,0,180])C0603(Name="C3",Value="",Library="rcl");
translate([51.594,25.400,0])rotate([180,0,180])C0603(Name="C4",Value="",Library="rcl");
translate([35.401,19.526,1.6])ES_1_5(Name="C5",Value="",Library="HAutomation_6");
translate([38.925,59.817,1.6])LDG_LG4801D(Name="L1",Value="LG-4801D",Library="OEM-Switch");
translate([68.342,59.849,1.6])LDG_LG4801D(Name="L2",Value="LG-4801D",Library="OEM-Switch");
translate([14.446,59.690,1.6])PTG_1841(Name="L3",Value="PTG-1841",Library="OEM-Switch");
translate([54.848,13.652,1.6])rotate([0,0,90])82114R(Name="L4",Value="82114R",Library="inductors");
translate([38.418,14.208,1.6])rotate([0,0,90])82114R(Name="L5",Value="82114R",Library="inductors");
// SMD
//translate([54,34.7,-0.5]) rotate([0,0,90.000]) cube([26,18,1], center = true);
translate([51.594,26.670,0])rotate([180,0,180])C0603(Name="C6",Value="",Library="rcl");
translate([51.753,27.940,0])rotate([180,0,180])C0603(Name="C7",Value="",Library="rcl");
translate([49.054,28.734,0])rotate([180,0,180])C0603(Name="C8",Value="",Library="rcl");
translate([49.054,32.385,0])rotate([180,0,180])C0603(Name="C9",Value="",Library="rcl");
translate([51.276,30.956,0])rotate([180,0,180])C0603(Name="C10",Value="",Library="rcl");
translate([58.579,32.544,0])rotate([180,0,270])C0603(Name="C11",Value="",Library="rcl");
translate([57.468,32.544,0])rotate([180,0,270])C0603(Name="C12",Value="",Library="rcl");
translate([56.356,32.544,0])rotate([180,0,270])C0603(Name="C13",Value="",Library="rcl");
translate([55.721,28.893,0])rotate([180,0,180])C0603(Name="C14",Value="",Library="rcl");
translate([51.276,39.688,0])rotate([180,0,180])C0603(Name="C15",Value="",Library="rcl");
translate([47.466,41.593,0])rotate([180,0,180])C0603(Name="C16",Value="",Library="rcl");
translate([52.546,43.021,0])rotate([180,0,180])C0603(Name="C17",Value="",Library="rcl");
translate([51.117,37.782,0])rotate([180,0,180])C0603(Name="C18",Value="",Library="rcl");
translate([60.325,37.465,0])rotate([180,0,180])C0603(Name="C19",Value="",Library="rcl");
translate([60.008,39.053,0])rotate([180,0,180])C0603(Name="C20",Value="",Library="rcl");
translate([60.166,40.799,0])rotate([180,0,180])C0603(Name="C21",Value="",Library="rcl");
translate([50.165,45.403,0])rotate([180,0,270])C0603(Name="C22",Value="",Library="rcl");
translate([51.435,45.720,0])rotate([180,0,270])C0603(Name="C23",Value="",Library="rcl");
translate([52.705,45.720,0])rotate([180,0,270])C0603(Name="C24",Value="",Library="rcl");
translate([53.975,45.561,0])rotate([180,0,270])C0603(Name="C25",Value="",Library="rcl");
translate([55.245,45.403,0])rotate([180,0,270])C0603(Name="C26",Value="",Library="rcl");
translate([56.356,45.403,0])rotate([180,0,270])C0603(Name="C27",Value="",Library="rcl");
translate([57.468,45.403,0])rotate([180,0,270])C0603(Name="C28",Value="",Library="rcl");
translate([4.842,62.151,0]) rotate([0,0,90.000]) cube([1.270,2.540,0.035], center = true);
translate([4.842,57.309,0]) rotate([0,0,90.000]) cube([1.270,2.540,0.035], center = true);
translate([25.162,62.548,0]) rotate([0,0,90.000]) cube([1.270,2.540,0.035], center = true);
translate([26.035,64.294,,0]) rotate([0,0,90.000]) cube([1.270,2.540,0.035], center = true);
translate([55.563,64.373,0]) rotate([0,0,90.000]) cube([1.270,2.540,0.035], center = true);
translate([54.610,62.548,0]) rotate([0,0,90.000]) cube([1.270,2.540,0.035], center = true);
translate([54.769,55.483,0]) rotate([0,0,90.000]) cube([1.270,2.540,0.035], center = true);
translate([55.563,57.309,0]) rotate([0,0,90.000]) cube([1.270,2.540,0.035], center = true);
translate([25.082,55.483,0]) rotate([0,0,90.000]) cube([1.270,2.540,0.035], center = true);
translate([25.956,57.229,0]) rotate([0,0,90.000]) cube([1.270,2.540,0.035], center = true);
translate([35.0,55.483-4.2,0]) rotate([0,0,90.000]) cube([1.270,25,0.035], center = true);
translate([68.7,55.483-4.2,0]) rotate([0,0,90.000]) cube([1.270,21,0.035], center = true);
translate([35.0,55.483-9,0]) rotate([0,0,90.000]) cube([1.270,25,0.035], center = true);
translate([68.7,55.483-8,0]) rotate([0,0,90.000]) cube([1.270,21,0.035], center = true);
translate([35.0,55.483-13,0]) rotate([0,0,90.000]) cube([1.270,25,0.035], center = true);
translate([68.7,55.483-12,0]) rotate([0,0,90.000]) cube([1.270,21,0.035], center = true);
translate([35.0,55.483-16.5,0]) rotate([0,0,90.000]) cube([1.270,25,0.035], center = true);
translate([68.7,55.483-16,0]) rotate([0,0,90.000]) cube([1.270,21,0.035], center = true);
translate([35.0,55.483-21,0]) rotate([0,0,90.000]) cube([1.270,25,0.035], center = true);
translate([68.7,55.483-20,0]) rotate([0,0,90.000]) cube([1.270,21,0.035], center = true);
translate([35.0,55.483-25,0]) rotate([0,0,90.000]) cube([1.270,25,0.035], center = true);
translate([35.0,55.483-30,0]) rotate([0,0,90.000]) cube([1.270,25,0.035], center = true);
translate([25,70,1.6]) rotate([0,0,90]) C1206();
translate([50,70,1.6]) rotate([0,0,90]) C1206();
translate([55,70,1.6]) rotate([0,0,90]) C1206();
translate([75.5,70,1.6]) rotate([0,0,90]) C1206();
translate([19.5,68.5,1.6]) rotate([0,0,90]) C1206();
translate([1.5,63.2,1.6]) rotate([0,0,90]) C1206();
translate([4,63.2,1.6]) rotate([0,0,90]) C1206();
//translate([30.639,22.225,1.6])ES_2_2(Name="C5",Value="",Library="HAutomation_6");
translate([43,8,1.6]) SO08(Name="",Value="",Library="");
translate([59.5,8,1.6]) SO08(Name="",Value="",Library="");
translate([81.8,43.5,1.6]) SO08(Name="",Value="",Library="");
translate([70.564,31.353,1.6])HC49_S(Name="Q2",Value="",Library="crystal");
translate([76.517,9.207,1.6])rotate([0,0,90])SPC4077(Name="J1",Value="",Library="con-jack");
}
module SK96_84(Name="",Value="",Library="")
{
SK96_polygon = [[0.0,16.5],[0.75,16.5],[1,16.75],[1.25,16.5],[1.5,16.5],[1.75,16.75],[2.0,16.5],[2.25,16.5],[2.5,16.75],[2.75,16.5],[3.0,16.5],[3.25,16.75],[3.5,16.5],[3.75,16.5],[4.0,16.75],[4.25,16.5],[7.0,16.5],[7.0,19.5],[4.25,19.5],[4.0,19.25],[3.75,19.5],[3.5,19.5],[3.25,19.25],[3.0,19.5],[2.75,19.5],[2.5,19.25],[2.25,19.5],[2.0,19.5],[1.75,19.25],[1.5,19.5],[1.25,19.5],[1.0,19.25],[0.75,19.5],[0.0,19.5],[0.0,27.0],[0.133972,27.5],[0.5,27.866025],[1.0,28.0],[1.5,27.866025],[1.866025,27.5],[2.0,27.0],[2.5,25.0],[2.633972,24.5],[3.0,24.133972],[3.5,24.0],[4.0,24.133972],[4.366025,24.5],[4.5,25.0],[5.0,27.0],[5.133972,27.5],[5.5,27.866025],[6.0,28.0],[6.5,27.866025],[6.866025,27.5],[7.0,27.0],[7.5,25.0],[7.633972,24.5],[8.0,24.133972],[8.5,24.0],[9.0,24.133972],[9.366025,24.5],[9.5,25.0],[10.0,27.0],[10.133972,27.5],[10.5,27.866025],[11.0,28.0],[11.5,27.866025],[11.866025,27.5],[12.0,27.0],[12.5,20.5],[12.633972,20.0],[13.0,19.633972],[13.5,19.5],[14.0,19.633972],[14.366025,20.0],[14.5,20.5],[15.0,27.0],[15.133972,27.5],[15.5,27.866025],[16.0,28.0],[16.5,27.866025],[16.866025,27.5],[17.0,27.0],[17.5,20.5],[17.633972,20.0],[18.0,19.633972],[18.5,19.5],[19.0,19.633972],[19.366025,20.0],[19.5,20.5],[20.0,27.0],[20.133972,27.5],[20.5,27.866025],[21.0,28.0],[21.5,27.866025],[21.866025,27.5],[22.0,27.0],[22.5,20.5],[22.633972,20.0],[23.0,19.633972],[23.5,19.5],[24.0,19.633972],[24.366025,20.0],[24.5,20.5],[25.0,27.0],[25.133972,27.5],[25.5,27.866025],[26.0,28.0],[26.5,27.866025],[26.866025,27.5],[27.0,27.0],[27.5,20.5],[27.633972,20.0],[28.0,19.633972],[28.5,19.5],[29.0,19.633972],[29.366025,20.0],[29.5,20.5],[30.0,27.0],[30.133972,27.5],[30.5,27.866025],[31.0,28.0],[31.5,27.866025],[31.866025,27.5],[32.0,27.0],[32.5,20.5],[32.633972,20.0],[33.0,19.633972],[33.5,19.5],[34.0,19.633972],[34.366025,20.0],[34.5,20.5],[35.0,27.0],[35.133972,27.5],[35.5,27.866025],[36.0,28.0],[36.5,27.866025],[36.866025,27.5],[37.0,27.0],[37.5,20.5],[37.633972,20.0],[38.0,19.633972],[38.5,19.5],[39.0,19.633972],[39.366025,20.0],[39.5,20.5],[40.0,27.0],[40.133972,27.5],[40.5,27.866025],[41.0,28.0],[41.5,27.866025],[41.866025,27.5],[42.0,27.0],[42.5,20.5],[42.633972,20.0],[43.0,19.633972],[43.5,19.5],[44.0,19.633972],[44.366025,20.0],[44.5,20.5],[45.0,27.0],[45.034072,27.258819],[45.133972,27.5],[45.292891,27.707106],[45.5,27.866025],[45.741178,27.965925],[46.0,28.0],[54.0,28.0],[54.5,27.866025],[54.866025,27.5],[55.0,27.0],[54.866025,26.5],[54.5,26.133972],[54.0,26.0],[48.5,26.0],[48.0,25.866025],[47.633972,25.5],[47.5,25.0],[47.633972,24.5],[48.0,24.133972],[48.5,24.0],[54.0,24.0],[54.5,23.866025],[54.866025,23.5],[55.0,23.0],[54.866025,22.5],[54.5,22.133972],[54.0,22.0],[48.5,22.0],[48.0,21.866025],[47.633972,21.5],[47.5,21.0],[47.633972,20.5],[48.0,20.133972],[48.5,20.0],[54.0,20.0],[54.5,19.866025],[54.866025,19.5],[55.0,19.0],[54.866025,18.5],[54.5,18.133972],[54.0,18.0],[48.5,18.0],[48.0,17.866025],[47.633972,17.5],[47.5,17.0],[47.633972,16.5],[48.0,16.133972],[48.5,16.0],[54.0,16.0],[54.5,15.866025],[54.866025,15.5],[55.0,15.0],[54.866025,14.5],[54.5,14.133972],[54.0,14.0],[8.0,14.0],[8.0,0.0],[5.5,0.0],[5.5,0.75],[5.25,1.0],[5.5,1.25],[5.5,1.5],[5.25,1.75],[5.5,2.0],[5.5,2.25],[5.25,2.5],[5.5,2.75],[5.5,3.0],[5.25,3.25],[5.5,3.5],[5.5,3.75],[5.25,4.0],[5.5,4.25],[5.5,7.0],[2.5,7.0],[2.5,4.25],[2.75,4.0],[2.5,3.75],[2.5,3.5],[2.75,3.25],[2.5,3.0],[2.5,2.75],[2.75,2.5],[2.5,2.25],[2.5,2.0],[2.75,1.75],[2.5,1.5],[2.5,1.25],[2.75,1.0],[2.5,0.75],[2.5,0.0],[0.0,0.0]];
color("DarkSlateGray") translate([-84/2,0,0]) rotate([90,0,90]) linear_extrude(84) polygon(SK96_polygon);
}
module BendedPIN(Diameter=0.5,l=2,l2=1, cl="silver")
{
if (Detailgrad > 19)
{
color(cl)
{
rotate([90,0,0]) translate([-2*Diameter,Diameter/4,0]) rotate_extrude(angle=90, $fn=2*Detailgrad) translate([2*Diameter, 0]) circle(Diameter/2,$fn=Detailgrad);
translate([0,0,-l]) cylinder(l+Diameter/4, Diameter/2,Diameter/2,$fn=Detailgrad);
translate([-2*Diameter,0,2*Diameter+Diameter/4]) rotate([90,0,-90]) cylinder(l2,Diameter/2, Diameter/2,$fn=Detailgrad);
}
}
else
{
color(cl)
{
translate([0,0,-l]) cylinder(l+Diameter/4+2*Diameter, Diameter/2,Diameter/2,$fn=Detailgrad);
translate([0,0,2*Diameter+Diameter/4]) rotate([90,0,-90]) cylinder(2*Diameter+l2,Diameter/2, Diameter/2,$fn=Detailgrad);
translate([0,0,2*Diameter+Diameter/4]) sphere(Diameter/2,$fn=Detailgrad);
}
}
}
module BendedSquare(Dim=0.6, r=0.75)
{
if (Detailgrad > 9)
{
color("silver")
{
rotate([90,0,-90]) translate([0,0,-Dim/2]) rotate_extrude(angle=90, convexity=10, $fn=20)
translate([r-(Dim/2), 0]) square([Dim,Dim]);
// translate([0,0,-l+Diameter/4]) cylinder(r=Diameter/2,h=l+Diameter/4,$fn=10);
//translate([-2*Diameter,0,2*Diameter+Diameter/4]) rotate([90,0,-90]) cylinder(r=Diameter/2,h=2* Diameter,$fn=10);
}
} else {InvisiblePart();}
}
module BendedRectangle(Dim=[0.6,0.9], r=0.75)
{
det = (($fn != undef) && ($fn != 0))? $fn : 20;
function bogen(point=[0,0], r = 1 ,phase = 0, winkel = 90, $fn=det) = [let(num=abs($fn*winkel/360)) for (i=[0:num], x=i*winkel/num) [point[0]+r*cos(x+phase),point[1]+r*sin(x+phase)]];
if (Detailgrad > 9)
{
rotate([180,-90,00 ])translate([0,0,-Dim[1]/2]) linear_extrude(Dim[1]) polygon(concat([[0,r+Dim[0]/2]], bogen([0,0],r=r-Dim[0]/2, phase = 90 ,winkel = -90), [[r-Dim[0]/2, 0]] ,bogen([0,0], r=r+Dim[0]/2)));
// rotate([90,0,-90]) translate([0,0,-Dim[1]/2]) rotate_extrude(angle=90, convexity=10, $fn=20) translate([r-(Dim[0]/2), 0]) square(Dim);
} else {InvisiblePart();
}
}
module pipe(matrix = [[0,0,0],[0,0,10]], r = 1, $fn = 20)
{
// rotate_extrude(angle=90, convexity=10) translate([2, 0, 0]) circle(r = r);
bendedpipe();
}
module bendedpipe(start = [5,0,0], ziel = [0,0,10], alpha = 25, beta = 100, $fn = 50, r = 1)
{
angle = (beta-alpha);
c = sqrt(pow((ziel[0]-start[0]),2) + pow((ziel[1]-start[1]),2) + pow((ziel[2]-start[2]),2));
h = (c/2) / sin(angle/2);
//a = c * sin(beta-alpha);
//b = c * cos(beta-alpha);
translate(start)
rotate([0,0,alpha]) translate([-h, 0, 0]) rotate_extrude(angle=angle, convexity=10, $fn = $fn) translate([h, 0, 0]) circle(r = r,$fn = $fn);
}
// EXTERN STL
module I6A4W(Name="",Value="",Library="") {translate([-0.7,0.5,2.3]) rotate([90,0,-90]) import(str(Package_path,"i6a_standard.stl"));}
module _614104150121(Name="",Value="",Library="") {translate([-3.5,-6,4]) rotate([180,0,180]) import(str(Package_path,"WE_61400416021.stl"));}
module _1728307(Name="",Value="",Library="") {translate([-5.73,5.70,0]) rotate([90,0,-90]) color("LimeGreen")import(str(Package_path,"PhoenixContact_1728307.stl"));}
module _1439890(Name="",Value="",Library="") { if (Detailgrad > 15) {translate([0,2.2,0]) rotate([90,0,0]) color("silver") import(str(Package_path,"PhoenixContact_1439890.stl"));} else {translate([0,-2.2,8.50]) rotate([90,00,0]) rotate([0,0,45]) M12_P_SINGLE();translate([0,-0.1,0]) color("DarkSlateGray") cubepart([15,12.5,14]);}} // A-Codiert 90
module _1424180(Name="",Value="",Library="") {if (Detailgrad > 15) {translate([0,-6,8.50]) rotate([270,0,0]) color("DarkSlateGray") import(str(Package_path,"PhoenixContact_1424180.stl"));} else {translate([0,-4.6,8.50]) rotate([90,00,0]) M12_FEMALE_X_CODED_8_TB(); translate([0,-0.75,0]) color("DarkSlateGray") cubepart([15,12.5,14]);}} //X-Codiert 90
module _1432363(Name="",Value="",Library="") {if (Detailgrad > 15) {translate([0,0,2.45]) rotate([90,0,0]) color("DarkSlateGray") import(str(Package_path,"PhoenixContact_1432363.stl"));} else{color("DarkSlateGray") cylinder(18.6,9/2,9/2); } M12_PHOENIX_HULL();} //A-Codiert 180
module _1402457(Name="",Value="",Library="") {if (Detailgrad > 15) {translate([0,0,1.1]) rotate([180,0,0]) color("silver") import(str(Package_path,"PhoenixContact_1402457.stl"));} else{M12_FEMALE_X_CODED_8_TB();} color("silver") M12_PHOENIX_HULL();} //X-Codiert 180
module _1432350(Name="",Value="",Library="") {translate([0,0,1.1]) rotate([90,0,0]) color("silver") import(str(Package_path,"PhoenixContact_1432350.stl"));} //A-Codiert 180
module _1406409(Name="",Value="",Library="") {color("DarkSlateGray") translate([0,0,19.5]) rotate([00,0,0]) import(str(Package_path,"PhoenixContact_1406409.stl"));} // S codiert
module _1406411(Name="",Value="",Library="") {color("DarkSlateGray") translate([0,0,19.5]) rotate([00,0,0]) import(str(Package_path,"PhoenixContact_1406411.stl"));} // T Codiert
module MSTBV4(Name="",Value="",Library="") {color("LimeGreen") { translate([-11.15,-3.8,0.0]) rotate([90,00,270]) import(str(Package_path,"PhoenixContact_1755765.stl"));BL508(4);}}
module AK500_4(Name="",Value="",Library="") {AK500(4);}
module BSH_060_01_F_D_A(Name="",Value="",Library="") { color("Gray") rotate([90,0,0]) import(str(Package_path,"SAMTEC_BSH_060_01_F_D_A.stl"));}
module BTH_060_01_F_D_A(Name="",Value="",Library="") { color("Silver") rotate([90,0,0]) import(str(Package_path,"SAMTEC_BTH_060_01_F_D_A.stl"));}
module MC_5H_38(Name="",Value="",Library="") {color("LimeGreen") { translate([-2*3.81,-3,0.0]) rotate([90,00,270]) import(str(Package_path,"PhoenixContact_1803455.stl"));
translate([-2.6*3.81,-6.4,10.5]) rotate([00,-90,0]) import(str(Package_path,"PhoenixContact_1803604.stl")); }}
module SV_3_5_2(Name="",Value="",Library="") {color("orange") { translate([3.5,3.5,0]) rotate([0,0,180]) import(str(Package_path,"Weidmueller_BL2_SL35.stl"));translate([-3.5,7,21.5]) rotate([0,180,180]) import(str(Package_path,"Weidmueller_BL2_SK35.stl"));}}
module MSTBV2(Name="",Value="",Library="")
{
if (Library=="con-phoenix-508")
{
MSTBV(2,Library);
}
else
{
color("orange")
{ translate([5.5,-4.1,20]) rotate([0,180,0]) import(str(Package_path,"Weidmueller_BL2_SK508.stl"));
}
MSTBV(2,Library);
}
}
module LPHT_04_24_X_RTX_ALIGNT(Name="",Value="",Library="") //U3 LPHT-04-24-X-RTXLPHT-04-24
{
translate([0.15,16.03,4.070]) rotate([00,180,180]) color("DarkSlateGray") import(str(Package_path,"LPHT_04_24_L_RT1_GP.stl"));
}
module LPHS_04_24_X_VP1_GP(Name="",Value="",Library="") // 70_2990()
{
translate([18.96,00,0]) rotate([90,0,00]) color("DarkSlateGray") import(str(Package_path,"LPHS_04_24_L_VP1_GP.stl"));
}
//module SL_3_5_4(Name="",Value="",Library="") {
//translate([7,-1,0]) rotate([90,00,180]) color("Orange") import("Weidmueller_SL3,5_4.stl"));
//}
module AK300_2(Name="",Value="",Library=""){translate([0.02,4.13,13.7]) rotate([32.65,0,180]) import(str(Package_path,"AK3002.stl"));}
module HFLEX_P10_2(Name="",Value="",Library="") {translate([0,0,1.6]) rotate([0,0,-90]) import(str(Package_path,"HFLEX_P10.stl"));}
module HFLEX_S10_2(Name="",Value="",Library="") {translate([2.5,17,-8.1]) rotate([90,0,0]) import(str(Package_path,"HFLEX_S10.stl"));}
module WLD3343(Name="",Value="",Library="") {translate([-20.7,16.2,-4.9]) rotate([90,0,0]) import(str(Package_path,"WLD3343.stl"));}
module _7499111447(Name="",Value="",Library="") {translate([0,0.2,6.7]) rotate([180,0,0]) import(str(Package_path,"WE_7499111447.stl"));} // RJ45
module 43045_0812(Name="",Value="",Library="") {translate([0,1.5,4.7]) import(str(Package_path,"Molex_43045_0813.stl"));}
module MICROFITS4(Name="",Value="",Library="") {translate([0,0,4.7]) import(str(Package_path,"Molex_43045_0412.stl"));}
module _1437012(Name="",Value="",Library="") {translate([0,-6.3,8.5]) rotate([180,0,0]) import(str(Package_path,"PhoenixContact_1437012.stl"));}
module _693072010801(Name="",Value="",Library="") {translate([4.5,2.8,0]) rotate([0,0,180]) import(str(Package_path,"WE_693072010801a.stl"));
translate([-2.1,-3.95,0]) cube([13.2,13.5,1]);}
module _629722000214(Name="",Value="",Library="") {translate([0.0,2.15,1.55]) import(str(Package_path,"629722000214.stl"));}
module JLEAD(Name="",Value="",Library="") {color("DarkSlateGray")
{
//rotate([90,0,0]) import("/bcm_jlead.stl"));
cubepart(size = [22,32.5,6.73]);
}}
// COLOR TOOL
function LEDCOLOR(string) =
!is_string(string)?
undef
: (contains(string , "red",true) || contains(string , "rd",true) || contains(string , "rot",true) || contains(string , "rt",true)) ?
"#FF2000"
: (contains(string , "black",true) || contains(string , "bk",true) || contains(string , "sw",true)|| contains(string , "gelb",true)) ?
"DarkSlateGray"
: (contains(string , "blue",true) || contains(string , "bl",true) || contains(string , "bu",true)|| contains(string , "blau",true)) ?
"Blue"
: (contains(string , "yellow",true) || contains(string , "ye",true) || contains(string , "ge",true)|| contains(string , "gelb",true)) ?
"Yellow"
: (contains(string , "white",true) || contains(string , "wh",true) || contains(string , "ws",true)|| contains(string , "wei",true)) ?
"MintCream"
: (contains(string , "or",true)) ?
"#FF8000"
: "Lime";
// MM TOOL
function StrToMMdef(string, def = 10) =
!is_string(string)?
def
: !contains(string, "mm", ignore_case=true)?
def
: parse_int(substring(string, 0, index_of(string,"mm",0,ignore_case=true)[0]), base=10, i=0, nb=def) ;
// STRING TOOLS
_ASCII_SPACE = 32;
_ASCII_LOWER_A = 97;
_ASCII_LOWER_Z = _ASCII_LOWER_A + 25;
_ASCII = "\t\n\r !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~";
_ASCII_CODE = concat(9,10,13, [for(i=[_ASCII_SPACE : _ASCII_LOWER_Z+4]) i]);
function ascii_code(string) =
!is_string(string)?
undef
:
[for (result = search(string, _ASCII, 0))
result == undef?
undef
:
_ASCII_CODE[result[0]]
]
;
function join(strings, delimeter="") =
strings == undef?
undef
: strings == []?
""
: _join(strings, len(strings)-1, delimeter);
function _join(strings, index, delimeter) =
index==0 ?
strings[index]
: str(_join(strings, index-1, delimeter), delimeter, strings[index]) ;
function lower(string) =
let(code = ascii_code(string))
join([for (i = [0:len(string)-1])
code[i] >= 65 && code[i] <= 90?
chr(code[i]+97-65)
:
string[i]
]);
function contains(string, substring, ignore_case=false) =
index_of(string, substring, ignore_case=ignore_case) != undef
;
function index_of(string, pattern, pos=0, ignore_case=false) =
pos == undef?
undef
: pos >= len(string)?
undef
: _coalesce_on([pos, _match(string, pattern, pos, ignore_case=ignore_case)],
[pos, undef],
index_of(string, pattern, pos+1, ignore_case=ignore_case))
;
function _coalesce_on(value, error, fallback) =
value == error?
fallback
:
value
;
function _match(string, pattern, pos, ignore_case=false) =
starts_with(string, pattern, pos, ignore_case=ignore_case)?
pos+len(pattern) : undef;
function starts_with(string, start, pos=0, ignore_case=false) =
equals( substring(string, pos, len(start)),
start,
ignore_case=ignore_case);
function equals(this, that, ignore_case=false) =
ignore_case?
lower(this) == lower(that)
:
this==that
;
function substring(string, start, length=undef) =
length == undef?
between(string, start, len(string))
:
between(string, start, length+start)
;
function between(string, start, end) =
string == undef?
undef
: start == undef?
undef
: start > len(string)?
undef
: start < 0?
before(string, end)
: end == undef?
undef
: end < 0?
undef
: end > len(string)?
after(string, start-1)
: start > end?
undef
: start == end ?
""
:
join([for (i=[start:end-1]) string[i]])
;
function after(string, index=0) =
string == undef?
undef
: index == undef?
undef
: index < 0?
string
: index >= len(string)-1?
""
:
join([for (i=[index+1:len(string)-1]) string[i]])
;
function parse_int(string, base=10, i=0, nb=0) =
string[0] == "-" ?
-1*_parse_int(string, base, 1)
:
_parse_int(string, base);
function _parse_int(string, base, i=0, nb=0) =
i == len(string) ?
nb
:
nb + _parse_int(string, base, i+1,
search(string[i],"0123456789ABCDEF")[0]*pow(base,len(string)-i-1));