How to create a media box using a Raspberry Pi and OSMC (KODI)
What you need
- Raspberry Pi 3 Model B+ (this is the model that I am using, but you can also use other models)
- SD Card — I have a 16GB one
- Power for Raspberry Pi
- Other computer to make the setups.
- A spare USB keyboard for the setup
Download the last image for Raspberry Pi.
Go to osmc.tv/download , scroll down and click on the blue button “Disk Image” to show the list of images for different platforms. I have a Raspberry Pi 3 Model B+ so from that list I go to “Raspberry Pi 2 / 3 / 3+” and download the first image (last by date).
Install on SD Card
Now insert the SD card in a card reader connected to your computer and you will need to install the image downloaded before to the SD card. The easier way to do this is using balenaEtcher.
- Go here to download balenaEtcher and install it. It’s available for Mac, Linux or Windows. So you should be covered.
- Open Etcher and choose the image file (.zip) that you just downloaded. The filename is something like this: OSMC_TGT_rbp2_20190105.img.gz
- Select the SD card you want to write to.
- And click “Flash!”.
- It should take less than 1 minute to flash it.
Power on the Raspberry Pi
Now insert the SD card in the Raspberry Pi, connect to the screen and power supply and wait to boot up the OSMC system. First time it will take longer because it’s doing some installs.
After a few minutes and a restart it should load up. From now on you will need to configure the system.
Configure the System
This steps are very intuitive and you just have to select the language of the system, the time zone, name of the device (can remain osmc). Enable the SSH so you will have access to connect to the raspberry via SSH.
For network access, I didn’t connect my Raspberry Pi via wired so I have to manually set-up the wireless connection. Select Wireless from the list -> Enable Adapter -> Select you network -> Enter the password and you should be connected now to internet.
Setup Remote app (mobile and web)
There is an app available for both Android and iOS to control the media center. Just search for Kodi remote and you should find in the store.
Default the system has no username or password for the remote, I recommend to add one. To do this go to Settings -> Service settings -> Control -> And in the Web server section that should be on by default add a username and password and keep in mind the port because you will need that.
Now go to the mobile app and enter all the details there to connect and that’s it.
Also you can control from a web interface just entering the IP address of the raspberry pi.
Tip1: If you don’t know the IP address go to System Info -> Network and there should be IP address if you are connected to internet.
Tip2: If you don’t see Control in the list, scroll far down and change from Basic to Standard/Advanced or Expert.
How to connect via SSH
If you enabled SSH access as described here in the initial setup steps now you can access the command line via SSH. If you didn’t change anything, the default credentials are:
- username = osmc
- password = osmc
So to connect just go to terminal and
$ ssh firstname.lastname@example.org (make sure you use your own IP address)
I recommend that you change the password first time you connect. To do this you just have to run the command
- Just type
passwdafter you connect to your raspberry using the
- Type the current password:
- And type the new password two times. Make sure you use a strong password.
- Next time when you ssh to media center you will need to use the new password.
Install YouTube Addon
- Go to Addons
- In the top left corner is small package icon. Select it
- Select ‘Install from Repository’.
- Choose ‘Video add-ons’ from the list
- Scroll down to Youtube and select it and Install
Tip: When searching for youtube in the list because there are a lot of addons you can press the left arrow and a menu will appear where you have search.
- Now go back and in Video Addons you should see Youtube. Select it and start the wizard to activate it.
- After you finish to select Language, Region select Sign In from the list
- You will need to do this twice when prompted go to http://youtube.com/activate and enter the code you have on the kodi screen.
- Now you should see all the content related to your YouTube account.
Install Transmission Client and Addon
If you want to install a torrent client on your raspberry pi transmission is a good option over osmc. Everything is very easy and straightforward, just follow the steps.
- Go to My OSMC down in the list
- Go to App Store — bottom right
- Install Transmission Torrent Client.
- Now the torrent client is installed on your osmc media center, and you can access it from your local internet entering the IP address of the Raspberry Pi and the port 9091. By default there is no password.
- Also if you want to have the Transmission Addon on your media center too so you can check the status of the torrents you can install it from following normal steps as described above at Youtube: Add-ons -> Install from repository -> Program add-ons -> Transmission -> Install.
Install Quasar addon
First it depends of what raspberry pi you use so you have to download a different version of quasar. If you have Raspberry pi 3 B+ like me you will need to download ARM v7. If you have a different one you can check using this command what version of processor you have:
- Go to quasar.surge.sh and copy the link to the zip file you need.
- SSH to your media center like described before
- I created a directory in the home directory named Downloads. You can name any name, just remember where you download the zip file.
- Download the zip using wget
$ wget https://github.com/scakemyer/plugin.video.quasar/releases/download/v0.9.78/plugin.video.quasar-0.9.78.linux_arm7.zip
- Go to Addons
- In the top left corner select the small package icon.
- Install from zip file and search for the zip file you just downloaded.
Tip: If something is not working try to restart the system. It might help.
Let me know what other addons you use on your kodi media center.