Skip to content

Commit 044d6f0

Browse files
committed
electronics: add support for WEMOS 8266 board components
1 parent 785244e commit 044d6f0

File tree

3 files changed

+34
-9
lines changed

3 files changed

+34
-9
lines changed

electronics/cpu.scad

+2-2
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ include <_internal.scad>
1616

1717
$vpd = 180;
1818

19-
module cpu(dim=[20, 20, 1.25]) {
20-
color(c_black)
19+
module cpu(dim=[20, 20, 1.25], clr=c_black) {
20+
color(clr)
2121
cube(dim, center=true);
2222
}
2323

electronics/misc.scad

+22
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,11 @@ include <_internal.scad>
1616

1717
$vpd = 200;
1818

19+
module antenna(dim=[7.5, 16, 1]) { // TODO
20+
color(c_black)
21+
cube(dim, center=true);
22+
}
23+
1924
module capacitor(dim=[6, 6, 5]) {
2025
l = dim[0];
2126
w = dim[1];
@@ -81,6 +86,11 @@ module ir(dim=[3.5, 5, 7]) {
8186
}
8287
}
8388

89+
module led(dim=[2, 1, 0.5], clr=c_yellow) { // TODO
90+
color(clr)
91+
cube(dim, center=true);
92+
}
93+
8494
module rt_bbb(dim=[3.5, 8, 10.5]) {
8595
rt1_l = dim[0];
8696
rt1_w = dim[1];
@@ -130,6 +140,11 @@ module serialcon_rpi(dim=[2.5, 22, 5.5]) {
130140
}
131141
}
132142

143+
function antenna_info() = [
144+
["category", "misc"],
145+
["watch", "nowhere"],
146+
];
147+
133148
function capacitor_info() = [
134149
["category", "misc"],
135150
["watch", "nowhere"],
@@ -150,6 +165,11 @@ function ir_info() = [
150165
["watch", "nowhere"],
151166
];
152167

168+
function led_info() = [
169+
["category", "misc"],
170+
["watch", "sky"],
171+
];
172+
153173
function rt_bbb_info() = [
154174
["category", "misc"],
155175
["watch", "nowhere"],
@@ -161,10 +181,12 @@ function serialcon_rpi_info() = [
161181
];
162182

163183
components_demo(pad=40) {
184+
antenna();
164185
capacitor();
165186
chip();
166187
extio_hikey();
167188
ir();
189+
led();
168190
serialcon_rpi();
169191
rt_bbb();
170192
}

electronics/usb.scad

+10-7
Original file line numberDiff line numberDiff line change
@@ -67,16 +67,19 @@ module usbx2(dim=[18, 14.5, 16], clr=c_black, has_folding=true) {
6767
cube([l, w, 3.5]);
6868
}
6969

70-
module microusb(dim=[6, 8, 3]) {
71-
l = dim[0];
72-
w = dim[1];
73-
h = dim[2];
70+
module microusb(dim=[6, 10, 6]) {
71+
jack_dim = [6, 8, 3];
72+
l = jack_dim[0];
73+
w = jack_dim[1];
74+
h = jack_dim[2];
7475
microusb_polygon_pos = [[1, h], [w-1, h], [w, h-1],
7576
[w-2, 0], [2, 0], [0, h-1]];
76-
rotate([0, 0, 180]) translate(dim * -.5) { // XXX
77+
p_w = dim[1];
78+
p_h = dim[2];
79+
rotate([0, 0, 180]) translate(jack_dim * -.5) { // XXX
7780
color(c_metal) {
78-
translate([l-1, 0])
79-
cube([1, w, h]);
81+
translate([l-1, (w-p_w)/2, (h-p_h)/2])
82+
cube([1, p_w, p_h]);
8083
rotate([90, 0, 90]) {
8184
linear_extrude(height=l-1) {
8285
difference() {

0 commit comments

Comments
 (0)