A simple replacement for the Gnarbox (RIP).
This is to replicate some of the functions of that device, ideally to run on different iterations of the Raspberry PI and to have output displayed on a range of modules, LEDs and displays as I have them and develop the code.
Currently there is an alternative for the Gnarrbox doing the rounds on Kickstarter etc, this is the UnifyDrive UT2, earlybird price is 399 USD without any storage addded see Kickstarter Campaign. A 2TB NVME drive is likely about 150 USD, so looking at 550 USD or possibly a lot more after launch.
This project then is to provide a much cheaper alternative to that, though maybe without a nice box to put it in, and no battery either. But, we can create it with Raspberry PI's, storage and display options that fit in our budgets!
To be clear, my intention is to create a small low cost device, that I can use to backup my photos and videos while travelling and then when returning home, can copy those photos either onto my computer or my NAS for editing. Everything else is a bonus. I could carry a small laptop but I have enough weight in my bag with cameras/lenses, tablet etc and I also do not want to have to create an application that I can run on my phone/tablet to perform this function. TBH a pocket laptop like those created by GPD may be suitable if I could add 2TB of NVME storage to them but they are still pretty pricy as are the linux phones that are available.
I am developing this against a Raspberry PI 5, this has a NVME NANO along with a WD Black 2TB SN770M NVME drive 2230 M.2, its packed into the standard Raspberry Pi 5 Case, though this needed some modification to allow the fan to work. I did not use the active cooler fan, as there were some reports of this fan being sub-optimal in this case, though my construction may be even more sub-optimal! To read from SD an micro SD cards I use an Anker 2-in-1 USB 3.0 SD Card Reader. Finally I Use Right Angle USB C Male to Female Adapters to keep the power cable tidy.
That is my setup, could do with a nicer case and something stronger than the thin perspex I used for the cover
Depending on devices you connect, then tall headers or extra tall headers may come in handy
I am using Raspberry PI OS lite (64bit) - so no GUI, this may change later to allow display on HDMI or similar screens
For the status output, I have the following and have tried to get them to work
-
Adafruit trinkey NeoPixel SAMD21 USB - this would eb a super basic display cannot get this to work with serial port
-
blinkt - basic LED only display, 8 LEDs. I've had this working but possibly my current blinkt! is broken
-
Adafruit Mini PiTFT - 135x240 Color TFT - this is currently the preferred display for a pi zero 2W
-
Adafruit Mini PiTFT - 240x240 Color TFT - this is currently the preferred display
-
Waveshare 1.28" Round Touchscreen LCD Display - cannot get this to work with 64 bit OS
-
LED shim - basic LED only display, 24 LEDs
The main code (gnarlypi) is to run at boot from cron, it will auto mount inserted SD cards (or cameras via USB) that appear to contain photos by having a DCIM directory at the top level of the device.
My setup has an attached NVME drive which will hold the copied photos but the code will copy to the directory usb_data in the users home directory. You can mount any USB or NVME drive to this directory. This will be noted later in the installation instructions.
To allow many different types of output displays, output status will be published to MQTT topics, scripts will be provided to read from these topics and display the required output that the device can manage, allowing many/all of the devices to be running sided by side! One other thing that intrepid users may want to consider is adding alternative status output devices, e.g use a text to speech synth to output via a speaker or headphones.
See [[the_software]] for more details
Head over to Raspberry PI and grab the Raspberry PI Imager. Choose your device, the OS (Raspberry PI OS lite) and edit your settings to enter your WiFi details, the hostname you want the device to use and the ssh credentials you wish to use.
Build your Raspberry PI, adding any required drives etc, I have some notes in Hardware setup
Hopefully this is the straight forwards bit, clone this repo onto your pi, into your home directory, then cd
into the gnarypi
directory and run the installer
./installer.sh
You will be prompted to enter a password (twice), this is for the SAMBA file sharing and is for the name of the user you are currently logged in as. Please remember this password!
Hopefully that will do everything needed and the system will reboot and it will just work. Raise an issue on the repo if there are any problems and I will see if I can resolve them.
If you make any changes to the connected displays run the display_config.sh
script to make changes.
Rebooting the system when it has been installed, will have the system up and running. Either connecting a camera (in storage mode) via USB or a suitable SD Card reader, such as the Anker 2-in-1 USB 3.0 SD Card Reader which also has micro SD card slots,
Copying will start automatically when a suitable card/device is connected, the display(s) will show the status until the copy is complete. You will then be prompted to remove the card and the system will return to waiting for another device to be connected.
Data should be read from a USB3 connected SD card reader around 180MB/s depending on your SD card and via a USB cable to your camera at about 25MB/s, so set aside plenty of time to copy! :)
The system uses SAMBA to provide file sharing, allowing you to retrieve previously stored files. On your home network, you should be able to connect to using the host name of the system you created when building the system
I have not given much thought to documenting this step but you will need to connect as a registered user, with the username of your raspberrypi and the password you created during installation.
- Windows - How to connect to Linux Samba shares from Windows
- Mac/OSX How to Connect Your macOS Device to an SMB Share
- Linux - given the range of options for file managers etc, I am not going to provide a link, you are competent enough to search the internet yourself
see [[TODO]]