Просмотр исходного кода

Added OrangePi PC Plus related stuff

Thomas Buck 6 лет назад
Родитель
Сommit
6dbdb026d8

+ 1906
- 0
opi-pc-plus/cam-holder-bottom.stl
Разница между файлами не показана из-за своего большого размера
Просмотреть файл


+ 2186
- 0
opi-pc-plus/cam-holder-top.stl
Разница между файлами не показана из-за своего большого размера
Просмотреть файл


+ 106
- 0
opi-pc-plus/cam-holder.scad Просмотреть файл

@@ -0,0 +1,106 @@
1
+//import("/Users/thomas/Downloads/y-corner.stl");
2
+
3
+// holder
4
+edge = 20;
5
+height = 40;
6
+hole_off = 10;
7
+hole_size = 8.0;
8
+hole_wiggle = 0.75;
9
+
10
+// adaptor
11
+length = 50;
12
+forw_height = 20;
13
+
14
+// cam
15
+cam_width = 27.0;
16
+cam_height = 5.0;
17
+cam_wall = 3.0;
18
+cam_holes = 3.2;
19
+cam_hole_off = 3.3;
20
+cam_hole_dist = 20.0;
21
+cam_mount_height = 15.0;
22
+cam_mount_dist = 10.0;
23
+
24
+mock_pole_height = 60.0;
25
+mock_pole_off = 10.0;
26
+
27
+$fn = 20;
28
+
29
+module prism(l, w, h) {
30
+    polyhedron(
31
+        points = [[0,0,0], [l,0,0], [l,w,0], [0,w,0], [0,w,h], [l,w,h]],
32
+        faces = [[0,1,2,3],[5,4,3,2],[0,4,5,1],[0,3,4],[5,2,1]]
33
+    );
34
+}
35
+
36
+module holder() {
37
+    difference() {
38
+        translate([-edge / 2, -edge / 2, 0])
39
+            cube([edge, edge, height]);
40
+        
41
+        translate([-edge / 2 - 1, 0, hole_off])
42
+            rotate([0, 90, 0])
43
+            cylinder(d = hole_size + hole_wiggle, h = edge + 2);
44
+        
45
+        translate([-edge / 2 - 1, 0, height - hole_off])
46
+            rotate([0, 90, 0])
47
+            cylinder(d = hole_size + hole_wiggle, h = edge + 2);
48
+    }
49
+}
50
+
51
+module adaptor() {
52
+    translate([-edge / 2, -edge / 2 - length, height - forw_height])
53
+    difference() {
54
+        cube([edge, length, forw_height]);
55
+        
56
+        translate([edge / 2, hole_off, -1])
57
+            cylinder(d = hole_size + hole_wiggle, h = forw_height + 2);
58
+    }
59
+}
60
+
61
+module cam_plate() {
62
+    difference() {
63
+        cube([cam_width, cam_wall, cam_mount_height]);
64
+        
65
+        translate([cam_hole_off, cam_wall + 1, cam_mount_height - cam_height])
66
+            rotate([90, 0, 0])
67
+            cylinder(d = cam_holes, h = cam_wall + 2);
68
+        
69
+        translate([cam_hole_off + cam_hole_dist, cam_wall + 1, cam_mount_height - cam_height])
70
+            rotate([90, 0, 0])
71
+            cylinder(d = cam_holes, h = cam_wall + 2);
72
+    }
73
+}
74
+
75
+module cam_mount() {
76
+    translate([0, -edge / 2 - length + hole_off, height - forw_height + mock_pole_height - mock_pole_off * 2])
77
+    difference() {
78
+        union() {
79
+            cylinder(d = hole_size + hole_wiggle + cam_wall * 2, h = cam_height);
80
+            
81
+            translate([-cam_width / 2, cam_mount_dist, 0])
82
+                cam_plate();
83
+            
84
+            translate([-cam_width / 2 + cam_width / 2 - ((hole_size + hole_wiggle) / 2 + cam_wall), 0, 0])
85
+                cube([cam_width - 2 * (cam_width / 2 - ((hole_size + hole_wiggle) / 2 + cam_wall)), cam_mount_dist + ((hole_size + hole_wiggle) / 2) - 2, cam_height]);
86
+            
87
+            translate([-(hole_size + hole_wiggle) / 2 - cam_wall, 0, 0])
88
+                rotate([0, -90, 0])
89
+                prism(cam_height, cam_mount_dist, cam_width / 2 - ((hole_size + hole_wiggle) / 2 + cam_wall));
90
+            
91
+            translate([(hole_size + hole_wiggle) / 2 + cam_wall, 0, cam_height])
92
+                rotate([0, 90, 0])
93
+                prism(cam_height, cam_mount_dist, cam_width / 2 - ((hole_size + hole_wiggle) / 2 + cam_wall));
94
+        }
95
+        
96
+        translate([0, 0, -1])
97
+            cylinder(d = hole_size + hole_wiggle, h = cam_height + 2);
98
+    }
99
+}
100
+
101
+holder(); adaptor();
102
+
103
+%translate([0, -edge / 2 - length + hole_off, height - forw_height - mock_pole_off])
104
+    cylinder(d = hole_size, h = mock_pole_height);
105
+
106
+cam_mount();

+ 2466
- 0
opi-pc-plus/opi-cam-mount-bottom.stl
Разница между файлами не показана из-за своего большого размера
Просмотреть файл


+ 450
- 0
opi-pc-plus/opi-cam-mount-top.stl Просмотреть файл

