1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

TiVo Streaming Plugin for Plex TiVoToGo.Bundle

Discussion in 'TiVo Roamio DVRs' started by ke3ju, Mar 6, 2018.

  1. Jun 7, 2018 #101 of 129
    rassi

    rassi Member

    152
    0
    Jul 18, 2003
    NE Ohio
    Ok, turned on tivolibre and that didn't make any difference. So tried running the command in a admin command prompt, it just put a bunch of high-bit ascii characters on my screen for a few seconds before it finally stopped scrolling. Never returned to the command line. Window changed to (Not Responding) and I think it died.
     
  2. Jun 7, 2018 #102 of 129
    windracer

    windracer joined the 10k club

    12,034
    141
    Jan 3, 2003
    St. Pete, FL
    I wouldn't think so ... unless Plex has to access the TiVo over the VPN?
     
  3. kbgators

    kbgators New Member

    25
    0
    Dec 28, 2012
    Thanks.
    I had a thought. What about a way to schedule daily downloads using this, so I can get a certain show daily from my tivo recordings onto Plex? Would be ideal to cut out the commercial as well as it comes over to Plex. Thoughts?
     
  4. windracer

    windracer joined the 10k club

    12,034
    141
    Jan 3, 2003
    St. Pete, FL
    Again, I didn't write this plug-in originally, just tinkering with it. From what I understand, channels like this are initiated by the user (when you click on them in the app). Not sure how it would run in the background to download certain recordings. That's above my coding level when it comes to this. kmttg is probably better suited for something like that.
     
    krkaufman likes this.
  5. lew

    lew Well-Known Member

    4,137
    51
    Mar 12, 2002
    That's what I do. It's really an alternative to the tivo plug in approach.

    I set up auto transfers with kmttg. Download, cut commercials then encode putting the encoded video in my Plex folder. I use Windows task to schedule a task which creates auto skip from skip mode then process my auto transfers.
     
    krkaufman likes this.
  6. kbgators

    kbgators New Member

    25
    0
    Dec 28, 2012
    Thanks. I run my media server and Plex on headless Ubuntu so not sure how I would get kmttg to work on the setup.
     
  7. windracer

    windracer joined the 10k club

    12,034
    141
    Jan 3, 2003
    St. Pete, FL
    My Ubuntu server is headless too. You can use VNC to connect to your server (once you have the stuff for X Windows installed) to get to the GUI and get kmttg setup and then use the command-line to execute it in batch. I used to do this a while back when I was using kmttg for auto-downloads.
     
  8. kbgators

    kbgators New Member

    25
    0
    Dec 28, 2012
    Hey thanks for the tip. Why don’t you do auto-download anymore? Seems better than manually picking show if you need them daily.
     
  9. windracer

    windracer joined the 10k club

    12,034
    141
    Jan 3, 2003
    St. Pete, FL
    To be honest I stopped back then because I was just using the TiVo mobile app more to watch the content. But now that I've found this Plex bundle and have been messing with it, I've thought about going back to a kmttg/Plex combination as I find myself using the Plex app to watch content on my phone now more than the TiVo app.
     
  10. kbgators

    kbgators New Member

    25
    0
    Dec 28, 2012
    That's my reasoning as well. I use radarr and sonarr to feed content to Plex, but some shows are only available by using TiVo, so I would like to get those over to Plex as well.
     
  11. windracer

    windracer joined the 10k club

    12,034
    141
    Jan 3, 2003
    St. Pete, FL
    Good news! Thanks to @stephen wheet I think tivolibre on Windows is working now. I've pushed a fix to the Github repo. I did a few basic tests on my barebones Windows Plex setup and streaming and downloading worked. Let me know how it goes.

    The RPC call (needed to properly name the file) on Windows still isn't working. I believe it's a similar path/spaces issue for the certificate file.
     
    BrettStah and ke3ju like this.
  12. windracer

    windracer joined the 10k club

    12,034
    141
    Jan 3, 2003
    St. Pete, FL
    Can one of you Windows users test the RPC query function for the episode search (by filling in your TiVo Online username and password in the plug-in settings) and let me know if it fails for you too? You'll see something like this in the plug-in log:

    Code:
    2018-07-11 22:14:56,997 (2a14) :  INFO (logkit:16) - Executing episodeSearch
    2018-07-11 22:14:57,002 (2a14) :  CRITICAL (core:574) - Exception (most recent call last):
      File "C:\Program Files (x86)\Plex\Plex Media Server\Resources\Plug-ins-31d3c0c65\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\components\runtime.py", line 843, in handle_request
        result = f(**d)
      File "C:\Users\username\AppData\Local\Plex Media Server\Plug-ins\TiVoToGo.bundle\Contents\Code\__init__.py", line 503, in downloadLocal
        remote = Remote(rpc_username, rpc_password)
      File "C:\Users\username\AppData\Local\Plex Media Server\Plug-ins\TiVoToGo.bundle\Contents\Code\__init__.py", line 753, in __init__
        self.ssl_socket = ssl.wrap_socket(self.socket, certfile=getCertPath())
      File "C:\Program Files (x86)\Plex\Plex Media Server\python27.zip\ssl.py", line 933, in wrap_socket
        ciphers=ciphers)
      File "C:\Program Files (x86)\Plex\Plex Media Server\python27.zip\ssl.py", line 580, in __init__
        self.getpeername()
      File "C:\Program Files (x86)\Plex\Plex Media Server\python27.zip\socket.py", line 228, in meth
        return getattr(self._sock,name)(*args)
    error: [Errno 10057] A request to send or receive data was disallowed because the socket is not connected and (when sending on a datagram socket using a sendto call) no address was supplied
    
    I thought maybe this was another Windows path/spaces issue with the certificate file, but after attempting some more debugging I'm not convinced of that anymore. The 10057 error seems to be connection/socket-related. I'm wondering if it's a difference in the ssl.py being used on Windows vs. Linux (Python 2.7). Really just guessing at this point ...
     
  13. BrettStah

    BrettStah Well-Known Member TCF Club

    30,140
    3,678
    Nov 12, 2000
    San Antonio
    I can try it, but maybe not until the weekend.
     
  14. reneg

    reneg Active Member

    939
    108
    Jun 19, 2002
    I installed the tivotogo plugin on Windows and am seeing the following in the logs after selecting download locally:
    Code:
    2018-07-12 09:18:11,301 (273c) :  INFO (logkit:16) - Executing episodeSearch
    2018-07-12 09:18:11,628 (273c) :  CRITICAL (core:574) - Exception (most recent call last):
      File "C:\Program Files (x86)\Plex\Plex Media Server\Resources\Plug-ins-fd05be322\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\components\runtime.py", line 843, in handle_request
        result = f(**d)
      File "g:\temp\Plex Media Server\Plug-ins\TiVoToGo.bundle\Contents\Code\__init__.py", line 501, in downloadLocal
        remote = Remote(rpc_username, rpc_password)
      File "g:\temp\Plex Media Server\Plug-ins\TiVoToGo.bundle\Contents\Code\__init__.py", line 706, in __init__
        self.ssl_socket = ssl.wrap_socket(self.socket, certfile=certfile_path)
      File "C:\Program Files (x86)\Plex\Plex Media Server\python27.zip\ssl.py", line 933, in wrap_socket
        ciphers=ciphers)
      File "C:\Program Files (x86)\Plex\Plex Media Server\python27.zip\ssl.py", line 580, in __init__
        self.getpeername()
      File "C:\Program Files (x86)\Plex\Plex Media Server\python27.zip\socket.py", line 228, in meth
        return getattr(self._sock,name)(*args)
    error: [Errno 10057] A request to send or receive data was disallowed because the socket is not connected and (when sending on a datagram socket using a sendto call) no address was supplied
    
    Plugin seems to work ok with the exception of download. Running Python 2.7.3
     
  15. windracer

    windracer joined the 10k club

    12,034
    141
    Jan 3, 2003
    St. Pete, FL
    Ok, thanks for confirming it's not just my PC. :) If you clear out your TiVo username and password from the plug-in settings, the download should work (as it will skip the episode name lookup which is causing this error/crash).
     
  16. reneg

    reneg Active Member

    939
    108
    Jun 19, 2002
    I'm late to the Plex Tivo plug-in game, but I was having trouble using the plug-in to download TS formatted files. I made some changes to enable TS downloads when TivoLibre is selected as well as change the file naming depending on whether the file is PS or TS format. I tried these changes on both a Roamio Pro & Premiere with both TS and PS files. Feel free to incorporate the changes or not. renegaudet/TiVoToGo.bundle
     
  17. windracer

    windracer joined the 10k club

    12,034
    141
    Jan 3, 2003
    St. Pete, FL
    If it's safe to assume always downloading a .TS file with tivolibre enabled, I have no problem with those changes, thanks. Although I did make your suggested modifications a little differently which required no changes to the dlThread function (that keeps the debug/log messages correct and requires no messing with the filenames in the Popen calls).

    And similar changes aren't necessary to the streaming part of the code you don't think?
     
  18. reneg

    reneg Active Member

    939
    108
    Jun 19, 2002
    No problem incorporating the changes however you see fit. This was my first time looking at the code at all.

    I didn't even try streaming, but looking at the other routines, I'd say similar changes are necessary for the streaming part.

    I've also been trying to figure out that 10057 error, but didn't have any luck. I'll keep poking at it as free time permits.
     
  19. windracer

    windracer joined the 10k club

    12,034
    141
    Jan 3, 2003
    St. Pete, FL
    I appreciate it (and I'm sure others do too)!

    I've noticed that using TS downloads seems to result in more choppy videos (macroblocking). I might add another option/preference so that you can enable tivolibre but then decide if you want TS downloads (your changes) or the MPEG downloads (original code).
     
  20. reneg

    reneg Active Member

    939
    108
    Jun 19, 2002
    Would you mind adding in a couple of lines of code to support listing multiple Tivos? This will remove white space & split Tivos by IP address that are comma separated from the configuration page. Change is located in the MainMenu function

    Current:
    Code:
            if tivoName == "":
                discoverTiVo(oc)
            else:
                oc.add(DirectoryObject(key=Callback(getTivoShows, tivoName=tivoName, tivoip=tivoName), title=L(tivoName)))
    Proposed change:
    Code:
            if tivoName == "":
                discoverTiVo(oc)
            else:
                tivos = tivoName.replace(' ','').split(',')
                for x in range (0, len(tivos)) :
                    oc.add(DirectoryObject(key=Callback(getTivoShows, tivoName=tivos[x], tivoip=tivos[x]), title=L(tivos[x])))
    
    Thanks
     

Share This Page