A Raspberry Pi Zero W is used as a USB Stick with integrated cloud syncronization. All files written to the USB drive are either copied to a Dropbox account or another linux server. Power is supplied by the USB port.
This project can be used in conjunction with a camera system which has the possibility to store the video files locally on a USB stick, but not in the cloud.
Each new video file is automatically uploaded to a free Dropbox account and can subsequently be viewed and replayed with the Dropbox app.
Some very basic linux skills are necessary. Should also work with a "Raspberry Pi Zero 2 W".
This project is open source software licensed via GNU General Public License v3.0, use at your own risk.
Basic process: Install a Raspberry Pi Zero W, adjust project config.json, copy project files to home directory of the Raspi and execute the setup script.
The Micro-SD card should have at least 16GB.
- Install Raspberry Pi OS Lite (32bit) from category Raspberry Pi OS (other) with the Raspberry Pi Imager. Take note whether it is a Debian Bullseye or Debian Bookworm image.
- Settings (After NEXT)
- Set Hostname: raspberrypi.local
- Enable SSH with Password
- Username: pi
- Password: YOUR_PASSWORD
- Setup your Wifi (important)
-
Be patient on first setup boot, it might take several minutes on Raspi Zero.
-
Download latest released RaspiAsUSBStickWithCloudSync.zip and extract files
-
Update settings in configuration file
config.json
:Entry Description ActivateDropboxSync Activate (1) or deactivate (0) sync to dropbox Dropbox... Prepare and configure for Dropbox sync -
Copy all extracted and updated files from
home_pi
to/home/pi
on the Raspberry Pi.For example use WinSCP:
- File protocol: SFTP
- Host name: raspberrypi.local
- User name: pi
- Password: YOUR_PASSWORD
-
Login to Raspberry Pi with SSH. For example use Putty with
Host name: raspberrypi.local
anduser: pi
- For Debian Bullseye image type and execute command:
bash /home/pi/execute_setup_bullseye.sh
- For Debian Brookworm image type execute command:
bash /home/pi/execute_setup_bookworm.sh
- For Debian Bullseye image type and execute command:
Note
The setup script downloads and installs necessary software components, configures driver modules as well as services and creates the USB drive image.
-
Restart and you are all set. For a first test connect the pi with it's USB port to your PC and see whether the USB drive is accessible. Create a folder with some files and check whether it is auto uploaded to configured Dropbox or linux server.
- Connect the USB cable to the USB port and not to the PWR port.
- Make sure to have a data capable USB cable and not a cable which only support power via USB.
-
Connect to system of your choice, for example camera system with video sync to USB.