API/interface to pull recorded show listings, metadata, and files off of the Tablo

I am having trouble getting the script to work. I am running it with the ip addy of the Tablo and the -list flag (obviously incorrectly or I wouldn’t be posting ) :frowning:


Probably something stupid. Any help would be appreciated.
Thanks

I tried the below script first. I also tried c:\Python27>tablo2go.py -tablo:192.168.1.6 -list with the same results.

c:\Python27>python tablo2go.py -list
Tablo Extractor (Version 0.23)
 Usage: tablo2go.py “search regex”
 Options:    -tablo:IP_ADDR        tablo ip address (multiple tablos seperated b
y a colon)
             -ffmpeg:PATH          path to ffmpeg (ex /bin/ffmpeg)
             -db:file              Tablo Extractor Database File
             -output:dir           Save final files here
             -a                    Reprocess ever 30 minutes, do not exit
             -list                 List videos on Tablo(s)
             -csv                  List videos on Tablo(s) in a script readable
format
                                   note: this sets debug/printing to off.
             -handbrake            Post process with handbrake (and delete .mp4
file)
             -tv                   Process only TV shows
             -movies               Process only Movies
             -proc:IP_ADDR:VIDEOID Process only specified file (only one)
             -c                    Mark matched videos as complete/transfered
 Note: Search Terms are optional and should be in a quote if more than one word.
c:\Python27>

@gradman2k3  , you are using an older version, try downloading the most recent from https://sites.google.com/a/moboard.com/tablo/ - -list was not an option in the first.  Hopefully that will help clean things up.

Thanks for the info. I just clicked on the top link stupidly assuming it was the latest version. I’ll grab the latest one and give it a go.
Thx

@brian0


I had similar results using hdmkv’s procedure:

[Feb 25 12:45:19 2015] [192.168.3.185] - Converting video to .mp4
[Feb 25 12:45:19 2015] [192.168.3.185] - Creating mp4 file
Traceback (most recent call last):
  File “tablo2go.py”, line 1051, in
    filename = get_video(ipaddr, show_id, tmsid, rDict(OPTIONS, [‘ffmpeg.exe’], ‘ffmpeg’)[0], OPTIONS, FLAGS, show_proc)

  File “tablo2go.py”, line 871, in get_video
    subprocess.call(cmd)
  File “C:\Python27\lib\subprocess.py”, line 522, in call
    return Popen(*popenargs, **kwargs).wait()
  File “C:\Python27\lib\subprocess.py”, line 710, in init
    errread, errwrite)
  File “C:\Python27\lib\subprocess.py”, line 958, in _execute_child
    startupinfo)
WindowsError: [Error 2] The system cannot find the file specified

Have you figured out how to correct so the script works?
@BoomerTheWeim
I'm trying to post process the tablo2go with mcebuddy.  i'm having some issues with the metadata being way off (season # results in 56 when it should be 3 for example, similar issues with episode #'s) and i'm not sure if its because of the way tablo2go names when the mce option is selected, if its because I'm using the mutagen option, or if my problem lies in the mcebuddy process.  I noticed you made changes to the 33 version.  I"m using the 56 version of tablo2go.  Did you have a similar problem?  Also, what's better to input to mce? .TS or MP4?

I would suggest reach out to the mcebuddy forum, they’re pretty responsive.


https://mcebuddy2x.codeplex.com/discussions
Solved! Used oldmike's procedure from 2/15/2015 which relocates (I copied) files from bin folder to c:\\python27 folder. -list, and download/convert to MP4, both work fine. I did see that a 1 hour 35 minute movie took 23 minutes to download and convert.
@brian0

I had similar results using hdmkv's procedure:

[Feb 25 12:45:19 2015] [192.168.3.185] - Converting video to .mp4
[Feb 25 12:45:19 2015] [192.168.3.185] - Creating mp4 file
Traceback (most recent call last):
  File "tablo2go.py", line 1051, in
    filename = get_video(ipaddr, show_id, tmsid, rDict(OPTIONS, ['ffmpeg.exe'], 'ffmpeg')[0], OPTIONS, FLAGS, show_proc)

  File "tablo2go.py", line 871, in get_video
    subprocess.call(cmd)
  File "C:\\Python27\\lib\\subprocess.py", line 522, in call
    return Popen(*popenargs, **kwargs).wait()
  File "C:\\Python27\\lib\\subprocess.py", line 710, in __init__
    errread, errwrite)
  File "C:\\Python27\\lib\\subprocess.py", line 958, in _execute_child
    startupinfo)
WindowsError: [Error 2] The system cannot find the file specified

Have you figured out how to correct so the script works?

My procedure was simply downloading the recorded stream as is (and not my procedure; just following script commands on page 1 of this thread); what you have above looks like it’s trying to convert?

