Initial import

This commit is contained in:
Ian Gulliver
2026-07-12 11:42:42 -07:00
commit ff7040a440
77 changed files with 760 additions and 0 deletions
+4
View File
@@ -0,0 +1,4 @@
*.stl filter=lfs diff=lfs merge=lfs -text
*.STL filter=lfs diff=lfs merge=lfs -text
*.3mf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
Binary file not shown.
@@ -0,0 +1,48 @@
$fn = 100;
difference() {
cylinder(h=10, d=10);
translate([0, 0, -0.1])
cylinder(h=10.2, d=7);
translate([-6, -7.9, -0.1])
cube([6.7, 6, 10.2]);
translate([0.5, -5, -0.1])
cube([2.0, 1.0, 10.2]);
}
difference() {
translate([-5, -7.38, 0])
cube([1.5, 7.38, 10]);
translate([-5.1, -7.48, -0.1])
cube([0.7, 0.7, 10.2]);
}
translate([-4.3, -6.68, 0])
cylinder(h=10, d=1.4);
translate([-3.5, -4.38, 0])
scale([0.5, 1.5, 1.0])
cylinder(h=10, d=4);
difference() {
union() {
translate([1.9, -5.6, 0])
cylinder(h=10, d=5);
}
translate([1.9, -5.6, -0.1])
cylinder(h=10.2, d=2.2);
}
translate([2.8, -7.935, 0])
rotate([0, 0, 20])
cube([6, 1.4, 10]);
translate([8.2, -5.22, 0])
rotate([0, 0, 20])
scale([0.5, 1.0, 1.0])
cylinder(h=10, d=1.4);
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,76 @@
part = 1; // [1:Bottom, 2:Top]
// (millimeters, length/width of interconnect grid unit)
unit_length_width = 1; // [1:100]
// (millimeters, height of interconnect grid overhang)
interlock_height = 1; // [1:100]
// (number of repeated units)
grid_length = 10; // [1:100]
// (number of repeated units)
grid_width = 10; // [1:100]
// (millimeters)
backing_height = 2; // [1:100]
interSurfaces([unit_length_width, interlock_height], [grid_length, grid_width], backing_height, part);
module interSurfaces(unit_size=[1,1], grid_size=[10,10], backing=2, only_part=0) {
total_size = [
grid_size[0] * (2 * unit_size[0]),
grid_size[1] * (2 * unit_size[0]),
backing + unit_size[0],
];
if (only_part == 0 || only_part == 1) {
color("red")
interSurface(unit_size, grid_size, backing);
}
if (only_part == 0 || only_part == 2) {
color("blue")
translate([total_size[0], total_size[1], (backing * 2) + (unit_size[1] * 2)]) {
rotate([0, 180, 90]) {
interSurface(unit_size, grid_size, backing);
}
}
}
}
module interSurface(unit_size, grid_size, backing) {
cube([
grid_size[0] * (2 * unit_size[0]),
grid_size[1] * (2 * unit_size[0]),
backing,
]);
translate([0, 0, backing]) {
interGrid(unit_size, grid_size);
}
}
module interGrid(unit_size, grid_size) {
for (i = [0 : grid_size[0] - 1]) {
translate([i * (unit_size[0] * 2), 0, 0]) {
interRow(unit_size, grid_size[1]);
}
}
}
module interRow(unit_size, length) {
for (i = [0 : length - 1]) {
translate([0, i * (unit_size[0] * 2), 0]) {
interHook(unit_size);
}
}
}
module interHook(unit_size) {
u = unit_size[0];
cube([u, u, unit_size[1] * 2]);
translate([u, 0, unit_size[1]]) {
cube([u, u, unit_size[1]]);
}
translate([0, u, unit_size[1]]) {
cube([u, u, unit_size[1]]);
}
}
@@ -0,0 +1,76 @@
part = 1; // [1:Bottom, 2:Top]
// (millimeters, length/width of interconnect grid unit)
unit_length_width = 1; // [1:100]
// (millimeters, height of interconnect grid overhang)
interlock_height = 1; // [1:100]
// (number of repeated units)
grid_length = 10; // [1:100]
// (number of repeated units)
grid_width = 10; // [1:100]
// (millimeters)
backing_height = 2; // [1:100]
interSurfaces([unit_length_width, interlock_height], [grid_length, grid_width], backing_height, part);
module interSurfaces(unit_size=[1,1], grid_size=[10,10], backing=2, only_part=0) {
total_size = [
grid_size[0] * (2 * unit_size[0]),
grid_size[1] * (2 * unit_size[0]),
backing + unit_size[0],
];
if (only_part == 0 || only_part == 1) {
color("red")
interSurface(unit_size, grid_size, backing);
}
if (only_part == 0 || only_part == 2) {
color("blue")
translate([total_size[0], total_size[1], (backing * 2) + (unit_size[1] * 2)]) {
rotate([0, 180, 90]) {
interSurface(unit_size, grid_size, backing);
}
}
}
}
module interSurface(unit_size, grid_size, backing) {
cube([
grid_size[0] * (2 * unit_size[0]),
grid_size[1] * (2 * unit_size[0]),
backing,
]);
translate([0, 0, backing]) {
interGrid(unit_size, grid_size);
}
}
module interGrid(unit_size, grid_size) {
for (i = [0 : grid_size[0] - 1]) {
translate([i * (unit_size[0] * 2), 0, 0]) {
interRow(unit_size, grid_size[1]);
}
}
}
module interRow(unit_size, length) {
for (i = [0 : length - 1]) {
translate([0, i * (unit_size[0] * 2), 0]) {
interHook(unit_size);
}
}
}
module interHook(unit_size) {
u = unit_size[0];
cube([u, u, unit_size[1] * 2]);
translate([u, 0, unit_size[1]]) {
cube([u, u, unit_size[1]]);
}
translate([0, u, unit_size[1]]) {
cube([u, u, unit_size[1]]);
}
}
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
+136
View File
@@ -0,0 +1,136 @@
only = "*";
color = "Black";
sku = "FibreX";
type = "ABS+GF";
manuf = "3DXTECH";
layer_height = 0.1;
swatches = 8;
swatch_width = 10;
card_width = swatches * swatch_width;
if (only == "*" || only == "c") {
difference() {
color("blue")
card();
label();
}
}
if (only == "*" || only == "l") {
color("magenta")
label();
}
if (only == "*" || only == "b") {
difference() {
translate([0, 0, 0])
cube([card_width, 15, 3]);
black();
}
}
if (only == "*" || only == "w") {
difference() {
translate([0, 15, 0])
cube([card_width, 15, 3]);
white();
}
}
if (only == "b2") {
black();
}
if (only == "w2") {
white();
}
module label() {
translate([0, 0, 2])
_label();
translate([card_width, 0, 1])
rotate([0, 180, 0])
_label();
}
module _label() {
translate([card_width / 2, 48, 0])
linear_extrude(1.01)
text(text=color, size=5, font="JetBrains Mono:style=Medium", halign="center");
translate([card_width * 12 / 64, 41, 0])
linear_extrude(1.01)
text(text=manuf, size=3.5, font="JetBrains Mono:style=Medium", halign="center");
translate([card_width * 52 / 64, 41, 0])
linear_extrude(1.01)
text(text=sku, size=3.5, font="JetBrains Mono:style=Medium", halign="center");
translate([card_width / 2, 40.75, 0])
linear_extrude(1.01)
text(text=type, size=4, font="JetBrains Mono:style=Medium", halign="center");
for (i = [0:swatches-1]) {
t = str(layer_height * (i+1));
translate([5 + (i * swatch_width), 33, 0])
linear_extrude(1.01)
text(text=str(t[1], t[2]), size=2.5, font="JetBrains Mono:style=Medium", halign="center");
}
}
module card() {
difference() {
hull() {
cube([card_width, 55, 3]);
for (x = [0, card_width]) {
for (y = [0, 55]) {
translate([x, y, 0])
cylinder(h=3, d=4, $fn=100);
}
}
}
translate([0, 0, -0.01])
cube([card_width, 15, 3.02]);
translate([0, 15, -0.01])
cube([card_width, 15, 3.01]);
}
black();
white();
}
module black() {
translate([0, 0, 3.0])
stack();
translate([card_width, 0, 0])
rotate([0, 180, 0])
stack();
}
module white() {
translate([0, 15, 3])
stack();
translate([card_width, 15, 0])
rotate([0, 180, 0])
stack();
}
module stack() {
for (i = [0:swatches]) {
color("teal", alpha=0.3)
translate([swatch_width * i, 0, 0 - ((i+1) * layer_height)])
cube([swatch_width * (swatches - i), 15, layer_height]);
}
}
+135
View File
@@ -0,0 +1,135 @@
// * c l b w
only = "w";
color = "Red";
sku = "40200";
type = "ABS";
manuf = "Bambu";
top = "Ironed";
bottom = "Engineering";
layer_height = 0.12;
nozzle = 0.2;
card_height = 3;
swatches = 10;
swatch_width = 10;
swatch_height = 10;
e = 0.02;
card_width = swatches * swatch_width;
if (only == "*" || only == "c") {
difference() {
color("blue", alpha=0.3)
card();
label();
}
}
if (only == "*" || only == "l") {
color("magenta")
label();
}
if (only == "*" || only == "b") {
black();
}
if (only == "*" || only == "w") {
white();
}
module label() {
translate([0, 0, 2])
_label(top);
translate([card_width, 0, 1])
rotate([0, 180, 0])
_label(bottom);
}
module _label(surface) {
l1 = 48;
l2 = 41;
l3 = 34;
l = card_width * 12 / 64;
c = card_width / 2;
r = card_width * 52 / 64;
translate([c, l1, 0])
linear_extrude(1.01)
text(text=color, size=5, font="JetBrains Mono:style=Medium", halign="center");
translate([l, l2, 0])
linear_extrude(1.01)
text(text=manuf, size=4, font="JetBrains Mono:style=Medium", halign="center");
translate([c, l2 - 0.25, 0])
linear_extrude(1.01)
text(text=type, size=4, font="JetBrains Mono:style=Medium", halign="center");
translate([r, l2, 0])
linear_extrude(1.01)
text(text=sku, size=4, font="JetBrains Mono:style=Medium", halign="center");
translate([l, l3, 0])
linear_extrude(1.01)
text(text=str("L ", layer_height), size=4, font="JetBrains Mono:style=Medium", halign="center");
translate([c, l3, 0])
linear_extrude(1.01)
text(text=surface, size=4, font="JetBrains Mono:style=Medium", halign="center");
translate([r, l3, 0])
linear_extrude(1.01)
text(text=str("N ", nozzle), size=4, font="JetBrains Mono:style=Medium", halign="center");
}
module card() {
difference() {
hull() {
for (x = [0, card_width]) {
for (y = [0, 55]) {
translate([x, y, 0])
cylinder(h=card_height, d=4, $fn=100);
}
}
}
translucent();
white();
black();
}
}
module black() {
color("black")
stack();
}
module white() {
translate([0, swatch_height, 0])
color("white")
stack();
}
module translucent() {
translate([0, swatch_height * 2 + (nozzle * 2), 0])
for (i = [0:swatches-1]) {
translate([swatch_width * i, 0, 0])
translate([0, 0, (i + 1) * layer_height])
cube([swatch_width, swatch_height, card_height - (i * layer_height)]);
}
}
module stack() {
for (i = [0:swatches-1]) {
translate([swatch_width * i, 0, 0])
color("black")
translate([0, 0, e + (swatches - i) * layer_height])
cube([swatch_width, swatch_height, card_height - e - ((swatches + 1) * layer_height)]);
}
}
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
+84
View File
@@ -0,0 +1,84 @@
$fn=500;
// * b l
only = "b";
// Global parameters passed cleanly into the modules
radius = 19;
cut_radius = 16.5;
cut_squash = 0.85;
height = 30;
twist = 90;
label1 = "40200";
label1_size = 3.8;
label2 = ".2";
label2_size = 2.7;
label3 = ".12";
label3_size = 2.7;
if (only == "*" || only == "b") {
color("blue")
ball(radius=radius, cut_radius=cut_radius, height=height, twist=twist, label1=label1, label1_size=label1_size, label2=label2, label2_size=label2_size, label3=label3, label3_size=label3_size,render_text=false);
}
if (only == "*" || only == "l") {
color("magenta")
_ball_text(radius=radius, height=height, twist=twist, label1=label1, label1_size=label1_size, label2=label2, label2_size=label2_size, label3=label3, label3_size=label3_size);
}
module ball(radius, cut_radius, height, twist=90, slices=200, scale_base=0.5, label1, label1_size, label2, label2_size, label3, label3_size, render_text=true) {
p_step = 2/slices;
h_step = height/slices;
t_step = twist/slices;
sf_range = 1-scale_base;
difference() {
translate([0, 0, height/2])
union() {
for (p=[-1 : p_step : 1-p_step]) {
p2 = p+p_step;
sf1 = scale_base + sf_range*cos(p*90);
sf2 = scale_base + sf_range*cos(p2*90);
translate([0, 0, p*(height/2)])
rotate([0, 0, p*(twist/2)])
scale([sf1, sf1, 1])
linear_extrude(height=h_step, twist=-t_step, scale=sf2/sf1)
_ball_flat(radius=radius, cut_radius=cut_radius);
}
}
_ball_text(radius=radius, height=height, twist=twist, label1=label1, label1_size=label1_size, label2=label2, label2_size=label2_size, label3=label3, label3_size=label3_size);
}
}
module _ball_text(radius, height, twist, label1, label1_size, label2, label2_size, label3, label3_size) {
// Counter the initial slice rotation
rotate([0, 0, -1*(twist/2)])
linear_extrude(height=1.01, center=false)
mirror([1, 0]) {
if (label1 != "") {
text(text=label1, font="JetBrains Mono", halign="center", valign="center", size=label1_size);
}
if (label2 != "") {
translate([0, label1_size * 1.2, 0])
text(text=label2, font="JetBrains Mono", halign="center", valign="center", size=label2_size);
}
if (label3 != "") {
translate([0, label1_size * -1.2, 0])
text(text=label3, font="JetBrains Mono", halign="center", valign="center", size=label3_size);
}
}
}
module _ball_flat(radius, cut_radius) {
difference() {
circle(r=radius);
for (x=[-1, 1], y=[-1, 1]) {
translate([x*radius, y*radius])
rotate([0, 0, 45 * x * y])
scale([cut_squash, 1, 1])
circle(r=cut_radius);
}
}
}
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.