Enabling Live TV in XBMC/OpenELEC
Allright, time to make Live TV work on OpenELEC. This is applicable not only for the Intel NUC but actually almost any hardware. Let’s start by looking at what do we actually need to watch TV on OpenELEC/XBMC.
- PC with OpenELEC installed (I’ve used version 3.95.7 for this tutorial)
- TV tuner that is supported by OpenELEC
- Antenna connected to the tuner
There is a list of supported TV tuners in the OpenELEC wiki, but it’s not complete. If your tuner is not on the list and it works anyway, please let the wiki maintainers know. For the Intel NUC we more or less have only the ability to use USB tuners. Mini PCI Express tuners might be an option for some but the options available are extremely limited. I’m using a PCTV 290e DVB-T/T2 tuner here, but regardless of the tuner the setup should be similar.
Backend and Frontend
Let’s start with backend and frontend concept. We’ll need both to watch TV. You can also think the backend as a server and the frontend as a client, but that’s a slight simplification. The backend will handle all the TV related activity, such as tuning the channels, managing recordings, handling the program guide (EPG) etc. The frontend is typically running on a device that will interact with the end user, ie. the person watching the TV. There can be several frontend connected to the same backend at the same time. The frontend will receive the video stream from the backend using IP transmission.
In our case, we run the backend and the frontend on the same OpenELEC machine. The backend is a software called Tvheadend and the frontend is a Tvheadend client in XBMC. It’s good to understand the relation between the frontend and the backend. The backend needs to work before there’s even point to try to configure the frontend.
So first we need to configure the backend. Tvheadend that is. First we need to install the Tvheadend addon in the XBMC.
1. First navigate to System – Add-ons – Get Add-ons. Select OpenELEC Mediacenter OS Add-ons.
2. Select Services and tvheadend. Install the add-on.
3. Now you need another computer that is located in the same network with your OpenELEC machine. Then you need to point your browser to the address of the OpenELEC machine. If you don’t know the IP address, you can have a look at system info on the System menu of XBMC.
My OpenELEC machine has IP address 192.168.0.48 so I will need to point my browser on my laptop to address http://192.168.0.48:9981.
4. Now you will see the web interface of the Tvheadend backend. This is where you will configure your tuners, channels and other settings. You can even schedule recordings via the web interface, but most of the time you will want to do that via other means.
Now click the tab Configuration open, select DVB Inputs and finally choose your tuner. Don’t wonder if the tuner on the list says something else than the tuner you bought from the shop. This tends to refer to the tuner module that’s built into your USB/PCIe tuner. For my PCTV 290e tuner it says Sony CXD2820R.
If you don’t see any tuner in the dropdown list your tuner might be unsupported.
5. Now tick the box that says Enabled and click the save button. Then you want to add some DVB networks based on your location. Click the Add DVB Network by Location button.
6. Now choose the network that corresponds to your location and the service you’re trying to tune. If there is no predefined entry for your location, try to find out the correct settings from your TV broadcaster or run the w_scan service (you’ll need a separate add-on for that, but I’m not going to go there now).
7. You can check on the Multiplexes tab if there are any muxes displayed. I’ve got all the 5 muxes that are broadcasted over the air here. You need to wait a moment while Tvheadend scans the muxes for services (channels).
8. Now move over to Services tab and you should see a list of TV channels that Tvheadend has found. In my case there are a lot of pay TV channels that require a subscription, which I don’t have. On this tab I need to map the services to channels. I choose all the free channels and click the Map selected button.
9. Flip over to the Channel / EPG tab. You should now see all the channels you mapped here. You can define the channel numbers if you wish – I like to do that. Remember to click Save changes if you do that. Otherwise no need to touch anything here. It is important that you see the channels on this tab. If you do not have any channels here, there is no point in proceeding any further.
10. Finally you might want to enable the timeshift function. Click open the Recording tab and choose Timeshift. Tick Enabled and On-Demand (unless you want Tvheadend to record all the time when you’re watching a channel). Adjust the maximum timeshift recording size if you wish and then click Save configuration.
You’re done, the backend is now configured. Time to move on and configure the frontend.
Configuring the Frontend
1. Now you need to enable the Tvheadend frontend. Check Systems – Add-ons – Disabled Add-ons and look for Tvheadend HTSP Client. If you cannot find the add-on on the list, there’s a chance that it’s already active.
2. Enable the add-on.
3. There should not be any need to touch the add-on configuration, but in case you want to check, have a look and check that the settings match the ones in the picture above.
4. Now you will need to enable the Live TV. The setting can be found from System – Live TV – General. Tick Enabled. Now the frontend will contact the backend and retrieve a list of channels.
5. You’re done. Move over to Live TV in the main menu and you should see a list of TV channels that corresponds to the list of channels that you had in the Tvheadend configuration.
And that’s it, you’ve got Live TV setup!