In just a few words:
- Download the image, do not unzip! It just needs way less space this way.
- Use Raspberry Pi Imager to write the Zip onto a 16GB Card
- It may pass the 100% on the progress bar, just wait until finished
- Depending on your OS, you will see boot, media and maybe root partition
- You may copy files onto the media partition for playback
- You can edit /boot/config.txt for video options
- Add alsa.txt to boot partition to route audio
Please consider a Donation to support the project 🤑
And here is the long read:
Which hardware to use
Since almost all Raspberry Pi use the same engine for video playback, it does not really matter which of them you buy. I suggest to use the Pi 3 A+ which comes in a small form factor but still features standard USB and HDMI connections. There is WiFi and Bluetooth on board, which could be used in future versions, or other projects.
The (micro) SD card can be any card that is 8 gigabytes (or more) in size. A fast card will allow the player to boot more quickly, but since it runs a read-only filesystem and basically stops using the SD card after booting, you could also buy the cheapest you can get. Look for the “A1” or better rated cards, they will boot fast.
As for the USB memory to play back from, the same rules apply. Buying a more expensive one will allow you to store files quickly, but for playback, even the cheap ones will deliver 2-3 megabytes per second, which is enough for the usual data rates of HD video.
Power source should be the original Raspberry, or a good quality tablet charger. It is not only about the amps the supply delivers, also the quality or stability (so to say) of the voltage matters. The operating system icon for insufficient power, which by default would indicate problems, is disabled. I suggest to do a 24h test before installing just to be safe.
Prepare your SD card with the software
Insert the (micro-) SD card into your card reader. Download “Raspberry Pi Imager” for your system, there select “Image” for operating system, then select the file you have downloaded here. It is not necessary to unpack the image after downloading. It would expand into an ~8GB image file.
It will take a while to write, and the progress counter might go past the 100%, so just be patient.
If the image was written properly, a drive called “boot” should show up, a “media” partition, or with MP4Museum-Sync, another partition called “loop”. (Windows might have trouble with showing “media”. Try Raspbian Desktop on the Pi)
Putting everything together
Insert the SD-Card into the Raspberry, connect your display or projector, and the power supply. To make sure the display connects correctly, turn it on before plug in the Raspberry.
After a while, there should be the MP4Museum logo coming up, with a start sound. When the logo goes away, the player software tries to index the files on the SD card as well as on connected usb drives. Every file found will be passed on to the playback engine, which is vlc. Whichever it can play, it will. Usually you would put nothing there which is not for playback, so only files like mp4, avi, mov, mp3, wav, jpg, png, etc. Pictures will be shown for about 5 seconds each.
While you can try whatever type of media you have at hand, only h264 encoded (also h265 on Pi4) mp4 will be played back by hardware, which usually gives you the best performance.
How to encode your media
It is suggested to use the open source software Handbrake, available for Windows, Mac and Linux. There are plenty of presets to start with, to get a reasonable file size while preserving image quality. Export from your editing or compositing tool in a production codec like DNX or ProRes, and then use Handbrake to encode to MP4. Use h264 Codec, except for 4k on Raspi4, which has to be h265.
For synchronized playback on MP4Museum-Sync, it has to be h264, best with constant bitrate for audio. There is no support for h265. Also, do not use variable framerates. The clips should be the same length on all players, and not to short, as it takes a few tries at first for the slaves to sync.
If you want seamless loops, make sure to include “loop.” in your filename, which will enable a special loop mode, so that the playing software runs continously. Depending on your content, if you experience lag around the loop, try different bitrates or keyframe modes in Handbrake, for example the “Production” preset. Loop Mode can be used with several files, adding a button to proceed from file to file.
Building the optional case
If you want to use the Pi 3 A+ hardware, and make a nice case for it just like i did, you can download the models for printing the plastic case. 3D-Print the big parts in your favorite color, and check if the hardware fits nicely with all ports freely accessible. The (optional) small piece, which should be printed in clear or transparent plastic, is used to cover the LED opening on the side. It might need some glue to stay in place.
If not done yet, insert the micro SD card with the installed image into the Pi. Then, place the board inside and screw four M3 10mm counter-sunk screws until they are half way into the board. Then put on the lid, press firmly to keep the board in place, and fasten screws until secured.
Next / Pause – Button
Sometimes your setup might need to use a button to control playback. The Raspberry has a bunch of inputs and outputs, called GPIO, which is the long connector on top of the board. Buttons, switches, relays can be used to either skip to the next file in a list of files, or restart playback, if only one file is played back. Another can pause and restart playback.
To build the hardware, you will need a standard button or switch (closing the circuit while being pressed), a connector for the GPIO and some wire. Simply make the switch connect +3.3V (Pin 1) and Pin 11 (pause) or 13 (quit player = skip / restart), as shown here:
This is a small piece of prototyping board sitting on top of the 2-row connector, which plugs into the rapsberry pi. The blue part is a wire screw terminal, so it becomes easy to exchange switches. The red wires are connecting the terminal to Pin 1 (for 3,3V) and Pin 13, the 7th Pin on that side.
It is possible to connect more switches or other sensors to the Raspberyy this way, with minor changes to the script. Find out more on Hacking.