Tut lets you mess with your Tablo. Some things it does:
- automatically finds your Tablo (there are options if you have multiples)
- builds a library of your recordings
- display stats about your library/recordings
- a large number of search options
- search/display incomplete recordings
Matching searches can than be used to:
- delete recordings from your Tablo
- copy recordings to wherever
Here's a fun example that could be used to cleanup crappy recordings on your Tablo:
./tut.py -L library --incomplete 70 | ./tut.py delete
That will find a show with one or more recordings that only managed to record 70% of the show and delete them.
-
Python 3 (tested against Python 3.7.3 on Ubuntu).
-
Tested against Tablo firmware:
- v.2.2.26
Download and unpack the zip of this project or clone it. Go there and...
- run
pip install -r requirements.xt
You maybe want to run this in a virtualenv
With any luck after you've installed it, you can run these commands and it'll do/display a bunch of stuff about your Tablo. See below for details on all sorts of other stuff you can do.
./tut.py config --discover
./tut.py library --build
./tut.py library --stats
./tut.py search --limit 2
Run something like:
./tut.py
python tut.py
python3 tut.py
and you should see something like:
usage: tut.py [-h] [--dry-run] [-L] [-v] [--version]
{config,library,search,copy,delete} ...
Available commands:
{config,library,search,copy,delete}
config manage configuration options
library manage the local library of recordings
search ways to search your library
copy copy recordings somewhere
delete delete recordings from the Tablo device
optional arguments:
-h, --help show this help message and exit
--dry-run show what would happen, but don't change anything
-L, --id-list if possible, only output a list of matching Object Ids
- Pipe this into other commands. (overrides --full and
any other output)
-v, --verbose amount of detail to display add vs (-vvvv) for maximum
amount
--version show program's version number and exit
First things first, get your Tablo set up:
./tut.py config --discover
Want to see some gory details of what happened there?
./tut.py -vvv config --discover
(more v, more info)
Then try:
./tut.py config --view
Possibly you want to look at the config file it told you exists?
Your "Library" is a local copy of recording data at the time you build it.
Before you can do anything useful, you'll need to build the local cache/library of your recordings:
./tut.py library --build
A slow run including 630 recordings takes about 40 sec.
./tut.py library --stats
And you'll see something like:
Overview
--------------------------------------------------
Total Recordings: 609
Total Watched: 65
By Current Recording State
--------------------------------------------------
Finished : 577
Failed : 32
Recording : 0
By Recording Type
--------------------------------------------------
Episodes/Series : 608
Movies : 1
Sports/Events : 0
Programs : 0
This attempts to group recordings by the show/episode they belong to help determine what is unsalvageable.
./tut.py library --incomplete
OR, just find the obviously unsalvageable ones. (70 means 70% or the full show was recorded)
./tut.py library --incomplete 70
You can also pipe the output to delete them like so:
./tut.py -L library --incomplete 70 | ./tut.py delete
There are a number of ways to search your library. This will be useful in specifying recordings you want to work with later.
Important: use the -L flag with any search to create a list that can be piped into other opertaions.
Run ./tut.py search
to see the numerous options available.
A few examples follow. Note the combination of flags.
./tut.py search colbert
or:
./tut.py search --term colbert
./tut.py search colbert --after 2019-07-19
./tut.py search --state failed
./tut.py search --state failed --limit 3
./tut.py search --type movie
./tut.py search --type movie --full
./tut.py -L search --duration 30s
Copy recordings off your Tablo. Currently there are no options to do anything but copy a full recording intact (compress more, downgrade, etc.).
Do a search, add the -L flag and pipe it into copy:
./tut.py -L search colbert | ./tut.py copy
Currently this doesn't: * try to put incomplete recordings together - as such, doesn't deal with TMS IDs to do that
Do a search, add the -L flag and pipe it into delete:
./tut.py -L search --duration 30s | ./tut.py delete
Note: you'll have to add a --yes
flag to make the delete actually occur.
This wouldn't have been made without:
-
the code for the Kodi add-on from the Nuvyyo folks. You'll find the slightly modified version of it
tablo
module.