Video Player: build a Raspberry Pi HTPC media centre
By Russell Barnes. Posted

Turn your Raspberry Pi into a working video player by setting up home theatre PC software
Advertisement
The desktop computer you've been waiting for: Raspberry Pi 500+
Building a video player with a Raspberry Pi is easy and useful. You can hook up your Raspberry Pi to a television and play internet video files, or streams.
Building a media centre, or HTPC (home theatre PC) is one of the most rewarding projects a newcomer can complete.
It’s easy to turn a Raspberry Pi into an HTPC, and you can quickly hook it up to your television.
Make a Raspberry Pi Video Player
Using an HTPC, you can play video and music files, and stream video and audio from online services. And unlike proprietary systems, such as Apple TV and Google Chromecast, you can use it to play just about any media format.
You can add streaming services to your HTPC, such as BBC iPlayer and Soma radio stations. These enable you to play media directly from the internet.
There are several pieces of software available for setting up an HTPC. Two options you’ll find on the Raspberry Pi Foundation’s Downloads page are OSMC and LibreELEC. Both are similar and run a media player called Kodi.
In this guide, we’re going to opt for OSMC. It’s a free and open-source media centre built on top of Debian, and is reliable and easy to use.
Setting up OSMC on a Raspberry Pi is a straightforward and rewarding project. Let’s get started.
>STEP-01: Installation of Image File
First, install the OSMC image to an SD card. Download the OSMC disk image for Raspberry Pi Zero or Raspberry Pi 2/3. Flash the image to an SD card using Etcher (etcher.io).
>STEP-02: Setup the Raspberry Pi
Insert the SD card into your Raspberry Pi. Connect a keyboard and use an HDMI cable to connect a display. Power up and go through the Welcome section. It’s a good idea to keep SSH enabled (the default option).
>STEP-03: Get hold of video files
To test video playback, we’ve downloaded a copyright-free video file of a movie called Return of the Kung Fu Dragon. Download the Ogg Video version and then transfer the file to a USB flash drive.
>STEP-04: Playing video files
Connect the flash drive to the Raspberry Pi. In the OSMC interface, select Videos > Files and the flash drive. Here you’ll see the Ogg video file you copied across. Select it, and the video will start playing.
>STEP-05: Video and audio streaming services
Select Videos > Video Add-ons > Get More. Scroll down the services to find Nasa and select Install. Press ESC to get back to the main screen and select Videos > Nasa. Choose Livestreams and NASA TV to watch the station. For keyboard controls, visit the Kodi wiki.
>STEP-06: Remote control
Open the app store on your phone and search for Official Kodi Remote (Kore on Android). Open the app, and click Add Host then Find Kodi. It should find the Raspberry Pi on your network. Click Save. Now use the app as a remote control.

Russell runs Raspberry Pi Press, which includes The MagPi, Hello World, HackSpace magazine, and book projects. He’s a massive sci-fi bore.
Subscribe to Raspberry Pi Official Magazine
Save up to 37% off the cover price and get a FREE Raspberry Pi Pico 2 W with a subscription to Raspberry Pi Official Magazine.
More articles

Raspberry Pi 500+ in Raspberry Pi Official Magazine issue 158
We’re quite taken with Raspberry Pi 500+. But when you don’t need all that processing power, and just want a board that will make a plastic skeleton jump around in a terrifying manner, you’ll find Raspberry Pi Pico more than up to the job. There’s more terror in the magazine (which is only right as […]
Read more →

Win one of five Raspberry Pi SSD 1TB
Raspberry Pi prides itself on high quality hardware, and this 1TB Raspberry Pi SSD is no different. You can use it with a standard Raspberry Pi or even in your desktop PC – the choice is yours. We have five to give away and you can enter below Win 1 of 5 Raspberry Pi SSD […]
Read more →

Dual-screen cyberdeck
Twin screens mean you can code on one screen while watching David Bowie’s 1978 Musikladen show on the other.
Read more →
Sign up to the newsletter
Get every issue delivered directly to your inbox and keep up to date with the latest news, offers, events, and more.