Pārlūkot izejas kodu

some ikea lack and octoprint stuff

Thomas Buck 3 gadus atpakaļ
vecāks
revīzija
01cdf17874

+ 19
- 0
input/projects/3d-printing/ikea-lack.md Parādīt failu

@@ -37,6 +37,25 @@ My design files for the mounting bracket [can be found on my Gitea server](https
37 37
 
38 38
 My design files for the filament holder [can be found on my Gitea server](https://git.xythobuz.de/thomas/3d-print-designs/src/branch/master/ikea-lack).
39 39
 
40
+## Lights
41
+
42
+To be able to better see in-progress prints, I decided to mount some LED light strips to the bottom sides of the two upper tables.
43
+I am using 12V warm-white LED strips with 120 LEDs per meter.
44
+They are simply connected to the 12V power supply of the Fabrikator Mini.
45
+That was the easiest solution for now, although they flicker somewhat when the Fabrikator Mini is running.
46
+I have to think of another solution for that, probably a second power supply.
47
+
48
+<!--%
49
+lightgallery([
50
+    [ "img/lack_light_switches.png", "Design of my light switch mount" ],
51
+    [ "img/lack_lights_1.jpg", "Finished light switches" ],
52
+    [ "img/lack_lights_2.jpg", "Top level lights" ],
53
+    [ "img/lack_lights_3.jpg", "Bottom level lights" ]
54
+])
55
+%-->
56
+
57
+My design files for the light switch mount [can be found on my Gitea server](https://git.xythobuz.de/thomas/3d-print-designs/src/branch/master/ikea-lack).
58
+
40 59
 ## Concrete slab for noise and vibration dampening
41 60
 
42 61
 Unfortunately, because the Ikea Lack tables are very lightweight and also hollow, they tend to amplify the sound coming from the 3D printers on them.

+ 9
- 7
input/projects/3d-printing/octoprint.md Parādīt failu

@@ -153,8 +153,8 @@ and enter something like this:
153 153
 import time
154 154
 import RPi.GPIO as GPIO
155 155
 
156
-sleep_timeout = 1000
157
-sleep_toggle = 5.0
156
+hold_timeout = 2000
157
+sleep_toggle = 2000
158 158
 pin_button = 5
159 159
 pin_power = 3
160 160
 
@@ -166,10 +166,12 @@ GPIO.setup(pin_power, GPIO.IN)
166 166
 GPIO.setup(pin_power, GPIO.OUT, initial=GPIO.input(pin_power))
167 167
 
168 168
 while True:
169
-    channel = GPIO.wait_for_edge(pin_button, GPIO.FALLING, timeout=sleep_timeout)
169
+    channel = GPIO.wait_for_edge(pin_button, GPIO.FALLING)
170 170
     if channel is not None:
171
-        GPIO.output(pin_power, not GPIO.input(pin_power))
172
-        time.sleep(sleep_toggle)
171
+        time.sleep(hold_timeout / 1000.0)
172
+        if not GPIO.input(pin_button):
173
+            GPIO.output(pin_power, not GPIO.input(pin_power))
174
+            time.sleep(sleep_toggle / 1000.0)
173 175
 
174 176
 GPIO.cleanup()
175 177
 </pre>
@@ -193,11 +195,11 @@ Now also make this script executable, register it for execution on boot, and run
193 195
 
194 196
 <pre class="sh_sh">
195 197
 sudo chmod a+x /etc/init.d/octopi-power-button
196
-sudo update-rc.d /etc/init.d/octopi-power-button defaults
198
+sudo update-rc.d octopi-power-button defaults
197 199
 sudo /etc/init.d/octopi-power-button
198 200
 </pre>
199 201
 
200
-Now every time you press the button (with a 5s debounce delay afterwards) the printer power will be toggled.
202
+Now simply hold your power button for two seconds and the printer power will be toggled.
201 203
 
202 204
 ### Automatic Photo Upload
203 205
 

Binārs
static/img/lack_light_switches.png Parādīt failu


Binārs
static/img/lack_light_switches_small.png Parādīt failu


Binārs
static/img/lack_lights_1.jpg Parādīt failu


Binārs
static/img/lack_lights_1_small.jpg Parādīt failu


Binārs
static/img/lack_lights_2.jpg Parādīt failu


Binārs
static/img/lack_lights_2_small.jpg Parādīt failu


Binārs
static/img/lack_lights_3.jpg Parādīt failu


Binārs
static/img/lack_lights_3_small.jpg Parādīt failu


Notiek ielāde…
Atcelt
Saglabāt