@jskenney
Thanks Jeffrey - This is a fantastic script!  I'm a Linux user (Linux Mint - based off Debian/Ubuntu), and I wanted to let you know it works great for me and to share my experience in case it helps others...

  • I did not need to install any additional software.  I just simply downloaded the latest tablo2go file (from https://sites.google.com/a/moboard.com/tablo/) and moved the .py file to my media directory. 
  • Python is already installed by default in Mint - I had no need to install it.
  • ffmpeg has been replaced by avconv starting in Ubuntu 14.04 / Mint 17, and uses the same syntax.  Again, I did not need to install it (included in libav-tools package), but I did need to tell tablo2go to use this program instead of ffmpeg using the option you kindly provided.
  • The auto detect IP address of my tablo didn't work for me, but I have mine assigned a static IP address, so I just use that and didn't investigate further.

Here is what my command line looks like:
cd ~/Media_Library
python tablo2go-2.0.56.py -tablo:192.168.1.50 -ffmpeg:avconv -list

Of course the -list option can be omitted or changed and a user would need to substitute their own IP address.

Thanks again for creating this.  It is very helpful and greatly appreciated.

I’m trying to use TTG on a Mac.  I’m calling TTG with:

./tablo2go-2.0.56.py -tablo:192.168.0.63 -ffmpeg:graham/Aplications/ffmpeg -db:./tablo2go.db -output:/Users/graham


Alleges well until (I think TTG calls ffmpeg, then I get this:


[Mar  8 15:01:45 2015] [192.168.0.63] - Creating mp4 file

Traceback (most recent call last):

  File “./tablo2go-2.0.56.py”, line 1051, in

    filename = get_video(ipaddr, show_id, tmsid, rDict(OPTIONS, [‘ffmpeg.exe’], ‘ffmpeg’)[0], OPTIONS, FLAGS, show_proc)

  File “./tablo2go-2.0.56.py”, line 871, in get_video

    subprocess.call(cmd)

  File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py”, line 522, in call

    return Popen(*popenargs, **kwargs).wait()

  File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py”, line 710, in init

    errread, errwrite)

  File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py”, line 1335, in _execute_child

    raise child_exception

OSError: [Errno 2] No such file or directory


It seems that TTG calls ffmpeg.EXE which is why I ask about running on a Mac.  All help most welcome.

Cheers

@Graham   Just guessing, but I wonder if ffmpeg on a Mac is just simply ffmpeg rather than ffmpeg.exe (like on WIndows).  If so, you could try the same trick I used on Linux using the -ffmpeg: option.  It is probably also case sensitive.


Maybe try appending -ffmpeg:ffmpeg to your command line.  Or try the command which ffmpeg to see if that returns a match.

@chuckc I think that’s how I called it in the command line?  I’m wondering if the .exe is hard coded somewhere…

@Graham ,


I am assuming you got ffmpeg from the ffmpeg 64 bit link (http://www.ffmpeg.org/download.html which sends you to http://evermeet.cx/ffmpeg/ )

I recommend that you uncompress the download and put the file in the same directory as tablo2go and use

./tablo2go.py -ffmpeg:./ffmpeg 

this should make it work

I got it from there, but via a different route I think!


I’ll try that, thanks


@chuckc I think that's how I called it in the command line?  I'm wondering if the .exe is hard coded somewhere......

No - The .exe is not hard coded if you use the -ffmpeg:” option, but it is assumed without it.  


You can try running ffmpeg from a command line to see if you have the correct name, case and path and then when you get it to respond, use the “-ffmpeg:” option to specify it to tablo2go. 

@Graham 's suggestion to download, decompress and put the file in the same directory as tablo2go is also a good solution and may be less work to get it going.

My wife already has something like 50 episodes of the total 98 episodes over 4 seasons of one of her favorite western shows recorded.

May I assume that when all is said and done, and we find she has all 98 on Tablo how simple would it be to tell this script that we want to grab ALL episodes of xxxx show, all 4 seasons, and convert/save to my PC’s drive (lots of space, no issues) sorted hopefully by episode and season. (With only 98 episodes over only 4 seasons that wouldn’t be nearly as bad as, gasp, GUNSMOKE and all 20 years and 10,000 episodes.)

I suspect the answer is buried here in 10 pages of conversation, but if there’s a simple yes or no can I grab all of one show’s episodes and download/convert them, that’s fine, 
I’ll do the searching in this thread to find the way if it’s a yes. 

I promised her that if she was able to figure out how to grab all episodes of her shows that when she had them all, I’d get them saved off on a PC so she could run them any time she wanted and never lose them. I’ll eventually make it easier for us OLD folks who love the old ways - and burn them to DVD with menus, and label them as to season, episodes, etc. as if she had bought them in a WalMart or from Amazon or whatever. 
She loves DVD box sets and this is cheaper by a long shot. I’ve got tons of DVDs.



@ShadowsPapa ,


The system was designed with the purpose in mind, and defaults to making a structure that is plex friendly (show/season/episode), additionally you don’t have to wait until all the files are on the tablo, the default should use a history file which will keep track of what has already been downloaded.

To go after a specific show just add the name at the end of the command line after the options, example (assuming ffmpeg is in the current directory)

./tablo2go.py -ffmpeg:./ffmpeg The Simpsons


@ShadowsPapa - Yes, this will work perfectly for what you want to do.  


In addition to what @jskenney posted, you can also manually edit the tablo.history file to skip files you want to leave on the tablo and not download.  I do this all the time.  First I use the “-list” option to get a list of all files on the tablo that are not yet download (i.e. those already present as recorded programs on the tablo, but not included in tablo.history) and then I copy and paste those lines matching files I want to skip into the tablo.history file.   Then when I run tablo2go, it will only download those files I have not excluded.

If you are wondering why I do this, I leave files on the tablo I don’t intend to keep or wouldn’t mind losing.  For those I want to keep, I download using tablo2go, remove the commercials and put them on my Plex server where they get backed up.  Then I delete those recordings from my tablo.

Wow, thanks. @jskenney it Can’t get any easier than that. I could create a VBscript to prompt me for a show title and make it as simple as using a shortcut, typing a show name, hit enter and letting it go to work. 


arrayScr = Split(WScript.ScriptFullName, “”, -1, 1)
For i = 0 to UBound(arrayScr) - 1
   varPath = varPath & arrayScr(i) & ""
Next

’ Prompt for Show name
ShowName = InputBox(“Enter the Show Title or Name”, “Extract show and convert”)
etc. etc.
objWSHShell.run ("tablo2go.py " & “-ffmpeg:./ffmpeg” & ShowName)

I could have it wait until tablo2go was finished and then log the start and stop times, or pop-up a box when it was finished, or show any errors and so on anyway,
 something similar to that, that’s a rough guess until I look at details.
I’m old skool and work my tricks with VBS.


I found it a lot easier just to keep the ffmpeg in the same folder as python scripts - especially since it’s a stand-alone exe without any need for a specific home or folder structure. So - it’s in the “current directory”. 

@ShadowsPapa - Sorry to get offside with a change of topic, but you mentioned saving shows to DVDs for long term preservation.  I have a WARNING for you.


My experience with burned DVDs has been horrible.  Most of those I burned (using different burners, different brands in either DVD+R or DVD-R disks) has been that they don’t last that long.  Many of mine went bad within 5 years and very few are readable after 8-9 years.  They were stored in air conditioned and sunlight free rooms and still failed.  As a result, I no longer trust them for anything long term.  I keep all media for long term on a primary Hard Disk with another external Hard Disk as backup.  

I never had this problem with CDs.  I have not tried burning Blu-ray Disks, so they might be better.

I understand the warning and can appreciate it, but yeah, I’d never count on a single copy of anything on a DVD as my only good copy. I’m super-paranoid so I’d always keep multiple copies, including originals on hard drive which I’d move to different drives as even hard drives can fail or fade. 
I’ve had decent luck with DVDs so far. Maybe it is luck, dunno.
I’m not only paranoid, I’m a paranoid packrat. I have things from computers and years I can’t even remember. When I burn things to DVD, the source is always kept off on a drive that’s checked every so often for integrity. My goal is to get them off the Tablo drive, get them to a medium that’s easy for my wife to use (pop a disk into the player and enjoy) while having a archive of the originals off elsewhere.

I always take whatever CD we buy and duplicate that and run from a copy.
DVDs, of course are typically protected and we’ve not had troubles with commercial copies of shows we’ve bought, but home-brew DVD so far has been fine. I can go back to files from a good 10 years ago and be ok. (I can say that as I have data from a retail store we owned and sold back January 1, 2005 and the files are all still there, intact. Tax info, newsletters, employee records, the web site content I had kept for reference, etc. all still there. I also checked on some files I had turned over to the FBI back in 2011 when I used forensic means to show an employee where I work was pirating movies on government equipment. I kept copies of all of my forensic work, files, documents, meeting notes and so on “just in case”, and those are still intact although that’s only been 4 years now)

For me DVDs are a disposable “convenience” medium for her. I would not delete originals as I have that SATA dock and use older drives to archive things I really want to keep safe. 

My main goal is to get the shows off Tablo as it would otherwise eventually fill. (dang, then I’d have to make some choices!)
This burning to DVD is more for keeping the Tablo “on-line storage” clear and make it convenient for my wife. she likes to SEE a physical thing, a DISK she can hold and put into a player.
DVDs would be off-line storage,
and another drive would be near-line storage - available but not IN Tablo. 

By the way, anyone interested in original install disks for Windows 3.0 from Northgate computer systems? I found my originals and some backup copies the other day.