@@ -0,0 +1,450 @@
1
+solid OpenSCAD_Model
2
+  facet normal -1 0 0
3
+    outer loop
4
+      vertex 2.5 2.5 7.9
5
+      vertex 2.5 29.7 9.9
6
+      vertex 2.5 29.7 7.9
7
+    endloop
8
+  endfacet
9
+  facet normal -1 -0 0
10
+    outer loop
11
+      vertex 2.5 29.7 9.9
12
+      vertex 2.5 2.5 7.9
13
+      vertex 2.5 2.5 9.9
14
+    endloop
15
+  endfacet
16
+  facet normal -1 0 0
17
+    outer loop
18
+      vertex 2.5 32.7 7.9
19
+      vertex 2.5 59.9 9.9
20
+      vertex 2.5 59.9 7.9
21
+    endloop
22
+  endfacet
23
+  facet normal -1 -0 0
24
+    outer loop
25
+      vertex 2.5 59.9 9.9
26
+      vertex 2.5 32.7 7.9
27
+      vertex 2.5 32.7 9.9
28
+    endloop
29
+  endfacet
30
+  facet normal -0 0 1
31
+    outer loop
32
+      vertex 18.1 49.9 9.9
33
+      vertex 24.5 32.7 9.9
34
+      vertex 24.5 59.9 9.9
35
+    endloop
36
+  endfacet
37
+  facet normal 0 0 1
38
+    outer loop
39
+      vertex 24.5 32.7 9.9
40
+      vertex 18.1 40.3 9.9
41
+      vertex 23 32.7 9.9
42
+    endloop
43
+  endfacet
44
+  facet normal -0 0 1
45
+    outer loop
46
+      vertex 18.1 40.3 9.9
47
+      vertex 24.5 32.7 9.9
48
+      vertex 18.1 49.9 9.9
49
+    endloop
50
+  endfacet
51
+  facet normal -0 0 1
52
+    outer loop
53
+      vertex 2.5 59.9 9.9
54
+      vertex 18.1 49.9 9.9
55
+      vertex 24.5 59.9 9.9
56
+    endloop
57
+  endfacet
58
+  facet normal 0 0 1
59
+    outer loop
60
+      vertex 2.5 32.7 9.9
61
+      vertex 8.5 40.3 9.9
62
+      vertex 8.5 49.9 9.9
63
+    endloop
64
+  endfacet
65
+  facet normal 0 0 1
66
+    outer loop
67
+      vertex 18.1 49.9 9.9
68
+      vertex 2.5 59.9 9.9
69
+      vertex 8.5 49.9 9.9
70
+    endloop
71
+  endfacet
72
+  facet normal 0 0 1
73
+    outer loop
74
+      vertex 2.5 32.7 9.9
75
+      vertex 8.5 49.9 9.9
76
+      vertex 2.5 59.9 9.9
77
+    endloop
78
+  endfacet
79
+  facet normal 0 0 1
80
+    outer loop
81
+      vertex 8.5 40.3 9.9
82
+      vertex 2.5 32.7 9.9
83
+      vertex 4 32.7 9.9
84
+    endloop
85
+  endfacet
86
+  facet normal -0 0 1
87
+    outer loop
88
+      vertex 23 29.7 9.9
89
+      vertex 24.5 2.5 9.9
90
+      vertex 24.5 29.7 9.9
91
+    endloop
92
+  endfacet
93
+  facet normal 0 0 1
94
+    outer loop
95
+      vertex 4 32.7 9.9
96
+      vertex 23 32.7 9.9
97
+      vertex 18.1 40.3 9.9
98
+    endloop
99
+  endfacet
100
+  facet normal 0 0 1
101
+    outer loop
102
+      vertex 23 32.7 9.9
103
+      vertex 4 32.7 9.9
104
+      vertex 23 29.7 9.9
105
+    endloop
106
+  endfacet
107
+  facet normal 0 0 1
108
+    outer loop
109
+      vertex 4 32.7 9.9
110
+      vertex 18.1 40.3 9.9
111
+      vertex 8.5 40.3 9.9
112
+    endloop
113
+  endfacet
114
+  facet normal 0 0 1
115
+    outer loop
116
+      vertex 23 29.7 9.9
117
+      vertex 4 32.7 9.9
118
+      vertex 4 29.7 9.9
119
+    endloop
120
+  endfacet
121
+  facet normal 0 0 1
122
+    outer loop
123
+      vertex 23 29.7 9.9
124
+      vertex 4 29.7 9.9
125
+      vertex 24.5 2.5 9.9
126
+    endloop
127
+  endfacet
128
+  facet normal 0 0 1
129
+    outer loop
130
+      vertex 2.5 2.5 9.9
131
+      vertex 4 29.7 9.9
132
+      vertex 2.5 29.7 9.9
133
+    endloop
134
+  endfacet
135
+  facet normal 0 0 1
136
+    outer loop
137
+      vertex 4 29.7 9.9
138
+      vertex 2.5 2.5 9.9
139
+      vertex 24.5 2.5 9.9
140
+    endloop
141
+  endfacet
142
+  facet normal 1 -0 0
143
+    outer loop
144
+      vertex 24.5 2.5 9.9
145
+      vertex 24.5 29.7 7.9
146
+      vertex 24.5 29.7 9.9
147
+    endloop
148
+  endfacet
149
+  facet normal 1 0 0
150
+    outer loop
151
+      vertex 24.5 29.7 7.9
152
+      vertex 24.5 2.5 9.9
153
+      vertex 24.5 2.5 7.9
154
+    endloop
155
+  endfacet
156
+  facet normal 1 -0 0
157
+    outer loop
158
+      vertex 24.5 32.7 9.9
159
+      vertex 24.5 59.9 7.9
160
+      vertex 24.5 59.9 9.9
161
+    endloop
162
+  endfacet
163
+  facet normal 1 0 0
164
+    outer loop
165
+      vertex 24.5 59.9 7.9
166
+      vertex 24.5 32.7 9.9
167
+      vertex 24.5 32.7 7.9
168
+    endloop
169
+  endfacet
170
+  facet normal 0 1 -0
171
+    outer loop
172
+      vertex 24.5 59.9 7.9
173
+      vertex 2.5 59.9 9.9
174
+      vertex 24.5 59.9 9.9
175
+    endloop
176
+  endfacet
177
+  facet normal 0 1 0
178
+    outer loop
179
+      vertex 2.5 59.9 9.9
180
+      vertex 24.5 59.9 7.9
181
+      vertex 2.5 59.9 7.9
182
+    endloop
183
+  endfacet
184
+  facet normal 0 0 -1
185
+    outer loop
186
+      vertex 24.5 2.5 7.9
187
+      vertex 23 29.7 7.9
188
+      vertex 24.5 29.7 7.9
189
+    endloop
190
+  endfacet
191
+  facet normal 0 0 -1
192
+    outer loop
193
+      vertex 4 32.7 7.9
194
+      vertex 23 32.7 7.9
195
+      vertex 23 29.7 7.9
196
+    endloop
197
+  endfacet
198
+  facet normal 0 0 -1
199
+    outer loop
200
+      vertex 4 29.7 7.9
201
+      vertex 23 29.7 7.9
202
+      vertex 24.5 2.5 7.9
203
+    endloop
204
+  endfacet
205
+  facet normal 0 0 -1
206
+    outer loop
207
+      vertex 4 32.7 7.9
208
+      vertex 23 29.7 7.9
209
+      vertex 4 29.7 7.9
210
+    endloop
211
+  endfacet
212
+  facet normal -0 0 -1
213
+    outer loop
214
+      vertex 18.1 40.3 7.9
215
+      vertex 4 32.7 7.9
216
+      vertex 8.5 40.3 7.9
217
+    endloop
218
+  endfacet
219
+  facet normal 0 0 -1
220
+    outer loop
221
+      vertex 23 32.7 7.9
222
+      vertex 4 32.7 7.9
223
+      vertex 18.1 40.3 7.9
224
+    endloop
225
+  endfacet
226
+  facet normal 0 0 -1
227
+    outer loop
228
+      vertex 2.5 2.5 7.9
229
+      vertex 4 29.7 7.9
230
+      vertex 24.5 2.5 7.9
231
+    endloop
232
+  endfacet
233
+  facet normal -0 0 -1
234
+    outer loop
235
+      vertex 4 29.7 7.9
236
+      vertex 2.5 2.5 7.9
237
+      vertex 2.5 29.7 7.9
238
+    endloop
239
+  endfacet
240
+  facet normal 0 0 -1
241
+    outer loop
242
+      vertex 18.1 40.3 7.9
243
+      vertex 24.5 32.7 7.9
244
+      vertex 23 32.7 7.9
245
+    endloop
246
+  endfacet
247
+  facet normal 0 0 -1
248
+    outer loop
249
+      vertex 24.5 32.7 7.9
250
+      vertex 18.1 40.3 7.9
251
+      vertex 18.1 49.9 7.9
252
+    endloop
253
+  endfacet
254
+  facet normal 0 0 -1
255
+    outer loop
256
+      vertex 24.5 32.7 7.9
257
+      vertex 18.1 49.9 7.9
258
+      vertex 24.5 59.9 7.9
259
+    endloop
260
+  endfacet
261
+  facet normal 0 0 -1
262
+    outer loop
263
+      vertex 2.5 59.9 7.9
264
+      vertex 18.1 49.9 7.9
265
+      vertex 8.5 49.9 7.9
266
+    endloop
267
+  endfacet
268
+  facet normal 0 0 -1
269
+    outer loop
270
+      vertex 2.5 32.7 7.9
271
+      vertex 8.5 40.3 7.9
272
+      vertex 4 32.7 7.9
273
+    endloop
274
+  endfacet
275
+  facet normal -0 0 -1
276
+    outer loop
277
+      vertex 8.5 40.3 7.9
278
+      vertex 2.5 32.7 7.9
279
+      vertex 8.5 49.9 7.9
280
+    endloop
281
+  endfacet
282
+  facet normal 0 0 -1
283
+    outer loop
284
+      vertex 18.1 49.9 7.9
285
+      vertex 2.5 59.9 7.9
286
+      vertex 24.5 59.9 7.9
287
+    endloop
288
+  endfacet
289
+  facet normal 0 0 -1
290
+    outer loop
291
+      vertex 2.5 59.9 7.9
292
+      vertex 8.5 49.9 7.9
293
+      vertex 2.5 32.7 7.9
294
+    endloop
295
+  endfacet
296
+  facet normal 0 -1 0
297
+    outer loop
298
+      vertex 2.5 2.5 7.9
299
+      vertex 24.5 2.5 9.9
300
+      vertex 2.5 2.5 9.9
301
+    endloop
302
+  endfacet
303
+  facet normal 0 -1 -0
304
+    outer loop
305
+      vertex 24.5 2.5 9.9
306
+      vertex 2.5 2.5 7.9
307
+      vertex 24.5 2.5 7.9
308
+    endloop
309
+  endfacet
310
+  facet normal 1 -0 0
311
+    outer loop
312
+      vertex 8.5 40.3 9.9
313
+      vertex 8.5 49.9 7.9
314
+      vertex 8.5 49.9 9.9
315
+    endloop
316
+  endfacet
317
+  facet normal 1 0 0
318
+    outer loop
319
+      vertex 8.5 49.9 7.9
320
+      vertex 8.5 40.3 9.9
321
+      vertex 8.5 40.3 7.9
322
+    endloop
323
+  endfacet
324
+  facet normal -1 0 0
325
+    outer loop
326
+      vertex 18.1 40.3 7.9
327
+      vertex 18.1 49.9 9.9
328
+      vertex 18.1 49.9 7.9
329
+    endloop
330
+  endfacet
331
+  facet normal -1 -0 0
332
+    outer loop
333
+      vertex 18.1 49.9 9.9
334
+      vertex 18.1 40.3 7.9
335
+      vertex 18.1 40.3 9.9
336
+    endloop
337
+  endfacet
338
+  facet normal 0 -1 0
339
+    outer loop
340
+      vertex 8.5 49.9 7.9
341
+      vertex 18.1 49.9 9.9
342
+      vertex 8.5 49.9 9.9
343
+    endloop
344
+  endfacet
345
+  facet normal 0 -1 -0
346
+    outer loop
347
+      vertex 18.1 49.9 9.9
348
+      vertex 8.5 49.9 7.9
349
+      vertex 18.1 49.9 7.9
350
+    endloop
351
+  endfacet
352
+  facet normal 0 1 -0
353
+    outer loop
354
+      vertex 18.1 40.3 7.9
355
+      vertex 8.5 40.3 9.9
356
+      vertex 18.1 40.3 9.9
357
+    endloop
358
+  endfacet
359
+  facet normal 0 1 0
360
+    outer loop
361
+      vertex 8.5 40.3 9.9
362
+      vertex 18.1 40.3 7.9
363
+      vertex 8.5 40.3 7.9
364
+    endloop
365
+  endfacet
366
+  facet normal -1 0 0
367
+    outer loop
368
+      vertex 4 29.7 7.9
369
+      vertex 4 32.7 9.9
370
+      vertex 4 32.7 7.9
371
+    endloop
372
+  endfacet
373
+  facet normal -1 -0 0
374
+    outer loop
375
+      vertex 4 32.7 9.9
376
+      vertex 4 29.7 7.9
377
+      vertex 4 29.7 9.9
378
+    endloop
379
+  endfacet
380
+  facet normal 0 1 -0
381
+    outer loop
382
+      vertex 4 29.7 7.9
383
+      vertex 2.5 29.7 9.9
384
+      vertex 4 29.7 9.9
385
+    endloop
386
+  endfacet
387
+  facet normal 0 1 0
388
+    outer loop
389
+      vertex 2.5 29.7 9.9
390
+      vertex 4 29.7 7.9
391
+      vertex 2.5 29.7 7.9
392
+    endloop
393
+  endfacet
394
+  facet normal 0 -1 0
395
+    outer loop
396
+      vertex 2.5 32.7 7.9
397
+      vertex 4 32.7 9.9
398
+      vertex 2.5 32.7 9.9
399
+    endloop
400
+  endfacet
401
+  facet normal 0 -1 -0
402
+    outer loop
403
+      vertex 4 32.7 9.9
404
+      vertex 2.5 32.7 7.9
405
+      vertex 4 32.7 7.9
406
+    endloop
407
+  endfacet
408
+  facet normal 1 -0 0
409
+    outer loop
410
+      vertex 23 29.7 9.9
411
+      vertex 23 32.7 7.9
412
+      vertex 23 32.7 9.9
413
+    endloop
414
+  endfacet
415
+  facet normal 1 0 0
416
+    outer loop
417
+      vertex 23 32.7 7.9
418
+      vertex 23 29.7 9.9
419
+      vertex 23 29.7 7.9
420
+    endloop
421
+  endfacet
422
+  facet normal 0 1 -0
423
+    outer loop
424
+      vertex 24.5 29.7 7.9
425
+      vertex 23 29.7 9.9
426
+      vertex 24.5 29.7 9.9
427
+    endloop
428
+  endfacet
429
+  facet normal 0 1 0
430
+    outer loop
431
+      vertex 23 29.7 9.9
432
+      vertex 24.5 29.7 7.9
433
+      vertex 23 29.7 7.9
434
+    endloop
435
+  endfacet
436
+  facet normal 0 -1 0
437
+    outer loop
438
+      vertex 23 32.7 7.9
439
+      vertex 24.5 32.7 9.9
440
+      vertex 23 32.7 9.9
441
+    endloop
442
+  endfacet
443
+  facet normal 0 -1 -0
444
+    outer loop
445
+      vertex 24.5 32.7 9.9
446
+      vertex 23 32.7 7.9
447
+      vertex 24.5 32.7 7.9
448
+    endloop
449
+  endfacet
450
+endsolid OpenSCAD_Model

