Added a constructor function for PCBs.
PCB text can now specify a colour. Added SOT23_6, TSOT23_8 and CAP1210 SMD packages. Added ESP-201 Wifi Module PCB. Added ESP12F Wifi module. Added tiny_buck converter PCB. Made 2p54joiner a bit longer. Fixed SOIC gullwing shape. Added Wifi antennas. Added Yunpen filtered IEC mains inlet. Added power jack socket. Added right angle option for LEDs. Added gear_motors. Added 686ZZ and 696ZZ ball bearings. Added two larger box section tubes. Added right angle option to square_buttons. Doesn't draw the frame yet. Added multiwatt11 package for L6203. Added ONS9143A 13A mains socket. Added radial electrolytic capacitors. Added LDE10_20B PSU module. Added screw_tearsink() to make horizontal countersunk holes. Can now have solid tracks on veroboard. Added veroboard_base() module to make an STL for a base with spacers. Corrected M6 spring washer thickness. Can now specify the height of a solder meniscus. slot() now has a center option. Added button_6mm_7 with a taller button. Added default fa, fs and fn constants used for drawing vitamins. These can be set via $default_fa and $default_fs that can also be set by environment variables: NOPSCADLIB_DEFAULT_FA and NOPSCADLIB_DEFAULT_FS.
@@ -49,8 +49,14 @@ squeezed_wall = $preview ? 2 * extrusion_width - layer_height * (1 - PI / 4)
|
||||
|
||||
inf = 1e10; // very big
|
||||
eps = 1/128; // small fudge factor to stop CSG barfing on coincident faces.
|
||||
$fa = 6;
|
||||
$fs = extrusion_width / 2;
|
||||
|
||||
fa = is_undef($vitamin_fa) ? 6 : $vitamin_fa; // Used for drawing vitamins, rather than printing.
|
||||
fs = is_undef($vitamin_fs) ? 0.25 : $vitamin_fs;
|
||||
fn = 32;
|
||||
|
||||
$fa = $fa == 12 ? 6 : $fa; // Defaults for printing
|
||||
$fs = $fs == 2 ? extrusion_width / 2 : $fs;
|
||||
|
||||
|
||||
// Some additional named colours
|
||||
silver = [0.75, 0.75, 0.75];
|
||||
|
3
lib.scad
@@ -25,19 +25,20 @@ include <core.scad>
|
||||
include <vitamins/psus.scad>
|
||||
include <vitamins/pcbs.scad>
|
||||
|
||||
include <vitamins/antennas.scad>
|
||||
include <vitamins/batteries.scad>
|
||||
include <vitamins/bearing_blocks.scad>
|
||||
include <vitamins/blowers.scad>
|
||||
include <vitamins/bldc_motors.scad>
|
||||
include <vitamins/box_sections.scad>
|
||||
include <vitamins/bulldogs.scad>
|
||||
include <vitamins/buttons.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>
|
||||
include <vitamins/gear_motors.scad>
|
||||
include <vitamins/geared_steppers.scad>
|
||||
include <vitamins/hot_ends.scad>
|
||||
include <vitamins/inserts.scad>
|
||||
|
BIN
libtest.png
Before Width: | Height: | Size: 956 KiB After Width: | Height: | Size: 968 KiB |
12
libtest.scad
@@ -42,6 +42,7 @@
|
||||
include <lib.scad>
|
||||
|
||||
use <tests/7_segments.scad>
|
||||
use <tests/antennas.scad>
|
||||
use <tests/ball_bearings.scad>
|
||||
use <tests/batteries.scad>
|
||||
use <tests/bearing_blocks.scad>
|
||||
@@ -65,6 +66,7 @@ use <tests/extrusion_brackets.scad>
|
||||
use <tests/fans.scad>
|
||||
use <tests/fastons.scad>
|
||||
use <tests/fuseholder.scad>
|
||||
use <tests/gear_motors.scad>
|
||||
use <tests/geared_steppers.scad>
|
||||
use <tests/hot_ends.scad>
|
||||
use <tests/IECs.scad>
|
||||
@@ -299,6 +301,9 @@ translate([x0, linear_bearings_y]) {
|
||||
translate([x0, steppers_y])
|
||||
stepper_motors();
|
||||
|
||||
translate([x0 + 400, steppers_y])
|
||||
gear_motors();
|
||||
|
||||
translate([x0, sheets_y])
|
||||
sheets();
|
||||
|
||||
@@ -456,10 +461,10 @@ translate([x2, panel_meters_y])
|
||||
translate([x2, extrusions_y])
|
||||
extrusions();
|
||||
|
||||
translate([400, transformers_y])
|
||||
translate([370, transformers_y])
|
||||
transformers();
|
||||
|
||||
translate([x4 + 50, transformers_y])
|
||||
translate([x4, transformers_y])
|
||||
no_explode() socket_boxes();
|
||||
|
||||
|
||||
@@ -497,6 +502,9 @@ translate([x4, rails_y + 130]) {
|
||||
translate([x4, cable_strip_y])
|
||||
cable_strips();
|
||||
|
||||
translate([x4 + 150, cable_strip_y])
|
||||
antennas();
|
||||
|
||||
translate([x4, kp_pillow_blocks_y])
|
||||
kp_pillow_blocks();
|
||||
|
||||
|
269
readme.md
@@ -22,33 +22,34 @@ A list of changes classified as breaking, additions or fixes is maintained in [C
|
||||
<table><tr>
|
||||
<th align="left"> Vitamins A-H </th><th align="left"> Vitamins I-Q </th><th align="left"> Vitamins R-Z </th><th align="left"> Printed </th><th align="left"> Utilities </th><th align="left"> Core Utilities </th></tr>
|
||||
<tr><td> <a href = "#7_segments">7_segments</a> </td><td> <a href = "#iecs">IECs</a> </td><td> <a href = "#radials">Radials</a> </td><td> <a href = "#box">Box</a> </td><td> <a href = "#annotation">Annotation</a> </td><td> <a href = "#bom">BOM</a> </td></tr>
|
||||
<tr><td> <a href = "#axials">Axials</a> </td><td> <a href = "#inserts">Inserts</a> </td><td> <a href = "#rails">Rails</a> </td><td> <a href = "#butt_box">Butt_box</a> </td><td> <a href = "#bezier">Bezier</a> </td><td> <a href = "#clip">Clip</a> </td></tr>
|
||||
<tr><td> <a href = "#bldc_motors">BLDC_motors</a> </td><td> <a href = "#jack">Jack</a> </td><td> <a href = "#ring_terminals">Ring_terminals</a> </td><td> <a href = "#cable_clip">Cable_clip</a> </td><td> <a href = "#catenary">Catenary</a> </td><td> <a href = "#global">Global</a> </td></tr>
|
||||
<tr><td> <a href = "#ball_bearings">Ball_bearings</a> </td><td> <a href = "#ldrs">LDRs</a> </td><td> <a href = "#rockers">Rockers</a> </td><td> <a href = "#cable_grommets">Cable_grommets</a> </td><td> <a href = "#core_xy">Core_xy</a> </td><td> <a href = "#polyholes">Polyholes</a> </td></tr>
|
||||
<tr><td> <a href = "#batteries">Batteries</a> </td><td> <a href = "#led_meters">LED_meters</a> </td><td> <a href = "#rod">Rod</a> </td><td> <a href = "#camera_housing">Camera_housing</a> </td><td> <a href = "#dogbones">Dogbones</a> </td><td> <a href = "#rounded_rectangle">Rounded_rectangle</a> </td></tr>
|
||||
<tr><td> <a href = "#bearing_blocks">Bearing_blocks</a> </td><td> <a href = "#leds">LEDs</a> </td><td> <a href = "#sbr_rails">SBR_rails</a> </td><td> <a href = "#carriers">Carriers</a> </td><td> <a href = "#fillet">Fillet</a> </td><td> <a href = "#sphere">Sphere</a> </td></tr>
|
||||
<tr><td> <a href = "#belts">Belts</a> </td><td> <a href = "#leadnuts">Leadnuts</a> </td><td> <a href = "#sk_brackets">SK_brackets</a> </td><td> <a href = "#corner_block">Corner_block</a> </td><td> <a href = "#gears">Gears</a> </td><td> <a href = "#teardrops">Teardrops</a> </td></tr>
|
||||
<tr><td> <a href = "#blowers">Blowers</a> </td><td> <a href = "#light_strips">Light_strips</a> </td><td> <a href = "#smds">SMDs</a> </td><td> <a href = "#door_hinge">Door_hinge</a> </td><td> <a href = "#hanging_hole">Hanging_hole</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#box_sections">Box_sections</a> </td><td> <a href = "#linear_bearings">Linear_bearings</a> </td><td> <a href = "#ssrs">SSRs</a> </td><td> <a href = "#door_latch">Door_latch</a> </td><td> <a href = "#horiholes">Horiholes</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#bulldogs">Bulldogs</a> </td><td> <a href = "#magnets">Magnets</a> </td><td> <a href = "#screws">Screws</a> </td><td> <a href = "#drag_chain">Drag_chain</a> </td><td> <a href = "#layout">Layout</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#buttons">Buttons</a> </td><td> <a href = "#mains_sockets">Mains_sockets</a> </td><td> <a href = "#sealing_strip">Sealing_strip</a> </td><td> <a href = "#fan_guard">Fan_guard</a> </td><td> <a href = "#maths">Maths</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#cable_strips">Cable_strips</a> </td><td> <a href = "#microswitches">Microswitches</a> </td><td> <a href = "#servo_motors">Servo_motors</a> </td><td> <a href = "#fixing_block">Fixing_block</a> </td><td> <a href = "#offset">Offset</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#cameras">Cameras</a> </td><td> <a href = "#microview">Microview</a> </td><td> <a href = "#shaft_couplings">Shaft_couplings</a> </td><td> <a href = "#flat_hinge">Flat_hinge</a> </td><td> <a href = "#pcb_utils">PCB_utils</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#circlips">Circlips</a> </td><td> <a href = "#modules">Modules</a> </td><td> <a href = "#sheets">Sheets</a> </td><td> <a href = "#foot">Foot</a> </td><td> <a href = "#quadrant">Quadrant</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#components">Components</a> </td><td> <a href = "#nuts">Nuts</a> </td><td> <a href = "#spades">Spades</a> </td><td> <a href = "#handle">Handle</a> </td><td> <a href = "#round">Round</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#dip">DIP</a> </td><td> <a href = "#o_ring">O_ring</a> </td><td> <a href = "#spools">Spools</a> </td><td> <a href = "#knob">Knob</a> </td><td> <a href = "#rounded_cylinder">Rounded_cylinder</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#d_connectors">D_connectors</a> </td><td> <a href = "#opengrab">Opengrab</a> </td><td> <a href = "#springs">Springs</a> </td><td> <a href = "#led_bezel">LED_bezel</a> </td><td> <a href = "#rounded_polygon">Rounded_polygon</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#displays">Displays</a> </td><td> <a href = "#pcb">PCB</a> </td><td> <a href = "#stepper_motors">Stepper_motors</a> </td><td> <a href = "#pcb_mount">PCB_mount</a> </td><td> <a href = "#rounded_triangle">Rounded_triangle</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#extrusion_brackets">Extrusion_brackets</a> </td><td> <a href = "#pcbs">PCBs</a> </td><td> <a href = "#swiss_clips">Swiss_clips</a> </td><td> <a href = "#psu_shroud">PSU_shroud</a> </td><td> <a href = "#sector">Sector</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#extrusions">Extrusions</a> </td><td> <a href = "#psus">PSUs</a> </td><td> <a href = "#terminals">Terminals</a> </td><td> <a href = "#pocket_handle">Pocket_handle</a> </td><td> <a href = "#sweep">Sweep</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#fans">Fans</a> </td><td> <a href = "#panel_meters">Panel_meters</a> </td><td> <a href = "#toggles">Toggles</a> </td><td> <a href = "#press_fit">Press_fit</a> </td><td> <a href = "#thread">Thread</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#fastons">Fastons</a> </td><td> <a href = "#photo_interrupters">Photo_interrupters</a> </td><td> <a href = "#transformers">Transformers</a> </td><td> <a href = "#printed_box">Printed_box</a> </td><td> <a href = "#tube">Tube</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#fuseholder">Fuseholder</a> </td><td> <a href = "#pillars">Pillars</a> </td><td> <a href = "#tubings">Tubings</a> </td><td> <a href = "#printed_pulleys">Printed_pulleys</a> </td><td></td><td></td></tr>
|
||||
<tr><td> <a href = "#geared_steppers">Geared_steppers</a> </td><td> <a href = "#pillow_blocks">Pillow_blocks</a> </td><td> <a href = "#variacs">Variacs</a> </td><td> <a href = "#ribbon_clamp">Ribbon_clamp</a> </td><td></td><td></td></tr>
|
||||
<tr><td> <a href = "#green_terminals">Green_terminals</a> </td><td> <a href = "#pin_headers">Pin_headers</a> </td><td> <a href = "#veroboard">Veroboard</a> </td><td> <a href = "#ssr_shroud">SSR_shroud</a> </td><td></td><td></td></tr>
|
||||
<tr><td> <a href = "#hot_ends">Hot_ends</a> </td><td> <a href = "#potentiometers">Potentiometers</a> </td><td> <a href = "#washers">Washers</a> </td><td> <a href = "#screw_knob">Screw_knob</a> </td><td></td><td></td></tr>
|
||||
<tr><td> <a href = "#hygrometer">Hygrometer</a> </td><td> <a href = "#pulleys">Pulleys</a> </td><td> <a href = "#wire">Wire</a> </td><td> <a href = "#socket_box">Socket_box</a> </td><td></td><td></td></tr>
|
||||
<tr><td></td><td></td><td> <a href = "#zipties">Zipties</a> </td><td> <a href = "#strap_handle">Strap_handle</a> </td><td></td><td></td></tr>
|
||||
<tr><td> <a href = "#antennas">Antennas</a> </td><td> <a href = "#inserts">Inserts</a> </td><td> <a href = "#rails">Rails</a> </td><td> <a href = "#butt_box">Butt_box</a> </td><td> <a href = "#bezier">Bezier</a> </td><td> <a href = "#clip">Clip</a> </td></tr>
|
||||
<tr><td> <a href = "#axials">Axials</a> </td><td> <a href = "#jack">Jack</a> </td><td> <a href = "#ring_terminals">Ring_terminals</a> </td><td> <a href = "#cable_clip">Cable_clip</a> </td><td> <a href = "#catenary">Catenary</a> </td><td> <a href = "#global">Global</a> </td></tr>
|
||||
<tr><td> <a href = "#bldc_motors">BLDC_motors</a> </td><td> <a href = "#ldrs">LDRs</a> </td><td> <a href = "#rockers">Rockers</a> </td><td> <a href = "#cable_grommets">Cable_grommets</a> </td><td> <a href = "#core_xy">Core_xy</a> </td><td> <a href = "#polyholes">Polyholes</a> </td></tr>
|
||||
<tr><td> <a href = "#ball_bearings">Ball_bearings</a> </td><td> <a href = "#led_meters">LED_meters</a> </td><td> <a href = "#rod">Rod</a> </td><td> <a href = "#camera_housing">Camera_housing</a> </td><td> <a href = "#dogbones">Dogbones</a> </td><td> <a href = "#rounded_rectangle">Rounded_rectangle</a> </td></tr>
|
||||
<tr><td> <a href = "#batteries">Batteries</a> </td><td> <a href = "#leds">LEDs</a> </td><td> <a href = "#sbr_rails">SBR_rails</a> </td><td> <a href = "#carriers">Carriers</a> </td><td> <a href = "#fillet">Fillet</a> </td><td> <a href = "#sphere">Sphere</a> </td></tr>
|
||||
<tr><td> <a href = "#bearing_blocks">Bearing_blocks</a> </td><td> <a href = "#leadnuts">Leadnuts</a> </td><td> <a href = "#sk_brackets">SK_brackets</a> </td><td> <a href = "#corner_block">Corner_block</a> </td><td> <a href = "#gears">Gears</a> </td><td> <a href = "#teardrops">Teardrops</a> </td></tr>
|
||||
<tr><td> <a href = "#belts">Belts</a> </td><td> <a href = "#light_strips">Light_strips</a> </td><td> <a href = "#smds">SMDs</a> </td><td> <a href = "#door_hinge">Door_hinge</a> </td><td> <a href = "#hanging_hole">Hanging_hole</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#blowers">Blowers</a> </td><td> <a href = "#linear_bearings">Linear_bearings</a> </td><td> <a href = "#ssrs">SSRs</a> </td><td> <a href = "#door_latch">Door_latch</a> </td><td> <a href = "#horiholes">Horiholes</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#box_sections">Box_sections</a> </td><td> <a href = "#magnets">Magnets</a> </td><td> <a href = "#screws">Screws</a> </td><td> <a href = "#drag_chain">Drag_chain</a> </td><td> <a href = "#layout">Layout</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#bulldogs">Bulldogs</a> </td><td> <a href = "#mains_sockets">Mains_sockets</a> </td><td> <a href = "#sealing_strip">Sealing_strip</a> </td><td> <a href = "#fan_guard">Fan_guard</a> </td><td> <a href = "#maths">Maths</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#buttons">Buttons</a> </td><td> <a href = "#microswitches">Microswitches</a> </td><td> <a href = "#servo_motors">Servo_motors</a> </td><td> <a href = "#fixing_block">Fixing_block</a> </td><td> <a href = "#offset">Offset</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#cable_strips">Cable_strips</a> </td><td> <a href = "#microview">Microview</a> </td><td> <a href = "#shaft_couplings">Shaft_couplings</a> </td><td> <a href = "#flat_hinge">Flat_hinge</a> </td><td> <a href = "#pcb_utils">PCB_utils</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#cameras">Cameras</a> </td><td> <a href = "#modules">Modules</a> </td><td> <a href = "#sheets">Sheets</a> </td><td> <a href = "#foot">Foot</a> </td><td> <a href = "#quadrant">Quadrant</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#circlips">Circlips</a> </td><td> <a href = "#nuts">Nuts</a> </td><td> <a href = "#spades">Spades</a> </td><td> <a href = "#handle">Handle</a> </td><td> <a href = "#round">Round</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#components">Components</a> </td><td> <a href = "#o_ring">O_ring</a> </td><td> <a href = "#spools">Spools</a> </td><td> <a href = "#knob">Knob</a> </td><td> <a href = "#rounded_cylinder">Rounded_cylinder</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#dip">DIP</a> </td><td> <a href = "#opengrab">Opengrab</a> </td><td> <a href = "#springs">Springs</a> </td><td> <a href = "#led_bezel">LED_bezel</a> </td><td> <a href = "#rounded_polygon">Rounded_polygon</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#d_connectors">D_connectors</a> </td><td> <a href = "#pcb">PCB</a> </td><td> <a href = "#stepper_motors">Stepper_motors</a> </td><td> <a href = "#pcb_mount">PCB_mount</a> </td><td> <a href = "#rounded_triangle">Rounded_triangle</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#displays">Displays</a> </td><td> <a href = "#pcbs">PCBs</a> </td><td> <a href = "#swiss_clips">Swiss_clips</a> </td><td> <a href = "#psu_shroud">PSU_shroud</a> </td><td> <a href = "#sector">Sector</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#extrusion_brackets">Extrusion_brackets</a> </td><td> <a href = "#psus">PSUs</a> </td><td> <a href = "#terminals">Terminals</a> </td><td> <a href = "#pocket_handle">Pocket_handle</a> </td><td> <a href = "#sweep">Sweep</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#extrusions">Extrusions</a> </td><td> <a href = "#panel_meters">Panel_meters</a> </td><td> <a href = "#toggles">Toggles</a> </td><td> <a href = "#press_fit">Press_fit</a> </td><td> <a href = "#thread">Thread</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#fans">Fans</a> </td><td> <a href = "#photo_interrupters">Photo_interrupters</a> </td><td> <a href = "#transformers">Transformers</a> </td><td> <a href = "#printed_box">Printed_box</a> </td><td> <a href = "#tube">Tube</a> </td><td></td></tr>
|
||||
<tr><td> <a href = "#fastons">Fastons</a> </td><td> <a href = "#pillars">Pillars</a> </td><td> <a href = "#tubings">Tubings</a> </td><td> <a href = "#printed_pulleys">Printed_pulleys</a> </td><td></td><td></td></tr>
|
||||
<tr><td> <a href = "#fuseholder">Fuseholder</a> </td><td> <a href = "#pillow_blocks">Pillow_blocks</a> </td><td> <a href = "#variacs">Variacs</a> </td><td> <a href = "#ribbon_clamp">Ribbon_clamp</a> </td><td></td><td></td></tr>
|
||||
<tr><td> <a href = "#gear_motors">Gear_motors</a> </td><td> <a href = "#pin_headers">Pin_headers</a> </td><td> <a href = "#veroboard">Veroboard</a> </td><td> <a href = "#ssr_shroud">SSR_shroud</a> </td><td></td><td></td></tr>
|
||||
<tr><td> <a href = "#geared_steppers">Geared_steppers</a> </td><td> <a href = "#potentiometers">Potentiometers</a> </td><td> <a href = "#washers">Washers</a> </td><td> <a href = "#screw_knob">Screw_knob</a> </td><td></td><td></td></tr>
|
||||
<tr><td> <a href = "#green_terminals">Green_terminals</a> </td><td> <a href = "#pulleys">Pulleys</a> </td><td> <a href = "#wire">Wire</a> </td><td> <a href = "#socket_box">Socket_box</a> </td><td></td><td></td></tr>
|
||||
<tr><td> <a href = "#hot_ends">Hot_ends</a> </td><td></td><td> <a href = "#zipties">Zipties</a> </td><td> <a href = "#strap_handle">Strap_handle</a> </td><td></td><td></td></tr>
|
||||
<tr><td> <a href = "#hygrometer">Hygrometer</a> </td><td></td><td></td><td></td><td></td><td></td></tr>
|
||||
</table>
|
||||
|
||||
---
|
||||
@@ -82,6 +83,53 @@ Presence of a decimal point is determined by the number of pins. Its position is
|
||||

|
||||
|
||||
|
||||
<a href="#top">Top</a>
|
||||
|
||||
---
|
||||
<a name="antennas"></a>
|
||||
## Antennas
|
||||
Wifi Antennas
|
||||
|
||||
[vitamins/antennas.scad](vitamins/antennas.scad) Object definitions.
|
||||
|
||||
[vitamins/antenna.scad](vitamins/antenna.scad) Implementation.
|
||||
|
||||
[tests/antennas.scad](tests/antennas.scad) Code for this example.
|
||||
|
||||
### Properties
|
||||
| Function | Description |
|
||||
|:--- |:--- |
|
||||
| `antenna_bot_d(type)` | Diameter at the base |
|
||||
| `antenna_gap(type)` | Space for left panel, washers and nuts when screwed on fully. |
|
||||
| `antenna_grip(type)` | Grip d, h, h2 |
|
||||
| `antenna_hinge(type)` | Hinge post width, z value of the pin, pin diameter, width reduction and slot width |
|
||||
| `antenna_length(type)` | Total length |
|
||||
| `antenna_rings(type)` | List of ring z, thickness, depths |
|
||||
| `antenna_split(type)` | Split point |
|
||||
| `antenna_straight(type)` | Length of the straight part |
|
||||
| `antenna_top_d(type)` | Diameter at the top |
|
||||
|
||||
### Functions
|
||||
| Function | Description |
|
||||
|:--- |:--- |
|
||||
| `antenna_hole_r(type)` | Panel hole radius |
|
||||
| `antenna_nut(type)` | The nut |
|
||||
|
||||
### Modules
|
||||
| Module | Description |
|
||||
|:--- |:--- |
|
||||
| `antenna(type, thickness, angle)` | Draw a WiFi antenna |
|
||||
|
||||

|
||||
|
||||
### Vitamins
|
||||
| Qty | Module call | BOM entry |
|
||||
| ---:|:--- |:---|
|
||||
| 1 | `antenna(ESP201_antenna)` | Antenna ESP201 |
|
||||
| 1 | `nut(ant_nut)` | Nut M6.25 x 1.8mm |
|
||||
| 1 | `star_washer(ant_washer_washer)` | Washer star M6.4 x 0.6mm |
|
||||
|
||||
|
||||
<a href="#top">Top</a>
|
||||
|
||||
---
|
||||
@@ -182,6 +230,8 @@ Also single bearing balls are modelled as just a silver sphere and a BOM entry.
|
||||
| 1 | `ball_bearing(BB6201)` | Ball bearing 6201-2RS 12mm x 32mm x 10mm |
|
||||
| 1 | `ball_bearing(BB624)` | Ball bearing 624-2RS 4mm x 13mm x 5mm |
|
||||
| 1 | `ball_bearing(BB6808)` | Ball bearing 6808-2RS 40mm x 52mm x 7mm |
|
||||
| 1 | `ball_bearing(BB686)` | Ball bearing 686ZZ 6mm x 13mm x 5mm |
|
||||
| 1 | `ball_bearing(BB696)` | Ball bearing 696ZZ 6mm x 16mm x 5mm |
|
||||
| 1 | `ball_bearing(BBF623)` | Ball bearing F623-2RS 3mm x 10mm x 4mm |
|
||||
| 1 | `ball_bearing(BBF693)` | Ball bearing F693ZZ 3mm x 8mm x 3mm |
|
||||
| 1 | `ball_bearing(BBF695)` | Ball bearing F695ZZ 5mm x 13mm x 4mm |
|
||||
@@ -189,7 +239,7 @@ Also single bearing balls are modelled as just a silver sphere and a BOM entry.
|
||||
| 1 | `ball_bearing(BBMR83)` | Ball bearing MR83ZZ 3mm x 8mm x 3mm |
|
||||
| 1 | `ball_bearing(BBMR93)` | Ball bearing MR93ZZ 3mm x 9mm x 4mm |
|
||||
| 1 | `ball_bearing(BBSMR95)` | Ball bearing SMR95ZZ 5mm x 9mm x 2.5mm |
|
||||
| 5 | ` bearing_ball(3)` | Steel ball 3mm |
|
||||
| 7 | ` bearing_ball(3)` | Steel ball 3mm |
|
||||
|
||||
|
||||
<a href="#top">Top</a>
|
||||
@@ -571,7 +621,9 @@ Box sections.
|
||||
| Qty | Module call | BOM entry |
|
||||
| ---:|:--- |:---|
|
||||
| 1 | `box_section(AL12x8x1, 100)` | Aluminium rectangular box section 12mm x 8mm x 1mm, length 100mm |
|
||||
| 1 | `box_section(AL20x20x2, 100)` | Aluminium rectangular box section 20mm x 20mm x 2mm, length 100mm |
|
||||
| 1 | `box_section(AL20x20x2, 80)` | Aluminium rectangular box section 20mm x 20mm x 2mm, length 80mm |
|
||||
| 1 | `box_section(AL38p1x25p4x1p6, 60)` | Aluminium rectangular box section 38.1mm x 25.4mm x 1.6mm, length 60mm |
|
||||
| 1 | `box_section(AL50p8x38p1x3, 40)` | Aluminium rectangular box section 50.8mm x 38.1mm x 3.0mm, length 40mm |
|
||||
| 1 | `box_section(CF10x10x1, 100)` | Carbon fiber rectangular box section 10mm x 10mm x 1mm, length 100mm |
|
||||
|
||||
|
||||
@@ -639,6 +691,7 @@ PCB mounted buttons. Can optionally have a coloured cap
|
||||
| `square_button_d(type)` | Button diameter |
|
||||
| `square_button_h(type)` | Height of the button above the PCB |
|
||||
| `square_button_height(type)` | Height of the base |
|
||||
| `square_button_ra_z(type)` | Height of button centre above the PCB for right_angle version |
|
||||
| `square_button_rivit(type)` | Size of the corner rivets |
|
||||
| `square_button_wall(type)` | Offset of the metal part |
|
||||
| `square_button_width(type)` | Width and depth of the base |
|
||||
@@ -646,7 +699,7 @@ PCB mounted buttons. Can optionally have a coloured cap
|
||||
### Modules
|
||||
| Module | Description |
|
||||
|:--- |:--- |
|
||||
| `square_button(type, colour = "yellow")` | Draw square button with specified cap colour if it has a cap |
|
||||
| `square_button(type, colour = "yellow", right_angle = false)` | Draw square button with specified cap colour if it has a cap |
|
||||
|
||||

|
||||
|
||||
@@ -656,6 +709,7 @@ PCB mounted buttons. Can optionally have a coloured cap
|
||||
| 1 | `square_button(button_12mm, "yellow")` | Square button 12mm with yellow cap |
|
||||
| 1 | `square_button(button_4p5mm)` | Square button 4.5mm |
|
||||
| 1 | `square_button(button_6mm)` | Square button 6mm |
|
||||
| 1 | `square_button(button_6mm_7)` | Square button 6mm |
|
||||
|
||||
|
||||
<a href="#top">Top</a>
|
||||
@@ -853,6 +907,7 @@ Various electronic components used in hot ends and heated beds.
|
||||
| `fack2spm()` | Draw a FACK2SPM Cat5E RJ45 shielded panel mount coupler |
|
||||
| `fack2spm_hole_positions()` | Place children at the FACK2SPM mounting hole positions |
|
||||
| `fack2spm_holes(h = 0)` | Cut the holes for a FACK2SPM |
|
||||
| `multiwatt11(part_no, tail = 3)` | Draw a MULTIWATT11 package |
|
||||
| `panel_USBA()` | Draw a panel mount USBA connector |
|
||||
| `panel_USBA_hole_positions()` | Place children at hole positions |
|
||||
| `panel_USBA_holes(h = 100)` | Make holes for USBA connector |
|
||||
@@ -1303,6 +1358,56 @@ Faston receptacles to mate with spade connectors
|
||||
| 1 | `fuseholder(6)` | Fuse holder 20mm |
|
||||
|
||||
|
||||
<a href="#top">Top</a>
|
||||
|
||||
---
|
||||
<a name="gear_motors"></a>
|
||||
## Gear_motors
|
||||
DC motors with a gearbox
|
||||
|
||||
[vitamins/gear_motors.scad](vitamins/gear_motors.scad) Object definitions.
|
||||
|
||||
[vitamins/gear_motor.scad](vitamins/gear_motor.scad) Implementation.
|
||||
|
||||
[tests/gear_motors.scad](tests/gear_motors.scad) Code for this example.
|
||||
|
||||
### Properties
|
||||
| Function | Description |
|
||||
|:--- |:--- |
|
||||
| `gm_boss(type)` | Motor boss diameter, corner radius, height and colour |
|
||||
| `gm_box(type)` | Size, corner radius, colour |
|
||||
| `gm_holes(type)` | List of hole positions |
|
||||
| `gm_hub(type)` | Motor hub diameter, height, corner rad |
|
||||
| `gm_motor(type)` | Motor position, diameter, height, corner rad and colour |
|
||||
| `gm_motor_boss(type)` | Motor mounting boss on gearbox |
|
||||
| `gm_screw(type)` | Screw type |
|
||||
| `gm_screw_boss(type)` | Screw boss diameter and height |
|
||||
| `gm_screw_depth(type)` | Screw hole depth |
|
||||
| `gm_shaft(type)` | Shaft diameter, flat width, length, flat length. |
|
||||
| `gm_shaft_offset(type)` | Offset of shaft from the centre of the gearbox |
|
||||
| `gm_tags(type)` | Tag size and pitch |
|
||||
|
||||
### Functions
|
||||
| Function | Description |
|
||||
|:--- |:--- |
|
||||
| `gm_box_width(type)` | Gearbox width if rectangular or diameter if round |
|
||||
| `gm_depth(type)` | Motor total depth |
|
||||
| `gm_motor_d(type)` | Motor diameter |
|
||||
| `gm_motor_pos(type)` | Motor position relative to centre of the gearbox |
|
||||
| `gm_shaft_flat_l(type)` | Length of the shaft flat section |
|
||||
| `gm_shaft_flat_w(type)` | Shaft width across the flat |
|
||||
| `gm_shaft_length(type)` | Length of the shaft |
|
||||
| `gm_shaft_pos(type)` | Shaft position |
|
||||
| `gm_shaft_r(type)` | Shaft radius |
|
||||
|
||||
### Modules
|
||||
| Module | Description |
|
||||
|:--- |:--- |
|
||||
| `gear_motor(type, alpha = 1)` | Draw specified gear motor, can be partially transparent to see what is behind it |
|
||||
|
||||

|
||||
|
||||
|
||||
<a href="#top">Top</a>
|
||||
|
||||
---
|
||||
@@ -1522,6 +1627,7 @@ IEC mains inlets and outlet.
|
||||
| `iec_body_r(type)` | Body corner radius |
|
||||
| `iec_body_w(type)` | Body width |
|
||||
| `iec_body_w2(type)` | Body width at the narrow part |
|
||||
| `iec_can(type)` | If it has a can then the width, height, thickness and total width of the metal flange |
|
||||
| `iec_depth(type)` | Depth of the body below the flange |
|
||||
| `iec_flange_h(type)` | Flange height |
|
||||
| `iec_flange_r(type)` | Flange corner radius |
|
||||
@@ -1556,14 +1662,15 @@ IEC mains inlets and outlet.
|
||||
| 1 | `iec(IEC_fused_inlet)` | IEC fused inlet JR-101-1F |
|
||||
| 1 | `iec(IEC_fused_inlet2)` | IEC fused inlet old |
|
||||
| 1 | `iec(IEC_inlet)` | IEC inlet |
|
||||
| 1 | `iec(IEC_yunpen)` | IEC inlet filtered |
|
||||
| 1 | `iec(IEC_inlet_atx)` | IEC inlet for ATX |
|
||||
| 1 | `iec(IEC_outlet)` | IEC outlet RS 811-7193 |
|
||||
| 1 | `iec(IEC_inlet_atx2)` | IEC pressfit inlet for ATX |
|
||||
| 1 | `iec(IEC_320_C14_switched_fused_inlet)` | IEC320 C14 switched fused inlet module |
|
||||
| 12 | `nut(M3_nut, nyloc = true)` | Nut M3 x 2.4mm nyloc |
|
||||
| 14 | `nut(M3_nut, nyloc = true)` | Nut M3 x 2.4mm nyloc |
|
||||
| 4 | `screw(M3_cs_cap_screw, 10)` | Screw M3 cs cap x 10mm |
|
||||
| 8 | `screw(M3_cs_cap_screw, 12)` | Screw M3 cs cap x 12mm |
|
||||
| 12 | `washer(M3_washer)` | Washer M3 x 7mm x 0.5mm |
|
||||
| 10 | `screw(M3_cs_cap_screw, 12)` | Screw M3 cs cap x 12mm |
|
||||
| 14 | `washer(M3_washer)` | Washer M3 x 7mm x 0.5mm |
|
||||
|
||||
|
||||
<a href="#top">Top</a>
|
||||
@@ -1642,6 +1749,7 @@ E.g. a "brown" socket for mains live needs to be displayed as "sienna" to look r
|
||||
| `jack_4mm_shielded_hole_radius()` | Panel hole radius for 4mm shielded jack |
|
||||
| `jack_4mm_shielded_nut_radius()` | Largest diameter of 4mm shielded jack |
|
||||
| `post_4mm_diameter()` | Outer diameter of 4mm binding post |
|
||||
| `power_jack_radius()` | Power jack socket flange radius |
|
||||
|
||||
### Modules
|
||||
| Module | Description |
|
||||
@@ -1651,6 +1759,7 @@ E.g. a "brown" socket for mains live needs to be displayed as "sienna" to look r
|
||||
| `jack_4mm_shielded(colour, thickness, display_colour = false)` | Draw a 4mm shielded jack |
|
||||
| `post_4mm(colour, thickness, display_colour = false)` | Draw a 4mm binding post |
|
||||
| `post_4mm_hole(h = 100, poly = false)` | Drill hole for 4mm binding post |
|
||||
| `power_jack(thickness)` | Draw a power jack socket with nut positioned for specified panel thickness |
|
||||
|
||||

|
||||
|
||||
@@ -1661,6 +1770,7 @@ E.g. a "brown" socket for mains live needs to be displayed as "sienna" to look r
|
||||
| 1 | `jack_4mm("blue", 3, "royalblue")` | 4mm jack socket blue |
|
||||
| 1 | `jack_4mm_plastic("[0.2, 0.2, 0.2]", 3, [0.2, 0.2, 0.2])` | 4mm plastic jack socket [0.2, 0.2, 0.2] |
|
||||
| 1 | `jack_4mm_shielded("brown", 3, "sienna")` | 4mm shielded jack socket brown |
|
||||
| 1 | `power_jack()` | Power jack socket |
|
||||
|
||||
|
||||
<a href="#top">Top</a>
|
||||
@@ -1860,11 +1970,12 @@ Standard domed through hole LEDs. Can specify colour and lead length.
|
||||
| Function | Description |
|
||||
|:--- |:--- |
|
||||
| `led_hole_radius(type)` | Radius of panel hole to accept LED |
|
||||
| `led_radius(type)` | Radius |
|
||||
|
||||
### Modules
|
||||
| Module | Description |
|
||||
|:--- |:--- |
|
||||
| `led(type, colour = "red", lead = 5)` | Draw specified LED with desired colour and led length |
|
||||
| `led(type, colour = "red", lead = 5, right_angle = 0)` | Draw specified LED with desired colour and lead length |
|
||||
|
||||

|
||||
|
||||
@@ -2047,6 +2158,7 @@ UK 13A sockets at the moment.
|
||||
| Function | Description |
|
||||
|:--- |:--- |
|
||||
| `mains_socket_corner(type)` | Corner radius |
|
||||
| `mains_socket_counterbore(type)` | Screw counterbore |
|
||||
| `mains_socket_depth(type)` | Depth at the base |
|
||||
| `mains_socket_height(type)` | Height |
|
||||
| `mains_socket_offset(type)` | Offset of the socket from the centre |
|
||||
@@ -2067,7 +2179,7 @@ UK 13A sockets at the moment.
|
||||
| `mains_socket(type)` | Draw specified 13A socket |
|
||||
| `mains_socket_earth_position(type)` | Position of earth terminal for DiBond panel |
|
||||
| `mains_socket_hole_positions(type)` | Position children at the screw holes |
|
||||
| `mains_socket_holes(type, h = 0)` | Panel cutout |
|
||||
| `mains_socket_holes(type, h = 0, earth = true, small = false)` | Panel cutout |
|
||||
|
||||

|
||||
|
||||
@@ -2075,6 +2187,7 @@ UK 13A sockets at the moment.
|
||||
| Qty | Module call | BOM entry |
|
||||
| ---:|:--- |:---|
|
||||
| 1 | `mains_socket(Contactum)` | Mains socket 13A |
|
||||
| 1 | `mains_socket(PMS9143A)` | Mains socket 13A |
|
||||
| 1 | `mains_socket(MKLOGIC)` | Mains socket 13A, switched |
|
||||
|
||||
|
||||
@@ -2468,6 +2581,7 @@ PCBs and perfboard with optional components. The shape can be a rectangle with o
|
||||
### Functions
|
||||
| Function | Description |
|
||||
|:--- |:--- |
|
||||
| `pcb(name, desc, size, corner_r = 0, hole_d = 0, land_d = 0, colour = "green", parts_on_bom = false, holes = [], components = [], accessories = [], grid = undef, polygon = undef, screw = undef)` | Constructor |
|
||||
| `pcb_component(type, name, index = 0)` | Return the component specified by name and index |
|
||||
| `pcb_component_position(type, name, index = 0)` | Return x y position of specified component |
|
||||
| `pcb_coord(type, p)` | Convert offsets from the edge to coordinates relative to the centre |
|
||||
@@ -2656,6 +2770,7 @@ PCBs and perfboard with optional components. The shape can be a rectangle with o
|
||||
### Functions
|
||||
| Function | Description |
|
||||
|:--- |:--- |
|
||||
| `pcb(name, desc, size, corner_r = 0, hole_d = 0, land_d = 0, colour = "green", parts_on_bom = false, holes = [], components = [], accessories = [], grid = undef, polygon = undef, screw = undef)` | Constructor |
|
||||
| `pcb_component(type, name, index = 0)` | Return the component specified by name and index |
|
||||
| `pcb_component_position(type, name, index = 0)` | Return x y position of specified component |
|
||||
| `pcb_coord(type, p)` | Convert offsets from the edge to coordinates relative to the centre |
|
||||
@@ -2722,6 +2837,8 @@ PCBs and perfboard with optional components. The shape can be a rectangle with o
|
||||
| 1 | `pcb(Duex2)` | Duex2 expansion board - not shown |
|
||||
| 1 | `pcb(Duex5)` | Duex5 expansion board |
|
||||
| 1 | `pcb(ESP-01)` | ESP-01 |
|
||||
| 1 | `pcb(ESP_12F)` | ESP-12F ESP8266 WiFi module |
|
||||
| 1 | `pcb(ESP_201)` | ESP-201 ESP8266 WiFi module |
|
||||
| 1 | `pcb(ESP32_DOIT_V1)` | ESP32 DOIT DEV KIT V1 |
|
||||
| 1 | `pcb(EnviroPlus)` | Enviro+ |
|
||||
| 1 | `pcb(ExtruderPCB)` | Extruder connection PCB - not shown |
|
||||
@@ -2758,17 +2875,16 @@ PCBs and perfboard with optional components. The shape can be a rectangle with o
|
||||
| 1 | `pcb(RPI_Pico)` | Raspberry Pi Pico |
|
||||
| 1 | `pcb(RPI0)` | Raspberry Pi Zero |
|
||||
| 8 | `screw(M2_cap_screw, 16)` | Screw M2 cap x 16mm |
|
||||
| 12 | `screw(M2_cap_screw, 20)` | Screw M2 cap x 20mm |
|
||||
| 2 | `screw(M2p5_cap_screw, 16)` | Screw M2.5 cap x 16mm |
|
||||
| 8 | `screw(M2_cap_screw, 20)` | Screw M2 cap x 20mm |
|
||||
| 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, 25)` | Screw M2.5 cap x 25mm |
|
||||
| 4 | `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_dome_screw, 20)` | Screw M2.5 dome x 20mm |
|
||||
| 12 | `screw(M2p5_cap_screw, 35)` | Screw M2.5 cap x 35mm |
|
||||
| 4 | `screw(M2p5_dome_screw, 25)` | Screw M2.5 dome x 25mm |
|
||||
| 4 | `screw(M2p5_pan_screw, 20)` | Screw M2.5 pan x 20mm |
|
||||
| 4 | `screw(M2p5_pan_screw, 25)` | Screw M2.5 pan x 25mm |
|
||||
| 4 | `screw(M2p5_pan_screw, 30)` | Screw M2.5 pan x 30mm |
|
||||
| 17 | `screw(M3_cap_screw, 16)` | Screw M3 cap x 16mm |
|
||||
| 15 | `screw(M3_cap_screw, 20)` | Screw M3 cap x 20mm |
|
||||
| 8 | `screw(M2p5_pan_screw, 30)` | Screw M2.5 pan x 30mm |
|
||||
| 19 | `screw(M3_cap_screw, 16)` | Screw M3 cap x 16mm |
|
||||
| 13 | `screw(M3_cap_screw, 20)` | Screw M3 cap x 20mm |
|
||||
| 11 | `screw(M3_cap_screw, 30)` | Screw M3 cap x 30mm |
|
||||
| 4 | `screw(M4_cap_screw, 20)` | Screw M4 cap x 20mm |
|
||||
| 4 | `screw(M4_cap_screw, 25)` | Screw M4 cap x 25mm |
|
||||
@@ -2777,6 +2893,7 @@ PCBs and perfboard with optional components. The shape can be a rectangle with o
|
||||
| 3 | `terminal_35(2)` | Terminal block 2 way 3.5mm - not shown |
|
||||
| 2 | `green_terminal(gt_2p54, 4)` | Terminal block 4 way 0.1" - not shown |
|
||||
| 1 | | USB A to Mini B lead - not shown |
|
||||
| 1 | `pcb(tiny_buck)` | Ultra Small 3A buck regulator |
|
||||
| 1 | `pcb(WD2002SJ)` | WD2002SJ Buck Boost DC-DC converter |
|
||||
| 20 | `washer(M2_washer)` | Washer M2 x 5mm x 0.3mm |
|
||||
| 38 | `washer(M2p5_washer)` | Washer M2.5 x 5.9mm x 0.5mm |
|
||||
@@ -2788,27 +2905,27 @@ PCBs and perfboard with optional components. The shape can be a rectangle with o
|
||||
| Qty | Filename |
|
||||
| ---:|:--- |
|
||||
| 4 | pcb_spacer20100.stl |
|
||||
| 4 | pcb_spacer20120.stl |
|
||||
| 4 | pcb_spacer20130.stl |
|
||||
| 4 | pcb_spacer2070.stl |
|
||||
| 4 | pcb_spacer2080.stl |
|
||||
| 4 | pcb_spacer2090.stl |
|
||||
| 4 | pcb_spacer25110.stl |
|
||||
| 4 | pcb_spacer25140.stl |
|
||||
| 4 | pcb_spacer25120.stl |
|
||||
| 4 | pcb_spacer25150.stl |
|
||||
| 4 | pcb_spacer25160_2.stl |
|
||||
| 4 | pcb_spacer25160.stl |
|
||||
| 4 | pcb_spacer25170_2.stl |
|
||||
| 4 | pcb_spacer25210.stl |
|
||||
| 4 | pcb_spacer25180_2.stl |
|
||||
| 4 | pcb_spacer25220.stl |
|
||||
| 4 | pcb_spacer25230.stl |
|
||||
| 2 | pcb_spacer2550.stl |
|
||||
| 4 | pcb_spacer2590.stl |
|
||||
| 4 | pcb_spacer30180.stl |
|
||||
| 4 | pcb_spacer25240.stl |
|
||||
| 4 | pcb_spacer2580.stl |
|
||||
| 2 | pcb_spacer2590.stl |
|
||||
| 4 | pcb_spacer30190.stl |
|
||||
| 3 | pcb_spacer30200.stl |
|
||||
| 8 | pcb_spacer3050.stl |
|
||||
| 4 | pcb_spacer30200.stl |
|
||||
| 3 | pcb_spacer30210.stl |
|
||||
| 10 | pcb_spacer3050.stl |
|
||||
| 9 | pcb_spacer3060.stl |
|
||||
| 7 | pcb_spacer3070.stl |
|
||||
| 8 | pcb_spacer3080.stl |
|
||||
| 9 | pcb_spacer3070.stl |
|
||||
| 4 | pcb_spacer3080.stl |
|
||||
| 4 | pcb_spacer40100.stl |
|
||||
| 4 | pcb_spacer4090.stl |
|
||||
|
||||
@@ -3250,6 +3367,12 @@ Radial components for PCBs.
|
||||
| `rd_disc_lead_d(type)` | Lead diameter and sleeve diameter |
|
||||
| `rd_disc_pitch(type)` | Lead pitch X & Y |
|
||||
| `rd_disc_size(type)` | Diameter, thickness and height |
|
||||
| `rd_electrolytic_colours(type)` | Colour of jacket and stripe |
|
||||
| `rd_electrolytic_crimp(type)` | Width and height of crimp |
|
||||
| `rd_electrolytic_lead_d(type)` | Lead diameter |
|
||||
| `rd_electrolytic_pitch(type)` | Lead pitch |
|
||||
| `rd_electrolytic_radius(type)` | Corner radius |
|
||||
| `rd_electrolytic_size(type)` | Diameter, crimp diameter, height |
|
||||
| `rd_module_colour(type)` | Colour |
|
||||
| `rd_module_kind(type)` | Relay, PSU, etc. |
|
||||
| `rd_module_pin_posns(type)` | list of pin positions |
|
||||
@@ -3269,6 +3392,7 @@ Radial components for PCBs.
|
||||
| Module | Description |
|
||||
|:--- |:--- |
|
||||
| `rd_disc(type, value, pitch = undef, z = 0, tail = 3)` | Draw a radial disc component |
|
||||
| `rd_electrolytic(type, value, pitch = undef, z = 0, tail = 3)` | Draw a radial electrolytic capcacitor |
|
||||
| `rd_module(type, value)` | Draw a PCB mounted potted module, e.g. PSU or relay |
|
||||
| `rd_transistor(type, value, kind = "Transistor", lead_positions = undef, z = 5, tail = 3)` | Draw a radial lead transistor |
|
||||
| `rd_xtal(type, value, z = 0, pitch = undef, tail = 3)` | Draw a crystal |
|
||||
@@ -3284,8 +3408,10 @@ Radial components for PCBs.
|
||||
| 1 | `rd_xtal(C_002RX, "C_002RX")` | Crystal C_002RX C_002RX |
|
||||
| 1 | `rd_xtal(HC49, "HC49")` | Crystal HC49 HC49 |
|
||||
| 1 | `rd_xtal(HC49_4H, "HC49_4H")` | Crystal HC49_4H HC49_4H |
|
||||
| 1 | `rd_electrolytic(ECAP8x12, "220uF35V")` | Electolytic capacitor ECAP8x12 220uF35V |
|
||||
| 1 | `rd_module(LDE10_20B, "12V 900ma")` | PSU LDE10_20B / 12V 900ma |
|
||||
| 1 | `rd_module(VCE03, "12V 250ma")` | PSU VCE03 / 12V 250ma |
|
||||
| 1 | `pcb(PERF70x50)` | Perfboard 70 x 50mm |
|
||||
| 2 | `pcb(PERF70x50)` | Perfboard 70 x 50mm |
|
||||
| 1 | `rd_module(HF33F, "012-HSL3F")` | Relay HF33F / 012-HSL3F |
|
||||
| 1 | `rd_transistor(E_LINE, "ZTX853")` | Transistor E_LINE ZTX853 |
|
||||
| 1 | `rd_transistor(TO92, "BC337")` | Transistor TO92 BC337 |
|
||||
@@ -3639,6 +3765,7 @@ For an explanation of `screw_polysink()` see <https://hydraraptor.blogspot.com/2
|
||||
| `screw_countersink(type, drilled = true)` | Countersink shape |
|
||||
| `screw_keyhole(type, h = 0)` | Make keyhole slot to accept and retain screw head |
|
||||
| `screw_polysink(type, h = 100, alt = false, sink = 0)` | A countersink hole made from stacked polyholes for printed parts, default is flush, `sink` can be used to recess the head |
|
||||
| `screw_tearsink(type)` | Countersink shape for horizontal holes |
|
||||
|
||||

|
||||
|
||||
@@ -4072,6 +4199,7 @@ E.g. 475A is 4.7uF 10V on the parts list.
|
||||
| 1 | `smd_capacitor(CAP0603)` | SMD capacitor 0603 |
|
||||
| 1 | `smd_capacitor(CAP0805)` | SMD capacitor 0805 |
|
||||
| 1 | `smd_capacitor(CAP1206)` | SMD capacitor 1206 |
|
||||
| 1 | `smd_capacitor(CAP1210)` | SMD capacitor 1210 |
|
||||
| 1 | `smd_qfp(QFP50P1200X1200X160_64N)` | SMD chip: ATSAM4S4BA, package : QFP50P1200X1200X160_64N |
|
||||
| 1 | `smd_resistor(L2012C, 10u)` | SMD choke 0805 10u |
|
||||
| 1 | `smd_coax(U_FL_R_SMT_1)` | SMD coax connector type: U_FL_R_SMT_1 |
|
||||
@@ -4086,7 +4214,9 @@ E.g. 475A is 4.7uF 10V on the parts list.
|
||||
| 1 | `smd_soic(SOIC8)` | SOIC8 package SOIC8 |
|
||||
| 1 | `smd_sot(SOT223)` | SOT223 package FZT851 |
|
||||
| 1 | `smd_sot(SOT23)` | SOT23 package 2N7000 |
|
||||
| 1 | `smd_soic(SOT23_6)` | SOT23_6 package SOT23_6 |
|
||||
| 1 | `smd_pot(TC33X1)` | TC33X1 package 10K |
|
||||
| 1 | `smd_soic(TSOT23_8)` | TSOT23_8 package TSOT23_8 |
|
||||
|
||||
|
||||
<a href="#top">Top</a>
|
||||
@@ -4650,12 +4780,13 @@ Veroboard with mounting holes, track breaks, removed tracks, solder points and c
|
||||
| `vero_no_track(type)` | Missing tracks |
|
||||
| `vero_pitch(type)` | Hole pitch |
|
||||
| `vero_screw(type)` | Mounting screw type |
|
||||
| `vero_solid_tracks(type)` | List of solid copper tracks (at the edges of some boards) |
|
||||
| `vero_strips(type)` | Number of strips |
|
||||
|
||||
### Functions
|
||||
| Function | Description |
|
||||
|:--- |:--- |
|
||||
| `vero(name, assembly, holes, strips, pitch = 2.54, fr4 = false, screw = M3_cap_screw, mounting_holes = [], breaks = [], no_tracks = [], components = [], joints = [])` | Constructor |
|
||||
| `vero(name, assembly, holes, strips, pitch = 2.54, fr4 = false, screw = M3_cap_screw, mounting_holes = [], breaks = [], no_tracks = [], components = [], joints = [], solid = [])` | Constructor |
|
||||
| `vero_grid_pos(type, x, y)` | Convert grid position to offset from the centre |
|
||||
| `vero_length(type)` | Length of the board |
|
||||
| `vero_size(type)` | Board size |
|
||||
@@ -4673,6 +4804,7 @@ Veroboard with mounting holes, track breaks, removed tracks, solder points and c
|
||||
| `vero_mounting_holes(type, h = 100)` | Drill mounting holes in a panel |
|
||||
| `veroboard(type)` | Draw specified veroboard with missing tracks and track breaks |
|
||||
| `veroboard_assembly(type, ngb = false)` | Draw the assembly with components |
|
||||
| `veroboard_base(type, height, thickness, wall = 2, tapped = false)` | Generate STL for a base with PCB spacers |
|
||||
| `veroboard_fastened_assembly(type, height, thickness, flip = false, ngb = false)` | Draw the assembly with components and fasteners in place |
|
||||
| `veroboard_fasteners(type, height, thickness, flip = false)` | Draw the fasteners in place |
|
||||
|
||||
@@ -4767,7 +4899,7 @@ If a washer is given a child, usually a screw or a nut, then it is placed on its
|
||||
| 1 | `spring_washer(M3p5_washer)` | Washer spring M3.5 x 1mm |
|
||||
| 1 | `spring_washer(M4_washer)` | Washer spring M4 x 1.2mm |
|
||||
| 1 | `spring_washer(M5_washer)` | Washer spring M5 x 1.6mm |
|
||||
| 1 | `spring_washer(M6_washer)` | Washer spring M6 x 1.6mm |
|
||||
| 1 | `spring_washer(M6_washer)` | Washer spring M6 x 1.9mm |
|
||||
| 1 | `spring_washer(M8_washer)` | Washer spring M8 x 2mm |
|
||||
| 1 | `star_washer(M2_washer)` | Washer star M2 x 0.3mm |
|
||||
| 1 | `star_washer(M2p5_washer)` | Washer star M2.5 x 0.5mm |
|
||||
@@ -6482,26 +6614,29 @@ UK 13A socket and printed backbox with earth terminal for the panel it is mounte
|
||||
### Vitamins
|
||||
| Qty | Module call | BOM entry |
|
||||
| ---:|:--- |:---|
|
||||
| 4 | `insert(F1BM3)` | Heatfit insert M3 x 5.8mm |
|
||||
| 6 | `insert(F1BM3)` | Heatfit insert M3 x 5.8mm |
|
||||
| 1 | `mains_socket(Contactum)` | Mains socket 13A |
|
||||
| 1 | `mains_socket(PMS9143A)` | Mains socket 13A |
|
||||
| 1 | `mains_socket(MKLOGIC)` | Mains socket 13A, switched |
|
||||
| 2 | `nut(M3_nut, nyloc = true)` | Nut M3 x 2.4mm nyloc |
|
||||
| 2 | `ring_terminal(M3_ringterm)` | Ring terminal 3mm |
|
||||
| 4 | `screw(M3_cs_cap_screw, 20)` | Screw M3 cs cap x 20mm |
|
||||
| 2 | `screw(M3_dome_screw, 10)` | Screw M3 dome x 10mm |
|
||||
| 4 | `star_washer(M3_washer)` | Washer star M3 x 0.5mm |
|
||||
| 3 | `nut(M3_nut, nyloc = true)` | Nut M3 x 2.4mm nyloc |
|
||||
| 3 | `ring_terminal(M3_ringterm)` | Ring terminal 3mm |
|
||||
| 6 | `screw(M3_cs_cap_screw, 20)` | Screw M3 cs cap x 20mm |
|
||||
| 3 | `screw(M3_dome_screw, 10)` | Screw M3 dome x 10mm |
|
||||
| 6 | `star_washer(M3_washer)` | Washer star M3 x 0.5mm |
|
||||
|
||||
### Printed
|
||||
| Qty | Filename |
|
||||
| ---:|:--- |
|
||||
| 1 | socket_box_Contactum.stl |
|
||||
| 1 | socket_box_MKLOGIC.stl |
|
||||
| 1 | socket_box_PMS9143A.stl |
|
||||
|
||||
### Assemblies
|
||||
| Qty | Name |
|
||||
| ---:|:--- |
|
||||
| 1 | socket_box_Contactum_assembly |
|
||||
| 1 | socket_box_MKLOGIC_assembly |
|
||||
| 1 | socket_box_PMS9143A_assembly |
|
||||
|
||||
|
||||
<a href="#top">Top</a>
|
||||
@@ -7019,7 +7154,7 @@ Utilities for making PCBs and components
|
||||
|:--- |:--- |
|
||||
| `cylindrical_wrap(r, h = eps)` | Wrap a 2D child extruded to height `h` around a cylinder with radius `r`. |
|
||||
| `solder(ir = 0.3)` | Maybe add solder meniscus if $solder is set |
|
||||
| `solder_meniscus(ir = 0.3, r)` | Draw a solder meniscus |
|
||||
| `solder_meniscus(ir = 0.3, r = 1, h = 0.7)` | Draw a solder meniscus |
|
||||
|
||||

|
||||
|
||||
@@ -7477,7 +7612,7 @@ leaving a scar on either surface.
|
||||
| `poly_drill(r, h = 100, center = true)` | Make a cylinder for drilling holes suitable for CNC routing if cnc_bit_r is non zero, otherwise a poly_cylinder. |
|
||||
| `poly_ring(or, ir, sides = undef)` | Make a 2D ring adjusted to have the correct internal radius |
|
||||
| `poly_tube(or, ir, h, center = false)` | Make a tube adjusted to have the correct internal radius |
|
||||
| `slot(r, l, h = 100)` | Make a horizontal slot suitable for CNC routing, set h = 0 for 2D version |
|
||||
| `slot(r, l, h = 100, center = false)` | Make a horizontal slot suitable for CNC routing, set h = 0 for 2D version |
|
||||
|
||||

|
||||
|
||||
|
@@ -24,7 +24,11 @@ from colorama import Fore, init
|
||||
|
||||
def check_options(dir = '.'):
|
||||
global options, options_mtime
|
||||
options = { "show_threads": str(os.getenv("NOPSCADLIB_SHOW_THREADS")) }
|
||||
options = {
|
||||
"show_threads": str(os.getenv("NOPSCADLIB_SHOW_THREADS")),
|
||||
"vitamin_fa": str(os.getenv("NOPSCADLIB_VITAMIN_FA")),
|
||||
"vitamin_fs": str(os.getenv("NOPSCADLIB_VITAMIN_FS"))
|
||||
}
|
||||
options_fname = dir + '/options.json'
|
||||
try:
|
||||
with open(options_fname) as json_file:
|
||||
|
31
tests/antennas.scad
Normal file
@@ -0,0 +1,31 @@
|
||||
//
|
||||
// NopSCADlib Copyright Chris Palmer 2023
|
||||
// nop.head@gmail.com
|
||||
// hydraraptor.blogspot.com
|
||||
//
|
||||
// This file is part of NopSCADlib.
|
||||
//
|
||||
// NopSCADlib is free software: you can redistribute it and/or modify it under the terms of the
|
||||
// GNU General Public License as published by the Free Software Foundation, either version 3 of
|
||||
// the License, or (at your option) any later version.
|
||||
//
|
||||
// NopSCADlib is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
// without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
// See the GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License along with NopSCADlib.
|
||||
// If not, see <https://www.gnu.org/licenses/>.
|
||||
//
|
||||
include <../core.scad>
|
||||
use <../utils/layout.scad>
|
||||
|
||||
include <../vitamins/antennas.scad>
|
||||
|
||||
module antennas()
|
||||
layout([for(a = antennas) cos(10) * antenna_length(a) ], 5, true) {
|
||||
antenna(antennas[$i], 3, 10);
|
||||
|
||||
}
|
||||
|
||||
if($preview)
|
||||
antennas();
|
@@ -22,20 +22,24 @@ use <../utils/layout.scad>
|
||||
include <../vitamins/ball_bearings.scad>
|
||||
|
||||
|
||||
module do_bearings(list)
|
||||
layout([for(b = list) bb_diameter(b)])
|
||||
ball_bearing(list[$i])
|
||||
if (bb_width(list[$i]) >= 5)
|
||||
bearing_ball(3);
|
||||
module do_bearings(list) {
|
||||
diameters = [for(b = list) bb_diameter(b)];
|
||||
max = max(diameters);
|
||||
layout(diameters) let(b = list[$i])
|
||||
//translate([0, (max - bb_diameter(b)) / 2])
|
||||
ball_bearing(list[$i])
|
||||
if (bb_width(list[$i]) >= 5)
|
||||
bearing_ball(3);
|
||||
}
|
||||
|
||||
module ball_bearings() {
|
||||
small_bearings = [for(b = ball_bearings) if(bb_diameter(b) < 12) b];
|
||||
small_bearings = [for(b = ball_bearings) if(bb_diameter(b) <= 13) b];
|
||||
big_bearings = [for(b = ball_bearings) if(!in(small_bearings, b)) b];
|
||||
|
||||
translate([0, 0])
|
||||
do_bearings(big_bearings);
|
||||
|
||||
translate([0, -20])
|
||||
translate([0, -25])
|
||||
do_bearings(small_bearings);
|
||||
}
|
||||
|
||||
|
@@ -22,8 +22,15 @@ use <../utils/layout.scad>
|
||||
include <../vitamins/box_sections.scad>
|
||||
|
||||
module box_sections() {
|
||||
layout([for(b = box_sections) box_section_size(b).x], 20)
|
||||
box_section(box_sections[$i], 100);
|
||||
woven = [for(b = box_sections) if(box_section_is_woven(b)) b];
|
||||
plain = [for(b = box_sections) if(!box_section_is_woven(b)) b];
|
||||
layout([for(b = woven) box_section_size(b).x * 0], 10)
|
||||
box_section(box_sections[$i], 100 - $i * 20);
|
||||
|
||||
translate([50, 0])
|
||||
for(i = [0 : len(plain) - 1])
|
||||
box_section(plain[i], 100 - i * 20);
|
||||
|
||||
}
|
||||
|
||||
if($preview)
|
||||
|
@@ -55,6 +55,10 @@ module components() {
|
||||
|
||||
translate([0, 130])
|
||||
al_clad_resistors();
|
||||
|
||||
translate([80, 10])
|
||||
multiwatt11("L6203");
|
||||
|
||||
}
|
||||
|
||||
if($preview)
|
||||
|
31
tests/gear_motors.scad
Normal file
@@ -0,0 +1,31 @@
|
||||
//
|
||||
// NopSCADlib Copyright Chris Palmer 2023
|
||||
// nop.head@gmail.com
|
||||
// hydraraptor.blogspot.com
|
||||
//
|
||||
// This file is part of NopSCADlib.
|
||||
//
|
||||
// NopSCADlib is free software: you can redistribute it and/or modify it under the terms of the
|
||||
// GNU General Public License as published by the Free Software Foundation, either version 3 of
|
||||
// the License, or (at your option) any later version.
|
||||
//
|
||||
// NopSCADlib is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
// without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
// See the GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License along with NopSCADlib.
|
||||
// If not, see <https://www.gnu.org/licenses/>.
|
||||
//
|
||||
include <../core.scad>
|
||||
include <../vitamins/gear_motors.scad>
|
||||
|
||||
use <../utils/layout.scad>
|
||||
|
||||
module gear_motors()
|
||||
layout([for(g = gear_motors) gm_box(g).x], 10)
|
||||
gear_motor(gear_motors[$i]);
|
||||
|
||||
|
||||
|
||||
if($preview)
|
||||
gear_motors();
|
@@ -32,6 +32,9 @@ module jacks() {
|
||||
|
||||
translate([60, 0])
|
||||
post_4mm("red",3);
|
||||
|
||||
translate([80, 0])
|
||||
power_jack(3);
|
||||
}
|
||||
|
||||
if($preview)
|
||||
|
@@ -57,7 +57,8 @@ module nuts() {
|
||||
sliding_t_nut(M6_sliding_t_nut);
|
||||
|
||||
if(n == M8_nut)
|
||||
sliding_t_nut(M8_sliding_ball_t_nut);
|
||||
rotate(90)
|
||||
sliding_t_nut(M8_sliding_ball_t_nut);
|
||||
}
|
||||
|
||||
translate([0, 80]) {
|
||||
|
@@ -33,7 +33,7 @@ module pcb_utils() {
|
||||
|
||||
color("silver")
|
||||
vflip()
|
||||
cylinder(d = 0.6, h = 3, $fn = 16);
|
||||
cylinder(d = 0.6, h = 3, $fs = fs, $fa = fa);
|
||||
|
||||
color("white")
|
||||
translate_z(h / 2)
|
||||
|
Before Width: | Height: | Size: 53 KiB After Width: | Height: | Size: 54 KiB |
Before Width: | Height: | Size: 6.5 KiB After Width: | Height: | Size: 6.5 KiB |
BIN
tests/png/antennas.png
Normal file
After Width: | Height: | Size: 17 KiB |
Before Width: | Height: | Size: 278 KiB After Width: | Height: | Size: 274 KiB |
Before Width: | Height: | Size: 114 KiB After Width: | Height: | Size: 135 KiB |
Before Width: | Height: | Size: 90 KiB After Width: | Height: | Size: 94 KiB |
Before Width: | Height: | Size: 164 KiB After Width: | Height: | Size: 164 KiB |
Before Width: | Height: | Size: 85 KiB After Width: | Height: | Size: 85 KiB |
Before Width: | Height: | Size: 51 KiB After Width: | Height: | Size: 51 KiB |
Before Width: | Height: | Size: 50 KiB After Width: | Height: | Size: 50 KiB |
Before Width: | Height: | Size: 26 KiB After Width: | Height: | Size: 30 KiB |
Before Width: | Height: | Size: 107 KiB After Width: | Height: | Size: 103 KiB |
Before Width: | Height: | Size: 72 KiB After Width: | Height: | Size: 78 KiB |
Before Width: | Height: | Size: 130 KiB After Width: | Height: | Size: 127 KiB |
Before Width: | Height: | Size: 123 KiB After Width: | Height: | Size: 123 KiB |
Before Width: | Height: | Size: 84 KiB After Width: | Height: | Size: 84 KiB |
Before Width: | Height: | Size: 38 KiB After Width: | Height: | Size: 38 KiB |
Before Width: | Height: | Size: 115 KiB After Width: | Height: | Size: 127 KiB |
Before Width: | Height: | Size: 133 KiB After Width: | Height: | Size: 133 KiB |
Before Width: | Height: | Size: 149 KiB After Width: | Height: | Size: 146 KiB |
Before Width: | Height: | Size: 118 KiB After Width: | Height: | Size: 118 KiB |
Before Width: | Height: | Size: 74 KiB After Width: | Height: | Size: 74 KiB |
Before Width: | Height: | Size: 76 KiB After Width: | Height: | Size: 74 KiB |
Before Width: | Height: | Size: 62 KiB After Width: | Height: | Size: 63 KiB |
Before Width: | Height: | Size: 119 KiB After Width: | Height: | Size: 119 KiB |
Before Width: | Height: | Size: 117 KiB After Width: | Height: | Size: 114 KiB |
Before Width: | Height: | Size: 152 KiB After Width: | Height: | Size: 147 KiB |
Before Width: | Height: | Size: 100 KiB After Width: | Height: | Size: 99 KiB |
BIN
tests/png/gear_motors.png
Normal file
After Width: | Height: | Size: 50 KiB |
Before Width: | Height: | Size: 94 KiB After Width: | Height: | Size: 95 KiB |
Before Width: | Height: | Size: 103 KiB After Width: | Height: | Size: 102 KiB |
Before Width: | Height: | Size: 118 KiB After Width: | Height: | Size: 118 KiB |
Before Width: | Height: | Size: 72 KiB After Width: | Height: | Size: 73 KiB |
Before Width: | Height: | Size: 38 KiB After Width: | Height: | Size: 40 KiB |
Before Width: | Height: | Size: 89 KiB After Width: | Height: | Size: 100 KiB |
Before Width: | Height: | Size: 141 KiB After Width: | Height: | Size: 141 KiB |
Before Width: | Height: | Size: 112 KiB After Width: | Height: | Size: 113 KiB |
Before Width: | Height: | Size: 72 KiB After Width: | Height: | Size: 75 KiB |
Before Width: | Height: | Size: 19 KiB After Width: | Height: | Size: 19 KiB |
Before Width: | Height: | Size: 31 KiB After Width: | Height: | Size: 31 KiB |
Before Width: | Height: | Size: 57 KiB After Width: | Height: | Size: 57 KiB |
Before Width: | Height: | Size: 61 KiB After Width: | Height: | Size: 60 KiB |
Before Width: | Height: | Size: 119 KiB After Width: | Height: | Size: 119 KiB |
Before Width: | Height: | Size: 114 KiB After Width: | Height: | Size: 114 KiB |
Before Width: | Height: | Size: 199 KiB After Width: | Height: | Size: 198 KiB |
Before Width: | Height: | Size: 113 KiB After Width: | Height: | Size: 112 KiB |
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 16 KiB |
Before Width: | Height: | Size: 254 KiB After Width: | Height: | Size: 250 KiB |
Before Width: | Height: | Size: 106 KiB After Width: | Height: | Size: 105 KiB |
Before Width: | Height: | Size: 43 KiB After Width: | Height: | Size: 43 KiB |
Before Width: | Height: | Size: 168 KiB After Width: | Height: | Size: 168 KiB |
Before Width: | Height: | Size: 71 KiB After Width: | Height: | Size: 71 KiB |
Before Width: | Height: | Size: 116 KiB After Width: | Height: | Size: 116 KiB |
Before Width: | Height: | Size: 136 KiB After Width: | Height: | Size: 137 KiB |
Before Width: | Height: | Size: 116 KiB After Width: | Height: | Size: 116 KiB |
Before Width: | Height: | Size: 237 KiB After Width: | Height: | Size: 237 KiB |
Before Width: | Height: | Size: 45 KiB After Width: | Height: | Size: 45 KiB |
Before Width: | Height: | Size: 231 KiB After Width: | Height: | Size: 201 KiB |
Before Width: | Height: | Size: 94 KiB After Width: | Height: | Size: 93 KiB |
Before Width: | Height: | Size: 189 KiB After Width: | Height: | Size: 191 KiB |
Before Width: | Height: | Size: 75 KiB After Width: | Height: | Size: 75 KiB |
Before Width: | Height: | Size: 63 KiB After Width: | Height: | Size: 63 KiB |
Before Width: | Height: | Size: 82 KiB After Width: | Height: | Size: 81 KiB |
Before Width: | Height: | Size: 162 KiB After Width: | Height: | Size: 161 KiB |
Before Width: | Height: | Size: 47 KiB After Width: | Height: | Size: 46 KiB |
Before Width: | Height: | Size: 169 KiB After Width: | Height: | Size: 179 KiB |
Before Width: | Height: | Size: 62 KiB After Width: | Height: | Size: 81 KiB |
Before Width: | Height: | Size: 181 KiB After Width: | Height: | Size: 181 KiB |
Before Width: | Height: | Size: 62 KiB After Width: | Height: | Size: 62 KiB |
Before Width: | Height: | Size: 104 KiB After Width: | Height: | Size: 104 KiB |
Before Width: | Height: | Size: 36 KiB After Width: | Height: | Size: 36 KiB |
Before Width: | Height: | Size: 111 KiB After Width: | Height: | Size: 111 KiB |
Before Width: | Height: | Size: 170 KiB After Width: | Height: | Size: 168 KiB |
Before Width: | Height: | Size: 94 KiB After Width: | Height: | Size: 92 KiB |
Before Width: | Height: | Size: 218 KiB After Width: | Height: | Size: 223 KiB |
Before Width: | Height: | Size: 29 KiB After Width: | Height: | Size: 30 KiB |
@@ -22,6 +22,18 @@ include <../vitamins/pcbs.scad>
|
||||
module radials() {
|
||||
pcb = PERF70x50;
|
||||
pcb(pcb);
|
||||
translate([0, pcb_width(pcb) + inch(0.2)]) {
|
||||
pcb(pcb);
|
||||
|
||||
pcb_grid(pcb, 10, 12)
|
||||
rd_module(rd_modules[2], "12V 900ma");
|
||||
|
||||
for(i = [0: len(rd_electrolytics) - 1])
|
||||
pcb_grid(pcb, i * 3, 2)
|
||||
rotate(-90)
|
||||
rd_electrolytic(rd_electrolytics[i], "220uF35V", z = 3, pitch = inch(0.2));
|
||||
}
|
||||
|
||||
$solder = pcb_solder(pcb);
|
||||
|
||||
for(i = [0 : len(rd_xtals) - 1])
|
||||
@@ -35,6 +47,7 @@ module radials() {
|
||||
rotate(-90)
|
||||
rd_module(rd_modules[1], "12V 250ma");
|
||||
|
||||
|
||||
for(i = [0 : len(rd_discs) - 1])
|
||||
pcb_grid(pcb, 1 + 2.5 * i, 1) {
|
||||
disc = rd_discs[i];
|
||||
|
@@ -109,7 +109,7 @@ module wires() {
|
||||
|
||||
ends = [for(p = positions) [[30, p.x, p.y], [0, p.x, p.y]]];
|
||||
paths = [for(i = [0 : len(tpaths) - 1]) bezier_join(ends[i], tpaths[i], 1.3, 3)];
|
||||
cable(cable, paths, $fn = 32);
|
||||
cable(cable, paths, $fs = fs, $fa = fa);
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -34,9 +34,10 @@ module arrow(length = 20) { //! Draw an arrow that faces downwards
|
||||
d = length / 20;
|
||||
head_r = 1.5 * d;
|
||||
|
||||
$fs = fs; $fa = fa;
|
||||
color("grey") %union() {
|
||||
translate_z(head_r)
|
||||
cylinder(d = d, h = length - head_r, $fn = 32);
|
||||
cylinder(d = d, h = length - head_r);
|
||||
|
||||
cylinder(r1 = 0, r2 = head_r, h = head_r);
|
||||
}
|
||||
|
@@ -110,8 +110,8 @@ module poly_drill(r, h = 100, center = true) //! Make a cylinder for drilling ho
|
||||
//
|
||||
// Horizontal slot
|
||||
//
|
||||
module slot(r, l, h = 100) //! Make a horizontal slot suitable for CNC routing, set h = 0 for 2D version
|
||||
extrude_if(h)
|
||||
module slot(r, l, h = 100, center = false) //! Make a horizontal slot suitable for CNC routing, set h = 0 for 2D version
|
||||
extrude_if(h, center)
|
||||
hull() {
|
||||
translate([l / 2,0])
|
||||
drill(r, 0);
|
||||
|
@@ -22,15 +22,14 @@
|
||||
//
|
||||
include <../utils/core/core.scad>
|
||||
|
||||
module solder_meniscus(ir = 0.3, r) { //! Draw a solder meniscus
|
||||
h = 0.7;
|
||||
|
||||
module solder_meniscus(ir = 0.3, r = 1, h = 0.7) { //! Draw a solder meniscus
|
||||
$fn = fn;
|
||||
color("silver") rotate_extrude()
|
||||
difference() {
|
||||
square([r, h]);
|
||||
|
||||
translate([r + eps, h + eps])
|
||||
ellipse(r - ir + eps, h, $fn = 64);
|
||||
ellipse(r - ir + eps, h);
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -33,7 +33,7 @@ module rounded_corner(r, h, r2, ir = 0) { //! 2D version
|
||||
|
||||
translate([r - r2 - ir, h - r2])
|
||||
intersection() {
|
||||
circle4n(r2, $fs = 0.2);
|
||||
circle4n(r2);
|
||||
|
||||
square(r2);
|
||||
}
|
||||
|
@@ -102,7 +102,7 @@ module 7_segment_digit(type, colour = grey(95), pin_length = 6.4) { //! Draw the
|
||||
for(x = [0 : 1 : pins.x - 1], y = [0 : 1 : pins.y - 1])
|
||||
translate([(x - (pins.x - 1) / 2) * pin_pitch.x, (y - (pins.y - 1) / 2) * pin_pitch.y]) {
|
||||
vflip()
|
||||
cylinder(d = pin_pitch[2], h = pin_length, $fn = 16);
|
||||
cylinder(d = pin_pitch[2], h = pin_length, $fn = fn);
|
||||
|
||||
solder();
|
||||
}
|
||||
|
229
vitamins/antenna.scad
Normal file
@@ -0,0 +1,229 @@
|
||||
//
|
||||
// NopSCADlib Copyright Chris Palmer 2023
|
||||
// nop.head@gmail.com
|
||||
// hydraraptor.blogspot.com
|
||||
//
|
||||
// This file is part of NopSCADlib.
|
||||
//
|
||||
// NopSCADlib is free software: you can redistribute it and/or modify it under the terms of the
|
||||
// GNU General Public License as published by the Free Software Foundation, either version 3 of
|
||||
// the License, or (at your option) any later version.
|
||||
//
|
||||
// NopSCADlib is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
// without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
// See the GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License along with NopSCADlib.
|
||||
// If not, see <https://www.gnu.org/licenses/>.
|
||||
//
|
||||
//
|
||||
//! Wifi Antennas
|
||||
//
|
||||
include <../core.scad>
|
||||
use <../utils/tube.scad>
|
||||
use <../utils/fillet.scad>
|
||||
use <../utils/thread.scad>
|
||||
|
||||
//
|
||||
// s d t s s s s p
|
||||
// c i h o t p p e
|
||||
// r a i f a r r n
|
||||
// e m c t r i i n
|
||||
// w e k n n y
|
||||
// t n d g g
|
||||
// e e i v
|
||||
// r s a d t e
|
||||
// s i h r
|
||||
// a k
|
||||
ant_washer = ["ant_washer", 6.4, 12, 0.6, false, 9.6, 8.6, 1, undef];
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
// s d t n w t t
|
||||
// c i h y a r h
|
||||
// r a i l s a r
|
||||
// e m c o h p e
|
||||
// w e k c e d
|
||||
// t n r d
|
||||
// e e t e p
|
||||
// r s h p i
|
||||
// s k t t
|
||||
// h c
|
||||
// h
|
||||
|
||||
ant_nut = ["ant_nut", 6.25, 9.24, 1.8, 1.8, ant_washer, 2, inch(1/36)];
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
function antenna_length(type) = type[2]; //! Total length
|
||||
function antenna_top_d(type) = type[3]; //! Diameter at the top
|
||||
function antenna_bot_d(type) = type[4]; //! Diameter at the base
|
||||
function antenna_split(type) = type[5]; //! Split point
|
||||
function antenna_straight(type) = type[6]; //! Length of the straight part
|
||||
function antenna_hinge(type) = type[7]; //! Hinge post width, z value of the pin, pin diameter, width reduction and slot width
|
||||
function antenna_grip(type) = type[8]; //! Grip d, h, h2
|
||||
function antenna_rings(type) = type[9]; //! List of ring z, thickness, depths
|
||||
function antenna_gap(type) = type[10]; //! Space for left panel, washers and nuts when screwed on fully.
|
||||
function antenna_hole_r(type) = 6.4 / 2; //! Panel hole radius
|
||||
function antenna_nut(type) = ant_nut; //! The nut
|
||||
|
||||
module antenna(type, thickness, angle) //! Draw a WiFi antenna
|
||||
{
|
||||
vitamin(str("antenna(", type[0], "): Antenna ", type[1]));
|
||||
|
||||
split = antenna_split(type);
|
||||
bot_d = antenna_bot_d(type);
|
||||
g = antenna_grip(type);
|
||||
grip_d = g[0];
|
||||
grip_h1 = g[1];
|
||||
grip_h2 = g[2];
|
||||
h = antenna_hinge(type);
|
||||
hinge_w = h[0];
|
||||
pin_z = h[1];
|
||||
pin_d = h[2];
|
||||
cutout = bot_d - h[3];
|
||||
slot_w = h[4];
|
||||
w = hinge_w + 0.2;
|
||||
slot_height = pin_z - split + w / 2;
|
||||
gap = antenna_gap(type);
|
||||
translate_z(gap - washer_thickness(ant_washer)) explode(20){
|
||||
color(grey(25)) {
|
||||
translate_z(pin_z) rotate([0, angle, 0]) translate_z(-pin_z) {
|
||||
difference() {
|
||||
// Main rod
|
||||
hull() {
|
||||
translate_z(split)
|
||||
cylinder(d = bot_d, h = antenna_straight(type));
|
||||
|
||||
d = antenna_top_d(type);
|
||||
translate_z(antenna_length(type) - d / 2)
|
||||
sphere(d = d);
|
||||
}
|
||||
|
||||
// Rings
|
||||
for(r = antenna_rings(type))
|
||||
translate_z(r[0])
|
||||
tube(or = bot_d / 2, ir = antenna_top_d(type) / 2 - r[2], h = r[1], center = false);
|
||||
|
||||
// Slot for hinge
|
||||
translate([w / 2, 0, split])
|
||||
cube([2 * w, w, 2 * slot_height], center = true);
|
||||
|
||||
// Chamfer top of slot and cut out to avoid knife edge
|
||||
translate([bot_d / 2, 0, split])
|
||||
hull() {
|
||||
cube([2 * cutout, bot_d, 2 * slot_height], center = true);
|
||||
|
||||
cube([eps, bot_d, 2 * (slot_height + cutout)], center = true);
|
||||
}
|
||||
|
||||
// Fillet at the bottom
|
||||
translate([bot_d / 2 - cutout, 0, split])
|
||||
rotate([90, 0, 180])
|
||||
fillet(r = bot_d / 2 - cutout, h = bot_d, center = true);
|
||||
|
||||
// Hole for hinge pin
|
||||
translate_z(pin_z)
|
||||
rotate([90, 0, 0])
|
||||
cylinder(d = pin_d, h = bot_d + 1, center = true);
|
||||
}
|
||||
// Hinge pins
|
||||
for(side = [-1, 1])
|
||||
hull() {
|
||||
translate([0, side * (bot_d - pin_d) / 2, pin_z])
|
||||
sphere(d = pin_d);
|
||||
|
||||
translate([0, side * slot_w / 2, pin_z])
|
||||
rotate([90, 0, 0])
|
||||
cylinder(d = pin_d, h = eps);
|
||||
}
|
||||
}
|
||||
// Static part
|
||||
translate_z(grip_h1)
|
||||
cylinder(d = bot_d, h = split - grip_h1);
|
||||
|
||||
// Hinge base
|
||||
translate_z(split)
|
||||
cube([hinge_w, hinge_w, 2 * (pin_z - w / 2 - split)], center = true);
|
||||
|
||||
// Hinge clevice
|
||||
cheek_w = (hinge_w - slot_w) / 2;
|
||||
for(side = [-1, 1])
|
||||
translate([0, side * (cheek_w + slot_w) / 2, pin_z])
|
||||
hull() {
|
||||
rotate([90, 0, 0])
|
||||
cylinder(d = hinge_w, h = cheek_w, center = true);
|
||||
|
||||
translate_z(split - pin_z)
|
||||
cube([ hinge_w, cheek_w, eps], center = true);
|
||||
}
|
||||
}
|
||||
// wire
|
||||
color("Chocolate")
|
||||
translate_z(split)
|
||||
cylinder(d = slot_w, h = slot_height, center = false);
|
||||
|
||||
// Grip for thread
|
||||
rib_d = grip_d - bot_d;
|
||||
ribs = floor(PI * bot_d / rib_d);
|
||||
color(grey(15)) {
|
||||
cylinder(d = bot_d, h = grip_h1);
|
||||
|
||||
for(i = [0 : ribs - 1])
|
||||
rotate(i * 360 / ribs)
|
||||
translate([bot_d / 2, 0, (grip_h1 - grip_h2) / 2])
|
||||
cylinder(d = rib_d, h = grip_h2, $fn = 32);
|
||||
}
|
||||
}
|
||||
|
||||
color(gold) {
|
||||
translate_z(thickness)
|
||||
explode(7, explode_children = true)
|
||||
//spring_washer(ant_washer)
|
||||
translate_z(exploded() ? 7 : 0)
|
||||
nut(ant_nut);
|
||||
|
||||
vflip()
|
||||
explode(25)
|
||||
star_washer(ant_washer);
|
||||
}
|
||||
|
||||
explode(-40) {
|
||||
color(gold) {
|
||||
vflip() translate_z(washer_thickness(ant_washer)) {
|
||||
cylinder(d = 8 / cos(30), $fn = 6, h = 2);
|
||||
|
||||
cylinder(d = 5 / cos(30), $fn = 6, h = 4.5);
|
||||
|
||||
vflip() {
|
||||
tube(or = 5.3 / 2, ir = 4.6 / 2, h = 11, center = false);
|
||||
|
||||
tube(or = 5 / 2, ir = 4.0 / 2, h = 9, center = false);
|
||||
|
||||
difference() {
|
||||
tube(or = 1 / 2, ir = 0.6 / 2, h = 8.8, center = false);
|
||||
|
||||
translate_z(8.8)
|
||||
cube([0.1, 2, 10], center = true);
|
||||
}
|
||||
|
||||
male_metric_thread(6.25, inch(1/36), 10, center = false, top = -1, bot = -1, solid = false, colour = gold);
|
||||
}
|
||||
}
|
||||
}
|
||||
color(grey(95))
|
||||
translate_z(-washer_thickness(ant_washer))
|
||||
tube(or = 5 / 2, ir = 0.5, h = 8.8, center = false);
|
||||
|
||||
color(grey(15))
|
||||
vflip() {
|
||||
cylinder(d = 2.5, h = 9);
|
||||
|
||||
cylinder(d = 1.75, h = 20);
|
||||
}
|
||||
}
|
||||
}
|
36
vitamins/antennas.scad
Normal file
@@ -0,0 +1,36 @@
|
||||
//
|
||||
// NopSCADlib Copyright Chris Palmer 2023
|
||||
// nop.head@gmail.com
|
||||
// hydraraptor.blogspot.com
|
||||
//
|
||||
// This file is part of NopSCADlib.
|
||||
//
|
||||
// NopSCADlib is free software: you can redistribute it and/or modify it under the terms of the
|
||||
// GNU General Public License as published by the Free Software Foundation, either version 3 of
|
||||
// the License, or (at your option) any later version.
|
||||
//
|
||||
// NopSCADlib is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
// without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
// See the GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License along with NopSCADlib.
|
||||
// If not, see <https://www.gnu.org/licenses/>.
|
||||
//
|
||||
//
|
||||
//! Wifi Antennas
|
||||
//
|
||||
|
||||
//
|
||||
// d l t b s s h g r g
|
||||
// e e o o p t i r i a
|
||||
// s n p t l r n i n p
|
||||
// c g i a g p g
|
||||
// t d d t i e s
|
||||
// h g d h h2
|
||||
// h postw pinz pind wr sw z t z
|
||||
// t
|
||||
ESP201_antenna = ["ESP201_antenna", "ESP201", 108.5, 7.9, 9.5, 20.6, 20.6, [5.3, 26, 1.7, 8.5, 2], [10, 9, 6.5], [[97.6, 0.7, 0.6], [99, 0.7, 0.6]], 6.45];
|
||||
|
||||
antennas = [ ESP201_antenna ];
|
||||
|
||||
use <antenna.scad>
|
@@ -28,8 +28,7 @@ module wire_link(d, l, h = 1, tail = 3, sleeve = false) { //! Draw a wire jumper
|
||||
vitamin(str("wire_link(", d, ", ", l, arg(h, 1, "h"), arg(tail, 3, "tail"), arg(sleeve, false, "sleeve"),
|
||||
"): Wire link ", d, "mm x ", l ? str(l / inch(1), "\"") : str(h + tail,"mm"), sleeve ? str(" with ", sleeve[1], " sleeving") : ""));
|
||||
r = d;
|
||||
$fn = 32;
|
||||
|
||||
$fn = fn;
|
||||
color("silver")
|
||||
if(l) {
|
||||
for(side = [-1, 1]) {
|
||||
@@ -38,16 +37,20 @@ module wire_link(d, l, h = 1, tail = 3, sleeve = false) { //! Draw a wire jumper
|
||||
|
||||
translate([side * (l / 2 - r), 0, h - r])
|
||||
rotate([90, 0, side * 90 - 90])
|
||||
rotate_extrude(angle = 90)
|
||||
rotate_extrude(angle = 90, $fn = fn * 2)
|
||||
translate([r, 0])
|
||||
circle(d = d);
|
||||
circle(d = d, $fn = fn);
|
||||
|
||||
translate([side * l /2, 0])
|
||||
solder(ir = d / 2);
|
||||
if(tail > 1)
|
||||
solder(ir = d / 2);
|
||||
else
|
||||
if(!is_undef($solder))
|
||||
translate_z(0.1)
|
||||
solder_meniscus(ir = d / 2, r = $solder.x, h = h - r - 0.1);
|
||||
}
|
||||
|
||||
translate_z(h)
|
||||
rotate([0, 90, 0])
|
||||
rotate([0, -90, 0])
|
||||
cylinder(d = d, h = l - 2 * r, center = true);
|
||||
}
|
||||
else {
|
||||
@@ -100,11 +103,11 @@ module ax_res(type, value, tol = 5, pitch = 0) { //! Through hole axial resistor
|
||||
body_d = ax_res_diameter(type);
|
||||
length = ax_res_length(type);
|
||||
h = end_d / 2;
|
||||
$fn = 32;
|
||||
r = 0.3;
|
||||
|
||||
colours = ["gold", "silver", "black", "brown", "red", "orange", "yellow", "green", "blue", "violet", "grey", "white"];
|
||||
|
||||
$fs = fs; $fa = fa;
|
||||
exp = floor(log(value) + eps);
|
||||
mult = exp - (len(str(value / pow(10, exp - 1))) > 2 ? 2 : 1);
|
||||
digits = str(value / pow(10, mult));
|
||||
@@ -171,7 +174,7 @@ module ax_diode(type, value, pitch = 0) { //! Through hole axial diode. If `pitc
|
||||
body_r = size.y / 2;
|
||||
length = size.x;
|
||||
r = size.z;
|
||||
$fn = 32;
|
||||
$fs = fs; $fa = fa;
|
||||
|
||||
|
||||
orientate_axial(length, body_r, pitch, wire_d) {
|
||||
|