Compare commits
533 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
dd8a100d9c | ||
|
01eeafb255 | ||
|
dd876c8fc9 | ||
|
ff40a276e1 | ||
|
463c620cc3 | ||
|
7b1a916043 | ||
|
1a2a9bb512 | ||
|
adcb515d20 | ||
|
34719c3360 | ||
|
024439d4c2 | ||
|
005c112ba9 | ||
|
dfbcbf84ab | ||
|
de051343d0 | ||
|
b6e47ed9b7 | ||
|
6a529c91a7 | ||
|
e7e9313e71 | ||
|
e19bb47273 | ||
|
494002aebe | ||
|
77e948f43c | ||
|
543cdb4e01 | ||
|
dab06ce4ca | ||
|
2e25932d5c | ||
|
ebd50bae53 | ||
|
8e47270607 | ||
|
ec3e752fc5 | ||
|
de17726d20 | ||
|
8587d52d1b | ||
|
cec8c3a107 | ||
|
848dcb86b9 | ||
|
a31f6f100c | ||
|
b3dd635889 | ||
|
3c9004f12d | ||
|
e256801206 | ||
|
4080179a74 | ||
|
9dc8062bef | ||
|
c2e85a5833 | ||
|
f2313a3f0c | ||
|
d95e1e64ed | ||
|
4eaaee6a4d | ||
|
f1737d257b | ||
|
ce258d6d4f | ||
|
272b7efd45 | ||
|
e84b5721d7 | ||
|
ec85cc5d4c | ||
|
264e4366f6 | ||
|
233fba275d | ||
|
c9ac393c0c | ||
|
208334a585 | ||
|
3a17b89d5c | ||
|
0f36c02b5e | ||
|
fb6695471f | ||
|
87b794d4a2 | ||
|
75262efe3a | ||
|
c1e4625382 | ||
|
6059c5f556 | ||
|
a5a55533e1 | ||
|
4ceb6bd863 | ||
|
e0df0f31a5 | ||
|
664d04ad93 | ||
|
78b8c2031e | ||
|
2001de2408 | ||
|
64fb562f58 | ||
|
bf163587fa | ||
|
1238dba90a | ||
|
f40a7d19a9 | ||
|
a054eb8216 | ||
|
05edd923b8 | ||
|
b58a59dab7 | ||
|
6b6ffb2b74 | ||
|
1e30ad24e8 | ||
|
dc715ff2b7 | ||
|
c57c202e31 | ||
|
26bfe96614 | ||
|
fa49ae09fa | ||
|
974457eabd | ||
|
2cc3c6ec7c | ||
|
633843d45e | ||
|
1a472c8ed5 | ||
|
f44d9ae424 | ||
|
4f0c443c8e | ||
|
ecd534b577 | ||
|
aec72118fa | ||
|
0d828f8f7f | ||
|
28c36a4e96 | ||
|
1ddfb35bda | ||
|
235caa4101 | ||
|
6a9af0af8a | ||
|
f066b1b8ae | ||
|
4be7b2f0ea | ||
|
3cc3c52b54 | ||
|
7f1634ef06 | ||
|
34c8c31cae | ||
|
a6a08088d9 | ||
|
06443a558b | ||
|
bcf9fb38df | ||
|
18f3d43780 | ||
|
eda88cc8d7 | ||
|
630268d71a | ||
|
66f793b00b | ||
|
cc5654d7d7 | ||
|
9989f13edf | ||
|
d46913ce4f | ||
|
b9f676a753 | ||
|
1a649060bd | ||
|
68fd04f6d5 | ||
|
ddc4150ed7 | ||
|
ed7e55808a | ||
|
3eff5fc2e0 | ||
|
744ebc2935 | ||
|
99a5570e24 | ||
|
b70911dc13 | ||
|
50d62b4170 | ||
|
7e126c94ca | ||
|
2d20fb130a | ||
|
738c7914e2 | ||
|
7596bcacf4 | ||
|
943deededf | ||
|
c8f16f4cdb | ||
|
a30aff9613 | ||
|
c0d9067b74 | ||
|
7e8f03df2e | ||
|
f173284709 | ||
|
6850953e71 | ||
|
2f60f568ff | ||
|
0206b2e868 | ||
|
38e2a22a11 | ||
|
4f68353f70 | ||
|
fbaae66d27 | ||
|
f8d17c6f16 | ||
|
97a6a65158 | ||
|
42fccc1afb | ||
|
662db2bd41 | ||
|
76aa613093 | ||
|
0e2778e13d | ||
|
50e23e5f81 | ||
|
59eeb2c5d4 | ||
|
7ea4dbe6cb | ||
|
0d062c24fa | ||
|
95b6771811 | ||
|
ed46cbb147 | ||
|
14ba135169 | ||
|
2a2b7d8bd6 | ||
|
055b4e7102 | ||
|
00d6efc315 | ||
|
985b6c08d2 | ||
|
1f55097bdd | ||
|
136584d086 | ||
|
225ea9b451 | ||
|
d341ce499e | ||
|
e7376e28c4 | ||
|
e238eaa473 | ||
|
1ac5a6f6cb | ||
|
28d8cba98c | ||
|
04e94a859a | ||
|
e696dc4718 | ||
|
30955eb350 | ||
|
d5abee4082 | ||
|
f33a0675f5 | ||
|
5223415429 | ||
|
89d2d2bb71 | ||
|
762ff9cb43 | ||
|
1ee80f4a90 | ||
|
43408843af | ||
|
c4ccc30b35 | ||
|
20db11f81e | ||
|
d82db46ea1 | ||
|
f87f3f51ee | ||
|
ac58524b85 | ||
|
ef06aa4387 | ||
|
68533f96d0 | ||
|
c826f10169 | ||
|
d775a16baa | ||
|
682b8caf41 | ||
|
c915dd8c5c | ||
|
213ce7e25f | ||
|
e5a38b37b3 | ||
|
669e51605f | ||
|
127aab2e7a | ||
|
680563808a | ||
|
df3da13d6b | ||
|
000a7fb0fb | ||
|
d4e8dd8311 | ||
|
1928ec6fb1 | ||
|
f4b9ab961c | ||
|
ac7c4403b9 | ||
|
b7b40ba6a4 | ||
|
317b485ee1 | ||
|
6218287e2a | ||
|
d04f2bc8d1 | ||
|
49c26079fe | ||
|
b5ee63bfc4 | ||
|
a5bc80c0e8 | ||
|
bf8014fba0 | ||
|
ccf2b8e21b | ||
|
99f277de8d | ||
|
fe1ab5d59a | ||
|
e06b485d3e | ||
|
72d9c398bc | ||
|
608f0b2db0 | ||
|
7f8dfb9e73 | ||
|
c9de51fbbb | ||
|
30b7d966a1 | ||
|
abe1b1db01 | ||
|
8835fa0b7d | ||
|
71f935de8e | ||
|
b0a6a873c0 | ||
|
0771d4742c | ||
|
970c538496 | ||
|
4d44eae16a | ||
|
cec790ec09 | ||
|
3c9ec5455b | ||
|
5be85f5c25 | ||
|
e6254daaf1 | ||
|
c31f58a4fd | ||
|
46fc574e7a | ||
|
6ee0fad2e1 | ||
|
6e76c2ce89 | ||
|
a2dfaef2b5 | ||
|
2c197be193 | ||
|
05a67d1b2e | ||
|
be4dc0c57a | ||
|
c4895f84c7 | ||
|
72700a0acb | ||
|
43c78fd1a3 | ||
|
8682d0a470 | ||
|
e71db80093 | ||
|
a280e1fcbd | ||
|
b1ad206ce4 | ||
|
da55f86536 | ||
|
9790bdda11 | ||
|
59c3f984c5 | ||
|
9c2dd1c37b | ||
|
74e569896b | ||
|
3a87d7afde | ||
|
ed6f8cf5c0 | ||
|
1c9945d978 | ||
|
9464ad5dbf | ||
|
370ad8a2d1 | ||
|
b424bea622 | ||
|
c8d9bb7d09 | ||
|
c35c732324 | ||
|
f5528c5a9a | ||
|
09bce09a85 | ||
|
389e2f9c2e | ||
|
c35e263113 | ||
|
bad33da95e | ||
|
f727e1d27d | ||
|
5ddd9f6324 | ||
|
f5d0bfb6c8 | ||
|
b2117fa99a | ||
|
6687a4a7c6 | ||
|
8524ddd34d | ||
|
427ef610de | ||
|
c8869fc415 | ||
|
21c06667a3 | ||
|
d19fad3f9f | ||
|
172bfb16d8 | ||
|
491dbae13b | ||
|
99ebfffd2b | ||
|
f04486a040 | ||
|
42a7d222b5 | ||
|
598a01295f | ||
|
5f72a12125 | ||
|
82502eb470 | ||
|
b541298eae | ||
|
9884160ed5 | ||
|
046c475e18 | ||
|
7b111c016a | ||
|
38c973b316 | ||
|
042d809ed0 | ||
|
3864839e52 | ||
|
2ba2c2c115 | ||
|
e3716ce8f9 | ||
|
c4f24974ab | ||
|
61dae9c7a4 | ||
|
41a26c453c | ||
|
bab4c8e8af | ||
|
a5c4bf05ad | ||
|
a65add65ac | ||
|
c449dd0a24 | ||
|
f16f7ddb09 | ||
|
9b5ec6af1a | ||
|
50958b064d | ||
|
c37373c920 | ||
|
700f5a2205 | ||
|
4993c3e82d | ||
|
c6b280f0e8 | ||
|
6012787781 | ||
|
30db66034c | ||
|
d6f344be3d | ||
|
f6aa3b3426 | ||
|
91c8c7bf4d | ||
|
dc93b8dcdf | ||
|
c9c094248e | ||
|
119c2cb6f4 | ||
|
24b391578b | ||
|
ec49ce1a6c | ||
|
f0c25d37b0 | ||
|
588a1edf62 | ||
|
3299aad5c8 | ||
|
74c52aac04 | ||
|
726d9ed2dc | ||
|
8a838dd1ce | ||
|
181c6ac624 | ||
|
e952aa7840 | ||
|
466ee31e10 | ||
|
4c926c529b | ||
|
edb1eccbf1 | ||
|
061812cc8b | ||
|
ce0c97b45e | ||
|
696b14699c | ||
|
2166a9be6a | ||
|
511729008d | ||
|
5111ec04bc | ||
|
cef3a620a6 | ||
|
da5191e52c | ||
|
d9af5b7f70 | ||
|
c30d7f1ad9 | ||
|
a5382cbe04 | ||
|
00c5c90a5e | ||
|
01c26d8a34 | ||
|
ef2102420b | ||
|
540f841163 | ||
|
1045502efb | ||
|
485184f092 | ||
|
b893c9069a | ||
|
69f4ced29d | ||
|
5c1aa849fe | ||
|
9d65f69bf3 | ||
|
515b99fdc0 | ||
|
631d052c68 | ||
|
1247303cb9 | ||
|
290be4beb6 | ||
|
24e941799d | ||
|
6a556c5879 | ||
|
14ab1bb8b6 | ||
|
be53547728 | ||
|
4138ed438e | ||
|
ba7d7d32ad | ||
|
d3049bc81b | ||
|
df35e14fc7 | ||
|
21c2aa5d62 | ||
|
c982876ebc | ||
|
5ccda42e5b | ||
|
92d0444e5f | ||
|
b239c1462e | ||
|
6413b7b2a0 | ||
|
0b0ce66c85 | ||
|
d38055c15c | ||
|
cf99418a19 | ||
|
0cd0e72d92 | ||
|
2c4a498a7a | ||
|
451101fcd6 | ||
|
c7a6d8164f | ||
|
8d7c44b80d | ||
|
dcfe4262c5 | ||
|
fe3b84f672 | ||
|
d1a17bd4ac | ||
|
b8efa11fd9 | ||
|
3bc8f35e37 | ||
|
39c11ef3b2 | ||
|
5a8a1da880 | ||
|
3147862212 | ||
|
4fc8a7f47d | ||
|
a9ed9944c3 | ||
|
9cd2dbc316 | ||
|
f3bfbbfcf2 | ||
|
baaa85ffed | ||
|
f1a49d4e28 | ||
|
0eed0673b0 | ||
|
9a4cc7ec42 | ||
|
2fb1185edf | ||
|
a782d43e67 | ||
|
ae934d47c7 | ||
|
823f3b936e | ||
|
3027b942a6 | ||
|
749a1f0648 | ||
|
5c898df217 | ||
|
7a566cc856 | ||
|
20d799a3c1 | ||
|
2ee95bba65 | ||
|
f49bb63266 | ||
|
258109811b | ||
|
b39fd536c2 | ||
|
a5a87d260d | ||
|
b09efb10e0 | ||
|
53acaac379 | ||
|
9b40e0dcef | ||
|
00ca412441 | ||
|
1e6d7f5dd6 | ||
|
ec07d95657 | ||
|
0dab0dca08 | ||
|
6e6cd45295 | ||
|
3a7fde6c56 | ||
|
c5bb898856 | ||
|
11ebe2225d | ||
|
a1e25bb878 | ||
|
9689683b7e | ||
|
08946e3d70 | ||
|
15c2946e91 | ||
|
34019196cd | ||
|
436fc71cf3 | ||
|
fd67c166f7 | ||
|
634deab911 | ||
|
e2feceb608 | ||
|
d1258e0b0c | ||
|
bd61a1dc55 | ||
|
055e83902f | ||
|
feec1e7ae5 | ||
|
be76af2fc4 | ||
|
9c1a9bf357 | ||
|
9647fb474b | ||
|
49fdfea792 | ||
|
ac0bacfeda | ||
|
6288059d99 | ||
|
0f1dff230a | ||
|
e379fa8ada | ||
|
313d7508df | ||
|
083caca4e8 | ||
|
49329df00c | ||
|
edc0b86bb1 | ||
|
5fbff060b0 | ||
|
b94ca4ad3a | ||
|
bc5515d35e | ||
|
44d213deaa | ||
|
145c5d9b1a | ||
|
7abbbd9b96 | ||
|
5b160cee88 | ||
|
3f31607840 | ||
|
1efed649cf | ||
|
b70c2f993c | ||
|
56e252f3dc | ||
|
f12b36ea04 | ||
|
bd5811e69b | ||
|
ede4da6f1d | ||
|
51cc2fd679 | ||
|
4ce2f53e20 | ||
|
e338c47e73 | ||
|
8328a70f42 | ||
|
cc794cd7c3 | ||
|
df28bd5116 | ||
|
61de6041d8 | ||
|
b2d712bca9 | ||
|
f3376edaf1 | ||
|
c073419c0b | ||
|
608168de8e | ||
|
fc45a40bd3 | ||
|
52e9c1d7fd | ||
|
ca1b34e9ca | ||
|
cbab9cea02 | ||
|
69cf998862 | ||
|
08bce9ec03 | ||
|
4aa7dbb416 | ||
|
7c7c2e5d3f | ||
|
f6f6664c0d | ||
|
2fd2e118a0 | ||
|
22c6fef113 | ||
|
dcf0c949b9 | ||
|
9ded315801 | ||
|
42e03679b4 | ||
|
d2c795f5f5 | ||
|
83b4ab2374 | ||
|
573c50774b | ||
|
4b93623492 | ||
|
d496898c80 | ||
|
544e69c71b | ||
|
240334784d | ||
|
516b225275 | ||
|
e46e6b6e5b | ||
|
4925979519 | ||
|
298d1f9284 | ||
|
fcf2f5f7f0 | ||
|
491c3b4ea8 | ||
|
94cb50f725 | ||
|
1d8275c061 | ||
|
3c605d608b | ||
|
9ba48c7e1a | ||
|
a6ebc5267b | ||
|
e9554ccffe | ||
|
0d179f3728 | ||
|
a94e462f34 | ||
|
7ce991e625 | ||
|
3e15be852f | ||
|
7c1c8e92f2 | ||
|
54c3b4f600 | ||
|
d80fc5709e | ||
|
30236046a8 | ||
|
93aeb4cf2c | ||
|
f62ca35c86 | ||
|
2320cbdbb8 | ||
|
769cb44207 | ||
|
f327df95a3 | ||
|
09956b6219 | ||
|
f8c9adca5a | ||
|
b83e56713f | ||
|
4c12d5fca4 | ||
|
da4f9fbdc3 | ||
|
614e5f3a72 | ||
|
a7eae4f549 | ||
|
3cd5769708 | ||
|
7b770abe12 | ||
|
31ab8562a7 | ||
|
db703379a3 | ||
|
cd925bc049 | ||
|
4a2951e22f | ||
|
a93a8f99fb | ||
|
73c436ee15 | ||
|
c69100bd71 | ||
|
e0b89359aa | ||
|
041d720c39 | ||
|
03a0c2fe98 | ||
|
7c2df8d36d | ||
|
8474718884 | ||
|
fe0f32ddc5 | ||
|
f191b9b0f4 | ||
|
2b3908b6fd | ||
|
0a84bf0927 | ||
|
da825b17ab | ||
|
ca153c971d | ||
|
0199587907 | ||
|
60350eb228 | ||
|
4f9729cf86 | ||
|
26f1338ca2 | ||
|
fc44b43638 | ||
|
182f39876a | ||
|
055e90cbb3 | ||
|
832380f893 | ||
|
929d082b25 | ||
|
57212b5701 | ||
|
1c3f136657 | ||
|
cfd2fd32a1 | ||
|
f573a91a09 | ||
|
d75aff2ccd |
1
.gitignore
vendored
@@ -11,3 +11,4 @@ options.json
|
||||
times.txt
|
||||
*_diff.png
|
||||
*.echo
|
||||
cmd_times.txt
|
||||
|
2507
CHANGELOG.md
Normal file
@@ -1,7 +1,7 @@
|
||||
# NopSCADlib usage
|
||||
|
||||
## Requirements
|
||||
1. OpenSCAD 2019.05 or later, download it from here: https://www.openscad.org/downloads.html
|
||||
1. OpenSCAD 2021.01 or later, download it from here: https://www.openscad.org/downloads.html
|
||||
1. Python 2.7+ or 3.6+ from https://www.python.org/downloads/
|
||||
1. ImageMagick 7 www.imagemagick.org
|
||||
|
||||
@@ -28,6 +28,8 @@ by downloading https://github.com/nophead/NopSCADlib/archive/master.zip and unzi
|
||||
|
||||
The `NopSCADlib/scripts` directory needs to be added to the executable search path, `PATH` on Windows and `path` on Linux and Mac.
|
||||
|
||||
Note that on Linux and OSX the full file name including the `.py` will be needed.
|
||||
|
||||
The installation can be tested by opening `NopSCADlib/libtest.scad` in the OpenSCAD GUI. It should render all the objects in the library in about 1 minute.
|
||||
|
||||
Running `tests` from the command line will run all the tests in the `tests` directory and build the `readme.md` catalog for GitHub and render it to `readme.html`
|
||||
@@ -270,6 +272,22 @@ The target config file is selected by generating `target.scad` that includes `co
|
||||
The rest of the project includes `target.scad` to use the configuration.
|
||||
Additionally all the generated file directories (assemblies, bom, stls, dxfs, etc.) are placed in a sub-directory called `<target_name>`.
|
||||
|
||||
The build system will look for a `<target_name>_assembly` module and use it as the top level module instead of `main_assembly` if it it exists.
|
||||
That allows the project description to be target specific if the top level modules are in different scad files.
|
||||
The top level assembly instructions and assembly contents could also be different if appropriate.
|
||||
|
||||
If the top level module is just a shell wrapper that simply includes one other assembly, with no additional parts, then it is removed from the build instructions and
|
||||
the assembly it calls becomes the top level. This allows a different project description for each target but only one set of top level instructions without repeating them.
|
||||
|
||||
### Costed BOMs
|
||||
|
||||
A costed bill of materials can be made by opening the generated file `bom/bom.csv` in a spreadsheet program using a single quote as the string delimiter and comma as the field separator.
|
||||
That gets a list of part descriptions and quantities to which prices can be added to get the total cost and perhaps a URL of where to buy each part.
|
||||
|
||||
If a Python file called `parts.py` is found then `bom.py` will attempt to call functions for each part to get a price and URL.
|
||||
Any functions not found are printed, so you can see the format expected.
|
||||
The function are passed the quantity to allow them to calculate volume discounts, etc.
|
||||
|
||||
### Other libraries
|
||||
|
||||
The build scripts need to be able to locate the source files where the modules to generate the STL files and assemblies reside. They will search all the scad files
|
||||
|
BIN
examples/EnviroPlus/assemblies/RPI_assembled.png
Normal file
After Width: | Height: | Size: 203 KiB |
BIN
examples/EnviroPlus/assemblies/RPI_assembled_tn.png
Normal file
After Width: | Height: | Size: 40 KiB |
BIN
examples/EnviroPlus/assemblies/RPI_assembly.png
Normal file
After Width: | Height: | Size: 265 KiB |
BIN
examples/EnviroPlus/assemblies/RPI_assembly_tn.png
Normal file
After Width: | Height: | Size: 52 KiB |
BIN
examples/EnviroPlus/assemblies/RPI_case_assembled.png
Normal file
After Width: | Height: | Size: 326 KiB |
BIN
examples/EnviroPlus/assemblies/RPI_case_assembled_tn.png
Normal file
After Width: | Height: | Size: 57 KiB |
BIN
examples/EnviroPlus/assemblies/RPI_case_assembly.png
Normal file
After Width: | Height: | Size: 336 KiB |
BIN
examples/EnviroPlus/assemblies/RPI_case_assembly_tn.png
Normal file
After Width: | Height: | Size: 58 KiB |
BIN
examples/EnviroPlus/assemblies/back_assembled.png
Normal file
After Width: | Height: | Size: 126 KiB |
BIN
examples/EnviroPlus/assemblies/back_assembled_tn.png
Normal file
After Width: | Height: | Size: 26 KiB |
BIN
examples/EnviroPlus/assemblies/back_assembly.png
Normal file
After Width: | Height: | Size: 132 KiB |
BIN
examples/EnviroPlus/assemblies/back_assembly_tn.png
Normal file
After Width: | Height: | Size: 28 KiB |
BIN
examples/EnviroPlus/assemblies/case_assembled.png
Normal file
After Width: | Height: | Size: 202 KiB |
BIN
examples/EnviroPlus/assemblies/case_assembled_tn.png
Normal file
After Width: | Height: | Size: 36 KiB |
BIN
examples/EnviroPlus/assemblies/case_assembly.png
Normal file
After Width: | Height: | Size: 249 KiB |
BIN
examples/EnviroPlus/assemblies/case_assembly_tn.png
Normal file
After Width: | Height: | Size: 44 KiB |
BIN
examples/EnviroPlus/assemblies/enviro_assembled.png
Normal file
After Width: | Height: | Size: 68 KiB |
BIN
examples/EnviroPlus/assemblies/enviro_assembled_tn.png
Normal file
After Width: | Height: | Size: 15 KiB |
BIN
examples/EnviroPlus/assemblies/enviro_assembly.png
Normal file
After Width: | Height: | Size: 125 KiB |
BIN
examples/EnviroPlus/assemblies/enviro_assembly_tn.png
Normal file
After Width: | Height: | Size: 24 KiB |
BIN
examples/EnviroPlus/assemblies/enviro_case_assembled.png
Normal file
After Width: | Height: | Size: 187 KiB |
BIN
examples/EnviroPlus/assemblies/enviro_case_assembled_tn.png
Normal file
After Width: | Height: | Size: 34 KiB |
BIN
examples/EnviroPlus/assemblies/enviro_case_assembly.png
Normal file
After Width: | Height: | Size: 236 KiB |
BIN
examples/EnviroPlus/assemblies/enviro_case_assembly_tn.png
Normal file
After Width: | Height: | Size: 42 KiB |
BIN
examples/EnviroPlus/assemblies/fan_controller_assembled.png
Normal file
After Width: | Height: | Size: 229 KiB |
BIN
examples/EnviroPlus/assemblies/fan_controller_assembled_tn.png
Normal file
After Width: | Height: | Size: 47 KiB |
BIN
examples/EnviroPlus/assemblies/fan_controller_assembly.png
Normal file
After Width: | Height: | Size: 130 KiB |
BIN
examples/EnviroPlus/assemblies/fan_controller_assembly_tn.png
Normal file
After Width: | Height: | Size: 29 KiB |
BIN
examples/EnviroPlus/assemblies/main_assembled.png
Normal file
After Width: | Height: | Size: 120 KiB |
BIN
examples/EnviroPlus/assemblies/main_assembled_tn.png
Normal file
After Width: | Height: | Size: 24 KiB |
BIN
examples/EnviroPlus/assemblies/main_assembly.png
Normal file
After Width: | Height: | Size: 219 KiB |
BIN
examples/EnviroPlus/assemblies/main_assembly_tn.png
Normal file
After Width: | Height: | Size: 38 KiB |
5
examples/EnviroPlus/bom/RPI_assembly.txt
Normal file
@@ -0,0 +1,5 @@
|
||||
RPI_assembly:
|
||||
Vitamins:
|
||||
1 Micro SD card
|
||||
1 Raspberry Pi Zero
|
||||
1 Pin header 20 x 2 right_angle
|
7
examples/EnviroPlus/bom/RPI_case_assembly.txt
Normal file
@@ -0,0 +1,7 @@
|
||||
RPI_case_assembly:
|
||||
Vitamins:
|
||||
2 Screw M2.5 pan x 6.4mm
|
||||
|
||||
Assemblies:
|
||||
1 RPI_assembly
|
||||
1 enviro_case_assembly
|
8
examples/EnviroPlus/bom/back_assembly.txt
Normal file
@@ -0,0 +1,8 @@
|
||||
back_assembly:
|
||||
Vitamins:
|
||||
1 Fan 17mm x 8mm
|
||||
1 PMS5003 particle detector
|
||||
|
||||
Printed:
|
||||
1 enviro_plus_case_base.stl
|
||||
1 fan_duct.stl
|
21
examples/EnviroPlus/bom/bom.csv
Normal file
@@ -0,0 +1,21 @@
|
||||
'Micro SD card', 1
|
||||
'Fan 17mm x 8mm', 1
|
||||
'Heatfit insert M2', 4
|
||||
'Nut M2.5 x 2.2mm nyloc', 4
|
||||
'Enviro+', 1
|
||||
'Raspberry Pi Zero', 1
|
||||
'Pin header 20 x 2 right_angle', 1
|
||||
'PMS5003 particle detector', 1
|
||||
'Screw M2 cap x 6mm', 4
|
||||
'Screw M2.5 pan x 6.4mm', 2
|
||||
'Screw M2.5 pan x 8mm', 4
|
||||
'Screw M3 pan x 6mm', 3
|
||||
'SMD capacitor 1206 10uF', 1
|
||||
'SMD resistor 0805 3K3 0.125W', 1
|
||||
'SOT223 package FZT851', 1
|
||||
'Veroboard 6 holes x 6strips', 1
|
||||
'Washer M2 x 5mm x 0.3mm', 4
|
||||
'Washer M2.5 x 5.9mm x 0.5mm', 4
|
||||
'Washer M3 x 7mm x 0.5mm', 3
|
||||
'Wire link 0.8mm x 6.5mm', 3
|
||||
'Wire link 0.8mm x 0.4"', 1
|
Can't render this file because it contains an unexpected character in line 21 and column 23.
|
194
examples/EnviroPlus/bom/bom.json
Normal file
@@ -0,0 +1,194 @@
|
||||
[
|
||||
{
|
||||
"name": "back_assembly",
|
||||
"big": null,
|
||||
"ngb": false,
|
||||
"zoomed": 0,
|
||||
"count": 1,
|
||||
"assemblies": {},
|
||||
"vitamins": {
|
||||
"pms5003(): PMS5003 particle detector": {
|
||||
"count": 1
|
||||
},
|
||||
"fan(fan17x8): Fan 17mm x 8mm": {
|
||||
"count": 1
|
||||
}
|
||||
},
|
||||
"printed": {
|
||||
"fan_duct.stl": {
|
||||
"count": 1,
|
||||
"colour": "darkorange"
|
||||
},
|
||||
"enviro_plus_case_base.stl": {
|
||||
"count": 1,
|
||||
"colour": "grey"
|
||||
}
|
||||
},
|
||||
"routed": {}
|
||||
},
|
||||
{
|
||||
"name": "RPI_assembly",
|
||||
"big": null,
|
||||
"ngb": false,
|
||||
"zoomed": 0,
|
||||
"count": 1,
|
||||
"assemblies": {},
|
||||
"vitamins": {
|
||||
"pcb(RPI0): Raspberry Pi Zero": {
|
||||
"count": 1
|
||||
},
|
||||
": Micro SD card": {
|
||||
"count": 1
|
||||
},
|
||||
"pin_header(2p54header, 20, 2, right_angle = true): Pin header 20 x 2 right_angle": {
|
||||
"count": 1
|
||||
}
|
||||
},
|
||||
"printed": {},
|
||||
"routed": {}
|
||||
},
|
||||
{
|
||||
"name": "fan_controller_assembly",
|
||||
"big": null,
|
||||
"ngb": false,
|
||||
"zoomed": 0,
|
||||
"count": 1,
|
||||
"assemblies": {},
|
||||
"vitamins": {
|
||||
"veroboard(fan_vb): Veroboard 6 holes x 6strips": {
|
||||
"count": 1
|
||||
},
|
||||
"wire_link(0.8, 10.16, tail = 2.5): Wire link 0.8mm x 0.4\"": {
|
||||
"count": 1
|
||||
},
|
||||
"wire_link(0.8, 0, h = 4, tail = 2.5): Wire link 0.8mm x 6.5mm": {
|
||||
"count": 3
|
||||
},
|
||||
"smd_resistor(RES0805, 3K3): SMD resistor 0805 3K3 0.125W": {
|
||||
"count": 1
|
||||
},
|
||||
"smd_capacitor(CAP1206): SMD capacitor 1206 10uF": {
|
||||
"count": 1
|
||||
},
|
||||
"smd_sot(SOT223): SOT223 package FZT851": {
|
||||
"count": 1
|
||||
}
|
||||
},
|
||||
"printed": {},
|
||||
"routed": {}
|
||||
},
|
||||
{
|
||||
"name": "enviro_assembly",
|
||||
"big": null,
|
||||
"ngb": false,
|
||||
"zoomed": 0,
|
||||
"count": 1,
|
||||
"assemblies": {
|
||||
"fan_controller_assembly": 1
|
||||
},
|
||||
"vitamins": {
|
||||
"pcb(EnviroPlus): Enviro+": {
|
||||
"count": 1
|
||||
}
|
||||
},
|
||||
"printed": {},
|
||||
"routed": {}
|
||||
},
|
||||
{
|
||||
"name": "case_assembly",
|
||||
"big": null,
|
||||
"ngb": false,
|
||||
"zoomed": 0,
|
||||
"count": 1,
|
||||
"assemblies": {},
|
||||
"vitamins": {
|
||||
"insert(F1BM2): Heatfit insert M2": {
|
||||
"count": 4
|
||||
},
|
||||
"washer(M3_washer): Washer M3 x 7mm x 0.5mm": {
|
||||
"count": 3
|
||||
},
|
||||
"screw(M3_pan_screw, 6): Screw M3 pan x 6mm": {
|
||||
"count": 3
|
||||
}
|
||||
},
|
||||
"printed": {
|
||||
"enviro_plus_case.stl": {
|
||||
"count": 1,
|
||||
"colour": "grey"
|
||||
},
|
||||
"bulkhead.stl": {
|
||||
"count": 1,
|
||||
"colour": "[0.862745, 0.0784314, 0.235294]"
|
||||
},
|
||||
"foot.stl": {
|
||||
"count": 3,
|
||||
"colour": "darkorange"
|
||||
}
|
||||
},
|
||||
"routed": {}
|
||||
},
|
||||
{
|
||||
"name": "enviro_case_assembly",
|
||||
"big": null,
|
||||
"ngb": false,
|
||||
"zoomed": 0,
|
||||
"count": 1,
|
||||
"assemblies": {
|
||||
"case_assembly": 1,
|
||||
"enviro_assembly": 1
|
||||
},
|
||||
"vitamins": {
|
||||
"screw(M2p5_pan_screw, 8): Screw M2.5 pan x 8mm": {
|
||||
"count": 4
|
||||
},
|
||||
"washer(M2p5_washer): Washer M2.5 x 5.9mm x 0.5mm": {
|
||||
"count": 4
|
||||
},
|
||||
"nut(M2p5_nut, nyloc = true): Nut M2.5 x 2.2mm nyloc": {
|
||||
"count": 4
|
||||
}
|
||||
},
|
||||
"printed": {},
|
||||
"routed": {}
|
||||
},
|
||||
{
|
||||
"name": "RPI_case_assembly",
|
||||
"big": null,
|
||||
"ngb": false,
|
||||
"zoomed": 0,
|
||||
"count": 1,
|
||||
"assemblies": {
|
||||
"enviro_case_assembly": 1,
|
||||
"RPI_assembly": 1
|
||||
},
|
||||
"vitamins": {
|
||||
"screw(M2p5_pan_screw, 6.4): Screw M2.5 pan x 6.4mm": {
|
||||
"count": 2
|
||||
}
|
||||
},
|
||||
"printed": {},
|
||||
"routed": {}
|
||||
},
|
||||
{
|
||||
"name": "main_assembly",
|
||||
"big": null,
|
||||
"ngb": false,
|
||||
"zoomed": 0,
|
||||
"count": 1,
|
||||
"assemblies": {
|
||||
"RPI_case_assembly": 1,
|
||||
"back_assembly": 1
|
||||
},
|
||||
"vitamins": {
|
||||
"washer(M2_washer): Washer M2 x 5mm x 0.3mm": {
|
||||
"count": 4
|
||||
},
|
||||
"screw(M2_cap_screw, 6): Screw M2 cap x 6mm": {
|
||||
"count": 4
|
||||
}
|
||||
},
|
||||
"printed": {},
|
||||
"routed": {}
|
||||
}
|
||||
]
|
53
examples/EnviroPlus/bom/bom.txt
Normal file
@@ -0,0 +1,53 @@
|
||||
Vitamins:
|
||||
F
|
||||
a
|
||||
n
|
||||
E
|
||||
n c
|
||||
v o
|
||||
R i n
|
||||
p r t
|
||||
i E o r
|
||||
n o
|
||||
c B C v c l M
|
||||
R a a a i a l a
|
||||
p s c s r s e i
|
||||
i e k e o e r n
|
||||
1| | | | | | | | 1 Micro SD card
|
||||
| | 1| | | | | | 1 Fan 17mm x 8mm
|
||||
| | | 4| | | | | 4 Heatfit insert M2
|
||||
| | | | | 4| | | 4 Nut M2.5 x 2.2mm nyloc
|
||||
| | | | 1| | | | 1 Enviro+
|
||||
1| | | | | | | | 1 Raspberry Pi Zero
|
||||
1| | | | | | | | 1 Pin header 20 x 2 right_angle
|
||||
| | 1| | | | | | 1 PMS5003 particle detector
|
||||
| | | | | | | 4| 4 Screw M2 cap x 6mm
|
||||
| 2| | | | | | | 2 Screw M2.5 pan x 6.4mm
|
||||
| | | | | 4| | | 4 Screw M2.5 pan x 8mm
|
||||
| | | 3| | | | | 3 Screw M3 pan x 6mm
|
||||
| | | | | | 1| | 1 SMD capacitor 1206 10uF
|
||||
| | | | | | 1| | 1 SMD resistor 0805 3K3 0.125W
|
||||
| | | | | | 1| | 1 SOT223 package FZT851
|
||||
| | | | | | 1| | 1 Veroboard 6 holes x 6strips
|
||||
| | | | | | | 4| 4 Washer M2 x 5mm x 0.3mm
|
||||
| | | | | 4| | | 4 Washer M2.5 x 5.9mm x 0.5mm
|
||||
| | | 3| | | | | 3 Washer M3 x 7mm x 0.5mm
|
||||
| | | | | | 3| | 3 Wire link 0.8mm x 6.5mm
|
||||
| | | | | | 1| | 1 Wire link 0.8mm x 0.4"
|
||||
|
||||
Printed:
|
||||
| | | 1| | | | | 1 bulkhead.stl
|
||||
| | | 1| | | | | 1 enviro_plus_case.stl
|
||||
| | 1| | | | | | 1 enviro_plus_case_base.stl
|
||||
| | 1| | | | | | 1 fan_duct.stl
|
||||
| | | 3| | | | | 3 foot.stl
|
||||
|
||||
Assemblies:
|
||||
1 RPI_assembly
|
||||
1 RPI_case_assembly
|
||||
1 back_assembly
|
||||
1 case_assembly
|
||||
1 enviro_assembly
|
||||
1 enviro_case_assembly
|
||||
1 fan_controller_assembly
|
||||
1 main_assembly
|
10
examples/EnviroPlus/bom/case_assembly.txt
Normal file
@@ -0,0 +1,10 @@
|
||||
case_assembly:
|
||||
Vitamins:
|
||||
4 Heatfit insert M2
|
||||
3 Screw M3 pan x 6mm
|
||||
3 Washer M3 x 7mm x 0.5mm
|
||||
|
||||
Printed:
|
||||
1 bulkhead.stl
|
||||
1 enviro_plus_case.stl
|
||||
3 foot.stl
|
6
examples/EnviroPlus/bom/enviro_assembly.txt
Normal file
@@ -0,0 +1,6 @@
|
||||
enviro_assembly:
|
||||
Vitamins:
|
||||
1 Enviro+
|
||||
|
||||
Assemblies:
|
||||
1 fan_controller_assembly
|
9
examples/EnviroPlus/bom/enviro_case_assembly.txt
Normal file
@@ -0,0 +1,9 @@
|
||||
enviro_case_assembly:
|
||||
Vitamins:
|
||||
4 Nut M2.5 x 2.2mm nyloc
|
||||
4 Screw M2.5 pan x 8mm
|
||||
4 Washer M2.5 x 5.9mm x 0.5mm
|
||||
|
||||
Assemblies:
|
||||
1 case_assembly
|
||||
1 enviro_assembly
|
8
examples/EnviroPlus/bom/fan_controller_assembly.txt
Normal file
@@ -0,0 +1,8 @@
|
||||
fan_controller_assembly:
|
||||
Vitamins:
|
||||
1 SMD capacitor 1206 10uF
|
||||
1 SMD resistor 0805 3K3 0.125W
|
||||
1 SOT223 package FZT851
|
||||
1 Veroboard 6 holes x 6strips
|
||||
3 Wire link 0.8mm x 6.5mm
|
||||
1 Wire link 0.8mm x 0.4"
|
8
examples/EnviroPlus/bom/main_assembly.txt
Normal file
@@ -0,0 +1,8 @@
|
||||
main_assembly:
|
||||
Vitamins:
|
||||
4 Screw M2 cap x 6mm
|
||||
4 Washer M2 x 5mm x 0.3mm
|
||||
|
||||
Assemblies:
|
||||
1 RPI_case_assembly
|
||||
1 back_assembly
|
BIN
examples/EnviroPlus/docs/cuts.jpg
Normal file
After Width: | Height: | Size: 107 KiB |
BIN
examples/EnviroPlus/docs/fan_connection.jpg
Normal file
After Width: | Height: | Size: 498 KiB |
BIN
examples/EnviroPlus/docs/fan_controller.jpg
Normal file
After Width: | Height: | Size: 164 KiB |
BIN
examples/EnviroPlus/docs/smt.jpg
Normal file
After Width: | Height: | Size: 129 KiB |
298
examples/EnviroPlus/readme.md
Normal file
@@ -0,0 +1,298 @@
|
||||
<a name="TOP"></a>
|
||||
# EnviroPlus
|
||||
Environmental monitor using Enviro+ sensor board and a Raspberry Pi Zero.
|
||||
|
||||

|
||||
|
||||
<span></span>
|
||||
|
||||
---
|
||||
## Table of Contents
|
||||
1. [Parts list](#Parts_list)
|
||||
1. [Back Assembly](#back_assembly)
|
||||
1. [RPI Assembly](#RPI_assembly)
|
||||
1. [Fan Controller Assembly](#fan_controller_assembly)
|
||||
1. [Enviro Assembly](#enviro_assembly)
|
||||
1. [Case Assembly](#case_assembly)
|
||||
1. [Enviro Case Assembly](#enviro_case_assembly)
|
||||
1. [RPI Case Assembly](#RPI_case_assembly)
|
||||
1. [Main Assembly](#main_assembly)
|
||||
|
||||
<span></span>
|
||||
[Top](#TOP)
|
||||
|
||||
---
|
||||
<a name="Parts_list"></a>
|
||||
## Parts list
|
||||
| <span style="writing-mode: vertical-rl; text-orientation: mixed;">Back</span> | <span style="writing-mode: vertical-rl; text-orientation: mixed;">RPI</span> | <span style="writing-mode: vertical-rl; text-orientation: mixed;">Fan Controller</span> | <span style="writing-mode: vertical-rl; text-orientation: mixed;">Enviro</span> | <span style="writing-mode: vertical-rl; text-orientation: mixed;">Case</span> | <span style="writing-mode: vertical-rl; text-orientation: mixed;">Enviro Case</span> | <span style="writing-mode: vertical-rl; text-orientation: mixed;">RPI Case</span> | <span style="writing-mode: vertical-rl; text-orientation: mixed;">Main</span> | <span style="writing-mode: vertical-rl; text-orientation: mixed;">TOTALS</span> | |
|
||||
|---:|---:|---:|---:|---:|---:|---:|---:|---:|:---|
|
||||
| | | | | | | | | | **Vitamins** |
|
||||
| . | . | . | 1 | . | . | . | . | 1 | Enviro+ |
|
||||
| 1 | . | . | . | . | . | . | . | 1 | Fan 17mm x 8mm |
|
||||
| . | . | . | . | 4 | . | . | . | 4 | Heatfit insert M2 |
|
||||
| . | 1 | . | . | . | . | . | . | 1 | Micro SD card |
|
||||
| . | . | . | . | . | 4 | . | . | 4 | Nut M2.5 x 2.2mm nyloc |
|
||||
| 1 | . | . | . | . | . | . | . | 1 | PMS5003 particle detector |
|
||||
| . | 1 | . | . | . | . | . | . | 1 | Pin header 20 x 2 right_angle |
|
||||
| . | 1 | . | . | . | . | . | . | 1 | Raspberry Pi Zero |
|
||||
| . | . | 1 | . | . | . | . | . | 1 | SMD capacitor 1206 10uF |
|
||||
| . | . | 1 | . | . | . | . | . | 1 | SMD resistor 0805 3K3 0.125W |
|
||||
| . | . | 1 | . | . | . | . | . | 1 | SOT223 package FZT851 |
|
||||
| . | . | . | . | . | . | . | 4 | 4 | Screw M2 cap x 6mm |
|
||||
| . | . | . | . | . | . | 2 | . | 2 | Screw M2.5 pan x 6.4mm |
|
||||
| . | . | . | . | . | 4 | . | . | 4 | Screw M2.5 pan x 8mm |
|
||||
| . | . | . | . | 3 | . | . | . | 3 | Screw M3 pan x 6mm |
|
||||
| . | . | 1 | . | . | . | . | . | 1 | Veroboard 6 holes x 6strips |
|
||||
| . | . | . | . | . | . | . | 4 | 4 | Washer M2 x 5mm x 0.3mm |
|
||||
| . | . | . | . | . | 4 | . | . | 4 | Washer M2.5 x 5.9mm x 0.5mm |
|
||||
| . | . | . | . | 3 | . | . | . | 3 | Washer M3 x 7mm x 0.5mm |
|
||||
| . | . | 1 | . | . | . | . | . | 1 | Wire link 0.8mm x 0.4" |
|
||||
| . | . | 3 | . | . | . | . | . | 3 | Wire link 0.8mm x 6.5mm |
|
||||
| 2 | 3 | 8 | 1 | 10 | 12 | 2 | 8 | 46 | Total vitamins count |
|
||||
| | | | | | | | | | **3D printed parts** |
|
||||
| . | . | . | . | 1 | . | . | . | 1 | bulkhead.stl |
|
||||
| . | . | . | . | 1 | . | . | . | 1 | enviro_plus_case.stl |
|
||||
| 1 | . | . | . | . | . | . | . | 1 | enviro_plus_case_base.stl |
|
||||
| 1 | . | . | . | . | . | . | . | 1 | fan_duct.stl |
|
||||
| . | . | . | . | 3 | . | . | . | 3 | foot.stl |
|
||||
| 2 | . | . | . | 5 | . | . | . | 7 | Total 3D printed parts count |
|
||||
|
||||
<span></span>
|
||||
[Top](#TOP)
|
||||
|
||||
---
|
||||
<a name="back_assembly"></a>
|
||||
## Back Assembly
|
||||
### Vitamins
|
||||
|Qty|Description|
|
||||
|---:|:----------|
|
||||
|1| Fan 17mm x 8mm|
|
||||
|1| PMS5003 particle detector|
|
||||
|
||||
|
||||
### 3D Printed parts
|
||||
|
||||
| 1 x enviro_plus_case_base.stl | 1 x fan_duct.stl |
|
||||
|---|---|
|
||||
|  | 
|
||||
|
||||
|
||||
|
||||
### Assembly instructions
|
||||

|
||||
|
||||
1. Print the fan duct in flexible TPE with low infill.
|
||||
1. Slide the pms5003 into the printed receptacle with the fan to the outside. Secure with tape if it is loose.
|
||||
1. Slide the fan into the fan duct.
|
||||
1. Slide the fan duct into the printed recepacle.
|
||||
|
||||

|
||||
|
||||
<span></span>
|
||||
[Top](#TOP)
|
||||
|
||||
---
|
||||
<a name="RPI_assembly"></a>
|
||||
## RPI Assembly
|
||||
### Vitamins
|
||||
|Qty|Description|
|
||||
|---:|:----------|
|
||||
|1| Micro SD card|
|
||||
|1| Pin header 20 x 2 right_angle|
|
||||
|1| Raspberry Pi Zero|
|
||||
|
||||
|
||||
### Assembly instructions
|
||||

|
||||
|
||||
* Solder a right angle connector to the Raspberry Pi Zero.
|
||||
|
||||

|
||||
|
||||
<span></span>
|
||||
[Top](#TOP)
|
||||
|
||||
---
|
||||
<a name="fan_controller_assembly"></a>
|
||||
## Fan Controller Assembly
|
||||
### Vitamins
|
||||
|Qty|Description|
|
||||
|---:|:----------|
|
||||
|1| SMD capacitor 1206 10uF|
|
||||
|1| SMD resistor 0805 3K3 0.125W|
|
||||
|1| SOT223 package FZT851|
|
||||
|1| Veroboard 6 holes x 6strips|
|
||||
|1| Wire link 0.8mm x 0.4"|
|
||||
|3| Wire link 0.8mm x 6.5mm|
|
||||
|
||||
|
||||
### Assembly instructions
|
||||

|
||||
|
||||
The fan controller is a single transistor wired as a Miller integrator that effectively multiplies the capacitor value by the gain of the transistor.
|
||||
It converts the PWM signal on GPI4 to a stead DC voltage so that the fan doesn't whine, or stutter.
|
||||
|
||||

|
||||
|
||||
***
|
||||
* Make two track cuts as shown, one wide and the other narrow.
|
||||
|
||||

|
||||
|
||||
1. Add the SMT compeonents and then the wire links.
|
||||
1. Add more solder around the transistor to act as a heatsink.
|
||||
|
||||

|
||||
|
||||
|
||||

|
||||
|
||||
<span></span>
|
||||
[Top](#TOP)
|
||||
|
||||
---
|
||||
<a name="enviro_assembly"></a>
|
||||
## Enviro Assembly
|
||||
### Vitamins
|
||||
|Qty|Description|
|
||||
|---:|:----------|
|
||||
|1| Enviro+|
|
||||
|
||||
|
||||
### Sub-assemblies
|
||||
|
||||
| 1 x fan_controller_assembly |
|
||||
|---|
|
||||
| 
|
||||
|
||||
|
||||
|
||||
### Assembly instructions
|
||||

|
||||
|
||||
* Solder the fan_controller to the Enviro+ expansion connector at the 5V, GND and #4 pins.
|
||||
|
||||

|
||||
|
||||
<span></span>
|
||||
[Top](#TOP)
|
||||
|
||||
---
|
||||
<a name="case_assembly"></a>
|
||||
## Case Assembly
|
||||
### Vitamins
|
||||
|Qty|Description|
|
||||
|---:|:----------|
|
||||
|4| Heatfit insert M2|
|
||||
|3| Screw M3 pan x 6mm|
|
||||
|3| Washer M3 x 7mm x 0.5mm|
|
||||
|
||||
|
||||
### 3D Printed parts
|
||||
|
||||
| 1 x bulkhead.stl | 1 x enviro_plus_case.stl | 3 x foot.stl |
|
||||
|---|---|---|
|
||||
|  |  | 
|
||||
|
||||
|
||||
|
||||
### Assembly instructions
|
||||

|
||||
|
||||
1. Solvent weld or glue the bulkhead into the recess in the bottom of the case.
|
||||
1. Fit the heatfit inserts with a soldering iron with a conical bit heated to about 200°C.
|
||||
1. Tap the three holes for the feet with an M3 tap.
|
||||
1. Screw on the three feet with M3 x 6mm pan screws and washers.
|
||||
|
||||

|
||||
|
||||
<span></span>
|
||||
[Top](#TOP)
|
||||
|
||||
---
|
||||
<a name="enviro_case_assembly"></a>
|
||||
## Enviro Case Assembly
|
||||
### Vitamins
|
||||
|Qty|Description|
|
||||
|---:|:----------|
|
||||
|4| Nut M2.5 x 2.2mm nyloc|
|
||||
|4| Screw M2.5 pan x 8mm|
|
||||
|4| Washer M2.5 x 5.9mm x 0.5mm|
|
||||
|
||||
|
||||
### Sub-assemblies
|
||||
|
||||
| 1 x case_assembly | 1 x enviro_assembly |
|
||||
|---|---|
|
||||
|  | 
|
||||
|
||||
|
||||
|
||||
### Assembly instructions
|
||||

|
||||
|
||||
* Screw the Enviro+ PCB to the front of the case using M2.5 x 8mm pan screws with washer and nuts on the inside.
|
||||
|
||||

|
||||
|
||||
<span></span>
|
||||
[Top](#TOP)
|
||||
|
||||
---
|
||||
<a name="RPI_case_assembly"></a>
|
||||
## RPI Case Assembly
|
||||
### Vitamins
|
||||
|Qty|Description|
|
||||
|---:|:----------|
|
||||
|2| Screw M2.5 pan x 6.4mm|
|
||||
|
||||
|
||||
### Sub-assemblies
|
||||
|
||||
| 1 x RPI_assembly | 1 x enviro_case_assembly |
|
||||
|---|---|
|
||||
|  | 
|
||||
|
||||
|
||||
|
||||
### Assembly instructions
|
||||

|
||||
|
||||
* Plug the RPi into the Enviro+ socket and secure with two screws self tapped into the bosses in the case.
|
||||
|
||||

|
||||
|
||||
<span></span>
|
||||
[Top](#TOP)
|
||||
|
||||
---
|
||||
<a name="main_assembly"></a>
|
||||
## Main Assembly
|
||||
### Vitamins
|
||||
|Qty|Description|
|
||||
|---:|:----------|
|
||||
|4| Screw M2 cap x 6mm|
|
||||
|4| Washer M2 x 5mm x 0.3mm|
|
||||
|
||||
|
||||
### Sub-assemblies
|
||||
|
||||
| 1 x RPI_case_assembly | 1 x back_assembly |
|
||||
|---|---|
|
||||
|  | 
|
||||
|
||||
|
||||
|
||||
### Assembly instructions
|
||||

|
||||
|
||||
* Solder the fan wires to the veroboard assembly
|
||||
|
||||

|
||||
|
||||
* Slide the back assembly into the case and secure with four M2 x 6mm cap screws and washers.
|
||||
|
||||

|
||||
|
||||
<span></span>
|
||||
[Top](#TOP)
|
45
examples/EnviroPlus/scad/fan_controller.scad
Normal file
@@ -0,0 +1,45 @@
|
||||
//
|
||||
//! Environmental monitor using Enviro+ sensor board and a Raspberry Pi Zero.
|
||||
//
|
||||
// GNU GPL v2
|
||||
// nop.head@gmail.com
|
||||
// hydraraptor.blogspot.com
|
||||
//
|
||||
// Top level model
|
||||
//
|
||||
|
||||
include <NopSCADlib/core.scad>
|
||||
use <NopSCADlib/vitamins/veroboard.scad>
|
||||
include <NopSCADlib/vitamins/smds.scad>
|
||||
|
||||
fan_vb = vero("fan_vb", "fan_controller", 6, 6, breaks = [[2, 1], [2 + eps, 5]],
|
||||
components = [
|
||||
[5, 3, 90, "link", inch(0.4), undef, undef, 2.5],
|
||||
[0, 5, 0, "link", 0, 4, undef, 2.5],
|
||||
[0, 1, 0, "link", 0, 4, undef, 2.5],
|
||||
[0, 0, 0, "link", 0, 4, undef, 2.5],
|
||||
[2, 5, 0, "-smd_res", RES0805, "3K3"],
|
||||
[4, 4.7, 90, "-smd_cap", CAP1206, 1.2, "10uF"],
|
||||
[2, 2.5, 180, "-smd_sot", SOT223, "FZT851"],
|
||||
],
|
||||
joints = [[5, 1], [5, 5], [0, [0, 1, 5]]]
|
||||
);
|
||||
|
||||
//! The fan controller is a single transistor wired as a Miller integrator that effectively multiplies the capacitor value by the gain of the transistor.
|
||||
//! It converts the PWM signal on GPI4 to a stead DC voltage so that the fan doesn't whine, or stutter.
|
||||
//!
|
||||
//! 
|
||||
//!
|
||||
//! ***
|
||||
//! * Make two track cuts as shown, one wide and the other narrow.
|
||||
//!
|
||||
//! 
|
||||
//!
|
||||
//! 1. Add the SMT compeonents and then the wire links.
|
||||
//! 1. Add more solder around the transistor to act as a heatsink.
|
||||
//!
|
||||
//! 
|
||||
//!
|
||||
module fan_controller_assembly() rotate(90) vflip(!exploded()) veroboard_assembly(fan_vb, -vero_thickness(fan_vb) - 1.4, 0);
|
||||
|
||||
fan_controller_assembly();
|
518
examples/EnviroPlus/scad/main.scad
Normal file
@@ -0,0 +1,518 @@
|
||||
//
|
||||
//! Environmental monitor using Enviro+ sensor board and a Raspberry Pi Zero.
|
||||
//
|
||||
// GNU GPL v2
|
||||
// nop.head@gmail.com
|
||||
// hydraraptor.blogspot.com
|
||||
//
|
||||
// Top level model
|
||||
//
|
||||
$explode = 0; // [0, 1]
|
||||
assembly = "main"; // [main, back, RPI, case, enviro_case, RPI_case]
|
||||
|
||||
/* [Hidden] */
|
||||
|
||||
show_box = true;
|
||||
show_enviroplus = true;
|
||||
$pp1_colour = "grey";
|
||||
$extrusion_width = 0.5;
|
||||
|
||||
include <NopSCADlib/core.scad>
|
||||
include <NopSCADlib/vitamins/pin_headers.scad>
|
||||
include <NopSCADlib/vitamins/pcbs.scad>
|
||||
include <NopSCADlib/vitamins/fans.scad>
|
||||
|
||||
use <NopSCADlib/vitamins/insert.scad>
|
||||
use <NopSCADlib/vitamins/veroboard.scad>
|
||||
use <NopSCADlib/utils/round.scad>
|
||||
use <NopSCADlib/printed/foot.scad>
|
||||
use <NopSCADlib/printed/printed_box.scad>
|
||||
use <fan_controller.scad>
|
||||
|
||||
rpi = RPI0;
|
||||
pcb = EnviroPlus;
|
||||
fan = fan17x8;
|
||||
foot = Foot(d = 13, h = 5, t = 2, r = 1, screw = M3_pan_screw);
|
||||
module foot_stl() foot(foot);
|
||||
|
||||
rpi_offset = [0, -pcb_width(pcb) / 2 + 0.5, pcb_width(rpi) / 2 + 8.6];
|
||||
rpi_holes = [0, 1];
|
||||
wall = 2;
|
||||
top_thickness = 2;
|
||||
base_thickness = 2;
|
||||
case_inner_rad = 8;
|
||||
|
||||
width = pcb_length(pcb) + 9 + 10;
|
||||
pcb_x = -(width - pcb_length(pcb) - 9) / 2;
|
||||
depth = pcb_width(pcb) + 9;
|
||||
height = pcb_width(rpi) / 2 + rpi_offset.z + 9;
|
||||
bulkhead_outset = 2;
|
||||
bulkhead_inset = 0.5;
|
||||
bulkhead_t = 2;
|
||||
clearance = 0.1;
|
||||
pcb_screw = alternate_screw(hs_pan, pcb_screw(pcb));
|
||||
|
||||
box = pbox(name = "enviro_plus_case", wall = wall, top_t = top_thickness, base_t = base_thickness, screw = M2_cap_screw, radius = case_inner_rad, ridges = [8, 1],
|
||||
size = [width, depth, height]);
|
||||
|
||||
pms5003 = [50, 38, 21];
|
||||
pms5003_wall = 1;
|
||||
pms5003_pos = [width / 2 - pms5003.x / 2 - pms5003_wall - pbox_screw_inset(box) - insert_boss_radius(screw_insert(pbox_screw(box)), wall) - 0.5,
|
||||
depth / 2 - pms5003.z / 2 - wall - 1,
|
||||
height + top_thickness - pms5003.y / 2];
|
||||
|
||||
|
||||
fan_duct_t = 1.7;
|
||||
foam_t = 0;
|
||||
fan_pos = [pms5003_pos.x - pms5003.x / 2 - pms5003_wall - fan_width(fan) / 2 - fan_duct_t, 1 + foam_t, 12 + top_thickness + fan_depth(fan) / 2];
|
||||
fan_socket = 8;
|
||||
|
||||
module fan_shape() {
|
||||
w = fan_width(fan);
|
||||
p = fan_hole_pitch(fan);
|
||||
r = w / 2 - p;
|
||||
|
||||
rounded_square([w, w], r);
|
||||
}
|
||||
|
||||
module fan_duct_stl() {
|
||||
module frame(z, offset, y = -fan_pos.y)
|
||||
translate([0, y, z])
|
||||
linear_extrude(height = eps)
|
||||
offset(offset)
|
||||
fan_shape();
|
||||
|
||||
z = height + top_thickness - fan_pos.z + fan_depth(fan) / 2 - fan_socket;
|
||||
|
||||
translate([0, -fan_pos.y, z])
|
||||
linear_extrude(height = fan_socket)
|
||||
difference() {
|
||||
fan_shape();
|
||||
|
||||
round(1)
|
||||
offset(-fan_duct_t)
|
||||
fan_shape();
|
||||
}
|
||||
|
||||
stl("fan_duct") union() {
|
||||
difference() {
|
||||
hull() {
|
||||
frame(z, 0);
|
||||
|
||||
frame(fan_depth(fan), fan_duct_t + foam_t, 0);
|
||||
}
|
||||
hull() {
|
||||
frame(z, -fan_duct_t);
|
||||
|
||||
frame(fan_depth(fan), foam_t -extrusion_width / 2, 0);
|
||||
}
|
||||
}
|
||||
|
||||
linear_extrude(height = fan_depth(fan))
|
||||
difference() {
|
||||
offset(fan_duct_t + foam_t)
|
||||
fan_shape();
|
||||
|
||||
offset(foam_t)
|
||||
fan_shape();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
module pms5003() {
|
||||
vitamin("pms5003(): PMS5003 particle detector");
|
||||
|
||||
w = pms5003.x;
|
||||
d = pms5003.y;
|
||||
h = pms5003.z;
|
||||
t = 0.1;
|
||||
color("silver")
|
||||
difference() {
|
||||
linear_extrude(height = h, center = true)
|
||||
difference() {
|
||||
square([w, d], center = true);
|
||||
|
||||
for(x = [-1, 1], y = [-1, 1])
|
||||
translate([x * w / 2, y * d / 2])
|
||||
square(2, center = true);
|
||||
}
|
||||
cube([w + 2 * eps, d + 2 * eps, t * 2], center = true);
|
||||
}
|
||||
|
||||
color("black")
|
||||
rounded_rectangle([w - 2 * t, d - 2 * t, h - 2 * t], r = 1, center = true);
|
||||
}
|
||||
|
||||
module pcb_shape(offset)
|
||||
rounded_square([pcb_length(pcb) + 2 * offset, pcb_width(pcb) + 2 * offset], pcb_radius(pcb) + offset);
|
||||
|
||||
module gap() {
|
||||
gap = pcb_component_position(pcb, "-chip");
|
||||
|
||||
translate([gap.x, -gap.y])
|
||||
square([17.5, 20], center = true);
|
||||
}
|
||||
|
||||
module rpi_holes()
|
||||
for(i = rpi_holes) {
|
||||
hole = pcb_coord(rpi, pcb_holes(rpi)[i]);
|
||||
translate([hole.x, rpi_offset.y, -hole.y + rpi_offset.z + top_thickness])
|
||||
rotate([90, 0, 0])
|
||||
children();
|
||||
}
|
||||
|
||||
module feet_positions() {
|
||||
clearance = 2;
|
||||
foot_r = foot_diameter(foot) / 2;
|
||||
x_inset = case_inner_rad + foot_r - pbox_ridges(box).y;
|
||||
z_inset = foot_r + clearance;
|
||||
h = height + base_thickness;
|
||||
|
||||
for(p = [[-1, -1], [1, -1], [0, 1]])
|
||||
translate([p.x * (width / 2 - x_inset), depth / 2 + wall + pbox_ridges(box).y, top_thickness + h / 2 + p.y * (h / 2 - z_inset)])
|
||||
rotate([90, 0, 0])
|
||||
children();
|
||||
}
|
||||
|
||||
module slots(h = 10, expand = 0) {
|
||||
for(comp = [["uSD", 2, 11, 0.7], ["flat_flex", 1, 12, 0.5]]) {
|
||||
p = pcb_component_position(rpi, comp[0]);
|
||||
translate([sign(p.x) * (width / 2 + wall / 2 + pbox_ridges(box).y / 2), rpi_offset.y + pcb_thickness(rpi) + comp[3], top_thickness + rpi_offset.z - p.y])
|
||||
rotate([90, 0, 90])
|
||||
hull() {
|
||||
vertical_tearslot(r = comp[1] + expand, l = comp[2], h = h);
|
||||
|
||||
if(expand)
|
||||
vertical_tearslot(r = comp[1] + expand + h / 2, l = comp[2], h = eps);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
module box_internal_additions() {
|
||||
translate([pcb_x, 0]) {
|
||||
linear_extrude(height = top_thickness + bulkhead_t)
|
||||
difference() {
|
||||
pcb_shape(bulkhead_outset + wall + pbox_ridges(box).y + eps);
|
||||
|
||||
gap();
|
||||
|
||||
pcb_shape(bulkhead_outset + clearance);
|
||||
}
|
||||
|
||||
rpi_holes()
|
||||
hull() {
|
||||
wall = 1.8;
|
||||
r = screw_radius(pcb_screw) + wall;
|
||||
z = depth / 2 + rpi_offset.y + pbox_ridges(box).y + eps;
|
||||
offset = max(r, z);
|
||||
cylinder(r =r, h = z);
|
||||
|
||||
translate([0, -offset - r, z])
|
||||
cube(eps);
|
||||
}
|
||||
}
|
||||
d = washer_diameter(screw_washer(foot_screw(foot))) + 1;
|
||||
h = pbox_ridges(box).y;
|
||||
feet_positions()
|
||||
translate_z(wall - eps)
|
||||
cylinder(d2 = d, d1 = d + 2 * h, h = h);
|
||||
|
||||
slots(wall + pbox_ridges(box).y + eps, 1);
|
||||
}
|
||||
|
||||
module box_external_additions() {
|
||||
amp = pbox_ridges(box).y + eps;
|
||||
d = foot_diameter(foot) + 1;
|
||||
feet_positions()
|
||||
cylinder(d1 = d, d2 = d + 2 * amp, h = amp);
|
||||
|
||||
slots(wall + pbox_ridges(box).y + eps, 1);
|
||||
}
|
||||
|
||||
|
||||
module box_holes() {
|
||||
translate([pcb_x, 0]) {
|
||||
linear_extrude(height = top_thickness + eps)
|
||||
pcb_shape(clearance);
|
||||
|
||||
rpi_holes()
|
||||
teardrop_plus(r = screw_pilot_hole(pcb_screw), h = 7 - 1.6, center = false);
|
||||
}
|
||||
feet_positions()
|
||||
teardrop(r = screw_pilot_hole(foot_screw(foot)), h = 10, center = true);
|
||||
|
||||
grills = 7;
|
||||
bar = 1.6;
|
||||
x = pcb_x + pcb_length(pcb) / 2 + 2 * wall + pbox_ridges(box).y + 2 * eps;
|
||||
w = width / 2 - x;
|
||||
d = depth - case_inner_rad;
|
||||
pitch = d / (grills - 1);
|
||||
for(i = [0 : grills -1])
|
||||
let(w = i == 0 || i == grills -1 ? w - 1 : w)
|
||||
translate([x + w / 2, -d / 2 + i * pitch])
|
||||
rounded_rectangle([w, pitch - bar, 10], 1);
|
||||
|
||||
slots();
|
||||
}
|
||||
|
||||
module bulkhead_stl() {
|
||||
holes = pcb_holes(pcb);
|
||||
pitch = max([for(h = holes) pcb_coord(pcb, h).x]) - min([for(h = holes) pcb_coord(pcb, h).x]);
|
||||
boss_r = (pitch - 51.4) / 2;
|
||||
|
||||
stl("bulkhead")
|
||||
linear_extrude(height = bulkhead_t)
|
||||
difference() {
|
||||
pcb_shape(bulkhead_outset);
|
||||
|
||||
gap();
|
||||
|
||||
difference() {
|
||||
pcb_shape(-bulkhead_inset);
|
||||
|
||||
pcb_screw_positions(pcb)
|
||||
rotate($i * 90)
|
||||
hull() {
|
||||
circle(boss_r);
|
||||
|
||||
translate([boss_r - eps, -boss_r])
|
||||
square([eps, boss_r]);
|
||||
|
||||
translate([-boss_r, boss_r - eps])
|
||||
square([boss_r, eps]);
|
||||
|
||||
translate([-boss_r, -boss_r])
|
||||
square(eps);
|
||||
}
|
||||
}
|
||||
|
||||
pcb_screw_positions(pcb)
|
||||
poly_circle(screw_clearance_radius(pcb_screw));
|
||||
}
|
||||
}
|
||||
|
||||
module enviro_plus_case_stl() {
|
||||
pbox(box) {
|
||||
box_internal_additions();
|
||||
box_holes();
|
||||
box_external_additions();
|
||||
}
|
||||
}
|
||||
|
||||
module base_additions() {
|
||||
w = pms5003.x + clearance;
|
||||
d = pms5003.z + clearance;
|
||||
wall = pms5003_wall;
|
||||
|
||||
translate([pms5003_pos.x, -pms5003_pos.y])
|
||||
linear_extrude(height = base_thickness + pms5003.y)
|
||||
difference() {
|
||||
square([w + 2 * wall, d + 2 * wall], center = true);
|
||||
square([w, d], center = true);
|
||||
}
|
||||
|
||||
translate([fan_pos.x, 0])
|
||||
linear_extrude(height = top_thickness + fan_socket)
|
||||
difference() {
|
||||
offset(wall)
|
||||
fan_shape();
|
||||
|
||||
fan_shape();
|
||||
}
|
||||
}
|
||||
|
||||
module base_holes() {
|
||||
for(i = [0 : 1]) {
|
||||
p = pcb_component_position(rpi, "usb_uA", i);
|
||||
translate([p.x + pcb_x, -rpi_offset.y - pcb_thickness(rpi) - 1.3])
|
||||
rounded_rectangle([11,7, 100], 0.5, true);
|
||||
}
|
||||
|
||||
translate([pms5003_pos.x, -pms5003_pos.y])
|
||||
rounded_rectangle([pms5003.x - 2 ,pms5003.z - 2, 100], 2, true);
|
||||
|
||||
translate([fan_pos.x, 0])
|
||||
linear_extrude(height = 2 * base_thickness + eps, center = true)
|
||||
round(1)
|
||||
offset(-fan_duct_t)
|
||||
fan_shape();
|
||||
}
|
||||
|
||||
module enviro_plus_case_base_stl()
|
||||
pbox_base(box) {
|
||||
base_additions();
|
||||
base_holes();
|
||||
}
|
||||
|
||||
//! * Solder a right angle connector to the Raspberry Pi Zero.
|
||||
module RPI_assembly()
|
||||
assembly("RPI") {
|
||||
pcb(rpi);
|
||||
|
||||
pcb_grid(rpi, 9.5, 0.5, -0.6)
|
||||
rotate(180)
|
||||
explode(20)
|
||||
pin_header(2p54header, 20, 2, right_angle = true);
|
||||
}
|
||||
|
||||
//! 1. Solvent weld or glue the bulkhead into the recess in the bottom of the case.
|
||||
//! 1. Fit the heatfit inserts with a soldering iron with a conical bit heated to about 200°C.
|
||||
//! 1. Tap the three holes for the feet with an M3 tap.
|
||||
//! 1. Screw on the three feet with M3 x 6mm pan screws and washers.
|
||||
module case_assembly() pose([ 29.60, 0.00, 158.00 ], exploded = true) pose([ 198.00, 0.00, 352.80 ], exploded = false)
|
||||
assembly("case") {
|
||||
if(show_box)
|
||||
stl_colour(pp1_colour) render() enviro_plus_case_stl();
|
||||
else
|
||||
render() difference() {
|
||||
enviro_plus_case_stl();
|
||||
|
||||
translate_z(height / 2)
|
||||
cube([100, 100, height - 20], center = true);
|
||||
}
|
||||
|
||||
pbox_inserts(box);
|
||||
|
||||
translate([pcb_x, 0, top_thickness])
|
||||
explode(20)
|
||||
stl_colour(pp2_colour) render() bulkhead_stl();
|
||||
|
||||
feet_positions() {
|
||||
foot_assembly(0, foot);
|
||||
|
||||
vflip()
|
||||
explode(20, explode_children = true)
|
||||
translate_z(foot_thickness(foot))
|
||||
screw_and_washer(foot_screw(foot), 6);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
//! * Solder the fan_controller to the Enviro+ expansion connector at the 5V, GND and #4 pins.
|
||||
module enviro_assembly() hflip(exploded())
|
||||
assembly("enviro") {
|
||||
if(show_enviroplus)
|
||||
pcb(pcb);
|
||||
|
||||
pcb_grid(pcb, 5.5, 2.5, -pcb_thickness(pcb)) {
|
||||
hflip()
|
||||
explode(15)
|
||||
fan_controller_assembly();
|
||||
}
|
||||
if(!exploded())
|
||||
for(x = [8, 7, 3])
|
||||
pcb_grid(pcb, x, 0, 0.05)
|
||||
solder_meniscus(pcb, 0.39, 1);
|
||||
}
|
||||
|
||||
//! * Screw the Enviro+ PCB to the front of the case using M2.5 x 8mm pan screws with washer and nuts on the inside.
|
||||
module enviro_case_assembly() pose([ 231.40, 0.00, 1.20 ])
|
||||
assembly("enviro_case") {
|
||||
case_assembly();
|
||||
|
||||
translate([pcb_x, 0, top_thickness])
|
||||
vflip() explode(20, explode_children = true) {
|
||||
t = pcb_thickness(pcb);
|
||||
nut = screw_nut(pcb_screw);
|
||||
washer = screw_washer(pcb_screw);
|
||||
|
||||
no_explode() enviro_assembly();
|
||||
|
||||
pcb_screw_positions(pcb) {
|
||||
translate_z(t)
|
||||
screw(pcb_screw, screw_longer_than(t + bulkhead_t + nut_thickness(nut, true) + washer_thickness(washer)));
|
||||
|
||||
translate_z(-bulkhead_t)
|
||||
vflip()
|
||||
explode(20, explode_children = true)
|
||||
nut_and_washer(nut, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//! * Plug the RPi into the Enviro+ socket and secure with two screws self tapped into the bosses in the case.
|
||||
module RPI_case_assembly() pose([ 20.50, 0.00, 153.30 ])
|
||||
assembly("RPI_case") {
|
||||
enviro_case_assembly();
|
||||
|
||||
translate([pcb_x, 0]) {
|
||||
translate_z(top_thickness) {
|
||||
|
||||
translate(rpi_offset)
|
||||
rotate([-90, 0, 0])
|
||||
RPI_assembly();
|
||||
}
|
||||
rpi_holes()
|
||||
vflip()
|
||||
translate_z(pcb_thickness(rpi))
|
||||
screw(pcb_screw, 6.4);
|
||||
}
|
||||
}
|
||||
|
||||
//! 1. Print the fan duct in flexible TPE with low infill.
|
||||
//! 1. Slide the pms5003 into the printed receptacle with the fan to the outside. Secure with tape if it is loose.
|
||||
//! 1. Slide the fan into the fan duct.
|
||||
//! 1. Slide the fan duct into the printed recepacle.
|
||||
module back_assembly() pose([ 228.60, 0.00, 24.30 ])
|
||||
assembly("back") {
|
||||
translate(pms5003_pos)
|
||||
explode(-50)
|
||||
rotate([90, 0, 0])
|
||||
pms5003();
|
||||
|
||||
explode(-20, explode_children = true)
|
||||
translate(fan_pos) {
|
||||
explode(-20)
|
||||
fan(fan);
|
||||
|
||||
translate_z(-fan_depth(fan) / 2)
|
||||
stl_colour(pp4_colour)
|
||||
render()
|
||||
fan_duct_stl();
|
||||
}
|
||||
|
||||
translate_z(height + top_thickness + base_thickness + eps) vflip()
|
||||
stl_colour(show_box ? pp1_colour : pp2_colour) render() enviro_plus_case_base_stl();
|
||||
}
|
||||
|
||||
//! * Solder the fan wires to the veroboard assembly
|
||||
//!
|
||||
//! 
|
||||
//!
|
||||
//! * Slide the back assembly into the case and secure with four M2 x 6mm cap screws and washers.
|
||||
module main_assembly() pose([170, 335, 0], exploded = false) pose([ 42.20, 0.00, 159.60 ], exploded = true)
|
||||
assembly("main") {
|
||||
RPI_case_assembly();
|
||||
|
||||
explode(20, explode_children = true) {
|
||||
pbox_base_screws(box);
|
||||
|
||||
back_assembly();
|
||||
}
|
||||
}
|
||||
|
||||
if($preview) {
|
||||
if(assembly == "main")
|
||||
main_assembly();
|
||||
else if(assembly == "case")
|
||||
case_assembly();
|
||||
else if(assembly == "back")
|
||||
back_assembly();
|
||||
else if(assembly == "RPI")
|
||||
RPI_assembly();
|
||||
else if(assembly == "RPI_case")
|
||||
RPI_case_assembly();
|
||||
else if(assembly == "enviro_case")
|
||||
enviro_case_assembly();
|
||||
}
|
||||
else {
|
||||
gap = 5;
|
||||
|
||||
enviro_plus_case_stl();
|
||||
|
||||
translate([0, -depth - gap])
|
||||
enviro_plus_case_base_stl();
|
||||
|
||||
translate([0, -2 * (depth + gap)])
|
||||
bulkhead_stl();
|
||||
}
|
BIN
examples/EnviroPlus/stls/bulkhead.png
Normal file
After Width: | Height: | Size: 15 KiB |
4594
examples/EnviroPlus/stls/bulkhead.stl
Normal file
BIN
examples/EnviroPlus/stls/enviro_plus_case.png
Normal file
After Width: | Height: | Size: 14 KiB |
99318
examples/EnviroPlus/stls/enviro_plus_case.stl
Normal file
BIN
examples/EnviroPlus/stls/enviro_plus_case_base.png
Normal file
After Width: | Height: | Size: 7.9 KiB |
12070
examples/EnviroPlus/stls/enviro_plus_case_base.stl
Normal file
BIN
examples/EnviroPlus/stls/fan_duct.png
Normal file
After Width: | Height: | Size: 14 KiB |
8738
examples/EnviroPlus/stls/fan_duct.stl
Normal file
BIN
examples/EnviroPlus/stls/foot.png
Normal file
After Width: | Height: | Size: 26 KiB |
15318
examples/EnviroPlus/stls/foot.stl
Normal file
Before Width: | Height: | Size: 96 KiB After Width: | Height: | Size: 96 KiB |
Before Width: | Height: | Size: 108 KiB After Width: | Height: | Size: 108 KiB |
Before Width: | Height: | Size: 105 KiB After Width: | Height: | Size: 105 KiB |
Before Width: | Height: | Size: 22 KiB After Width: | Height: | Size: 22 KiB |
Before Width: | Height: | Size: 138 KiB After Width: | Height: | Size: 137 KiB |
Before Width: | Height: | Size: 121 KiB After Width: | Height: | Size: 121 KiB |
Before Width: | Height: | Size: 201 KiB After Width: | Height: | Size: 201 KiB |
Before Width: | Height: | Size: 124 KiB After Width: | Height: | Size: 123 KiB |
Before Width: | Height: | Size: 135 KiB After Width: | Height: | Size: 135 KiB |
16
examples/MainsBreakOutBox/bom/bom.csv
Normal file
@@ -0,0 +1,16 @@
|
||||
'Ferrule for 1.5mm^2 wire - not shown', 3
|
||||
'Wire blue 30/0.25mm strands, length 150mm - not shown', 2
|
||||
'Wire brown 30/0.25mm strands, length 150mm - not shown', 2
|
||||
'Wire green & yellow 30/0.25mm strands, length 150mm - not shown', 2
|
||||
'IEC inlet for ATX', 1
|
||||
'Heatfit insert M3', 2
|
||||
'4mm shielded jack socket blue', 2
|
||||
'4mm shielded jack socket brown', 1
|
||||
'4mm shielded jack socket green', 2
|
||||
'Mains socket 13A', 1
|
||||
'Nut M3 x 2.4mm nyloc', 6
|
||||
'Screw M3 cs cap x 12mm', 2
|
||||
'Screw M3 cs cap x 20mm', 2
|
||||
'Screw M3 dome x 10mm', 4
|
||||
'Heatshrink sleeving ID 3.2mm x 15mm - not shown', 8
|
||||
'Washer M3 x 7mm x 0.5mm', 10
|
|
@@ -3,6 +3,7 @@
|
||||
"name": "base_assembly",
|
||||
"big": null,
|
||||
"ngb": false,
|
||||
"zoomed": 0,
|
||||
"count": 1,
|
||||
"assemblies": {},
|
||||
"vitamins": {
|
||||
@@ -22,6 +23,7 @@
|
||||
"name": "feet_assembly",
|
||||
"big": null,
|
||||
"ngb": false,
|
||||
"zoomed": 0,
|
||||
"count": 1,
|
||||
"assemblies": {
|
||||
"base_assembly": 1
|
||||
@@ -49,6 +51,7 @@
|
||||
"name": "mains_in_assembly",
|
||||
"big": null,
|
||||
"ngb": false,
|
||||
"zoomed": 0,
|
||||
"count": 1,
|
||||
"assemblies": {
|
||||
"feet_assembly": 1
|
||||
@@ -86,6 +89,7 @@
|
||||
"name": "main_assembly",
|
||||
"big": null,
|
||||
"ngb": false,
|
||||
"zoomed": 0,
|
||||
"count": 1,
|
||||
"assemblies": {
|
||||
"mains_in_assembly": 1
|
||||
|
11
examples/MainsBreakOutBox/platters/all.scad
Normal file
@@ -0,0 +1,11 @@
|
||||
include <NopSCADlib/core.scad>
|
||||
|
||||
*use_stl("socket_box"); // Importing the STL gives a CGAL error although NetFabb finds nothing wrong with it.
|
||||
|
||||
use <../scad/bob_main.scad>
|
||||
|
||||
render() socket_box_stl();
|
||||
|
||||
for(i = [0 : 3])
|
||||
translate([i * 25 - 1.5 * 25, -70])
|
||||
use_stl("foot");
|
@@ -31,7 +31,8 @@
|
||||
//! while its earth is disconnected. Don't be tempted to float the earth of an oscilloscope this way, use a mains isolation transformer to power the DUT instead.
|
||||
//! Earth leakage can be measured Canadian CSA style by disconnected the neutral link from the left socket and linking the central neutral to the live.
|
||||
//
|
||||
$extrusion_width = 0.5;
|
||||
$extrusion_width = 0.4;
|
||||
$layer_height = 0.2;
|
||||
$pp1_colour = "dimgrey";
|
||||
$pp2_colour = [0.9, 0.9, 0.9];
|
||||
|
||||
|
5
examples/MainsBreakOutBox/stls/deps/all.txt
Normal file
@@ -0,0 +1,5 @@
|
||||
socket_box.stl
|
||||
foot.stl
|
||||
foot.stl
|
||||
foot.stl
|
||||
foot.stl
|
Before Width: | Height: | Size: 23 KiB After Width: | Height: | Size: 23 KiB |
87250
examples/MainsBreakOutBox/stls/printed/all.stl
Normal file
Before Width: | Height: | Size: 121 KiB After Width: | Height: | Size: 121 KiB |
BIN
gallery/IOT_LOAD.png
Normal file
After Width: | Height: | Size: 259 KiB |
Before Width: | Height: | Size: 287 KiB After Width: | Height: | Size: 287 KiB |
Before Width: | Height: | Size: 121 KiB After Width: | Height: | Size: 121 KiB |
BIN
gallery/PSU_cover.png
Normal file
After Width: | Height: | Size: 279 KiB |
BIN
gallery/PotBox.png
Normal file
After Width: | Height: | Size: 164 KiB |
Before Width: | Height: | Size: 252 KiB After Width: | Height: | Size: 390 KiB |
Before Width: | Height: | Size: 202 KiB After Width: | Height: | Size: 202 KiB |
@@ -1,40 +1,35 @@
|
||||
# A gallery of projects made with NopSCADlib
|
||||
<a name="TOP"></a>
|
||||
## ArduinoThermostat
|
||||
Arduino thermostat to control a beer fridge to use it as an environmental chamber.
|
||||
|
||||

|
||||
|
||||
|
||||
<a name="TOP"></a>
|
||||
## EnviroPlus
|
||||
Environmental monitor using Enviro+ sensor board and a Raspberry Pi Zero.
|
||||
|
||||

|
||||
|
||||
|
||||
<a name="TOP"></a>
|
||||
## FilamentDryBox
|
||||
A small fan oven with a spool holder to keep the filament warm and dry.
|
||||
|
||||

|
||||
|
||||
|
||||
<a name="TOP"></a>
|
||||
## HydraBot
|
||||
Current state of HydraRaptor after being modified for laser engraving.
|
||||
|
||||

|
||||
|
||||
|
||||
<a name="TOP"></a>
|
||||
## IOT 50V PSU
|
||||
WiFi controllable PSU
|
||||
|
||||

|
||||
|
||||
## IOT LOAD
|
||||
WiFi controllable programmable load
|
||||
|
||||

|
||||
|
||||
<a name="TOP"></a>
|
||||
## Lab ATX PSU
|
||||
Bench power supply built around an ATX PSU.
|
||||
|
||||
@@ -47,15 +42,11 @@ Bench power supply built around an ATX PSU.
|
||||
|
||||
|
||||
|
||||
|
||||
<a name="TOP"></a>
|
||||
## Laser Load
|
||||
15kV dummy load for testing CO2 laser PSUs
|
||||
|
||||

|
||||
|
||||
|
||||
<a name="TOP"></a>
|
||||
## MainsBreakOutBox
|
||||
13A socket break out box with 4mm jacks to measure voltage and / or load current and earth leakage current.
|
||||
|
||||
@@ -72,8 +63,6 @@ Earth leakage can be measured Canadian CSA style by disconnected the neutral lin
|
||||
|
||||

|
||||
|
||||
|
||||
<a name="TOP"></a>
|
||||
## Mains Box
|
||||
Mains isolated and variable supply with metering.
|
||||
|
||||
@@ -81,15 +70,21 @@ Mains isolated and variable supply with metering.
|
||||
|
||||
|
||||
|
||||
## PSU Cover
|
||||
A base and shroud to make PSU safe to sit on a desk
|
||||
|
||||

|
||||
|
||||
## PotBox
|
||||
Potentiometer box with course and fine controls and three 4mm binding posts
|
||||
|
||||

|
||||
|
||||
<a name="TOP"></a>
|
||||
## SunBot
|
||||
A solar tracker to keep a solar panel pointing at the sun.
|
||||
|
||||

|
||||
|
||||
|
||||
<a name="TOP"></a>
|
||||
## Turntable
|
||||
WiFi enabled remote control turntable for photography
|
||||
|
||||
@@ -97,8 +92,6 @@ WiFi enabled remote control turntable for photography
|
||||
|
||||
Was actually made from DiBond but shown made with carbon fibre here.
|
||||
|
||||
|
||||
<a name="TOP"></a>
|
||||
## Variac
|
||||
Motorised variac with WiFi control, see [hydraraptor.blogspot.com/2018/04/esp8266-spi-spy](https://hydraraptor.blogspot.com/2018/04/esp8266-spi-spy.html)
|
||||
|
||||
@@ -106,4 +99,3 @@ Motorised variac with WiFi control, see [hydraraptor.blogspot.com/2018/04/esp826
|
||||
|
||||
|
||||
|
||||
|
||||
|
@@ -24,22 +24,24 @@
|
||||
// bom defaults to 0
|
||||
// Setting $bom on the command line or in the main file before including lib.scad overrides it everywhere.
|
||||
// Setting $bom after including lib overrides bom in the libs but not in the local file.
|
||||
// Setting $_bom in the local file overrides it in the local file but not in the libs.
|
||||
//
|
||||
rr_green = [0, 146/255, 0]; // RepRap logo colour
|
||||
crimson = [220/255, 20/255, 60/255];
|
||||
|
||||
$_bom = is_undef($bom) ? 0 : $bom; // 0 no bom, 1 assemblies and stls, 2 vitamins as well
|
||||
$exploded = is_undef($explode) ? 0 : $explode; // 1 for exploded view
|
||||
layer_height = is_undef($layer_height) ? 0.25 : $layer_height; // layer heigth when printing
|
||||
layer_height = is_undef($layer_height) ? 0.25 : $layer_height; // layer height when printing
|
||||
layer_height0 = is_undef($layer_height0) ? layer_height : $layer_height0; // height of first layer if different
|
||||
extrusion_width = is_undef($extrusion_width) ? 0.5 : $extrusion_width; // filament width when printing
|
||||
nozzle = is_undef($nozzle) ? 0.45 : $nozzle; // 3D printer nozzle
|
||||
cnc_bit_r = is_undef($cnc_bit_r) ? 1.2 : $cnc_bit_r; // minimum tool radius when milling 2D objects
|
||||
pp1_colour = is_undef($pp1_colour) ? rr_green : $pp1_colour; // printed part colour 1, RepRap logo colour
|
||||
pp2_colour = is_undef($pp2_colour) ? "Crimson" : $pp2_colour; // printed part colour 2
|
||||
pp3_colour = is_undef($pp3_colour) ? "SteelBlue" : $pp3_colour; // printed part colour 3
|
||||
pp4_colour = is_undef($pp4_colour) ? "darkorange" : $pp4_colour;// printed part colour 4
|
||||
show_rays = is_undef($show_rays) ? false : $show_rays; // show camera sight lines and light direction
|
||||
show_threads = is_undef($show_threads) ? false : $show_threads; // show screw threads
|
||||
show_plugs = is_undef($show_plugs) ? false : $show_plugs; // plugs on headers
|
||||
teardrop_angle = is_undef($teardrop_angle) ? 45 : $teardrop_angle; // teardrop angle
|
||||
pp1_colour = is_undef($pp1_colour) ? rr_green : $pp1_colour;// printed part colour 1, RepRap logo colour
|
||||
pp2_colour = is_undef($pp2_colour) ? crimson : $pp2_colour;// printed part colour 2
|
||||
pp3_colour = is_undef($pp3_colour) ? "SteelBlue" : $pp3_colour;// printed part colour 3
|
||||
pp4_colour = is_undef($pp4_colour) ? "darkorange" : $pp4_colour;// printed part colour 4
|
||||
|
||||
|
||||
// Minimum wall is about two filaments wide but we extrude it closer to get better bonding
|
||||
squeezed_wall = $preview ? 2 * extrusion_width - layer_height * (1 - PI / 4)
|
||||
@@ -50,12 +52,11 @@ eps = 1/128; // small fudge factor to stop CSG barfing on coincident faces.
|
||||
$fa = 6;
|
||||
$fs = extrusion_width / 2;
|
||||
|
||||
function round_to_layer(z) = ceil(z / layer_height) * layer_height;
|
||||
// Some additional named colours
|
||||
function grey(n) = [0.01, 0.01, 0.01] * n; //! Generate a shade of grey to pass to color().
|
||||
gold = [255/255, 215/255, 0/255];
|
||||
brass = [255/255, 220/255, 100/255];
|
||||
silver = [0.75, 0.75, 0.75];
|
||||
silver = [0.75, 0.75, 0.75];
|
||||
gold = [255, 215, 0] / 255;
|
||||
brass = [255, 220, 100] / 255;
|
||||
copper = [230, 140, 51] / 255;
|
||||
|
||||
/*
|
||||
* Enums
|
||||
@@ -71,11 +72,6 @@ hs_grub = 4; // pulley set screw
|
||||
hs_cs_cap = 5;
|
||||
hs_dome = 6;
|
||||
//
|
||||
// Hot end descriptions
|
||||
//
|
||||
jhead = 1;
|
||||
e3d = 2;
|
||||
//
|
||||
// Face enumeration
|
||||
//
|
||||
f_bottom = 0;
|
||||
|
10
lib.scad
@@ -26,7 +26,10 @@ include <vitamins/psus.scad>
|
||||
include <vitamins/pcbs.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>
|
||||
@@ -37,7 +40,6 @@ include <vitamins/extrusion_brackets.scad>
|
||||
include <vitamins/geared_steppers.scad>
|
||||
include <vitamins/hot_ends.scad>
|
||||
include <vitamins/inserts.scad>
|
||||
include <vitamins/kp_pillow_blocks.scad>
|
||||
include <vitamins/ldrs.scad>
|
||||
include <vitamins/leadnuts.scad>
|
||||
include <vitamins/led_meter.scad>
|
||||
@@ -47,12 +49,13 @@ include <vitamins/mains_sockets.scad>
|
||||
include <vitamins/modules.scad>
|
||||
include <vitamins/panel_meters.scad>
|
||||
include <vitamins/pillars.scad>
|
||||
include <vitamins/pillow_blocks.scad>
|
||||
include <vitamins/pin_headers.scad>
|
||||
include <vitamins/pulleys.scad>
|
||||
include <vitamins/ring_terminals.scad>
|
||||
include <vitamins/rails.scad>
|
||||
include <vitamins/rod.scad>
|
||||
include <vitamins/scs_bearing_blocks.scad>
|
||||
include <vitamins/servo_motors.scad>
|
||||
include <vitamins/shaft_couplings.scad>
|
||||
include <vitamins/sheets.scad>
|
||||
include <vitamins/sk_brackets.scad>
|
||||
@@ -60,6 +63,7 @@ include <vitamins/spools.scad>
|
||||
include <vitamins/ssrs.scad>
|
||||
include <vitamins/stepper_motors.scad>
|
||||
include <vitamins/swiss_clips.scad>
|
||||
include <vitamins/terminal.scad>
|
||||
include <vitamins/toggles.scad>
|
||||
include <vitamins/transformers.scad>
|
||||
include <vitamins/tubings.scad>
|
||||
@@ -89,7 +93,7 @@ use <utils/gears.scad>
|
||||
use <utils/hanging_hole.scad>
|
||||
use <utils/fillet.scad>
|
||||
use <utils/rounded_polygon.scad>
|
||||
use <utils/rounded_right_triangle.scad>
|
||||
use <utils/rounded_triangle.scad>
|
||||
use <utils/layout.scad>
|
||||
use <utils/round.scad>
|
||||
use <utils/offset.scad>
|
||||
|
BIN
libtest.png
Before Width: | Height: | Size: 882 KiB After Width: | Height: | Size: 973 KiB |
159
libtest.scad
@@ -33,18 +33,25 @@
|
||||
//!
|
||||
//! See [usage](docs/usage.md) for requirements, installation instructions and a usage guide.
|
||||
//!
|
||||
//! A list of changes classified as breaking, additions or fixes is maintained in [CHANGELOG.md](CHANGELOG.md).
|
||||
//!
|
||||
//! <img src="libtest.png" width="100%"/>
|
||||
//
|
||||
// This file shows all the parts in the library.
|
||||
//
|
||||
include <lib.scad>
|
||||
|
||||
use <tests/7_segments.scad>
|
||||
use <tests/ball_bearings.scad>
|
||||
use <tests/batteries.scad>
|
||||
use <tests/bearing_blocks.scad>
|
||||
use <tests/belts.scad>
|
||||
use <tests/BLDC_motors.scad>
|
||||
use <tests/blowers.scad>
|
||||
use <tests/box_sections.scad>
|
||||
use <tests/bulldogs.scad>
|
||||
use <tests/buttons.scad>
|
||||
use <tests/cable_clip.scad>
|
||||
use <tests/cable_strips.scad>
|
||||
use <tests/cameras.scad>
|
||||
use <tests/camera_housing.scad>
|
||||
@@ -62,12 +69,12 @@ use <tests/hot_ends.scad>
|
||||
use <tests/IECs.scad>
|
||||
use <tests/inserts.scad>
|
||||
use <tests/jack.scad>
|
||||
use <tests/KP_pillow_blocks.scad>
|
||||
use <tests/leadnuts.scad>
|
||||
use <tests/LDRs.scad>
|
||||
use <tests/LEDs.scad>
|
||||
use <tests/light_strips.scad>
|
||||
use <tests/linear_bearings.scad>
|
||||
use <tests/LED_bezel.scad>
|
||||
use <tests/LED_meters.scad>
|
||||
use <tests/magnets.scad>
|
||||
use <tests/microswitches.scad>
|
||||
@@ -78,6 +85,8 @@ use <tests/opengrab.scad>
|
||||
use <tests/panel_meters.scad>
|
||||
use <tests/PCBs.scad>
|
||||
use <tests/pillars.scad>
|
||||
use <tests/pillow_blocks.scad>
|
||||
use <tests/potentiometers.scad>
|
||||
use <tests/press_fit.scad>
|
||||
use <tests/PSUs.scad>
|
||||
use <tests/pulleys.scad>
|
||||
@@ -86,8 +95,8 @@ use <tests/ring_terminals.scad>
|
||||
use <tests/rockers.scad>
|
||||
use <tests/rod.scad>
|
||||
use <tests/screws.scad>
|
||||
use <tests/SCS_bearing_blocks.scad>
|
||||
use <tests/sealing_strip.scad>
|
||||
use <tests/servo_motors.scad>
|
||||
use <tests/shaft_couplings.scad>
|
||||
use <tests/sheets.scad>
|
||||
use <tests/SK_brackets.scad>
|
||||
@@ -116,7 +125,9 @@ use <tests/fixing_block.scad>
|
||||
use <tests/flat_hinge.scad>
|
||||
use <tests/foot.scad>
|
||||
use <tests/handle.scad>
|
||||
use <tests/knob.scad>
|
||||
use <tests/PCB_mount.scad>
|
||||
use <tests/pocket_handle.scad>
|
||||
use <tests/printed_box.scad>
|
||||
use <tests/printed_pulleys.scad>
|
||||
use <tests/ribbon_clamp.scad>
|
||||
@@ -139,25 +150,55 @@ cable_grommets_y = 0;
|
||||
translate([x5, cable_grommets_y])
|
||||
cable_grommets();
|
||||
|
||||
translate([x5, cable_grommets_y + 30])
|
||||
led_bezels();
|
||||
|
||||
translate([x5 + 50, cable_grommets_y])
|
||||
ribbon_clamps();
|
||||
|
||||
translate([x5 + 95, cable_grommets_y])
|
||||
press_fits();
|
||||
|
||||
translate([x5, cable_grommets_y + 60])
|
||||
fixing_blocks_y = cable_grommets_y + 60;
|
||||
translate([x5, fixing_blocks_y])
|
||||
fixing_blocks();
|
||||
|
||||
translate([x5, cable_grommets_y + 90])
|
||||
corner_blocks_y = fixing_blocks_y + 30;
|
||||
translate([x5, corner_blocks_y])
|
||||
corner_blocks();
|
||||
|
||||
translate([x5, cable_grommets_y + 150])
|
||||
feet();
|
||||
|
||||
translate([x5 + 70, cable_grommets_y + 150])
|
||||
screw_knobs_y = corner_blocks_y + 70;
|
||||
translate([x5, screw_knobs_y])
|
||||
screw_knobs();
|
||||
|
||||
translate([x5, cable_grommets_y + 470]) {
|
||||
knobs_y = screw_knobs_y + 40;
|
||||
translate([640, knobs_y])
|
||||
printed_pulley_test();
|
||||
|
||||
translate([x5, knobs_y])
|
||||
knobs();
|
||||
|
||||
clips_y = knobs_y + 50;
|
||||
translate([x5, clips_y])
|
||||
cable_clips();
|
||||
|
||||
strap_y = clips_y + 50;
|
||||
translate([x5 + 60, strap_y])
|
||||
strap_handles();
|
||||
|
||||
translate([x6, strap_y])
|
||||
feet();
|
||||
|
||||
handle_y = strap_y + 50;
|
||||
translate([x5, handle_y])
|
||||
handle();
|
||||
|
||||
pocket_y = handle_y + 70;
|
||||
translate([x5 + 65, pocket_y])
|
||||
pocket_handles();
|
||||
|
||||
hinge_y = pocket_y + 100;
|
||||
translate([x5, hinge_y]) {
|
||||
door_hinges()
|
||||
door_latches();
|
||||
|
||||
@@ -165,28 +206,19 @@ translate([x5, cable_grommets_y + 470]) {
|
||||
flat_hinges();
|
||||
}
|
||||
|
||||
translate([x5, cable_grommets_y + 370])
|
||||
no_explode() socket_boxes();
|
||||
|
||||
translate([x5 + 60, cable_grommets_y + 200])
|
||||
strap_handles();
|
||||
|
||||
translate([640, cable_grommets_y + 200])
|
||||
printed_pulley_test();
|
||||
|
||||
translate([x5, cable_grommets_y + 250])
|
||||
handle();
|
||||
|
||||
translate([950, 600])
|
||||
box_test();
|
||||
|
||||
translate([890, 750])
|
||||
pbox_y = hinge_y + 70;
|
||||
translate([900, pbox_y])
|
||||
printed_boxes();
|
||||
|
||||
translate([850, 1330])
|
||||
bbox_test();
|
||||
box_y = pbox_y + 150;
|
||||
translate([950, box_y])
|
||||
box_test();
|
||||
|
||||
|
||||
translate([950, 1525])
|
||||
rotate(-90)
|
||||
bbox_test();
|
||||
|
||||
inserts_y = 0;
|
||||
nuts_y = inserts_y + 20;
|
||||
washers_y = nuts_y + 120;
|
||||
@@ -198,13 +230,14 @@ sealing_strip_y = springs_y + 20;
|
||||
tubings_y = sealing_strip_y + 20;
|
||||
pillars_y = tubings_y + 20;
|
||||
ball_bearings_y = pillars_y + 40;
|
||||
pulleys_y = ball_bearings_y +40;
|
||||
hot_ends_y = pulleys_y + 60;
|
||||
linear_bearings_y = hot_ends_y + 50;
|
||||
sheets_y = linear_bearings_y + 100;
|
||||
pcbs_y = sheets_y + 40;
|
||||
displays_y = pcbs_y + 170;
|
||||
fans_y = displays_y + 80;
|
||||
pulleys_y = ball_bearings_y + 40;
|
||||
leadnuts_y = pulleys_y + 60;
|
||||
linear_bearings_y = leadnuts_y + 50;
|
||||
steppers_y = linear_bearings_y + 110;
|
||||
sheets_y = steppers_y + 55;
|
||||
pcbs_y = sheets_y + 60;
|
||||
displays_y = pcbs_y + 265;
|
||||
fans_y = displays_y + 110;
|
||||
transformers_y = fans_y + 120;
|
||||
psus_y = transformers_y + 190;
|
||||
|
||||
@@ -247,13 +280,19 @@ translate([x0, ball_bearings_y])
|
||||
translate([x0, pulleys_y])
|
||||
pulleys();
|
||||
|
||||
translate([x0, leadnuts_y])
|
||||
leadnuts();
|
||||
|
||||
translate([x0 + 120, leadnuts_y])
|
||||
leadnuthousings();
|
||||
|
||||
translate([x0, linear_bearings_y]) {
|
||||
linear_bearings();
|
||||
rods();
|
||||
}
|
||||
|
||||
translate([x0 + 10, hot_ends_y])
|
||||
hot_ends();
|
||||
translate([x0, steppers_y])
|
||||
stepper_motors();
|
||||
|
||||
translate([x0, sheets_y])
|
||||
sheets();
|
||||
@@ -271,7 +310,7 @@ translate([x0, fans_y]) {
|
||||
fan_guards();
|
||||
}
|
||||
|
||||
translate([x0, transformers_y])
|
||||
translate([760, fans_y])
|
||||
variacs();
|
||||
|
||||
translate([x0, psus_y]) {
|
||||
@@ -283,7 +322,6 @@ translate([x0, psus_y]) {
|
||||
zipties_y = 0;
|
||||
bulldogs_y = zipties_y + 30;
|
||||
swiss_clips_y = bulldogs_y + 35;
|
||||
leadnuts_y = swiss_clips_y + 50;
|
||||
|
||||
translate([x1, zipties_y])
|
||||
zipties();
|
||||
@@ -294,10 +332,6 @@ translate([x1, bulldogs_y])
|
||||
translate([x1, swiss_clips_y])
|
||||
swiss_clips();
|
||||
|
||||
translate([x1, leadnuts_y])
|
||||
leadnuts();
|
||||
|
||||
|
||||
leds_y = 0;
|
||||
carriers_y = leds_y + 40;
|
||||
magnets_y = carriers_y + 40;
|
||||
@@ -354,18 +388,18 @@ iecs_y = d_connectors_y + 80;
|
||||
modules_y = iecs_y + 60;
|
||||
ssrs_y = modules_y + 80;
|
||||
blowers_y = ssrs_y + 60;
|
||||
batteries_y = blowers_y + 100;
|
||||
steppers_y = batteries_y + 55;
|
||||
panel_meters_y = steppers_y + 70;
|
||||
hot_ends_y = blowers_y + 100;
|
||||
batteries_y = hot_ends_y + 55;
|
||||
panel_meters_y = batteries_y + 70;
|
||||
extrusions_y = panel_meters_y + 80;
|
||||
|
||||
translate([x3, veroboard_y])
|
||||
veroboard_test();
|
||||
|
||||
translate([x3 + 70, veroboard_y + 30])
|
||||
translate([x3 + 60, veroboard_y + 20])
|
||||
geared_steppers();
|
||||
|
||||
translate([x3 + 140, veroboard_y + 20])
|
||||
translate([x3 + 160, ssrs_y])
|
||||
pcb_mounts();
|
||||
|
||||
translate([x3 + 170, veroboard_y + 16])
|
||||
@@ -401,8 +435,8 @@ translate([x3, blowers_y])
|
||||
translate([x3, batteries_y])
|
||||
batteries();
|
||||
|
||||
translate([x2, steppers_y]) // interloper
|
||||
stepper_motors();
|
||||
translate([x3 + 10, hot_ends_y])
|
||||
hot_ends();
|
||||
|
||||
translate([x2, panel_meters_y])
|
||||
panel_meters();
|
||||
@@ -410,23 +444,32 @@ translate([x2, panel_meters_y])
|
||||
translate([x2, extrusions_y])
|
||||
extrusions();
|
||||
|
||||
translate([x3, transformers_y])
|
||||
translate([400, transformers_y])
|
||||
transformers();
|
||||
|
||||
translate([x4 + 50, transformers_y])
|
||||
no_explode() socket_boxes();
|
||||
|
||||
|
||||
belts_y = 0;
|
||||
rails_y = belts_y + 200;
|
||||
extrusion_brackets_y = rails_y + 250;
|
||||
sk_brackets_y = extrusion_brackets_y + 80;
|
||||
kp_pillow_blocks_y = sk_brackets_y + 50;
|
||||
kp_pillow_blocks_y = sk_brackets_y + 60;
|
||||
scs_bearing_blocks_y = kp_pillow_blocks_y + 60;
|
||||
box_sections_y = batteries_y;
|
||||
BLDC_y = scs_bearing_blocks_y + 120;
|
||||
pot_y = BLDC_y + 40;
|
||||
cable_strip_y = pot_y + 50;
|
||||
|
||||
translate([0, transformers_y])
|
||||
servo_motors();
|
||||
|
||||
translate([x4 + 200, belts_y + 58]) {
|
||||
belt_test();
|
||||
|
||||
translate([0, 60])
|
||||
opengrab_test();
|
||||
|
||||
}
|
||||
|
||||
translate([x4 + 175, belts_y, -20])
|
||||
@@ -435,7 +478,7 @@ translate([x4 + 175, belts_y, -20])
|
||||
translate([x4, rails_y + 130])
|
||||
rails();
|
||||
|
||||
translate([770, fans_y + 50])
|
||||
translate([x4, cable_strip_y])
|
||||
cable_strips();
|
||||
|
||||
translate([x4, kp_pillow_blocks_y])
|
||||
@@ -447,12 +490,20 @@ translate([x4, sk_brackets_y])
|
||||
translate([x4, extrusion_brackets_y])
|
||||
extrusion_brackets();
|
||||
|
||||
translate([x4 + 120, extrusion_brackets_y])
|
||||
translate([x1, swiss_clips_y + 50])
|
||||
shaft_couplings();
|
||||
|
||||
translate([x4, scs_bearing_blocks_y])
|
||||
scs_bearing_blocks();
|
||||
|
||||
translate([x4, BLDC_y])
|
||||
bldc_motors();
|
||||
|
||||
translate([x4, pot_y])
|
||||
potentiometers();
|
||||
|
||||
translate([x2, box_sections_y])
|
||||
box_sections();
|
||||
|
||||
translate([x6, 125])
|
||||
light_strips();
|
||||
|
126
printed/box.scad
@@ -30,10 +30,16 @@
|
||||
//! 
|
||||
//!
|
||||
//! Normally the side sheets are the same type but they can be overridden individually as long as the substitute has the same thickness.
|
||||
//!
|
||||
//! A box can have an optional name to allow more than one in the same project.
|
||||
//!
|
||||
//! The top bezel can have an optional child, which is subtracted to allow modification.
|
||||
//
|
||||
include <../core.scad>
|
||||
include <../utils/core/core.scad>
|
||||
use <../vitamins/sheet.scad>
|
||||
use <../vitamins/insert.scad>
|
||||
use <../vitamins/screw.scad>
|
||||
use <../vitamins/washer.scad>
|
||||
use <../utils/quadrant.scad>
|
||||
use <../utils/round.scad>
|
||||
|
||||
@@ -48,12 +54,13 @@ function box_sheets(type) = type[3]; //! Sheet type used for the sides
|
||||
function box_top_sheet(type) = type[4]; //! Sheet type for the top
|
||||
function box_base_sheet(type) = type[5]; //! Sheet type for the bottom
|
||||
function box_feet(type) = type[6]; //! True to enable feet on the bottom bezel
|
||||
function box_width(type) = type[7]; //! Internal width
|
||||
function box_depth(type) = type[8]; //! Internal depth
|
||||
function box_height(type) = type[9]; //! Internal height
|
||||
function box_name(type) = type[7]; //! Name for projects with more than one box
|
||||
function box_width(type) = type[8]; //! Internal width
|
||||
function box_depth(type) = type[9]; //! Internal depth
|
||||
function box_height(type) = type[10];//! Internal height
|
||||
|
||||
function box(screw, wall, sheets, top_sheet, base_sheet, size, feet = false, shelf_screw = M3_dome_screw) = //! Construct a property list for a box.
|
||||
concat([screw, shelf_screw, wall, sheets, top_sheet, base_sheet, feet], size);
|
||||
function box(screw, wall, sheets, top_sheet, base_sheet, size, feet = false, shelf_screw = undef, name = "box") = //! Construct a property list for a box.
|
||||
concat([screw, is_undef(shelf_screw) ? screw : shelf_screw, wall, sheets, top_sheet, base_sheet, feet, name], size);
|
||||
|
||||
function box_bezel_clearance(type) = bezel_clearance;
|
||||
|
||||
@@ -64,7 +71,7 @@ function box_washer(type) = screw_washer(box_screw(type));
|
||||
function box_insert(type) = screw_insert(box_screw(type));
|
||||
function box_shelf_insert(type) = screw_insert(box_shelf_screw(type));
|
||||
|
||||
function box_hole_inset(type) = washer_radius(box_washer(type)) + 1;
|
||||
function box_hole_inset(type) = washer_radius(box_washer(type)) + 1; //! Screw inset from the corner of the internal dimensions
|
||||
function box_insert_r(type) = insert_hole_radius(box_insert(type));
|
||||
function box_insert_l(type) = insert_length(box_insert(type));
|
||||
function box_boss_r(type) = ceil(corrected_radius(box_insert_r(type)) + box_wall(type));
|
||||
@@ -79,7 +86,6 @@ function box_screw_length(type, top) =
|
||||
let(s = top ? box_top_sheet(type) : box_base_sheet(type))
|
||||
screw_length(box_screw(type), sheet_thickness(s) + box_corner_gap(type) + box_profile_overlap(type) - 1, washers = 2, insert = true, longer = true);
|
||||
|
||||
function box_wall_clearance(type) = box_sheet_slot(type) / 2 - sheet_thickness(box_sheets(type)) / 2;
|
||||
function box_margin(type) = box_profile_overlap(type) + box_corner_gap(type); //! How much the bezel intrudes on the specified height
|
||||
function box_intrusion(type) = box_hole_inset(type) + box_boss_r(type); //! Corner profile intrusion
|
||||
function sheet_reduction(type) = 2 * box_corner_gap(type) + sheet_end_clearance;
|
||||
@@ -89,6 +95,8 @@ function box_bezel_height(type, bottom) = //! Bezel height for top or bottom
|
||||
let(t1 = sheet_thickness(box_base_sheet(type)), t2 = sheet_thickness(box_top_sheet(type)))
|
||||
box_corner_rad(type) + box_profile_overlap(type) + (bottom ? max(t1, t2) : t2) - sheet_thickness(box_sheets(type));
|
||||
|
||||
function box_bc_name(type, suffix) = let(name = box_name(type)) name == "box" ? suffix : str(name, "_", suffix); // Backwards compatible name
|
||||
|
||||
grill_hole = 5;
|
||||
grill_gap = 1.9;
|
||||
|
||||
@@ -141,7 +149,7 @@ module box_corner_profile_2D(type) { //! The 2D shape of the corner profile.
|
||||
module box_corner_profile(type) { //! Generates the corner profile STL for 3D printing.
|
||||
length = box_height(type) - 2 * box_margin(type);
|
||||
|
||||
stl("box_corner_profile")
|
||||
stl(str(box_name(type), "_corner_profile"))
|
||||
difference() {
|
||||
linear_extrude(length, center = true, convexity = 5)
|
||||
box_corner_profile_2D(type);
|
||||
@@ -190,7 +198,7 @@ module box_corner_profile_section(type, section, sections) { //! Generates inter
|
||||
}
|
||||
|
||||
module box_corner_profile_sections(type, section, sections) { //! Generate four copies of a corner profile section
|
||||
stl("box_corner_profile");
|
||||
stl(str(box_name(type), "_corner_profile"));
|
||||
offset = box_boss_r(type) + 1;
|
||||
for(i = [0 : 3])
|
||||
rotate(i * 90)
|
||||
@@ -220,14 +228,14 @@ module box_bezel(type, bottom) { //! Generates top and bottom bezel STLs
|
||||
height = box_bezel_height(type, bottom);
|
||||
foot_extension = foot_height - height;
|
||||
|
||||
stl(bottom ? "bottom_bezel" : "top_bezel")
|
||||
stl(box_bc_name(type, bottom ? "bottom_bezel" : "top_bezel"))
|
||||
difference() {
|
||||
w = box_width(type);
|
||||
d = box_depth(type);
|
||||
translate_z(-box_profile_overlap(type)) difference() {
|
||||
tw = w + 2 * outset;
|
||||
td = d + 2 * outset;
|
||||
rounded_rectangle([tw, td, feet ? foot_height : height], box_corner_rad(type), false);
|
||||
rounded_rectangle([tw, td, feet ? foot_height : height], box_corner_rad(type));
|
||||
//
|
||||
// Remove edges between the feet
|
||||
//
|
||||
@@ -264,7 +272,7 @@ module box_bezel(type, bottom) { //! Generates top and bottom bezel STLs
|
||||
// recess for top / bottom panel
|
||||
//
|
||||
translate_z(cgap)
|
||||
rounded_rectangle([w + bezel_clearance, d + bezel_clearance, height], inner_r + bezel_clearance / 2, false);
|
||||
rounded_rectangle([w + bezel_clearance, d + bezel_clearance, height], inner_r + bezel_clearance / 2);
|
||||
//
|
||||
// leave plastic over the corner profiles
|
||||
//
|
||||
@@ -280,6 +288,12 @@ module box_bezel(type, bottom) { //! Generates top and bottom bezel STLs
|
||||
box_screw_hole_positions(type)
|
||||
poly_circle(screw_clearance_radius(box_screw(type)));
|
||||
}
|
||||
//
|
||||
// Optional child to subtract
|
||||
//
|
||||
if($children && !bottom)
|
||||
translate_z(-box_profile_overlap(type))
|
||||
children();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -353,7 +367,6 @@ module box_bezel_section(type, bottom, rows, cols, x, y) { //! Generates interlo
|
||||
|
||||
translate([0, bw2 / 2, dh2 / 2])
|
||||
cube([eps, bw2 - 2 * dowel_wall + 2 * extrusion_width, dh2], center = true);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -369,7 +382,9 @@ module box_bezel_section(type, bottom, rows, cols, x, y) { //! Generates interlo
|
||||
union() {
|
||||
clip(xmin = 0, xmax = w, ymin = 0, ymax = h)
|
||||
translate([tw / 2 - x * w, th / 2 - y * h, profile_overlap])
|
||||
box_bezel(type, bottom);
|
||||
box_bezel(type, bottom)
|
||||
if($children && !bottom)
|
||||
children();
|
||||
|
||||
if(x < cols - 1 && y == 0)
|
||||
translate([w, 0])
|
||||
@@ -438,8 +453,6 @@ module box_screw_hole_positions(type) {
|
||||
}
|
||||
|
||||
module box_base_blank(type) { //! Generates a 2D template for the base sheet
|
||||
dxf("box_base");
|
||||
|
||||
difference() {
|
||||
sheet_2D(box_base_sheet(type), box_width(type), box_depth(type), box_sheet_r(type));
|
||||
|
||||
@@ -449,8 +462,6 @@ module box_base_blank(type) { //! Generates a 2D template for the base sheet
|
||||
}
|
||||
|
||||
module box_top_blank(type) { //! Generates a 2D template for the top sheet
|
||||
dxf("box_top");
|
||||
|
||||
difference() {
|
||||
sheet_2D(box_top_sheet(type), box_width(type), box_depth(type), box_sheet_r(type));
|
||||
|
||||
@@ -463,18 +474,19 @@ function subst_sheet(type, sheet) =
|
||||
let(s = box_sheets(type))
|
||||
sheet ? assert(sheet_thickness(sheet) == sheet_thickness(s)) sheet : s;
|
||||
|
||||
module box_shelf_blank(type, sheet = false) { //! Generates a 2D template for a shelf sheet
|
||||
dxf("box_shelf");
|
||||
|
||||
module box_shelf_blank(type, sheet = false, wall = undef) { //! Generates a 2D template for a shelf sheet
|
||||
difference() {
|
||||
sheet_2D(subst_sheet(type, sheet), box_width(type) - bezel_clearance, box_depth(type) - bezel_clearance, 1);
|
||||
|
||||
offset(bezel_clearance / 2)
|
||||
box_corner_quadrants(type, box_width(type), box_depth(type));
|
||||
|
||||
box_shelf_screw_positions(type, [], 0, wall)
|
||||
drill(screw_clearance_radius(box_shelf_screw(type)), 0);
|
||||
}
|
||||
}
|
||||
|
||||
module box_shelf_screw_positions(type, screw_positions, thickness = 0, wall = undef) { //! Place children at the shelf screw positions
|
||||
module box_shelf_screw_positions(type, screw_positions, thickness = 0, wall = undef, top_screws = true) { //! Place children at the shelf screw positions
|
||||
w = is_undef(wall) ? box_wall(type) : wall;
|
||||
insert = box_shelf_insert(type);
|
||||
translate_z(-insert_boss_radius(insert, w))
|
||||
@@ -482,13 +494,22 @@ module box_shelf_screw_positions(type, screw_positions, thickness = 0, wall = un
|
||||
multmatrix(p)
|
||||
translate_z(thickness)
|
||||
children();
|
||||
|
||||
r = box_boss_r(type);
|
||||
inset = box_intrusion(type) - r + (r + insert_boss_radius(insert, w) + bezel_clearance / 2) / sqrt(2);
|
||||
if(top_screws)
|
||||
translate_z(thickness)
|
||||
for(x = [-1, 1], y = [-1, 1])
|
||||
translate([x * (box_width(type) / 2 - inset), y * (box_depth(type) / 2 - inset)])
|
||||
rotate(45 * x * (2 + y))
|
||||
children();
|
||||
}
|
||||
|
||||
module box_shelf_bracket(type, screw_positions, wall = undef) { //! Generates a shelf bracket, the first optional child is a 2D cutout and the second 3D cutouts
|
||||
w = is_undef(wall) ? box_wall(type) : wall;
|
||||
insert = box_shelf_insert(type);
|
||||
lip = 2 * insert_boss_radius(insert, w);
|
||||
width = insert_length(insert) + w;
|
||||
width = max(insert_length(insert) + w, lip);
|
||||
|
||||
module shape()
|
||||
difference() {
|
||||
@@ -512,7 +533,7 @@ module box_shelf_bracket(type, screw_positions, wall = undef) { //! Generates a
|
||||
square([lip, eps]);
|
||||
}
|
||||
|
||||
stl("shelf_bracket")
|
||||
stl(box_bc_name(type, "shelf_bracket"))
|
||||
difference() {
|
||||
union() {
|
||||
linear_extrude(w)
|
||||
@@ -564,33 +585,44 @@ module box_shelf_bracket_section(type, rows, cols, x, y) { //! Generates section
|
||||
children();
|
||||
}
|
||||
|
||||
module box_left_blank(type, sheet = false) { //! Generates a 2D template for the left sheet, `sheet` can be set to override the type
|
||||
dxf("box_left");
|
||||
|
||||
module box_left_blank(type, sheet = false) //! Generates a 2D template for the left sheet, `sheet` can be set to override the type
|
||||
sheet_2D(subst_sheet(type, sheet), box_depth(type) - sheet_reduction(type), box_height(type) - sheet_reduction(type), 1);
|
||||
}
|
||||
|
||||
module box_right_blank(type, sheet = false) { //! Generates a 2D template for the right sheet, `sheet` can be set to override the type
|
||||
dxf("box_right");
|
||||
|
||||
module box_right_blank(type, sheet = false) //! Generates a 2D template for the right sheet, `sheet` can be set to override the type
|
||||
sheet_2D(subst_sheet(type, sheet), box_depth(type) - sheet_reduction(type), box_height(type) - sheet_reduction(type), 1);
|
||||
}
|
||||
|
||||
module box_front_blank(type, sheet = false) { //! Generates a 2D template for the front sheet, `sheet` can be set to override the type
|
||||
dxf("box_front");
|
||||
|
||||
module box_front_blank(type, sheet = false) //! Generates a 2D template for the front sheet, `sheet` can be set to override the type
|
||||
sheet_2D(subst_sheet(type, sheet), box_width(type) - sheet_reduction(type), box_height(type) - sheet_reduction(type), 1);
|
||||
}
|
||||
|
||||
module box_back_blank(type, sheet = false) { //! Generates a 2D template for the back sheet, `sheet` can be set to override the type
|
||||
dxf("box_back");
|
||||
|
||||
module box_back_blank(type, sheet = false) //! Generates a 2D template for the back sheet, `sheet` can be set to override the type
|
||||
sheet_2D(subst_sheet(type, sheet), box_width(type) - sheet_reduction(type), box_height(type) - sheet_reduction(type), 1);
|
||||
}
|
||||
|
||||
module box_base(type) render_2D_sheet(box_base_sheet(type)) box_base_blank(type); //! Default base, can be overridden to customise
|
||||
module box_top(type) render_2D_sheet(box_top_sheet(type)) box_top_blank(type); //! Default top, can be overridden to customise
|
||||
module box_back(type) render_2D_sheet(box_sheets(type)) box_back_blank(type); //! Default back, can be overridden to customise
|
||||
module box_front(type) render_2D_sheet(box_sheets(type)) box_front_blank(type); //! Default front, can be overridden to customise
|
||||
module box_left(type) render_2D_sheet(box_sheets(type)) box_left_blank(type); //! Default left side, can be overridden to customise
|
||||
module box_right(type) render_2D_sheet(box_sheets(type)) box_right_blank(type); //! Default right side, can be overridden to customise
|
||||
module box_base(type) //! Default base, can be overridden to customise
|
||||
render_2D_sheet(box_base_sheet(type))
|
||||
dxf(str(box_name(type), "_base"))
|
||||
box_base_blank(type);
|
||||
|
||||
module box_top(type) //! Default top, can be overridden to customise
|
||||
render_2D_sheet(box_top_sheet(type))
|
||||
dxf(str(box_name(type), "_top"))
|
||||
box_top_blank(type);
|
||||
|
||||
module box_back(type) //! Default back, can be overridden to customise
|
||||
render_2D_sheet(box_sheets(type))
|
||||
dxf(str(box_name(type), "_back"))
|
||||
box_back_blank(type);
|
||||
|
||||
module box_front(type) //! Default front, can be overridden to customise
|
||||
render_2D_sheet(box_sheets(type))
|
||||
dxf(str(box_name(type), "_front"))
|
||||
box_front_blank(type);
|
||||
|
||||
module box_left(type) //! Default left side, can be overridden to customise
|
||||
render_2D_sheet(box_sheets(type))
|
||||
dxf(str(box_name(type), "_left"))
|
||||
box_left_blank(type);
|
||||
|
||||
module box_right(type) //! Default right side, can be overridden to customise
|
||||
render_2D_sheet(box_sheets(type))
|
||||
dxf(str(box_name(type), "_right"))
|
||||
box_right_blank(type);
|
||||
|
@@ -23,12 +23,12 @@
|
||||
// parameters to make the assembly views. E.g. module box_assembly() _box_assembly(box);
|
||||
//
|
||||
module _box_assembly(type, top = true, base = true, left = true, right = true, back = true, front = true, bezels = true, corners = 4)
|
||||
assembly("box") {
|
||||
assembly(box_name(type)) {
|
||||
echo("Box:", box_width(type), box_depth(type), box_height(type));
|
||||
|
||||
t = sheet_thickness(box_sheets(type));
|
||||
|
||||
for(corner = [0 : corners - 1]) {
|
||||
for(corner = [0 : 1 : corners - 1]) {
|
||||
x = [-1,1,1,-1][corner];
|
||||
y = [-1,-1,1,1][corner];
|
||||
translate([x * (box_width(type) / 2 + 25 * exploded()), y * (box_depth(type) / 2 + 25 * exploded())])
|
||||
@@ -50,7 +50,9 @@ assembly("box") {
|
||||
translate_z(z * (box_height(type) / 2 - box_corner_gap(type) + 50 * exploded()))
|
||||
rotate([z * 90 - 90, 0, 0])
|
||||
if(bezels && (z > 0 ? top : base))
|
||||
stl_colour(pp1_colour) render() box_bezel(type, z < 0);
|
||||
stl_colour(pp1_colour) render() box_bezel(type, z < 0)
|
||||
if(z > 0 && $children)
|
||||
children();
|
||||
|
||||
translate_z(z * (box_height(type) / 2 + sheet_thickness + 50 * exploded()))
|
||||
box_screw_hole_positions(type)
|
||||
|
@@ -31,7 +31,8 @@
|
||||
//! * An optional list of fixing blocks to be omitted can be given.
|
||||
//! * Star washers can be omitted by setting the 11th parameter to false.
|
||||
//!
|
||||
//! Uses [fixing blocks](#fixing_block) and [corner blocks](#corner_block).
|
||||
//! Uses [fixing blocks](#fixing_block) and [corner blocks](#corner_block) by default. Setting `thin_blocks` uses 2screw_blocks instead of
|
||||
//! fixing_blocks along the sides.
|
||||
//
|
||||
|
||||
use <fixing_block.scad>
|
||||
@@ -46,15 +47,17 @@ function bbox_span(type) = type[4]; //! Maximum span between fixing blocks
|
||||
function bbox_width(type) = type[5]; //! Internal width
|
||||
function bbox_depth(type) = type[6]; //! Internal depth
|
||||
function bbox_height(type) = type[7]; //! Internal height
|
||||
function bbox_name(type) = type[8] ? type[8] : "bbox"; //! Optional name if there is more than one box in a project
|
||||
function bbox_skip_blocks(type)= type[9] ? type[9] : []; //! List of fixing blocks to skip, used to allow a hinged panel for example
|
||||
function star_washers(type) = type[10] ? type[10] : is_undef(type[10]); //! Set to false to remove star washers.
|
||||
function bbox_name(type) = type[8]; //! Optional name if there is more than one box in a project
|
||||
function bbox_skip_blocks(type)= type[9]; //! List of fixing blocks to skip, used to allow a hinged panel for example
|
||||
function bbox_star_washers(type)= type[10];//! Set to false to remove star washers.
|
||||
function bbox_thin_blocks(type) = type[11];//! Set for 2 screw blocks instead of three hole fixing blocks.
|
||||
function bbox_short_inserts(type)= type[12];//! Set to use short inserts in the blocks
|
||||
|
||||
function bbox(screw, sheets, base_sheet, top_sheet, span, size, name = "bbox", skip_blocks = [], star_washers = true) = //! Construct the property list for a butt_box
|
||||
[ screw, sheets, base_sheet, top_sheet, span, size.x, size.y, size.z, name, skip_blocks, star_washers ];
|
||||
function bbox(screw, sheets, base_sheet, top_sheet, span, size, name = "bbox", skip_blocks = [], star_washers = true, thin_blocks = false, short_inserts = false) = //! Construct the property list for a butt_box
|
||||
[ screw, sheets, base_sheet, top_sheet, span, size.x, size.y, size.z, name, skip_blocks, star_washers, thin_blocks, short_inserts ];
|
||||
|
||||
function bbox_volume(type) = bbox_width(type) * bbox_depth(type) * bbox_height(type) / 1000000; //! Internal volume in litres
|
||||
function bbox_area(type) = let(w = bbox_width(type), d = bbox_depth(type), h = bbox_height(type)) //! Internal surdface area in m^2
|
||||
function bbox_area(type) = let(w = bbox_width(type), d = bbox_depth(type), h = bbox_height(type)) //! Internal surface area in m^2
|
||||
2 * (w * d + w * h + d * h) / 1000000;
|
||||
|
||||
module bbox_shelf_blank(type) { //! 2D template for a shelf
|
||||
@@ -76,7 +79,8 @@ function corner_block_positions(type) = let(
|
||||
rotate([z > 0 ? 180 : 0, 0, corner * 90 + (z > 0 ? 90 : 0)])
|
||||
];
|
||||
|
||||
function corner_holes(type) = [for(p = corner_block_positions(type), q = corner_block_holes(bbox_screw(type))) p * q];
|
||||
function corner_holes(type) = let(short = bbox_short_inserts(type))
|
||||
[for(p = corner_block_positions(type), q = corner_block_holes(bbox_screw(type), short_insert = short)) p * q];
|
||||
|
||||
function fixing_block_positions(type) = let(
|
||||
width = bbox_width(type),
|
||||
@@ -108,15 +112,17 @@ function fixing_block_positions(type) = let(
|
||||
rotate([y > 0 ? 180 : 0, x * y * 90, 0]),
|
||||
];
|
||||
|
||||
function side_holes(type) = [for(p = fixing_block_positions(type), q = fixing_block_holes(bbox_screw(type))) p * q];
|
||||
function side_holes(type) = let(
|
||||
screw = bbox_screw(type),
|
||||
short = bbox_short_inserts(type),
|
||||
holes = bbox_thin_blocks(type) ? 2screw_block_holes(screw, short_insert = short) : fixing_block_holes(screw))
|
||||
[for(p = fixing_block_positions(type), q = holes) p * q];
|
||||
|
||||
module bbox_drill_holes(type, t)
|
||||
position_children(concat(corner_holes(type), side_holes(type)), t)
|
||||
drill(screw_clearance_radius(bbox_screw(type)), 0);
|
||||
|
||||
module bbox_base_blank(type) { //! 2D template for the base
|
||||
dxf(str(bbox_name(type), "_base"));
|
||||
|
||||
difference() {
|
||||
sheet_2D(bbox_base_sheet(type), bbox_width(type), bbox_depth(type), 1);
|
||||
|
||||
@@ -125,8 +131,6 @@ module bbox_base_blank(type) { //! 2D template for the base
|
||||
}
|
||||
|
||||
module bbox_top_blank(type) { //! 2D template for the top
|
||||
dxf(str(bbox_name(type), "_top"));
|
||||
|
||||
t = sheet_thickness(bbox_sheets(type));
|
||||
|
||||
difference() {
|
||||
@@ -142,8 +146,6 @@ function subst_sheet(type, sheet) =
|
||||
sheet ? assert(sheet_thickness(sheet) == sheet_thickness(s)) sheet : s;
|
||||
|
||||
module bbox_left_blank(type, sheet = false) { //! 2D template for the left side
|
||||
dxf(str(bbox_name(type), "_left"));
|
||||
|
||||
t = sheet_thickness(bbox_sheets(type));
|
||||
bb = sheet_thickness(bbox_base_sheet(type));
|
||||
|
||||
@@ -156,8 +158,6 @@ module bbox_left_blank(type, sheet = false) { //! 2D template for the left side
|
||||
}
|
||||
|
||||
module bbox_right_blank(type, sheet = false) { //! 2D template for the right side
|
||||
dxf(str(bbox_name(type), "_right"));
|
||||
|
||||
t = sheet_thickness(bbox_sheets(type));
|
||||
bb = sheet_thickness(bbox_base_sheet(type));
|
||||
|
||||
@@ -170,8 +170,6 @@ module bbox_right_blank(type, sheet = false) { //! 2D template for the right sid
|
||||
}
|
||||
|
||||
module bbox_front_blank(type, sheet = false, width = 0) { //! 2D template for the front
|
||||
dxf(str(bbox_name(type), "_front"));
|
||||
|
||||
t = sheet_thickness(bbox_sheets(type));
|
||||
bb = sheet_thickness(bbox_base_sheet(type));
|
||||
bt = sheet_thickness(bbox_top_sheet(type));
|
||||
@@ -185,8 +183,6 @@ module bbox_front_blank(type, sheet = false, width = 0) { //! 2D template for th
|
||||
}
|
||||
|
||||
module bbox_back_blank(type, sheet = false) { //! 2D template for the back
|
||||
dxf(str(bbox_name(type), "_back"));
|
||||
|
||||
bb = sheet_thickness(bbox_base_sheet(type));
|
||||
t = sheet_thickness(bbox_sheets(type));
|
||||
|
||||
@@ -198,22 +194,48 @@ module bbox_back_blank(type, sheet = false) { //! 2D template for the back
|
||||
}
|
||||
}
|
||||
|
||||
module bbox_base(type) render_2D_sheet(bbox_base_sheet(type)) bbox_base_blank(type); //! Default base, can be overridden to customise
|
||||
module bbox_top(type) render_2D_sheet(bbox_top_sheet(type)) bbox_top_blank(type); //! Default top, can be overridden to customise
|
||||
module bbox_back(type) render_2D_sheet(bbox_sheets(type)) bbox_back_blank(type); //! Default back, can be overridden to customise
|
||||
module bbox_front(type) render_2D_sheet(bbox_sheets(type)) bbox_front_blank(type); //! Default front, can be overridden to customise
|
||||
module bbox_left(type) render_2D_sheet(bbox_sheets(type)) bbox_left_blank(type); //! Default left side, can be overridden to customise
|
||||
module bbox_right(type) render_2D_sheet(bbox_sheets(type)) bbox_right_blank(type); //! Default right side, can be overridden to customise
|
||||
module bbox_base(type) //! Default base, can be overridden to customise
|
||||
render_2D_sheet(bbox_base_sheet(type))
|
||||
dxf(str(bbox_name(type), "_base"))
|
||||
bbox_base_blank(type);
|
||||
|
||||
module bbox_top(type) //! Default top, can be overridden to customise
|
||||
render_2D_sheet(bbox_top_sheet(type))
|
||||
dxf(str(bbox_name(type), "_top"))
|
||||
bbox_top_blank(type);
|
||||
|
||||
module bbox_back(type) //! Default back, can be overridden to customise
|
||||
render_2D_sheet(bbox_sheets(type))
|
||||
dxf(str(bbox_name(type), "_back"))
|
||||
bbox_back_blank(type);
|
||||
|
||||
module bbox_front(type) //! Default front, can be overridden to customise
|
||||
render_2D_sheet(bbox_sheets(type))
|
||||
dxf(str(bbox_name(type), "_front"))
|
||||
bbox_front_blank(type);
|
||||
|
||||
module bbox_left(type) //! Default left side, can be overridden to customise
|
||||
render_2D_sheet(bbox_sheets(type))
|
||||
dxf(str(bbox_name(type), "_left"))
|
||||
bbox_left_blank(type);
|
||||
|
||||
module bbox_right(type) //! Default right side, can be overridden to customise
|
||||
render_2D_sheet(bbox_sheets(type))
|
||||
dxf(str(bbox_name(type), "_right"))
|
||||
bbox_right_blank(type);
|
||||
|
||||
module _bbox_assembly(type, top = true, base = true, left = true, right = true, back = true, front = true) { //! The box assembly, wrap with a local copy without parameters
|
||||
width = bbox_width(type);
|
||||
depth = bbox_depth(type);
|
||||
height = bbox_height(type);
|
||||
echo("Box:", width, depth, height, volume = bbox_volume(type), area = bbox_area(type));
|
||||
echo("Butt_box:", width, depth, height, volume = bbox_volume(type), area = bbox_area(type));
|
||||
|
||||
t = sheet_thickness(bbox_sheets(type));
|
||||
bt = sheet_thickness(bbox_base_sheet(type));
|
||||
tt = sheet_thickness(bbox_top_sheet(type));
|
||||
star_washers = bbox_star_washers(type);
|
||||
thin_blocks = bbox_thin_blocks(type);
|
||||
short = bbox_short_inserts(type);
|
||||
|
||||
function is_missing_screw(p) = p.y > depth / 2 - 1 ? !back : false;
|
||||
|
||||
@@ -223,13 +245,16 @@ module _bbox_assembly(type, top = true, base = true, left = true, right = true,
|
||||
let(q = transform([0, 0, 0], p), thickness = q.z > 0 ? tt : bt)
|
||||
multmatrix(p)
|
||||
fastened_corner_block_assembly(is_missing_screw(q) && ((q.z > 0) != (q.x > 0)) ? 0 : t, bbox_screw(type), thickness,
|
||||
is_missing_screw(q) && ((q.z > 0) == (q.x > 0)) ? 0 : t, star_washers = star_washers(type));
|
||||
is_missing_screw(q) && ((q.z > 0) == (q.x > 0)) ? 0 : t, star_washers = star_washers, short_insert = short);
|
||||
|
||||
h = height / 2 - 1;
|
||||
for(p = fixing_block_positions(type))
|
||||
let(q = transform([0, 0, 0], p), thickness = q.z > h ? tt : q.z < -h ? bt : t)
|
||||
multmatrix(p)
|
||||
fastened_fixing_block_assembly(is_missing_screw(q) ? 0 : t, bbox_screw(type), thickness2 = thickness, star_washers = star_washers(type));
|
||||
if(thin_blocks)
|
||||
fastened_2screw_block_assembly(is_missing_screw(q) ? 0 : t, bbox_screw(type), thickness_below = thickness, star_washers = star_washers, short_insert = short);
|
||||
else
|
||||
fastened_fixing_block_assembly(is_missing_screw(q) ? 0 : t, bbox_screw(type), thickness2 = thickness, star_washers = star_washers);
|
||||
|
||||
for(x = [-1, 1])
|
||||
translate([x * (width / 2 + t / 2 + eps + 25 * exploded()), 0])
|
||||
|
117
printed/cable_clip.scad
Normal file
@@ -0,0 +1,117 @@
|
||||
//
|
||||
// NopSCADlib Copyright Chris Palmer 2022
|
||||
// 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/>.
|
||||
//
|
||||
|
||||
//
|
||||
//! Cable clips to order. Can be for one or two cables of different sizes.
|
||||
//
|
||||
include <../core.scad>
|
||||
use <../vitamins/wire.scad>
|
||||
use <../utils/fillet.scad>
|
||||
|
||||
wall = 2;
|
||||
|
||||
function cable_clip_width(screw) = max(wall + 2 * screw_clearance_radius(screw) + wall, washer_diameter(screw_washer(screw))); //! Width given the `screw`.
|
||||
function cable_clip_height(cable) = cable_height(cable) + wall; //! Height given the `cable`.
|
||||
function cable_clip_extent(screw, cable) = screw_clearance_radius(screw) + wall + cable_width(cable) + wall; //! How far it extends from the screw.
|
||||
function cable_clip_offset(screw, cable) = screw_clearance_radius(screw) + wall + cable_width(cable) / 2; //! The offset of the cable from the screw
|
||||
|
||||
module single_cable_clip(screw, cable, h = 0) {
|
||||
screw_dia = 2 * screw_clearance_radius(screw);
|
||||
height = cable_clip_width(screw);
|
||||
depth = h ? h : cable_height(cable) + wall;
|
||||
w = cable_width(cable);
|
||||
width = wall + w + wall + screw_dia + wall;
|
||||
hole_x = wall + w + wall + screw_dia / 2;
|
||||
rad = min(wall + cable_wire_size(cable) / 2, depth / 2);
|
||||
r = extrusion_width - eps;
|
||||
translate([-hole_x, 0]) difference() {
|
||||
linear_extrude(height)
|
||||
difference() {
|
||||
hull() {
|
||||
rounded_square([width, 1], r, center = false);
|
||||
|
||||
translate([width - 1, 0])
|
||||
rounded_square([1, depth], r, center = false);
|
||||
|
||||
translate([rad, depth - rad])
|
||||
circle(r = rad);
|
||||
}
|
||||
|
||||
translate([wall + cable_width(cable) / 2, 0]) {
|
||||
hull() {
|
||||
for(p = cable_bundle_positions(cable))
|
||||
translate(p)
|
||||
circle(d = cable_wire_size(cable));
|
||||
|
||||
square([w, eps], center = true);
|
||||
}
|
||||
for(side = [-1, 1])
|
||||
translate([side * w / 2, 0])
|
||||
hflip(side < 0)
|
||||
fillet(r = r, h = 0);
|
||||
}
|
||||
}
|
||||
|
||||
translate([hole_x, depth / 2, height / 2])
|
||||
rotate([90,0,0])
|
||||
teardrop_plus(h = depth + 1, r = screw_dia / 2, center = true);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
module double_cable_clip(screw, cable1, cable2) {
|
||||
h = max(cable_clip_height(cable1), cable_clip_height(cable2));
|
||||
union() {
|
||||
single_cable_clip(screw, cable1, h);
|
||||
|
||||
mirror([1,0,0]) single_cable_clip(screw, cable2, h);
|
||||
}
|
||||
}
|
||||
|
||||
module cable_clip(screw, cable1, cable2 = 0) { //! Create the STL for a single cable or two cable clip
|
||||
function clip_str(screw) = str("cable_clip_", screw_radius(screw) * 20);
|
||||
function cable_str(cable) = str("_", cable_wires(cable), "_", round(cable_wire_size(cable) * 10));
|
||||
|
||||
if(cable2) {
|
||||
stl(str(clip_str(screw), cable_str(cable1), cable_str(cable2)));
|
||||
|
||||
double_cable_clip(screw, cable1, cable2);
|
||||
}
|
||||
else {
|
||||
stl(str(clip_str(screw), cable_str(cable1)));
|
||||
|
||||
single_cable_clip(screw, cable1);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
module cable_clip_assembly(screw, thickness, cable1, cable2 = 0) { //! Cable clip with the fasteners
|
||||
height = max(cable_clip_height(cable1), cable2 ? cable_clip_height(cable2) : 0);
|
||||
|
||||
stl_colour(pp1_colour) render()
|
||||
translate([0, cable_clip_width(screw) / 2]) rotate([90, 0, 0])
|
||||
cable_clip(screw, cable1, cable2);
|
||||
|
||||
translate_z(height)
|
||||
screw_and_washer(screw, screw_length(screw, height + thickness, 2, nyloc = true));
|
||||
|
||||
translate_z(-thickness)
|
||||
vflip()
|
||||
nut_and_washer(screw_nut(screw), true);
|
||||
}
|
@@ -158,14 +158,14 @@ module mouse_grommet_hole(r, h = 50, z = undef, expand = wall + clearance) //! M
|
||||
square([2 * R, eps]);
|
||||
}
|
||||
|
||||
function mouse_grommet_offset(r) = r + wall;
|
||||
function mouse_grommet_offset(r) = r + wall; //! Offset of the wire from the ground
|
||||
function mouse_grommet_length(r) = 2 * r + 2 * wall + 2 * overlap; //! Length of grommet given r
|
||||
|
||||
module mouse_grommet(r, thickness) { //! Make the STL for a mouse grommet
|
||||
|
||||
width = 2 * (wall + clearance) + thickness;
|
||||
length = 2 * r + 2 * wall + 2 * overlap;
|
||||
|
||||
stl(str("mouse_grommet_", r * 10, "_", thickness))
|
||||
stl(str("mouse_grommet_", r * 20, "_", thickness))
|
||||
rotate([90, 0, 0])
|
||||
union() {
|
||||
for(side = [-1, 1])
|
||||
@@ -193,10 +193,10 @@ module mouse_grommet_assembly(r, thickness)
|
||||
mouse_grommet(r, thickness);
|
||||
|
||||
module ribbon_grommet_20_3_stl() ribbon_grommet(20, 3);
|
||||
module mouse_grommet_15_3_stl() mouse_grommet(1.5, 3);
|
||||
module mouse_grommet_20_3_stl() mouse_grommet(2, 3);
|
||||
module mouse_grommet_25_3_stl() mouse_grommet(2.5, 3);
|
||||
module mouse_grommet_30_3_stl() mouse_grommet(3, 3);
|
||||
module mouse_grommet_30_3_stl() mouse_grommet(1.5, 3);
|
||||
module mouse_grommet_40_3_stl() mouse_grommet(2, 3);
|
||||
module mouse_grommet_50_3_stl() mouse_grommet(2.5, 3);
|
||||
module mouse_grommet_60_3_stl() mouse_grommet(3, 3);
|
||||
|
||||
module round_grommet_bottom_30_stl() round_grommet_bottom(3);
|
||||
module round_grommet_bottom_40_stl() round_grommet_bottom(4);
|
||||
|
@@ -23,7 +23,6 @@
|
||||
include <../core.scad>
|
||||
include <../vitamins/cameras.scad>
|
||||
use <../vitamins/pcb.scad>
|
||||
use <../vitamins/insert.scad>
|
||||
|
||||
wall = 1.75;
|
||||
min_wall = 2 * extrusion_width;
|
||||
|