+ 156
- 0
opi-pc-plus/opi-cam-mount.scad Просмотреть файл

@@ -0,0 +1,156 @@
1
+opi_cam_width = 19.0;
2
+opi_cam_height = 54.4;
3
+opi_cam_depth = 4.5;
4
+
5
+opi_cam_bottom_depth = 1.4;
6
+opi_cam_bottom_height = 30.0;
7
+opi_cam_bottom_off_y = 7.5;
8
+
9
+opi_lens_width = 8.6;
10
+opi_lens_height = 8.6;
11
+opi_lens_off_x = 5.0;
12
+opi_lens_off_y = 9.0;
13
+
14
+cable_cut_width = 15.0;
15
+wall_size = 2.0;
16
+
17
+cable_tie_width = 3.0;
18
+cable_tie_height = 2.0;
19
+cable_tie_off_1 = 9.0;
20
+cable_tie_off_2 = 47.0;
21
+
22
+screw_holes = 3.2;
23
+screw_plate = 10.0;
24
+
25
+lens_gap = 0.5;
26
+top_gap = 0.5;
27
+
28
+$fn = 10;
29
+
30
+module cam() {
31
+    cube([opi_cam_width, opi_cam_height, opi_cam_depth]);
32
+    
33
+    translate([opi_lens_off_x, opi_cam_height - opi_lens_height - opi_lens_off_y, opi_cam_depth])
34
+        cube([opi_lens_width, opi_lens_height, 5]);
35
+    
36
+    translate([0, opi_cam_bottom_off_y, -opi_cam_bottom_depth])
37
+        cube([opi_cam_width, opi_cam_bottom_height, opi_cam_bottom_depth]);
38
+}
39
+
40
+module holder_bottom_walls() {
41
+    difference() {
42
+        cube([opi_cam_width + (4 * wall_size), opi_cam_height + (4 * wall_size), wall_size + opi_cam_bottom_depth]);
43
+        
44
+        translate([2 * wall_size, (2 * wall_size) + opi_cam_bottom_off_y, wall_size])
45
+            cube([opi_cam_width, opi_cam_bottom_height, opi_cam_bottom_depth + 1]);
46
+    }
47
+    
48
+    // inner walls
49
+    translate([wall_size, wall_size, wall_size])
50
+        cube([opi_cam_width + (2 * wall_size), wall_size, opi_cam_depth + opi_cam_bottom_depth]);
51
+    translate([wall_size, opi_cam_height + (2 * wall_size), wall_size])
52
+        cube([opi_cam_width + (2 * wall_size), wall_size, opi_cam_depth + opi_cam_bottom_depth]);
53
+    translate([wall_size, 2 * wall_size, wall_size])
54
+        cube([wall_size, opi_cam_height, opi_cam_depth + opi_cam_bottom_depth]);
55
+    translate([opi_cam_width + (2 * wall_size), 2 * wall_size, wall_size])
56
+        cube([wall_size, opi_cam_height, opi_cam_depth + opi_cam_bottom_depth]);
57
+    
58
+    // outer walls
59
+    translate([0, 0, wall_size])
60
+        cube([opi_cam_width + (4 * wall_size), wall_size, opi_cam_depth + opi_cam_bottom_depth + wall_size]);
61
+    translate([0, opi_cam_height + (3 * wall_size), wall_size])
62
+        cube([opi_cam_width + (4 * wall_size), wall_size, opi_cam_depth + opi_cam_bottom_depth + wall_size]);
63
+    translate([0, wall_size, wall_size])
64
+        cube([wall_size, opi_cam_height + (2 * wall_size), opi_cam_depth + opi_cam_bottom_depth + wall_size]);
65
+    translate([opi_cam_width + (3 * wall_size), wall_size, wall_size])
66
+        cube([wall_size, opi_cam_height + (2 * wall_size), opi_cam_depth + opi_cam_bottom_depth + wall_size]);
67
+}
68
+
69
+module screws() {
70
+    difference() {
71
+        cube([(4 * wall_size) + opi_cam_width, screw_plate, wall_size]);
72
+        
73
+        translate([3.3, screw_plate / 2, -1])
74
+            cylinder(d = screw_holes, h = wall_size + 2);
75
+        translate([23.3, screw_plate / 2, -1])
76
+            cylinder(d = screw_holes, h = wall_size + 2);
77
+        //translate([13.3, screw_plate / 2, -1])
78
+        //    cylinder(d = screw_holes, h = wall_size + 2);
79
+        //translate([((4 * wall_size) + opi_cam_width) / 3, screw_plate / 2, -1])
80
+        //    cylinder(d = screw_holes, h = wall_size + 2);
81
+        //translate([((4 * wall_size) + opi_cam_width) * 2 / 3, screw_plate / 2, -1])
82
+        //    cylinder(d = screw_holes, h = wall_size + 2);
83
+    }
84
+}
85
+
86
+module holder_bottom() {
87
+    difference() {
88
+        holder_bottom_walls();
89
+        
90
+        // ribbon cable
91
+        translate([((opi_cam_width + (4 * wall_size)) - cable_cut_width) / 2, -1, wall_size + opi_cam_bottom_depth])
92
+            cube([cable_cut_width, (2 * wall_size) + 2, opi_cam_depth]);
93
+        
94
+        // cable-tie center
95
+        translate([wall_size, ((4 * wall_size) + opi_cam_height - cable_tie_width) / 2, -1])
96
+            cube([cable_tie_height, cable_tie_width, (3 * wall_size) + opi_cam_depth + opi_cam_bottom_depth]);
97
+        translate([opi_cam_width + (2 * wall_size), ((4 * wall_size) + opi_cam_height - cable_tie_width) / 2, -1])
98
+            cube([cable_tie_height, cable_tie_width, (3 * wall_size) + opi_cam_depth + opi_cam_bottom_depth]);
99
+        
100
+        // cable-tie bottom
101
+        translate([wall_size, (2 * wall_size) + cable_tie_off_1, -1])
102
+            cube([cable_tie_height, cable_tie_width, (3 * wall_size) + opi_cam_depth + opi_cam_bottom_depth]);
103
+        translate([opi_cam_width + (2 * wall_size), (2 * wall_size) + cable_tie_off_1, -1])
104
+            cube([cable_tie_height, cable_tie_width, (3 * wall_size) + opi_cam_depth + opi_cam_bottom_depth]);
105
+        
106
+        // cable-tie top
107
+        translate([wall_size, (2 * wall_size) + cable_tie_off_2, -1])
108
+            cube([cable_tie_height, cable_tie_width, (3 * wall_size) + opi_cam_depth + opi_cam_bottom_depth]);
109
+        translate([opi_cam_width + (2 * wall_size), (2 * wall_size) + cable_tie_off_2, -1])
110
+            cube([cable_tie_height, cable_tie_width, (3 * wall_size) + opi_cam_depth + opi_cam_bottom_depth]);
111
+    }
112
+    
113
+    translate([0, -screw_plate, 0])
114
+        screws();
115
+}
116
+
117
+module holder_top() {
118
+    difference() {
119
+        translate([top_gap, top_gap, 0])
120
+            cube([opi_cam_width + (2 * wall_size) - (2 * top_gap), opi_cam_height + (2 * wall_size) - (2 * top_gap), wall_size]);
121
+        
122
+        // camera lens
123
+        translate([wall_size + opi_lens_off_x - lens_gap, wall_size + opi_cam_height - opi_lens_height - opi_lens_off_y - lens_gap, -1])
124
+        cube([opi_lens_width + (2 * lens_gap), opi_lens_height + (2 * lens_gap), wall_size + 2]);
125
+        
126
+        // cable-tie center
127
+        translate([0, ((2 * wall_size) + opi_cam_height - cable_tie_width) / 2, -1])
128
+            cube([cable_tie_height, cable_tie_width, wall_size + 2]);
129
+        translate([opi_cam_width + wall_size, ((2 * wall_size) + opi_cam_height - cable_tie_width) / 2, -1])
130
+            cube([cable_tie_height, cable_tie_width, wall_size + 2]);
131
+        
132
+        /*
133
+        // cable-tie bottom
134
+        translate([0, wall_size + cable_tie_off_1, -1])
135
+            cube([cable_tie_height, cable_tie_width, wall_size + 2]);
136
+        translate([opi_cam_width + wall_size, wall_size + cable_tie_off_1, -1])
137
+            cube([cable_tie_height, cable_tie_width, wall_size + 2]);
138
+        
139
+        // cable-tie top
140
+        translate([0, wall_size + cable_tie_off_2, -1])
141
+            cube([cable_tie_height, cable_tie_width, wall_size + 2]);
142
+        translate([opi_cam_width + wall_size, wall_size + cable_tie_off_2, -1])
143
+            cube([cable_tie_height, cable_tie_width, wall_size + 2]);
144
+        */
145
+    }
146
+}
147
+
148
+holder_bottom();
149
+
150
+%translate([2 * wall_size, 2 * wall_size, wall_size])
151
+    cam();
152
+
153
+
154
+translate([wall_size, wall_size, wall_size + opi_cam_depth + opi_cam_bottom_depth])
155
+    holder_top();
156
+

