I’ve been building a TV app for Android TV and Fire TV, called TvStreme.
It’s two things really. It’s a streaming player for Xtream Codes services, the sort that give you a server address, a username and a password, and it’s just as much a media player for your own network, so it’ll play video and music straight off a NAS or a share.
There are plenty of apps that already do the streaming side. I tried a lot of them and didn’t get on with any of them, too many adverts, or a subscription of their own, or everything buried three menus deep. Just to make matters worse, you can never really find out where these apps come from.
Get a bad one of those behind your network and it’s good night Vienna for anything else on the same network.
None of them were simple enough for the person who was going to be using it.
As it stands I reckon it’s easier to use and a lot more powerful than anything else I’ve come across. I’m sure something better is out there, I just haven’t found it.
Before anything else
TvStreme is only a player. It comes with no channels, no playlists and no provider of any kind, and it does nothing at all until somebody puts their own details into it. It’ll run perfectly happily on nothing but your own files on the network.
The login it uses is just a way of delivering channels and there’s nothing dodgy about the format itself. There are properly licensed services that use it and pay for what they carry, and if you’re on one of those you’re not breaking any law. There are also plenty that aren’t licensed, and the free codes scattered all over the internet are almost always somebody else’s leaked account, so leave those well alone. A real service looks like a real company, with an address and a privacy policy, not a Telegram link.
Some countries are a lot stricter about all this than others. Check the law where you live, that part is on you and not me. I’m writing about the app, not about what anyone points it at.
What it is
Kotlin, native, sideloaded, not on any app store. It’s on version 1.1.6 as you read this, which is around 60 files and 8,000-odd lines of Kotlin.
The player runs on Android, so TV boxes, sticks and tablets. The separate program for setting a box up runs on Windows and Mac, both Apple silicon and Intel.
It has to run on an old Fire TV Stick on Android 7.1.1, and that decided nearly everything. No Compose, just plain views and lists. The channel list is never loaded into memory in one go, it goes straight into a local database in batches. The database is only a cache, and old entries are only deleted once a list has downloaded properly, so a refresh that fails halfway doesn’t wipe what was already there.
What it does
Live TV with categories, what’s on now and next, and a small muted preview.
A full TV guide grid you drive with the remote, and from it you can watch something, record the rest of it, set a future programme to record, or go back to something that’s already been on.
Films and series, with resume, sorting and search, and a details screen with the poster, plot, cast and rating.
A picker for the audio and subtitle tracks a video actually has, and it’ll pick up a subtitle file sat next to a video on the share.
Catch-up.
Recording and downloads, including recordings set in advance off the guide, which can go to a Windows or Samba share instead of the stick.
Radio, both the provider’s and an internet radio directory.
Favourites, themes and channel ordering.
Your own files
It doesn’t need a provider at all, it works just as well with nothing but a share on the network.
Audio plays as a queue of whatever else is in the folder, so an album carries on by itself.
There’s a play all and a shuffle all for a folder and everything under it, so an album or a whole pile of them just runs.
Simple mode
This is the reason for the whole thing. It’s simple mode in the settings, but round here it’s YiaYia mode, which is Greek for grandma. It’s for one person in the family who has no interest in technology at all. Telly on, the channel it was left on, and nothing on screen asking questions.
So simple mode hides the lot. No settings, no search, no downloads. There’s the favourites and the full channel list, and almost nothing else can be got at from it. The lists refresh themselves when they get old. Back does nothing on the home screen so there’s no way of falling out of the app by accident. There’s one button to come out of it for when I’m stood in front of it.
It starts itself when the box boots, and it can pick up its settings and a new version from a file on my own server, so I don’t have to keep going round and poking at it.
The bits that took the longest
Lists arriving cut off halfway, which turned out to be the provider and not me. It now falls back to fetching one category at a time.
Channels with a perfect picture and no sound, down to the audio format they use. That needed a decoder adding.
Playing files straight off a network share, which Android doesn’t make easy.
None of it was clever, mostly just stubbornness.
Where it’s up to
It’s in use on the real devices now, not just the emulator.
After a fair bit of testing it’s much smoother to watch than the apps I was using before, IPTV Smarters being the obvious one to compare it with. That part I wasn’t expecting.
The last few features I’d wanted in it have all gone in over the last few days: subtitles and an audio track picker, detail screens, recordings you can set in advance, and the TV guide grid.
If you want a copy
It’s free. Put your email address in and it’ll send you the links: the Android app itself, and the setup program for Windows or Mac. That’s the only thing the address is used for. There’s no list, nothing to sign up to and nothing else to it.
You know where this one came from, at any rate. It’s got my name on it and it comes off my own website, not some advert-strewn download link hidden away in the middle of a page full of porno links.
It’s signed with a debug key and it doesn’t come from any app store, so the rest of this is about persuading the box to accept it.
Getting it onto the box
This is the general shape of it only. Every box words these menus differently, and they get moved about with updates, so look the exact steps up for your own device rather than trusting mine.
On a Fire TV stick: Settings, then My Fire TV, then About, and press the middle button on the device name about seven times until it says developer options are on. Then back into My Fire TV, Developer options, and turn ADB debugging on.
On an Android TV or Google TV box: Settings, then About, press the middle button on Build number about seven times, then find Developer options and turn USB debugging on.
You’ll also have to let it install apps that didn’t come from a store. Older boxes have one switch for unknown sources. Newer ones don’t, they ask you about it per app at the moment you install.
Then it’s either a USB stick with the file on it and a file manager on the box, or adb from the computer: connect to the box’s IP address, allow it on the telly when it asks, and install. The setup program does the adb part for you once the box is connected, which is what it’s for.
When you’re done, go back and turn ADB debugging or USB debugging off again. There’s no reason to leave it on, and a box sat on your network with debugging wide open is exactly the sort of thing I was moaning about at the top of this.
You only have to do all that once. After that it looks for new versions itself and offers them, you just say yes, and it works really well. Android still puts its own install prompt up at the end, and there’s no getting round that one.
The setup program
That’s the Windows and Mac download. It exists for one reason: typing a server address, a username and a long password with a remote control is miserable. You run it, a page opens in your browser, and you fill the boxes in with a proper keyboard, or just paste them straight in. It then sends the lot over to the box on the same adb connection, the account, the network share details and which mode to start up in. The share settings in particular are far less painful that way.
Passwords go to the box and aren’t kept on the computer. It isn’t code-signed either, so Windows and macOS will both pull a face the first time you run it.
You don’t need it. Everything it does can be typed into the app itself if you’d rather, it’s just slower.
