mirror of
https://github.com/nophead/NopSCADlib.git
synced 2025-08-11 18:04:02 +02:00
Merge branch 'pcremades-master'
This commit is contained in:
3
lib.scad
3
lib.scad
@@ -23,7 +23,7 @@
|
||||
include <core.scad>
|
||||
|
||||
include <vitamins/psus.scad>
|
||||
include <vitamins/pcbs.scad>
|
||||
include <vitamins/displays.scad> // Includes pcbs.scad
|
||||
|
||||
include <vitamins/antennas.scad>
|
||||
include <vitamins/batteries.scad>
|
||||
@@ -34,7 +34,6 @@ include <vitamins/box_sections.scad>
|
||||
include <vitamins/bulldogs.scad>
|
||||
include <vitamins/cameras.scad>
|
||||
include <vitamins/components.scad>
|
||||
include <vitamins/displays.scad>
|
||||
include <vitamins/extrusions.scad>
|
||||
include <vitamins/extrusion_brackets.scad>
|
||||
include <vitamins/fastons.scad>
|
||||
|
BIN
libtest.png
BIN
libtest.png
Binary file not shown.
Before Width: | Height: | Size: 1018 KiB After Width: | Height: | Size: 1022 KiB |
27
readme.md
27
readme.md
@@ -1106,7 +1106,7 @@ LCD displays.
|
||||
| 1 | `display(BigTreeTech_TFT35v3_0)` | BigTreeTech TFT35 v3.0 |
|
||||
| 1 | `display(HDMI5)` | HDMI display 5" |
|
||||
| 1 | `display(TFT128x160)` | LCD TFT ST7735 display 128x160 |
|
||||
| 1 | `display(LCD1602A)` | LCD display 1602A |
|
||||
| 2 | `display(LCD1602A)` | LCD display 1602A |
|
||||
| 1 | `display(LCD2004A)` | LCD display 2004A |
|
||||
| 1 | `display(LCDS7282B)` | LCD display S-7282B |
|
||||
| 1 | `display(SSD1963_4p3)` | LCD display SSD1963 4.3" |
|
||||
@@ -3000,6 +3000,7 @@ PCBs and perfboard with optional components. The shape can be a rectangle with o
|
||||
| 1 | `pcb(EnviroPlus)` | Enviro+ |
|
||||
| 1 | `pcb(ExtruderPCB)` | Extruder connection PCB - not shown |
|
||||
| 1 | `pcb(HW803_1WAY_RELAY)` | HW-803 5V 1 way relay module |
|
||||
| 1 | `pcb(I2C_LCD_Backpack)` | I2C / SPI character LCD backpack |
|
||||
| 1 | `pcb(KY_040)` | KY-040 rotart encoder breakout |
|
||||
| 1 | `pcb(Keyes5p1)` | Keyes5.1 Arduino Uno expansion board - not shown |
|
||||
| 1 | `pcb(L9110S)` | L9110S 2-Channel motor driver module |
|
||||
@@ -3038,11 +3039,12 @@ PCBs and perfboard with optional components. The shape can be a rectangle with o
|
||||
| 4 | `screw(M2_cap_screw, 25)` | Screw M2 cap x 25mm |
|
||||
| 2 | `screw(M2p5_cap_screw, 20)` | Screw M2.5 cap x 20mm |
|
||||
| 8 | `screw(M2p5_cap_screw, 30)` | Screw M2.5 cap x 30mm |
|
||||
| 8 | `screw(M2p5_cap_screw, 35)` | Screw M2.5 cap x 35mm |
|
||||
| 4 | `screw(M2p5_cap_screw, 40)` | Screw M2.5 cap x 40mm |
|
||||
| 4 | `screw(M2p5_cap_screw, 35)` | Screw M2.5 cap x 35mm |
|
||||
| 8 | `screw(M2p5_cap_screw, 40)` | Screw M2.5 cap x 40mm |
|
||||
| 4 | `screw(M2p5_dome_screw, 25)` | Screw M2.5 dome x 25mm |
|
||||
| 4 | `screw(M2p5_pan_screw, 20)` | Screw M2.5 pan x 20mm |
|
||||
| 8 | `screw(M2p5_pan_screw, 30)` | Screw M2.5 pan x 30mm |
|
||||
| 4 | `screw(M2p5_pan_screw, 30)` | Screw M2.5 pan x 30mm |
|
||||
| 4 | `screw(M2p5_pan_screw, 35)` | Screw M2.5 pan x 35mm |
|
||||
| 19 | `screw(M3_cap_screw, 16)` | Screw M3 cap x 16mm |
|
||||
| 13 | `screw(M3_cap_screw, 20)` | Screw M3 cap x 20mm |
|
||||
| 5 | `screw(M3_cap_screw, 25)` | Screw M3 cap x 25mm |
|
||||
@@ -3067,24 +3069,25 @@ PCBs and perfboard with optional components. The shape can be a rectangle with o
|
||||
| Qty | Filename |
|
||||
| ---:|:--- |
|
||||
| 4 | pcb_spacer20100.stl |
|
||||
| 4 | pcb_spacer20150.stl |
|
||||
| 4 | pcb_spacer20160.stl |
|
||||
| 4 | pcb_spacer2070.stl |
|
||||
| 4 | pcb_spacer2080.stl |
|
||||
| 4 | pcb_spacer2090.stl |
|
||||
| 2 | pcb_spacer25110.stl |
|
||||
| 4 | pcb_spacer25140.stl |
|
||||
| 4 | pcb_spacer25180.stl |
|
||||
| 4 | pcb_spacer25150.stl |
|
||||
| 4 | pcb_spacer25190.stl |
|
||||
| 4 | pcb_spacer25200_2.stl |
|
||||
| 4 | pcb_spacer25200.stl |
|
||||
| 4 | pcb_spacer25210_2.stl |
|
||||
| 4 | pcb_spacer25250.stl |
|
||||
| 4 | pcb_spacer25220_2.stl |
|
||||
| 4 | pcb_spacer25260.stl |
|
||||
| 4 | pcb_spacer25270.stl |
|
||||
| 4 | pcb_spacer25280.stl |
|
||||
| 4 | pcb_spacer2580.stl |
|
||||
| 5 | pcb_spacer30130.stl |
|
||||
| 4 | pcb_spacer30220.stl |
|
||||
| 1 | pcb_spacer30130.stl |
|
||||
| 4 | pcb_spacer30140.stl |
|
||||
| 4 | pcb_spacer30230.stl |
|
||||
| 3 | pcb_spacer30240.stl |
|
||||
| 4 | pcb_spacer30240.stl |
|
||||
| 3 | pcb_spacer30250.stl |
|
||||
| 10 | pcb_spacer3050.stl |
|
||||
| 9 | pcb_spacer3060.stl |
|
||||
| 9 | pcb_spacer3070.stl |
|
||||
|
Binary file not shown.
Before Width: | Height: | Size: 70 KiB After Width: | Height: | Size: 68 KiB |
Binary file not shown.
Before Width: | Height: | Size: 237 KiB After Width: | Height: | Size: 234 KiB |
@@ -17,6 +17,8 @@
|
||||
// If not, see <https://www.gnu.org/licenses/>.
|
||||
//
|
||||
|
||||
include <pcbs.scad>
|
||||
|
||||
HDMI5PCB = pcb("", "", [121.11, 77.93, 1.65], hole_d = 2.2, colour = "mediumblue",
|
||||
holes = [[4.6, 4.9], [4.6, -3.73], [97.69, -3.73], [97.69, 4.9]],
|
||||
components = [
|
||||
@@ -46,6 +48,17 @@ LCD1602APCB = pcb("", "", [80, 36, 1.65], hole_d = 2.9, land_d = 5, colour = "gr
|
||||
]
|
||||
);
|
||||
|
||||
LCD1602APCBI2C = pcb("", "", [80, 36, 1.65], hole_d = 2.9, land_d = 5, colour = "green",
|
||||
holes = [[-2.5, -2.5], [-2.5, 2.5], [2.5, 2.5], [2.5, -2.5]],
|
||||
components = [
|
||||
[-27.05, - 2.5, 0, "2p54header", 16, 1],
|
||||
[ -27.05, -10.0, 0, "pcb", 3, I2C_LCD_Backpack],
|
||||
],
|
||||
grid = [
|
||||
52.95 - inch(0.75), 36 - 2.5, 16, 1, silver, inch(0.1), inch(0.1),
|
||||
]
|
||||
);
|
||||
|
||||
LCD1602A = ["LCD1602A", "LCD display 1602A", 71.3, 24.3, 7.0, LCD1602APCB,
|
||||
[0, 0, 0], // pcb offst
|
||||
[[-64.5 / 2, -14.5 / 2], [64.5 / 2, 14.5 / 2, 0.6]], // aperture
|
||||
@@ -54,6 +67,14 @@ LCD1602A = ["LCD1602A", "LCD display 1602A", 71.3, 24.3, 7.0, LCD1602APCB,
|
||||
[], // clearance need for the ts ribbon
|
||||
];
|
||||
|
||||
LCD1602AI2C = ["LCD1602A", "LCD display 1602A", 71.3, 24.3, 7.0, LCD1602APCBI2C,
|
||||
[0, 0, 0], // pcb offst
|
||||
[[-64.5 / 2, -14.5 / 2], [64.5 / 2, 14.5 / 2, 0.6]], // aperture
|
||||
[], // touch screen
|
||||
0, // thread length
|
||||
[], // clearance need for the ts ribbon
|
||||
];
|
||||
|
||||
LCD2004APCB = pcb("", "", [98, 60, 1.65], hole_d = 2.9, land_d = 5, colour = "green",
|
||||
holes = [[-2.5, -2.5], [-2.5, 2.5], [2.5, 2.5], [2.5, -2.5]],
|
||||
components = [
|
||||
@@ -167,6 +188,6 @@ BigTreeTech_TFT35v3_0 = ["BigTreeTech_TFT35v3_0", "BigTreeTech TFT35 v3.0",
|
||||
];
|
||||
|
||||
|
||||
displays = [HDMI5, SSD1963_4p3, LCD2004A, BigTreeTech_TFT35v3_0, LCD1602A, LCDS7282B, TFT128x160];
|
||||
displays = [HDMI5, SSD1963_4p3, LCD2004A, BigTreeTech_TFT35v3_0, LCD1602A, LCD1602AI2C, LCDS7282B, TFT128x160];
|
||||
|
||||
use <display.scad>
|
||||
|
@@ -1097,6 +1097,56 @@ module trimpot10(vertical, cutout = false) { //! Draw a ten turn trimpot
|
||||
}
|
||||
}
|
||||
|
||||
//! Draw a 1/4" square trimpot (https://ar.mouser.com/datasheet/2/54/3362-776956.pdf)
|
||||
module trimpot3362() {
|
||||
l = 6.60;
|
||||
w = 6.99;
|
||||
h = 4.88;
|
||||
foot_w = 0.38;
|
||||
foot_h = 0.38;
|
||||
screw_h = 0;
|
||||
screw_d = 2.25;
|
||||
slot_w = 0.6;
|
||||
slot_h = 0.8;
|
||||
|
||||
module adjust(){
|
||||
d = 2.77;
|
||||
width = 0.64;
|
||||
deep = 0.89;
|
||||
|
||||
color("white"){
|
||||
difference(){
|
||||
cylinder(d=d, h=2*deep, center=true);
|
||||
translate([0, 0, deep-deep/2+0.01])
|
||||
cube([d, width, deep], center=true);
|
||||
translate([0, 0, deep-deep/2+0.01]) rotate([0, 0, 90])
|
||||
cube([d, width, deep], center=true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
color("#2CA1FD") {
|
||||
difference(){
|
||||
translate([0, 0, foot_h / 2 + h / 2])
|
||||
cube([w, l, h - foot_h], center = true);
|
||||
translate_z(h-0.88) hull() adjust();
|
||||
//Grub
|
||||
for(ang=[-30:30:210])
|
||||
rotate([0, 0, ang])
|
||||
translate([2.77/2+0.46, 0, h]) cube([1, 0.3, 0.3], center=true);
|
||||
}
|
||||
|
||||
for(x = [-1, 1], y = [1, -1])
|
||||
translate([x * (w - foot_w) / 2, y * (l - foot_w) / 2, h / 2])
|
||||
cube([foot_w, foot_w, h], center = true);
|
||||
|
||||
for(x = [-1, 1])
|
||||
translate([x*(w/2-1), -l/2, h/2+foot_h/2])
|
||||
cube([0.7, 0.7, h-foot_h], center=true);
|
||||
}
|
||||
translate([0, 0, h-0.89]) adjust();
|
||||
}
|
||||
|
||||
module block(size, colour, makes_cutout, cutouts, r = 0, rtop = 0) //! Draw a coloured cube to represent a random PCB component
|
||||
if(cutouts) {
|
||||
if(makes_cutout)
|
||||
@@ -1181,6 +1231,7 @@ module pcb_component(comp, cutouts = false, angle = undef) { //! Draw pcb compon
|
||||
if(show(comp, "jst_ph")) jst_xh_header(jst_ph_header, comp[4], param(5, false), param(6, false), param(7, undef));
|
||||
if(show(comp, "jst_zh")) jst_xh_header(jst_zh_header, comp[4], param(5, false), param(6, false), param(7, undef));
|
||||
if(show(comp, "potentiometer")) let(pot = param(4, BTT_encoder)) translate_z(pot_size(pot).z) vflip() potentiometer(pot, shaft_length = param(5, undef));
|
||||
if(show(comp, "trimpot3362")) trimpot3362();
|
||||
if(show(comp, "buzzer")) buzzer(param(4, 9), param(5, 12), param(6, grey(20)));
|
||||
if(show(comp, "smd_250V_fuse")) smd_250V_fuse(comp[4], comp[5]);
|
||||
if(show(comp, "smd_res")) smd_resistor(comp[4], comp[5]);
|
||||
|
@@ -1296,11 +1296,28 @@ tiny_buck = pcb("tiny_buck", "Ultra Small 3A buck regulator", [20, 11, 1.6],
|
||||
grid = [inch(0.05), 11 / 2 - inch(0.15), 1, 4, "silver", 0, inch(0.1)]
|
||||
);
|
||||
|
||||
I2C_LCD_Backpack = let(size=[42, 19, 1.2])
|
||||
pcb("I2C_LCD_Backpack", "I2C / SPI character LCD backpack",
|
||||
size = size, //size
|
||||
colour = "black",
|
||||
components = [[size[0]-2, -size[1]/2, 90, "2p54header", 4, 1, false, undef, true],
|
||||
[2, size[1]-8.5, 270, "2p54header", 2, 1, false, false, true],
|
||||
[size[0]/2, size[1]/2, 90, "smd_soic", SOIC16, "PCF8574"],
|
||||
[size[0]*3/4, 11, 0, "trimpot3362"],
|
||||
// Silkscreen
|
||||
[size[0]*3/4+6, size[1]-5.8, 0, "text", 3, 1, "GND", "Liberation Sans:style=Bold"],
|
||||
[size[0]*3/4+6, size[1]-5.8-2.54, 0, "text", 3, 1, "VCC", "Liberation Sans:style=Bold"],
|
||||
[size[0]*3/4+6, size[1]-5.8-2.54*2, 0, "text", 3, 1, "SDA", "Liberation Sans:style=Bold"],
|
||||
[size[0]*3/4+6, size[1]-5.8-2.54*3, 0, "text", 3, 1, "SCL", "Liberation Sans:style=Bold"]
|
||||
],
|
||||
grid = [2, size[1]-2, 16, 1, silver, inch(0.1), inch(0.9)]
|
||||
);
|
||||
|
||||
tiny_pcbs = [ESP_201, ESP_01M, XIAO, ESP_12F, MP1584EN, ESP_01,tiny_buck, LIPO_fuel_gauge, 9DOF_stick];
|
||||
|
||||
big_pcbs = [BTT_RELAY_V1_2, BTT_SKR_MINI_E3_V2_0, BTT_SKR_E3_TURBO, BTT_SKR_V1_4_TURBO, DuetE, Duex5];
|
||||
|
||||
pcbs = [KY_040, TP4056, L9110S, ZC_A0591, RCWL0516, MT3608,RAMPSEndstop, ArduinoNano, HW803_1WAY_RELAY, Feather405, RPI_Pico,
|
||||
pcbs = [KY_040, TP4056, L9110S, ZC_A0591, RCWL0516, MT3608,RAMPSEndstop, ArduinoNano, I2C_LCD_Backpack, HW803_1WAY_RELAY, Feather405, RPI_Pico,
|
||||
ESP32_DOIT_V1, BlackPill, RPI0, EnviroPlus, ArduinoUno3, ArduinoLeonardo, WD2002SJ, OPZ2, PanelDue_v3, RPI3A, RPI3, RPI4];
|
||||
|
||||
pcbs_not_shown = [Melzi, Duex2, PSU12V1A, Keyes5p1, PI_IO, ExtruderPCB];
|
||||
|
Reference in New Issue
Block a user