<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>UserCTL.xyz</title><link>https://blog.userctl.xyz/</link><description>Recent content on UserCTL.xyz</description><generator>Hugo -- gohugo.io</generator><language>en-GB</language><copyright>Copyright © 2021-2022 JP Roemer — CC BY‑NC‑SA 4.0</copyright><lastBuildDate>Mon, 21 Jun 2021 00:00:00 +0000</lastBuildDate><atom:link href="https://blog.userctl.xyz/rss.xml" rel="self" type="application/rss+xml"/><item><title>Adding a power button and status LEDs to you Raspberry Pi</title><link>https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/</link><pubDate>Fri, 24 Jun 2022 12:00:00 +0000</pubDate><guid>https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/</guid><description>&lt;p>Following the release of my &lt;a href="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/">MP-1 Rack collection&lt;/a>, I wanted to share some more details about how I added a power button, a power status LED, and an activity LED to my Raspberry Pi module.&lt;/p>
&lt;p>Finding the right configuration was not as easy as it seems, and as I wasn&amp;rsquo;t able to find a single source where both a power button and some status LED were added together, I ended up testing quite a lot of different setup. The ultimate goal being to be able to handle as much as possible without using important buses, having to solder extra pins or requiring any software on the Pi itself.&lt;/p>
&lt;p>
&lt;a href="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/rpi-power-activity-led-components.jpg" target="_blank" rel="noopener noreferrer">
&lt;img src="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/rpi-power-activity-led-components.jpg"
srcset="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/rpi-power-activity-led-components_hu75964322e7711b88939357edb5790982_752221_720x0_resize_q100_h2_mitchellnetravali.webp 720w"
alt="Raspberry Pi power Button and status LEDs components" width="720"
/>
&lt;/a>
&lt;/p>
&lt;h2 id="adding-a-power-button">Adding a power button&lt;/h2>
&lt;p>Adding a power button to my Raspberry Pi was relatively straight forward once I understood how the &lt;a href="https://github.com/raspberrypi/firmware/blob/329af8a59d91ea023ce3e2566e2ccd4ec0624438/boot/overlays/README#L1232-L1295" target="_blank" rel="noopener">&lt;code>gpio-shutdown&lt;/code> overlay&lt;/a> worked and which pin to use to restart the Pi once it was powered off.&lt;/p>
&lt;p>The important part here is to know that, starting with the Raspberry Pi 1 B+, you can restart a powered off board by bridging the &lt;a href="https://pinout.xyz/pinout/pin5_gpio3" target="_blank" rel="noopener">GPIO3 pin (Pin 5)&lt;/a> to &lt;a href="https://pinout.xyz/pinout/ground" target="_blank" rel="noopener">Ground&lt;/a>. By knowing that, we can also configure the &lt;code>gpio-shutdown&lt;/code> overlay to use this same pin to cleanly shut down a Raspberry Pi when it&amp;rsquo;s on.&lt;/p>
&lt;p>So, in order to add a power button to my Pi, I connected a momentary push button between those two pins as follows:&lt;/p>
&lt;p>
&lt;a href="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/rpi-power-button_bb.png" target="_blank" rel="noopener noreferrer">
&lt;img src="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/rpi-power-button_bb.png"
srcset="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/rpi-power-button_bb_hufc7a6d6b188940ae20866cb208cf5f2f_80154_720x0_resize_q100_h2_mitchellnetravali_3.webp 720w"
alt="Raspberry Pi power button wiring diagram" width="720"
/>
&lt;/a>
&lt;/p>
&lt;p>Then update the &lt;code>/boot/config.txt&lt;/code> file to include the following:&lt;/p>
&lt;div class="highlight">&lt;pre tabindex="0" class="chroma">&lt;code class="language-txt" data-lang="txt">&lt;span class="line">&lt;span class="cl">dtoverlay=gpio-shutdown,gpio_pin=3,debounce=1000
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;p>This configures the &lt;code>gpio-shutdown&lt;/code> overlay to use the GPIO3 pin for shutdown with a debounce value of 1000 ms (1 second) meaning that the button needs to be pressed for at least 1s before the Pi starts its shutdown procedure. This parameter is pretty useful to prevent accidental triggering.&lt;/p>
&lt;p>The only issue with using this setup to handle power management is that the GPIO3 pin is also used by the I²C bus as the SCL Pin thus requiring I²C to be disabled. If this bus is required, a more complex setup might be possible but has not been investigated here.&lt;/p>
&lt;blockquote>
&lt;p>&lt;strong>Note&lt;/strong>&lt;/p>
&lt;p>Using &lt;code>gpio-shutdown&lt;/code> to power off a Raspberry Pi does not completely cut power to it, it only puts it in a halted state (similar to what happens when running &lt;code>poweroff&lt;/code> or &lt;code>halt&lt;/code> on it). It will still consume a negligible amount of power.&lt;/p>
&lt;/blockquote>
&lt;h2 id="adding-a-power-status-led">Adding a power status LED&lt;/h2>
&lt;p>Things started to get a little harder once I tried to add a power status LED. A lot of different setup have been documented on the internet such as wiring it to the UART TXD pin, but I felt like using the UART bus this way wasn&amp;rsquo;t a clean solution.&lt;/p>
&lt;p>Another issue I found was most of the setup were using pins that are pulled up to 3.3V when the Pi is powered off (pin 1 to 8 are pulled up by default, requiring a pull-down resistor to be used properly). This can be a nice side effect if you wish to have a dimmed LED when the Raspberry Pi is powered off, but this wasn&amp;rsquo;t what I was looking for.&lt;/p>
&lt;p>In the end I decided to use the &lt;a href="https://pinout.xyz/pinout/pin11_gpio17" target="_blank" rel="noopener">GPIO17 pin (Pin 11)&lt;/a> with the &lt;a href="https://www.raspberrypi.com/documentation/computers/config_txt.html#gpio-control" target="_blank" rel="noopener">GPIO control directives&lt;/a> available in &lt;code>config.txt&lt;/code> to drive it high on boot. As this pin is not pulled-up by default, the LED will be completely off when the Pi is off.&lt;/p>
&lt;p>Using a 3 mm 2.2V 20mA red LED with a 3.3 kΩ resistor (to reduce its brightness), I installed it between GPIO17 and Ground as follows:&lt;/p>
&lt;p>
&lt;a href="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/rpi-power-led_bb.png" target="_blank" rel="noopener noreferrer">
&lt;img src="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/rpi-power-led_bb.png"
srcset="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/rpi-power-led_bb_hu96850d1834c39e8551d1705508b3b852_78887_720x0_resize_q100_h2_mitchellnetravali_3.webp 720w"
alt="Raspberry Pi power status led wiring diagram" width="720"
/>
&lt;/a>
&lt;/p>
&lt;p>Then updated the &lt;code>/boot/config.txt&lt;/code> file to add the following directive with instruct the system to drive the GPIO17 pin high on boot:&lt;/p>
&lt;div class="highlight">&lt;pre tabindex="0" class="chroma">&lt;code class="language-txt" data-lang="txt">&lt;span class="line">&lt;span class="cl">gpio=17=op,dh
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;p>This setup can be adapted to any other GPIO pin available on the board with the caveat about pulled-up pins previously described. A pretty neat setup I tested &amp;ldquo;abusing&amp;rdquo; this caveat was to use the &lt;a href="https://pinout.xyz/pinout/pin3_gpio2" target="_blank" rel="noopener">GPIO2 pin&lt;/a> using &lt;code>gpio=2=op,dh&lt;/code> to have a dimly lit LED when the Pi is off and a brighter LED when it&amp;rsquo;s on.&lt;/p>
&lt;h2 id="adding-an-activity-led">Adding an activity LED&lt;/h2>
&lt;p>Finally, it was time to add an external activity LED, this was pretty easy once I stumbled upon the &lt;a href="https://github.com/raspberrypi/firmware/blob/329af8a59d91ea023ce3e2566e2ccd4ec0624438/boot/overlays/README#L295-L310" target="_blank" rel="noopener">&lt;code>act-led&lt;/code> overlay&lt;/a>. This overlay is easy to configure as it only really requires a GPIO pin but can be customized using the &lt;a href="https://github.com/raspberrypi/firmware/blob/329af8a59d91ea023ce3e2566e2ccd4ec0624438/boot/overlays/README#L262-L264" target="_blank" rel="noopener">&lt;code>act_led_trigger&lt;/code> parameter&lt;/a> to choose which event should trigger it.&lt;/p>
&lt;p>The choice of the GPIO pin to use had to follow the same logic as for the power status LED, but I really couldn&amp;rsquo;t use a pulled-up pin here as I didn&amp;rsquo;t want it to light up at all if nothing happened on the Pi. In the end I decided to use the &lt;a href="https://pinout.xyz/pinout/pin13_gpio27" target="_blank" rel="noopener">GPIO27 pin (Pin 13)&lt;/a> as it was near a ground pin, close to GPIO17 and not pulled-up by default.&lt;/p>
&lt;p>Here I used a 3 mm 2.2V 20mA yellow LED with a 4.7 kΩ resistor (still to limit its brightness) wired between GPIO27 and Ground:&lt;/p>
&lt;p>
&lt;a href="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/rpi-activity-led_bb.png" target="_blank" rel="noopener noreferrer">
&lt;img src="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/rpi-activity-led_bb.png"
srcset="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/rpi-activity-led_bb_hu57be1527b531c1f3b8aa673aead18f76_80491_720x0_resize_q100_h2_mitchellnetravali_3.webp 720w"
alt="Raspberry Pi activity status led wiring diagram" width="720"
/>
&lt;/a>
&lt;/p>
&lt;p>Finally, updating the &lt;code>/boot/config.txt&lt;/code> one last time to add &lt;code>act-led&lt;/code> overlay configuration:&lt;/p>
&lt;div class="highlight">&lt;pre tabindex="0" class="chroma">&lt;code class="language-txt" data-lang="txt">&lt;span class="line">&lt;span class="cl">dtparam=act_led_trigger=mmc0
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">dtoverlay=act-led,activelow=off,gpio=27
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;p>Here I set the &lt;code>act_led_trigger&lt;/code> to &lt;code>mmc0&lt;/code> which will make the LED react to filesystem usage on the SD card of the Pi. This could be set to any of the other triggers available from the following list:&lt;/p>
&lt;div class="highlight">&lt;pre tabindex="0" class="chroma">&lt;code class="language-txt" data-lang="txt">&lt;span class="line">&lt;span class="cl">none No trigger
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">kbd-scrolllock Keyboard scroll lock
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">kbd-numlock Keyboard num lock
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">kbd-capslock Keyboard caps lock
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">kbd-kanalock Keyboard kana lock
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">kbd-shiftlock Keyboard shift
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">kbd-altgrlock Keyboard altgr
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">kbd-ctrllock Keyboard ctrl
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">kbd-altlock Keyboard alt
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">kbd-shiftllock Keyboard left shift
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">kbd-shiftrlock Keyboard right shift
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">kbd-ctrlllock Keyboard left ctrl
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">kbd-ctrlrlock Keyboard right ctrl
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">timer Flash at 1 second intervals
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">oneshot Flash only once
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">heartbeat Flash like a heartbeat (1-0-1-00000)
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">backlight Always on
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">gpio Flash when a certain GPIO is high???
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">cpu0 Flash on cpu0 usage
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">cpu1 Flash on cpu1 usage
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">cpu2 Flash on cpu2 usage
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">cpu3 Flash on cpu3 usage
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">default-on Always on
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">[input] Default state
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">panic Flash on kernel panic
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">mmc0 Flash on mmc0 (primary SD Card interface) activity
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">mmc1 Flash on mmc1 (secondary SD Card interface) activity
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">rfkill0 Flash on wifi activity
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">rfkill1 Flash on bluetooth activity
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;p>Thanks to &lt;a href="https://raspberrypi.stackexchange.com/users/3334/ameer" target="_blank" rel="noopener">Ameer&lt;/a> on the &lt;a href="https://raspberrypi.stackexchange.com/a/69759" target="_blank" rel="noopener">Raspberry Pi Stack Exchange forum&lt;/a> for creating this list.&lt;/p>
&lt;h2 id="final-setup">Final setup&lt;/h2>
&lt;p>In the end, if we put everything together we can achieve quite a nice setup without requiring any extra software on your Raspberry Pi that handles:&lt;/p>
&lt;ul>
&lt;li>a power button to shut down and reboot your Raspberry Pi&lt;/li>
&lt;li>a power status LED lighting up when the system if on&lt;/li>
&lt;li>an activity LED reacting to file system&lt;/li>
&lt;/ul>
&lt;p>The final wiring diagram should look like this:&lt;/p>
&lt;p>
&lt;a href="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/rpi-power-leds-final_bb.png" target="_blank" rel="noopener noreferrer">
&lt;img src="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/rpi-power-leds-final_bb.png"
srcset="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/rpi-power-leds-final_bb_hua73ea03de5beaf44d9e66a7216fee8eb_87787_720x0_resize_q100_h2_mitchellnetravali_3.webp 720w"
alt="Raspberry Pi power button, power status and activity status led wiring diagram" width="720"
/>
&lt;/a>
&lt;/p>
&lt;p>And the &lt;code>/boot/config.txt&lt;/code> file should have the following lines at the end:&lt;/p>
&lt;div class="highlight">&lt;pre tabindex="0" class="chroma">&lt;code class="language-txt" data-lang="txt">&lt;span class="line">&lt;span class="cl"># Power button
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">dtoverlay=gpio-shutdown,gpio_pin=3,debounce=1000
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"># Power status LED
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">gpio=17=op,dh
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"># Activity LED
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">dtparam=act_led_trigger=mmc0
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">dtoverlay=act-led,activelow=off,gpio=27
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;p>Paired with the &lt;a href="https://www.printables.com/model/227181" target="_blank" rel="noopener">MP-1 Rack Raspberry Pi module&lt;/a>, this setup allowed me to achieve my goal of having a rack mounted solution with power controls and feedback for my Pis. And I hope it helped you too if you were looking for something similar&lt;/p>
&lt;p>
&lt;a href="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/mp1-rack-pi-module.jpg" target="_blank" rel="noopener noreferrer">
&lt;img src="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/mp1-rack-pi-module.jpg"
srcset="https://blog.userctl.xyz/posts/2022/06/adding-power-button-status-leds-raspberry-pi/images/mp1-rack-pi-module_huf19009cd6da5c1c50b738fc47412f017_875439_720x0_resize_q100_h2_mitchellnetravali.webp 720w"
alt="MP-1 Rack Raspberry Pi modules" width="720"
/>
&lt;/a>
&lt;/p>
&lt;h2 id="references">References&lt;/h2>
&lt;ul>
&lt;li>&lt;a href="https://github.com/raspberrypi/firmware/blob/329af8a59d91ea023ce3e2566e2ccd4ec0624438/boot/overlays/README#L1232-L1295" target="_blank" rel="noopener">&lt;code>gpio-shutdown&lt;/code> overlay documentation&lt;/a>&lt;/li>
&lt;li>&lt;a href="https://embeddedcomputing.com/technology/open-source/development-kits/raspberry-pi-power-up-and-shutdown-with-a-physical-button" target="_blank" rel="noopener">&lt;em>Raspberry Pi Power-Up and Shutdown with a Physical Button&lt;/em> by Jeremy S. Cook&lt;/a>&lt;/li>
&lt;li>&lt;a href="https://www.stderr.nl/Blog/Hardware/RaspberryPi/PowerButton.html" target="_blank" rel="noopener">&lt;em>Raspberry pi powerdown and powerup button&lt;/em> by Matthijs Kooijman&lt;/a>&lt;/li>
&lt;li>&lt;a href="https://howchoo.com/g/ytzjyzy4m2e/build-a-simple-raspberry-pi-led-power-status-indicator" target="_blank" rel="noopener">&lt;em>Build a Simple Raspberry Pi LED Power/Status Indicator&lt;/em> by Zach on Howchoo&lt;/a>&lt;/li>
&lt;li>&lt;a href="https://forums.raspberrypi.com/viewtopic.php?p=1800623#p1800623" target="_blank" rel="noopener">&lt;em>Use GPIO 2 for power LED&lt;/em> on the Raspberry Pi forum&lt;/a>&lt;/li>
&lt;li>&lt;a href="https://forums.raspberrypi.com/viewtopic.php?t=267032" target="_blank" rel="noopener">&lt;em>External PWR &amp;amp; ACT LEDS&lt;/em> on the Raspberry Pi forum&lt;/a>&lt;/li>
&lt;li>&lt;a href="https://raspberrypi.stackexchange.com/a/69759" target="_blank" rel="noopener">&lt;code>act_led_trigger&lt;/code> values by Ameer on StackExchange&lt;/a>&lt;/li>
&lt;/ul></description></item><item><title>Building the MP-1 Rack collection: a modular racking system</title><link>https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/</link><pubDate>Mon, 20 Jun 2022 21:00:00 +0000</pubDate><guid>https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/</guid><description>&lt;p>After receiving my long awaited &lt;a href="http://www.zimaboard.com/" target="_blank" rel="noopener">ZimaBoards&lt;/a>, I was looking for a solution to install them in my 19&amp;quot; rack easily before starting building my Kubernetes cluster.&lt;/p>
&lt;p>I&amp;rsquo;ve seen in the past some modular racking setup for the Raspberry Pi such as the &lt;a href="https://github.com/mcpiface/McPiFace" target="_blank" rel="noopener">Pi Blade McPiFace from Stephen Harrison&lt;/a>, the &lt;a href="https://www.thingiverse.com/thing:3022136" target="_blank" rel="noopener">RackPi 3D model by Daniel Reinke&lt;/a> or the &lt;a href="https://www.thingiverse.com/thing:1793758" target="_blank" rel="noopener">Raspberry Pi Rack covers made by Daniel Mostosi&lt;/a> that I really liked. The common denominator between all of them being the use of the &lt;a href="https://www.musicstore.com/en_OT/EUR/DAP-2-HE-Rackblende-f-Modulsystem-10-Segmente-MP-1/art-PAH0017160-000" target="_blank" rel="noopener">DAP Audio MP-1 modular rack frame&lt;/a> as a base.&lt;/p>
&lt;p>I decided to take inspiration from those existing modules and build my own modules for the MP-1 frame to achieve the perfect modular rack I wanted that could house my 4 ZimaBoards, a Raspberry Pi and some keystone jacks. This started by ordering the frame and some official blanks for reference.&lt;/p>
&lt;p>
&lt;a href="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/mp1-rack-mounted.jpg" target="_blank" rel="noopener noreferrer">
&lt;img src="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/mp1-rack-mounted.jpg"
srcset="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/mp1-rack-mounted_hu5daf18fd4f8805e70461d5b54ab598a5_804978_720x0_resize_q100_h2_mitchellnetravali.webp 720w"
alt="MP-1 Rack modules mounted" width="720"
/>
&lt;/a>
&lt;/p>
&lt;h2 id="the-dap-audio-mp-1-modular-frame">The DAP Audio MP-1 Modular Frame&lt;/h2>
&lt;p>While waiting for my order to arrive, I started looking around for some dimensions to start designing each mount. There isn&amp;rsquo;t much data available on the internet and the main resources for dimensions was the previously mentioned 3D models.&lt;/p>
&lt;p>Once I received my order, I took the time to measure everything before installing the frame to help others build their custom modules in the future.&lt;/p>
&lt;p>The frame is a 2U 19&amp;quot; rack panel made from 2 mm bent sheet metal consisting of two 9 mm wide rails and a 441 mm × 70.3 mm center opening. Each rail has ten 3 mm untapped screw holes, though the panel is delivered with the required self-taping screws required to attach your modules. Those dimensions provide space for ten 44.1 mm × 88.3 mm segments, which was confirmed by their blank module measurements.&lt;/p>
&lt;p>Here is a drawing of the dimensions I was able to measure from the frame itself and from the official &lt;a href="https://www.musicstore.com/en_OT/EUR/DAP-Leer-Modul-f-Rackblende-2-10-2-Segmente/art-PAH0017179-000" target="_blank" rel="noopener">one&lt;/a> and &lt;a href="https://www.musicstore.com/en_OT/EUR/DAP-Leer-Modul-f-Rackblende-1-10-1-Segment/art-PAH0017178-000" target="_blank" rel="noopener">two segments&lt;/a> blank face plates available on the Music Store website.&lt;/p>
&lt;p>
&lt;a href="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/dap-audio-mp1.png" target="_blank" rel="noopener noreferrer">
&lt;img src="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/dap-audio-mp1.png"
srcset="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/dap-audio-mp1_hudf7a0a95fc11b0cdbbae22c89e886247_16293_720x0_resize_q100_h2_mitchellnetravali_3.webp 720w"
alt="DAP Audio MP-1 Modular Rack Frame dimensions" width="720"
/>
&lt;/a>
&lt;/p>
&lt;p>
&lt;a href="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/dap-audio-mp1-blanks.png" target="_blank" rel="noopener noreferrer">
&lt;img src="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/dap-audio-mp1-blanks.png"
srcset="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/dap-audio-mp1-blanks_hu94456c5ba29262b7256834838e71c4c9_9668_720x0_resize_q100_h2_mitchellnetravali_3.webp 720w"
alt="DAP MP-1 Module dimensions" width="720"
/>
&lt;/a>
&lt;/p>
&lt;h2 id="the-mp-1-rack-collection">The MP-1 Rack collection&lt;/h2>
&lt;p>Now that I had my base, it was time to build the modules to fill in the frame with my small computers. I ended up building a collection of four modules to fit everything I needed:&lt;/p>
&lt;ul>
&lt;li>&lt;a href="https://www.printables.com/model/227179" target="_blank" rel="noopener">a ZimaBoard mount&lt;/a> that can accommodate up to two 2.5&amp;quot; hard drives&lt;/li>
&lt;li>&lt;a href="https://www.printables.com/model/227181" target="_blank" rel="noopener">a Raspberry Pi mount&lt;/a> with a power button and front facing HDMI port&lt;/li>
&lt;li>&lt;a href="https://www.printables.com/model/227186" target="_blank" rel="noopener">a keystone module&lt;/a> in two size to house either 2 or 6 jacks&lt;/li>
&lt;li>&lt;a href="https://www.printables.com/model/227187" target="_blank" rel="noopener">a blank module&lt;/a> to fill in empty spaces&lt;/li>
&lt;/ul>
&lt;p>
&lt;a href="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/mp1-rack-modules.jpg" target="_blank" rel="noopener noreferrer">
&lt;img src="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/mp1-rack-modules.jpg"
srcset="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/mp1-rack-modules_hudc4e88fe8dc70eb65cc8dc4d4b8cef9b_933612_720x0_resize_q100_h2_mitchellnetravali.webp 720w"
alt="MP-1 Rack modules preview" width="720"
/>
&lt;/a>
&lt;/p>
&lt;h3 id="zimaboard-module">ZimaBoard module&lt;/h3>
&lt;p>I started by first building the ZimaBoard mount, the requirement here was to create a simple but effective way to mount it with spaces for two 2.5&amp;quot; 9.5 mm drives. I first looked at integrating an existing hot-swap solution such as the &lt;a href="https://www.icydock.com/goods.php?id=234" target="_blank" rel="noopener">Icy Dock flexiDOCK MB522SP-B&lt;/a> in my model, sadly, those 3.5&amp;quot; modules are too large to fit in the 2 segments space I wanted this module to take (so I can fit 4 of them on one frame).&lt;/p>
&lt;p>In the end, adding some simple rails under the mount was the solution I went with, it does not provide any hot-swap capabilities but works extremely well with the official &lt;a href="https://shop.zimaboard.com/collections/diy-nas-media-server-bt-client/products/sata-y-cable-for-zimaboard-2-5-inch-hdd-3-5-inch-hdd-raid-free-nas-unraid" target="_blank" rel="noopener">SATA Y Cable&lt;/a>.&lt;/p>
&lt;p>
&lt;a href="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/mp1-rack-zimaboard.jpg" target="_blank" rel="noopener noreferrer">
&lt;img src="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/mp1-rack-zimaboard.jpg"
srcset="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/mp1-rack-zimaboard_hu6a35e30894c47dc62199d5be58df84ff_395243_720x0_resize_q100_h2_mitchellnetravali.webp 720w"
alt="MP-1 Rack ZimaBoard module" width="720"
/>
&lt;/a>
&lt;/p>
&lt;h3 id="raspberry-pi-module">Raspberry Pi module&lt;/h3>
&lt;p>I then went on to create my own Raspberry Pi module, as said in the introduction existing solutions already exists, but none had both space of a front-facing HDMI port and some LEDs / buttons. This started with just a simple mount and cutouts, I decided to use heat-set insert as a mounting solution here to strengthen the connection between the Pi and the module.&lt;/p>
&lt;p>Following that, I added both a space for a 6 mm × 6 mm momentary switch and two 3 mm LEDs that I have configured as a &lt;code>gpio-shutdown&lt;/code> trigger, a simple power LED, and an HDD activity led (more details is available on &lt;a href="https://www.printables.com/model/227181" target="_blank" rel="noopener">this model Printables page&lt;/a>).&lt;/p>
&lt;p>Finally, I added a keystone jack mount, so I can use one of those slim FPV HDMI cables and an HDMI keystone to add a front facing HDMI port (as those cables are also available as mini-HDMI to HDMI, this solution can also be adapted for the Raspberry Pi 4).&lt;/p>
&lt;p>I decided to publish multiple variants of this specific model module as I understand that not everybody wants some shiny LEDs or spent the necessary cash to add the front-facing HDMI port. I&amp;rsquo;ve also added a screw-in version of each variant if you do not want to use any heat-set insert to mount your Pi.&lt;/p>
&lt;p>
&lt;a href="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/mp1-rack-raspberrypi.jpg" target="_blank" rel="noopener noreferrer">
&lt;img src="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/mp1-rack-raspberrypi.jpg"
srcset="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/mp1-rack-raspberrypi_huec896a4e8579eea6a1d975a9d977db2d_466222_720x0_resize_q100_h2_mitchellnetravali.webp 720w"
alt="MP-1 Rack Raspberry Pi module" width="720"
/>
&lt;/a>
&lt;/p>
&lt;h3 id="extra-modules">Extra modules&lt;/h3>
&lt;p>Now that I have a keystone jack footprint, I decided to add two modules to the collection that just allows you to attach some keystone to your frame: a small one segment module that can house 2 jacks and a two segments module for 6 jacks. This ended up being quite a handy way to cleanly connect my router to my rack without having an exposed long cable.&lt;/p>
&lt;p>I also added one segment and two segments blank modules to the collection to provide an easy way to plug your empty slots if you haven&amp;rsquo;t bought the official ones with your frame or to use as a base when creating your own modules.&lt;/p>
&lt;p>
&lt;a href="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/mp1-rack-extra.jpg" target="_blank" rel="noopener noreferrer">
&lt;img src="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/mp1-rack-extra.jpg"
srcset="https://blog.userctl.xyz/posts/2022/06/building-mp1-rack-collection-modular-racking-system/images/mp1-rack-extra_hua6c6a506b198f1a202c7e68a466ec8da_400419_720x0_resize_q100_h2_mitchellnetravali.webp 720w"
alt="MP-1 Rack keystone and blank modules" width="720"
/>
&lt;/a>
&lt;/p>
&lt;h3 id="download-the-collection">Download the collection&lt;/h3>
&lt;p>You can find all those models with their Fusion 360 source files in the &lt;a href="https://www.printables.com/social/242926-orax/collections/191937" target="_blank" rel="noopener">MP-1 Rack collection on Printables&lt;/a> as well as a &lt;a href="https://www.printables.com/model/224057-zimaboard-dual-hdd-stand" target="_blank" rel="noopener">standalone version of the ZimaBoard mount to use a simple desk stand&lt;/a>.&lt;/p>
&lt;p>I really hope this collection will help others create their perfect mounting solutions for their small single board computer and inspire more people in building modules for the MP-1 frame!&lt;/p></description></item><item><title>Announcing BerryOS: a lightweight OS for your Raspberry Pi</title><link>https://blog.userctl.xyz/posts/2022/05/announcing-berryos-lightweight-os-raspberry-pi/</link><pubDate>Mon, 30 May 2022 22:00:00 +0000</pubDate><guid>https://blog.userctl.xyz/posts/2022/05/announcing-berryos-lightweight-os-raspberry-pi/</guid><description>&lt;p>After a couple of weeks working on it, I am proud to finally be releasing the first version of &lt;a href="https://berryos.wiki/" target="_blank" rel="noopener">BerryOS&lt;/a> to the public!&lt;/p>
&lt;h2 id="what-is-berryos">What is BerryOS?&lt;/h2>
&lt;p>
&lt;a href="https://blog.userctl.xyz/posts/2022/05/announcing-berryos-lightweight-os-raspberry-pi/images/berryos-banner.png" target="_blank" rel="noopener noreferrer">
&lt;img src="https://blog.userctl.xyz/posts/2022/05/announcing-berryos-lightweight-os-raspberry-pi/images/berryos-banner.png"
srcset="https://blog.userctl.xyz/posts/2022/05/announcing-berryos-lightweight-os-raspberry-pi/images/berryos-banner_hue5bda957566a0833f00f68da66c062c0_11802_720x0_resize_q100_h2_mitchellnetravali_3.webp 720w"
alt="BerryOS Logo" width="720"
/>
&lt;/a>
&lt;/p>
&lt;p>BerryOS is a lightweight operating system for your Raspberry Pi based on the official Raspberry Pi OS Lite bootstrapped directly from its sources. It is available in two variant: &lt;code>BerryOS/armhf&lt;/code> and &lt;code>BerryOS/arm64&lt;/code> for 32 &amp;amp; 64-bit ARM compatible hardware.&lt;/p>
&lt;p>When building it, my goal was to create a lightweight version of Raspberry Pi OS Lite than can be configured headlessly at first boot using &lt;a href="https://cloud-init.io/" target="_blank" rel="noopener">&lt;code>cloud-init&lt;/code>&lt;/a>. Other images including &lt;code>cloud-init&lt;/code> already exists such as the &lt;a href="https://ubuntu.com/download/raspberry-pi" target="_blank" rel="noopener">Ubuntu Server RPi release&lt;/a> or the now defunct &lt;a href="https://blog.hypriot.com/downloads/" target="_blank" rel="noopener">HypriotOS&lt;/a>, though most of them includes extra software or are not based on Debian itself.&lt;/p>
&lt;p>In order to keep the same level of compatibility with 3rd party software and hardware, I decided to bootstrap it directly from the Raspberry Pi OS sources (&lt;a href="http://raspbian.org/" target="_blank" rel="noopener">Raspbian GNU/Linux&lt;/a> and &lt;a href="https://www.debian.org/" target="_blank" rel="noopener">Debian GNU/Linux&lt;/a> for its &lt;code>armhf&lt;/code> and &lt;code>arm64&lt;/code> version respectively) with some tweaks to the list of pre-installed package and default configuration.&lt;/p>
&lt;p>In the end, BerryOS turned out to be nearly 40% lighter than Raspberry Pi OS Lite, had fewer processes running by default while being completely configurable using &lt;code>cloud-init&lt;/code>.&lt;/p>
&lt;p>Here is a comparison table between the first BerryOS release (BerryOS Bullseye 2022.05.30) and the latest Raspberry Pi OS Lite release (Raspberry Pi OS Bullseye 2022.04.04) running on a Raspberry Pi 3 B:&lt;/p>
&lt;table>
&lt;thead>
&lt;tr>
&lt;th>Stat&lt;/th>
&lt;th>BerryOS/armhf&lt;/th>
&lt;th>RaspiOS/armhf&lt;/th>
&lt;th>BerryOS/arm64&lt;/th>
&lt;th>RaspiOS/arm64&lt;/th>
&lt;/tr>
&lt;/thead>
&lt;tbody>
&lt;tr>
&lt;td>RAM usage&lt;/td>
&lt;td>37M&lt;/td>
&lt;td>57M&lt;/td>
&lt;td>52M&lt;/td>
&lt;td>72M&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>Running processes&lt;/td>
&lt;td>12&lt;/td>
&lt;td>18&lt;/td>
&lt;td>12&lt;/td>
&lt;td>20&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>Disk usage&lt;/td>
&lt;td>807.1M&lt;/td>
&lt;td>1.3G&lt;/td>
&lt;td>611.7M&lt;/td>
&lt;td>1.3G&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>Pre-installed packages&lt;/td>
&lt;td>312&lt;/td>
&lt;td>530&lt;/td>
&lt;td>285&lt;/td>
&lt;td>521&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>Download size&lt;/td>
&lt;td>201M&lt;/td>
&lt;td>297M&lt;/td>
&lt;td>153M&lt;/td>
&lt;td>271M&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>Image size&lt;/td>
&lt;td>1312M&lt;/td>
&lt;td>1924M&lt;/td>
&lt;td>1112M&lt;/td>
&lt;td>1908M&lt;/td>
&lt;/tr>
&lt;/tbody>
&lt;/table>
&lt;p>The methodology for these results can be found in &lt;a href="https://github.com/0rax/BerryOS/blob/main/README.md#Benchmark" target="_blank" rel="noopener">the Benchmark section of the BerryOS README file&lt;/a>.&lt;/p>
&lt;h2 id="where-to-get-it">Where to get it?&lt;/h2>
&lt;p>BerryOS is completely open-source and licensed under the &lt;a href="https://opensource.org/licenses/ISC" target="_blank" rel="noopener">ISC License&lt;/a>. Its source code is hosted on GitHub at &lt;a href="https://github.com/0rax/BerryOS" target="_blank" rel="noopener">github.com/0rax/BerryOS&lt;/a>.&lt;/p>
&lt;p>From there, you can download all current and previous version of each variant or checkout &lt;a href="https://berryos.wiki/" target="_blank" rel="noopener">its documentation&lt;/a> (which is still a work in progress) where you will also find &lt;a href="hhttps://berryos.wiki/docs/examples/">some example configuration files&lt;/a> to get you started.&lt;/p>
&lt;p>If you decide to give it a go and find any issues with it, do not hesitate to &lt;a href="https://github.com/0rax/BerryOS/issues/new" target="_blank" rel="noopener">report them on GitHub&lt;/a>, so they can be fixed as soon as possible.&lt;/p>
&lt;h2 id="how-to-use-it">How to use it?&lt;/h2>
&lt;p>Grab your closest Raspberry Pi and your SD card of choice, head to the &lt;a href="https://github.com/0rax/BerryOS/releases/latest" target="_blank" rel="noopener">latest release page&lt;/a> and download the variant you need.&lt;/p>
&lt;ul>
&lt;li>&lt;code>BerryOS/armhf&lt;/code> should be compatible with ALL Raspberry Pi models.&lt;/li>
&lt;li>&lt;code>BerryOS/arm64&lt;/code> should be compatible with the Raspberry Pi 3B, 3B+, 4 &amp;amp; 400, Compute Module 3, 3+ &amp;amp; 4 as well as the Raspberry Pi Zero 2 W.&lt;/li>
&lt;/ul>
&lt;p>
&lt;a href="https://blog.userctl.xyz/posts/2022/05/announcing-berryos-lightweight-os-raspberry-pi/images/rpi-3b.jpg" target="_blank" rel="noopener noreferrer">
&lt;img src="https://blog.userctl.xyz/posts/2022/05/announcing-berryos-lightweight-os-raspberry-pi/images/rpi-3b.jpg"
srcset="https://blog.userctl.xyz/posts/2022/05/announcing-berryos-lightweight-os-raspberry-pi/images/rpi-3b_hubce0dc0a8248cbd6c0a31cb67d590823_190548_720x0_resize_q100_h2_mitchellnetravali.webp 720w"
alt="Raspberry Pi 3B &amp;amp;amp; SD Card" width="720"
/>
&lt;/a>
&lt;/p>
&lt;p>Fire up you favorite tool and flash your newly acquired image to your SD card. Any flashing tools should work, such as the official &lt;a href="https://www.raspberrypi.com/software/" target="_blank" rel="noopener">Raspberry Pi Imager&lt;/a>, &lt;a href="https://www.balena.io/etcher/" target="_blank" rel="noopener">balenaEtcher&lt;/a>, &lt;a href="https://github.com/hypriot/flash" target="_blank" rel="noopener">Hypriot&amp;rsquo;s &lt;code>flash&lt;/code> tool&lt;/a> or even &lt;code>dd&lt;/code> on any *NIX like system.&lt;/p>
&lt;blockquote>
&lt;p>&lt;strong>Note&lt;/strong>&lt;/p>
&lt;p>&lt;a href="https://github.com/hypriot/flash" target="_blank" rel="noopener">Hypriot&amp;rsquo;s &lt;code>flash&lt;/code> tool&lt;/a> can be used pretty efficiently with BerryOS as it allows you to specify extra configuration file to copy to your SD card after flashing directly from the command line.&lt;/p>
&lt;p>For example to flash BerryOS with a custom &lt;code>user-data&lt;/code> and &lt;code>config.txt&lt;/code> file you already have on disk, you can just run:&lt;/p>
&lt;div class="highlight">&lt;pre tabindex="0" class="chroma">&lt;code class="language-sh" data-lang="sh">&lt;span class="line">&lt;span class="cl">flash --userdata user-data.yaml --bootconf config.txt ~/Downloads/berryos-arm64-bullseye-20220527.img.xz
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;/blockquote>
&lt;p>Once successfully flashed, unplug and re-plug your SD card from your computer (to force remounting it) and open the drive named &lt;code>boot&lt;/code>. You should be able to open the &lt;code>user-data&lt;/code> file with your favorite text editor from there.&lt;/p>
&lt;p>&lt;code>user-data&lt;/code> is the configuration file that will be used by &lt;code>cloud-init&lt;/code> to configure your system on its first boot. We have set it up to use the &lt;a href="https://cloudinit.readthedocs.io/en/latest/topics/format.html#cloud-config-data" target="_blank" rel="noopener">Cloud Config format&lt;/a> as it makes configuring a system really simple, though other format are also available.&lt;/p>
&lt;p>This is a really important file when setting up a BerryOS system, as this is where you will set up how to access your system.&lt;/p>
&lt;blockquote>
&lt;p>&lt;strong>Note&lt;/strong>&lt;/p>
&lt;p>By default, BerryOS does not enable password based SSH access to the default user to follow the decision made by the Raspberry Pi Foundation in April 2022 to disable it on Raspberry Pi OS Bullseye going forward (&lt;a href="https://www.raspberrypi.com/news/raspberry-pi-bullseye-update-april-2022/" target="_blank" rel="noopener">source&lt;/a>).&lt;/p>
&lt;/blockquote>
&lt;p>I would suggest going through the whole file (also &lt;a href="https://github.com/0rax/BerryOS/blob/main/rootfs/boot/user-data" target="_blank" rel="noopener">available on GitHub&lt;/a>) and read the comments to understand what you are able to configure using it. You can also have more extensive explanation of the configuration capabilities in &lt;a href="https://berryos.wiki/docs/config" target="_blank" rel="noopener">the project documentation&lt;/a>.&lt;/p>
&lt;p>Here we will just update the default user (&lt;code>pi&lt;/code>) password and enable SSH password authentication and set the system hostname. To do so, append the following lines to the &lt;code>user-data&lt;/code> file:&lt;/p>
&lt;div class="highlight">&lt;pre tabindex="0" class="chroma">&lt;code class="language-yaml" data-lang="yaml">&lt;span class="line">&lt;span class="cl">&lt;span class="nt">hostname&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="l">berryos.userctl.xyz &lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="c"># Set system hostname&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="w">&lt;/span>&lt;span class="nt">manage_etc_hosts&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="kc">true&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="c"># Update /etc/hosts with the new hostname&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="w">&lt;/span>&lt;span class="nt">password&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="l">berryos &lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="c"># Set default user password&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="w">&lt;/span>&lt;span class="nt">chpasswd&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w"> &lt;/span>{&lt;span class="w"> &lt;/span>&lt;span class="nt">expire&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="kc">false&lt;/span>&lt;span class="w"> &lt;/span>}&lt;span class="w"> &lt;/span>&lt;span class="c"># Do not expire password after first login&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="w">&lt;/span>&lt;span class="nt">ssh_pwauth&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="kc">true&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="c"># Enable SSH password authentication for default user&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;p>The &lt;code>password&lt;/code> field can either be a plaintext password or a hashed version of it. On *NIX system, a password can be hashed using the &lt;code>openssl passwd -6&lt;/code> command. The file would end up looking like:&lt;/p>
&lt;div class="highlight">&lt;pre tabindex="0" class="chroma">&lt;code class="language-yaml" data-lang="yaml">&lt;span class="line">&lt;span class="cl">&lt;span class="nt">password&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="l">$6$kEE0sV/2tz/jWBtQ$tRpM0XqKhl3xEroj837u6VCQadIoSL......nSY48unRmtsZv0&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="w">&lt;/span>&lt;span class="nt">chpasswd&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w"> &lt;/span>{&lt;span class="w"> &lt;/span>&lt;span class="nt">expire&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="kc">false&lt;/span>&lt;span class="w"> &lt;/span>}&lt;span class="w"> &lt;/span>&lt;span class="c"># Do not expire password after first login&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="w">&lt;/span>&lt;span class="nt">ssh_pwauth&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="kc">true&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="c"># Enable SSH password authentication&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;p>If you wish to assign a static IP to your Raspberry Pi, you should also edit the &lt;a href="https://github.com/0rax/BerryOS/blob/main/rootfs/boot/network-config" target="_blank" rel="noopener">&lt;code>network-config&lt;/code>&lt;/a> file. For example, to assign the &lt;code>192.168.1.128&lt;/code> IP to your Pi with a &lt;code>/24&lt;/code> netmask (equivalent to &lt;code>255.255.255.0&lt;/code>) and &lt;code>192.168.1.1&lt;/code> as gateway, you should update the file to look like this.&lt;/p>
&lt;div class="highlight">&lt;pre tabindex="0" class="chroma">&lt;code class="language-yaml" data-lang="yaml">&lt;span class="line">&lt;span class="cl">&lt;span class="nt">version&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="m">2&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="w">&lt;/span>&lt;span class="nt">ethernets&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="w"> &lt;/span>&lt;span class="nt">eth0&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="w"> &lt;/span>&lt;span class="nt">dhcp4&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="kc">false&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="w"> &lt;/span>&lt;span class="nt">addresses&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="w"> &lt;/span>- &lt;span class="m">192.168.1.128&lt;/span>&lt;span class="l">/24&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="w"> &lt;/span>&lt;span class="nt">routes&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="w"> &lt;/span>- &lt;span class="nt">to&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="m">0.0.0.0&lt;/span>&lt;span class="l">/0&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="w"> &lt;/span>&lt;span class="nt">via&lt;/span>&lt;span class="p">:&lt;/span>&lt;span class="w"> &lt;/span>&lt;span class="m">192.168.1.1&lt;/span>&lt;span class="w">
&lt;/span>&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;p>Save your modifications, un-mount your SD card and insert it in your Raspberry Pi. Connect you Ethernet cable and power supply, and after some time you should be able to access it using &lt;code>ssh pi@$ip&lt;/code>.&lt;/p>
&lt;p>As &lt;code>avahi-daemon&lt;/code> IS NOT installed by default, you will not be able to use the Pi hostname to connect to it. If you haven&amp;rsquo;t given it a static IP, you will need to find it another way. The easiest solution is to plug a screen to it as BerryOS prints the system IPs on each TTY by default (you might need to switch to TTY2 to get a clean reading by using &lt;code>Alt + Right&lt;/code>). Another solution is to check your router&amp;rsquo;s DHCP assignation table.&lt;/p>
&lt;blockquote>
&lt;p>&lt;strong>Note&lt;/strong>&lt;/p>
&lt;p>If you require Wi-Fi connectivity, you should check out the &lt;a href="https://berryos.wiki/docs/config/network/" target="_blank" rel="noopener">Network Configuration guide&lt;/a> in the BerryOS Wiki to set it up properly.&lt;/p>
&lt;/blockquote>
&lt;p>Congratulation, you can now enjoy BerryOS to its full extent!&lt;/p>
&lt;h2 id="the-future-of-berryos">The future of BerryOS&lt;/h2>
&lt;p>BerryOS is the operating system I with I had for quite some years now, thus I intend to support and keep it up to date with mainstream Raspberry Pi OS for the foreseeable future.&lt;/p>
&lt;p>Having a lightweight alternative to the default operating system for your Raspberry Pi is the real goal here, something than can be used by anyone that just want to tinker a bit more with their hardware and have more control over its software. I do not want to create a complete new ecosystem but keep it as close and compatible with RaspiOS as possible without adding unnecessary software or removing capabilities.&lt;/p>
&lt;p>The clear next step for the project now is to expand its documentation and add more example of how &lt;code>cloud-init&lt;/code> can be used. Those Cloud Config files are great to share setups with each other and having great resources built around this possibility should be what we aspire to.&lt;/p>
&lt;p>If this is something that you find interesting, come check it out, or even get involved with the project on &lt;a href="https://github.com/0rax/BerryOS" target="_blank" rel="noopener">GitHub&lt;/a>.&lt;/p></description></item></channel></rss>