This is an old revision of the document!


Raspi Video Looper

This is a manual for a simple video-loop-player based on a Raspberry Pi (Zero).

Burn and Config

Burn a Raspberry Pi OS Lite on an SD card. And boot up your Raspberry and connect it to your local net.
(If you want to connect your Raspberry Pi Zero over an USB cable follow this manual:Connect a Raspberry Pi Zero over USB).

Enable SSH on the Raspberry Pi in:

$ sudo raspi-config

(or create a new file named “ssh” in the boot folder).
Change password and expand file system, too and reboot.

Software

To find your Pi on the local net one can scan it with this comand:

 $ sudo arp-scan -l

Log in with: $ ssh pi@ 192.168.???.???? on the Pi update and upgrade:

$ sudo apt update
$ sudo apt upgrade

Install the omxplayer:

$ sudo apt install omxplayer

Autostart

To create the autostart open:

$ sudo nano /etc/rc.local

and write before “exit 0” the following:

printf "  \n"
printf "    =============================================\n"
printf "    =             MY VIDEO LOOP                =\n"
printf "    =                                           =\n"
printf "    =          wolfgang spahn 01-2021           =\n"
printf "    =         http://dernulleffekt.de           =\n"
printf "    =============================================\n"
printf " \n"

If one wants to runan additional program these line should be added: # start LEDs blinking printf “start to blink an LED on GPIO 27\n” /home/pi/paper-duino-pi/blink_02.py &

And to start the omxplayer add that: # start the omxplayer printf “start the video loop\n” omxplayer /home/pi/video/myvideo.mp4 & The video has to be an mp4 (H264) format
To run the omxplayer in the background one has to add the “&” at the end of the line.


Read Only

For preventing any data loss while turning off the Pi one has to change the SD card to read only: Read-Only SD Card