+ 6582
- 0
opi-pc-plus/opi-pc-plus-bottom.stl
Разница между файлами не показана из-за своего большого размера
Просмотреть файл


+ 41022
- 0
opi-pc-plus/opi-pc-plus-top.stl
Разница между файлами не показана из-за своего большого размера
Просмотреть файл


+ 373
- 0
opi-pc-plus/opi-pc-plus.scad Просмотреть файл

@@ -0,0 +1,373 @@
1
+opi_width = 56;
2
+opi_length = 85.5;
3
+opi_holes = 2.8;
4
+opi_hole_dist = 3.0;
5
+opi_pcb_height = 1.6;
6
+
7
+opi_power_width = 8.2;
8
+opi_power_height = 6.2;
9
+opi_power_depth = 12.7;
10
+opi_power_off_x = 7.5;
11
+opi_power_off_y = -2.0;
12
+
13
+opi_hdmi_width = 15.2;
14
+opi_hdmi_height = 5.7;
15
+opi_hdmi_depth = 11.6;
16
+opi_hdmi_off_x = opi_power_off_x + opi_power_width + 14.5;
17
+opi_hdmi_off_y = opi_power_off_y;
18
+
19
+opi_audio_diameter = 5.1;
20
+opi_audio_depth = 13.0;
21
+opi_audio_off_x = opi_hdmi_off_x + opi_hdmi_width + 17.5;
22
+opi_audio_off_y = opi_hdmi_off_y;
23
+
24
+opi_sd_width = 14.8;
25
+opi_sd_height = 2.0;
26
+opi_sd_depth = 14.8;
27
+opi_sd_off_y = 16.5;
28
+
29
+opi_reset_diameter = 4.0;
30
+opi_reset_depth = 5.0;
31
+opi_reset_off_y = 8.5;
32
+opi_reset_off_x = -0.8;
33
+opi_reset_off_z = 1.1;
34
+
35
+opi_cam_width = 16.5;
36
+opi_cam_depth = 5.0;
37
+opi_cam_height = 2.0;
38
+opi_cam_off_y = 15.5;
39
+opi_cam_off_x = 1.0;
40
+
41
+opi_micro_usb_width = 7.9;
42
+opi_micro_usb_height = 2.9;
43
+opi_micro_usb_depth = 5.8;
44
+opi_micro_usb_off_y = opi_cam_off_y + opi_cam_width + 3.5;
45
+opi_micro_usb_off_x = -0.8;
46
+
47
+opi_ir_width = 6.0;
48
+opi_ir_height = 8.3;
49
+opi_ir_depth = 5.5;
50
+opi_ir_off_x = 16.5;
51
+opi_ir_off_y = -0.9;
52
+
53
+opi_single_usb_width = 5.8;
54
+opi_single_usb_height = 13.2;
55
+opi_single_usb_depth = 19.7;
56
+opi_single_usb_off_y = 6.8;
57
+opi_single_usb_off_x = -4.3;
58
+
59
+opi_lan_width = 16.1;
60
+opi_lan_depth = 21.7;
61
+opi_lan_height = 13.4;
62
+opi_lan_off_y = opi_single_usb_off_y + opi_single_usb_width + 3.0;
63
+opi_lan_off_x = -4.2;
64
+
65
+opi_dual_usb_width = 13.2;
66
+opi_dual_usb_depth = 17.5;
67
+opi_dual_usb_height = 15.0;
68
+opi_dual_usb_off_y = opi_lan_off_y + opi_lan_width + 4.3;
69
+opi_dual_usb_off_x = -4.1;
70
+
71
+standoff_height = 3.0;
72
+standoff_diameter = 5.0;
73
+standoff_hole = 2.5;
74
+
75
+outer_wall_size = 2.0;
76
+bottom_top_size = 2.0;
77
+
78
+total_height = (2 * bottom_top_size) + standoff_height + opi_pcb_height + opi_dual_usb_height;
79
+
80
+wall_height = total_height - (2 * bottom_top_size);
81
+
82
+top_standoff_height = wall_height - standoff_height - opi_pcb_height;
83
+top_standoff_hole = 3.0;
84
+
85
+sma_diameter = 5.9;
86
+sma_off_x = 15.0;
87
+sma_off_y = 15.0;
88
+
89
+cable_cut_width = 51.0;
90
+cable_cut_depth = 5.4;
91
+cable_cut_off_x = 8.8;
92
+cable_cut_off_y = 1.2;
93
+
94
+text_depth = 0.25;
95
+
96
+text1_font = "Liberation Sans";
97
+text1_size = 7;
98
+text1 = "OrangePi PC Plus";
99
+text1_off_x = 6;
100
+text1_off_y = 20;
101
+
102
+text2_font = "Liberation Sans";
103
+text2_size = 5.5;
104
+text2 = "by xythobuz.de";
105
+text2_off_x = 27;
106
+text2_off_y = 40.5;
107
+
108
+corner_helper_size = 20;
109
+corner_helper_height = 0.2;
110
+
111
+$fn = 20;
112
+
113
+module orangepi_pc_plus() {
114
+    difference() {
115
+        // pcb
116
+        cube([opi_length, opi_width, opi_pcb_height]);
117
+        
118
+        // mounting holes
119
+        for (i = [0 : 1]) {
120
+            for (j = [0 : 1]) {
121
+                translate([i * opi_length, j * opi_width, -1])
122
+                    translate([-((i * 2) - 1) * opi_hole_dist, 0, 0])
123
+                    translate([0, -((j * 2) - 1) * opi_hole_dist, 0])
124
+                    cylinder(d = opi_holes, h = opi_pcb_height + 2);
125
+            }
126
+        }
127
+    }
128
+    
129
+    // power connector
130
+    translate([opi_power_off_x, opi_power_off_y, opi_pcb_height])
131
+        cube([opi_power_width, opi_power_depth, opi_power_height]);
132
+    
133
+    // hdmi connector
134
+    translate([opi_hdmi_off_x, opi_hdmi_off_y, opi_pcb_height])
135
+        cube([opi_hdmi_width, opi_hdmi_depth, opi_hdmi_height]);
136
+    
137
+    // audio connector
138
+    translate([opi_audio_off_x + (opi_audio_diameter / 2), opi_audio_off_y + opi_audio_depth, opi_pcb_height + (opi_audio_diameter / 2)])
139
+        rotate([90, 0, 0])
140
+        cylinder(d = opi_audio_diameter, h = opi_audio_depth);
141
+    
142
+    // micro sd card slot
143
+    translate([0, opi_sd_off_y, -opi_sd_height])
144
+        cube([opi_sd_depth, opi_sd_width, opi_sd_height]);
145
+    
146
+    // reset button
147
+    translate([opi_reset_off_x, opi_reset_off_y + (opi_reset_diameter / 2), opi_pcb_height + (opi_reset_diameter / 2) + opi_reset_off_z])
148
+        rotate([0, 90, 0])
149
+        cylinder(d = opi_reset_diameter, h = opi_reset_depth);
150
+    
151
+    // camera connector
152
+    translate([opi_cam_off_x, opi_cam_off_y, opi_pcb_height])
153
+        cube([opi_cam_depth, opi_cam_width, opi_cam_height]);
154
+    
155
+    // micro usb connector
156
+    translate([opi_micro_usb_off_x, opi_micro_usb_off_y, opi_pcb_height])
157
+        cube([opi_micro_usb_depth, opi_micro_usb_width, opi_micro_usb_height]);
158
+    
159
+    // ir receiver
160
+    translate([opi_length - opi_ir_off_x - opi_ir_width, opi_width - opi_ir_off_y - opi_ir_depth, opi_pcb_height])
161
+        cube([opi_ir_width, opi_ir_depth, opi_ir_height]);
162
+    
163
+    // single usb port
164
+    translate([opi_length - opi_single_usb_off_x - opi_single_usb_depth, opi_width - opi_single_usb_off_y - opi_single_usb_width, opi_pcb_height])
165
+        cube([opi_single_usb_depth, opi_single_usb_width, opi_single_usb_height]);
166
+    
167
+    // ethernet port
168
+    translate([opi_length - opi_lan_off_x - opi_lan_depth, opi_width - opi_lan_off_y - opi_lan_width, opi_pcb_height])
169
+        cube([opi_lan_depth, opi_lan_width, opi_lan_height]);
170
+    
171
+    // dual usb ports
172
+    translate([opi_length - opi_dual_usb_off_x - opi_dual_usb_depth, opi_width - opi_dual_usb_off_y - opi_dual_usb_width, opi_pcb_height])
173
+        cube([opi_dual_usb_depth, opi_dual_usb_width, opi_dual_usb_height]);
174
+}
175
+
176
+module case_bottom() {
177
+    // bottom plate
178
+    cube([opi_length + (2 * outer_wall_size), opi_width + (2 * outer_wall_size), bottom_top_size]);
179
+    
180
+    // print helper corner disks
181
+    for (i = [0 : 1]) {
182
+        for (j = [0 : 1]) {
183
+            translate([i * (opi_length + (2 * outer_wall_size)), j * (opi_width + (2 * outer_wall_size)), 0])
184
+            cylinder(d = corner_helper_size, h = corner_helper_height);
185
+        }
186
+    }
187
+    
188
+    // standoffs
189
+    translate([outer_wall_size, outer_wall_size, 0])
190
+    for (i = [0 : 1]) {
191
+        for (j = [0 : 1]) {
192
+            translate([i * opi_length, j * opi_width, bottom_top_size])
193
+                translate([-((i * 2) - 1) * opi_hole_dist, 0, 0])
194
+                translate([0, -((j * 2) - 1) * opi_hole_dist, 0])
195
+                difference() {
196
+                    cylinder(d = standoff_diameter, h = standoff_height);
197
+                    cylinder(d = standoff_hole, h = standoff_height + 1);
198
+                }
199
+        }
200
+    }
201
+    
202
+    // left (micro sd) wall
203
+    translate([0, 0, bottom_top_size])
204
+    difference() {
205
+        cube([outer_wall_size, opi_width + (2 * outer_wall_size), standoff_height + opi_pcb_height]);
206
+        
207
+        // sd card cutout
208
+        translate([-1, outer_wall_size + opi_sd_off_y, standoff_height - opi_sd_height])
209
+            cube([outer_wall_size + 2, opi_sd_width, opi_sd_height + standoff_height]);
210
+    }
211
+    
212
+    // front wall
213
+    translate([outer_wall_size, 0, bottom_top_size])
214
+        cube([opi_length, outer_wall_size, standoff_height + opi_pcb_height]);
215
+    
216
+    // back wall
217
+    translate([outer_wall_size, opi_width + outer_wall_size, bottom_top_size])
218
+        cube([opi_length, outer_wall_size, standoff_height + opi_pcb_height]);
219
+    
220
+    // right wall
221
+    translate([outer_wall_size + opi_length, 0, bottom_top_size])
222
+        cube([outer_wall_size, opi_width + (2 * outer_wall_size), standoff_height + opi_pcb_height]);
223
+}
224
+
225
+module case_top() {
226
+    difference() {
227
+        // top plate
228
+        cube([opi_length + (2 * outer_wall_size), opi_width + (2 * outer_wall_size), bottom_top_size]);
229
+        
230
+        // sma connector
231
+        translate([outer_wall_size + sma_off_x, outer_wall_size + opi_width - sma_off_y, -1])
232
+            cylinder(d = sma_diameter, h = bottom_top_size + 2);
233
+        
234
+        // holes in top plate
235
+        translate([outer_wall_size, outer_wall_size, 0])
236
+        for (i = [0 : 1]) {
237
+            for (j = [0 : 1]) {
238
+                translate([i * opi_length, j * opi_width, -1])
239
+                    translate([-((i * 2) - 1) * opi_hole_dist, 0, 0])
240
+                    translate([0, -((j * 2) - 1) * opi_hole_dist, 0])
241
+                    cylinder(d = top_standoff_hole, h = bottom_top_size + 2);
242
+            }
243
+        }
244
+        
245
+        // cable cutout
246
+        translate([outer_wall_size + cable_cut_off_x, outer_wall_size + opi_width - cable_cut_off_y - cable_cut_depth, -1])
247
+            cube([cable_cut_width, cable_cut_depth, bottom_top_size + 2]);
248
+        
249
+        // text in top plate
250
+        translate([text1_off_x, text1_off_y, bottom_top_size - text_depth])
251
+            linear_extrude(height = text_depth + 0.1) {
252
+            text(text1, font = text1_font, size = text1_size);
253
+        }
254
+        
255
+        translate([text2_off_x, text2_off_y, bottom_top_size - text_depth])
256
+            linear_extrude(height = text_depth + 0.1) {
257
+            text(text2, font = text2_font, size = text2_size);
258
+        }
259
+    }
260
+    
261
+    // print helper corner disks
262
+    for (i = [0 : 1]) {
263
+        for (j = [0 : 1]) {
264
+            translate([i * (opi_length + (2 * outer_wall_size)), j * (opi_width + (2 * outer_wall_size)), bottom_top_size - corner_helper_height])
265
+            cylinder(d = corner_helper_size, h = corner_helper_height);
266
+        }
267
+    }
268
+    
269
+    // standoffs
270
+    translate([outer_wall_size, outer_wall_size, 0])
271
+    for (i = [0 : 1]) {
272
+        for (j = [0 : 1]) {
273
+            translate([i * opi_length, j * opi_width, -top_standoff_height])
274
+                translate([-((i * 2) - 1) * opi_hole_dist, 0, 0])
275
+                translate([0, -((j * 2) - 1) * opi_hole_dist, 0])
276
+                difference() {
277
+                    cylinder(d = standoff_diameter, h = top_standoff_height);
278
+                    
279
+                    translate([0, 0, -1])
280
+                        cylinder(d = top_standoff_hole, h = top_standoff_height + 2);
281
+                }
282
+        }
283
+    }
284
+    
285
+    // front wall
286
+    translate([outer_wall_size, 0, -top_standoff_height])
287
+    difference() {
288
+        cube([opi_length, outer_wall_size, top_standoff_height]);
289
+        
290
+        // power connector
291
+        translate([opi_power_off_x, -1, -1])
292
+            cube([opi_power_width, outer_wall_size + 2, opi_power_height + 1]);
293
+        
294
+        // hdmi connector
295
+        translate([opi_hdmi_off_x, -1, -1])
296
+            cube([opi_hdmi_width, outer_wall_size + 2, opi_hdmi_height + 1]);
297
+        
298
+        // audio connector
299
+        translate([opi_audio_off_x, -1, -1])
300
+            cube([opi_audio_diameter, outer_wall_size + 2, opi_audio_diameter + 1]);
301
+    }
302
+    
303
+    // back wall
304
+    translate([outer_wall_size, opi_width + outer_wall_size, -top_standoff_height])
305
+    difference() {
306
+        cube([opi_length, outer_wall_size, top_standoff_height]);
307
+        
308
+        translate([opi_length - opi_ir_off_x - opi_ir_width, -1, -1])
309
+            cube([opi_ir_width, outer_wall_size + 2, opi_ir_height + 1]);
310
+    }
311
+    
312
+    // left wall
313
+    translate([0, 0, -top_standoff_height])
314
+    difference() {
315
+        cube([outer_wall_size, opi_width + (2 * outer_wall_size), top_standoff_height]);
316
+        
317
+        // reset button
318
+        translate([-1, outer_wall_size + opi_reset_off_y, -1])
319
+            cube([outer_wall_size + 2, opi_reset_diameter, opi_reset_diameter + opi_reset_off_z + 1]);
320
+        
321
+        // camera connector
322
+        translate([-1, outer_wall_size + opi_cam_off_y, -1])
323
+            cube([outer_wall_size + 2, opi_cam_width, opi_cam_height + 1]);
324
+        
325
+        // micro usb connector
326
+        translate([-1, outer_wall_size + opi_micro_usb_off_y, -1])
327
+            cube([outer_wall_size + 2, opi_micro_usb_width, opi_micro_usb_height + 1]);
328
+    }
329
+    
330
+    // right wall
331
+    translate([outer_wall_size + opi_length, 0, -top_standoff_height])
332
+    difference() {
333
+        cube([outer_wall_size, opi_width + (2 * outer_wall_size), top_standoff_height]);
334
+        
335
+        // single usb port
336
+        translate([-1, outer_wall_size + opi_width - opi_single_usb_off_y - opi_single_usb_width, -1])
337
+            cube([outer_wall_size + 2, opi_single_usb_width, opi_single_usb_height + 1]);
338
+        
339
+        // ethernet port
340
+        translate([-1, outer_wall_size + opi_width - opi_lan_off_y - opi_lan_width, -1])
341
+            cube([outer_wall_size + 2, opi_lan_width, opi_lan_height + 1]);
342
+        
343
+        // dual usb ports
344
+        translate([-1, outer_wall_size + opi_width - opi_dual_usb_off_y - opi_dual_usb_width, -1])
345
+            cube([outer_wall_size + 2, opi_dual_usb_width, opi_dual_usb_height + 1]);
346
+    }
347
+}
348
+
349
+module case_whole() {
350
+    case_bottom();
351
+    
352
+    translate([0, 0, total_height - bottom_top_size])
353
+        case_top();
354
+}
355
+
356
+// ---------------------
357
+// For looking at it in the OpenSCAD editor:
358
+/*
359
+case_whole();
360
+// place orangepi inside case, for visualization
361
+%translate([outer_wall_size, outer_wall_size, bottom_top_size + standoff_height])
362
+    orangepi_pc_plus();
363
+*/
364
+// ---------------------
365
+// For printing:
366
+/*
367
+case_bottom();
368
+*/
369
+translate([0, 2 * (opi_width + (2 * outer_wall_size)) + 25, bottom_top_size])
370
+    rotate([180, 0, 0])
371
+    case_top();
372
+
373
+// ---------------------

+ 35758
- 0
opi-pc-plus/opi-pc-plus.stl
Разница между файлами не показана из-за своего большого размера
Просмотреть файл


Загрузка…
Отмена
Сохранить