Difference between revisions of "Netflix Streaming"

From MythTV Official Wiki
Jump to: navigation, search
(Add button to Myth Menu System)
(Use Wine, Silverlight, and Firefox for watching Netflix under MythTV)
 
(22 intermediate revisions by 9 users not shown)
Line 1: Line 1:
 +
== Use Native Google Chrome ==
 +
The simplest and smoothest way to watch Netflix is with the latest Chrome browser.
 +
Complete instructions are at [[Netflix_Native_Integration]].
 +
 +
== Use Wine, Silverlight, and Firefox for watching Netflix under MythTV ==
 +
It is possible to watch Netflix on linux using wine.  Note using wine in this manner may break other applications which use wine.
 +
 +
=== Full Install instructions With Scripts to Integrate Lirc ===
 +
http://www.mythtv.org/wiki/Netflix_Streaming_LIRC_Integration
 +
=== Ubuntu Install ===
 +
see http://www.iheartubuntu.com/2012/11/ppa-for-netflix-desktop-app.html
 +
=== Gentoo Install ===
 +
# download silverlight.patch from this page to /etc/portage/patches/app-emulation/wine
 +
# echo ">app-emulation/wine-1.5.18" >> /etc/portage/package.mask
 +
# Unmask wine and winetricks:  echo "app-emulation/wine ~amd64" >> /etc/portage/package.keywords && echo "app-emulation/winetricks ~amd64" >> /etc/portage/package.keywords
 +
# emerge -av wine winetricks
 +
# install firefox in wine:
 +
# install silverlight in wine:
 +
# wget -O Firefox-14.0.1.exe http://download.mozilla.org/?product=firefox-14.0.1-funnelcake13&os=win&lang=en-US; wine Firefox-14.0.1.exe /S  (more recent versions of FF should work too)
 +
# wget -O Silverlight-4.exe http://silverlight.dlservice.microsoft.com/download/6/A/1/6A13C54D-3F35-4082-977A-27F30ECE0F34/10329.00/runtime/Silverlight.exe; wine Silverlight-4.exe /q
 +
# install fonts: winetricks allfonts
 +
# Verify extended attribute support
 +
## cd ~/.wine
 +
## touch tt
 +
## setfattr -n "user.testAttr" -v "attribute value" tt
 +
## getfattr tt
 +
# For me I have to set opengl to x11-org: select opengl set xorg-x11
 +
# Start firefox in wine: wine "C:\Program Files (x86)\Mozilla Firefox\firefox.exe" http://netflix.com/
 +
# login to netflix as you normally would and try to stream something
 +
# Troubleshooting
 +
## error N8156-6022: I got this error when extended attributes weren't enabled. 
 +
### Check that your kernel supports it: zcat /proc/config.gz | grep XATTR
 +
### Try remounting your fs with mount / -o remount,user_xattr
 +
## error N8156-6013: find mspr.hds under ~/.wine and delete it
 +
# References/external sites
 +
## http://www.iheartubuntu.com/2012/11/netflix-on-ubuntu-is-here.html
 +
## https://forums.gentoo.org/viewtopic.php?p=7197880#7197880
 +
==== HDMI Sound ====
 +
It may be necessary to do the following in order to get sound working across the HDMI interface.
 +
 +
First, list the available sound devices.
 +
 +
  ~$ aplay -l
 +
  **** List of PLAYBACK Hardware Devices ****
 +
  card 0: NVidia [HDA NVidia], device 0: ALC662 rev1 Analog [ALC662 rev1 Analog]
 +
  Subdevices: 0/1
 +
  Subdevice #0: subdevice #0
 +
  card 0: NVidia [HDA NVidia], device 1: ALC662 rev1 Digital [ALC662 rev1 Digital]
 +
  Subdevices: 1/1
 +
  Subdevice #0: subdevice #0
 +
  card 0: NVidia [HDA NVidia], device 3: NVIDIA HDMI [NVIDIA HDMI]
 +
  Subdevices: 1/1
 +
  Subdevice #0: subdevice #0
 +
 +
Next, create /etc/asound.conf with the HDMI device set as default (alter the value based on the output of the above command):
 +
  defaults.pcm.device 3
 +
 +
=== Myth Install ===
 +
==== Add button to Myth Menu System ====
 +
Copy the myth menu you wish to overide to your .mythtv directory<br>
 +
  $ sudo cp /usr/share/mythtv/themes/defaultmenu/mainmenu.xml  /home/<your home directory>/.mythtv/mainmenu.xml
 +
Edit the XML file and add a new section after "Watch TV". Beware that a tag mismatch will prevent the MythTV frontend from starting up properly.<br>
 +
  <button>
 +
    <type>VIDEO</type>
 +
    <text>Watch Netflix</text>
 +
    <action>EXEC DISPLAY=":0" netflix-desktop</action>
 +
  </button>
 +
or
 +
  <button>
 +
    <type>VIDEO</type>
 +
    <text>Watch Netflix</text>
 +
    <action>EXEC DISPLAY=":0.1"  wine "C:\Program Files (x86)\Mozilla Firefox\firefox.exe" http://netflix.com/</action>
 +
  </button>
 +
==== Options for navigating in firefox with the remote ====
 +
## Use X Mouse Keys (should work with all window managers)
 +
### install xkbset if necessary
 +
### enable Mouse Keys: xkbset a ;xkbset m
 +
### test that can now use the keys on your numeric key pad to move the mouse and click (5)
 +
### then map those keys to your remove as needed
 +
 +
== Use VMware and IE for watching Netflix in Windows XP under MythTV ==
 +
I just updated my system using VMware and IE and the CPU usage went down to 80% and now the movies have no jitter.  The first section of this wiki covers that.  My hardware is an Asus M3A with an AMD 5400+ processor and a Nvidia based 6200 graphics card with SPDIF audio. For spdif sound install see AllensDigitalAudioHowto  Allen (4/16/2010)  PS.  I am the author of the original VirtualBox/ Firefox system but seem to be logged in under a different user name.
 +
=== Install VMware and Windows ===
 +
Go to their web site and follow the instructions.  The version you want is VMware Player and it is free. [http://www.vmware.com/products/player/] You will need to register.  Be sure to download the instructions but they are really easy. 
 +
==== Documentation needed ====
 +
==== Getting Started Guide ====
 +
Page 22 of the Getting Started Guide -- Installing VMware Player on a Linux Host
 +
 +
Page 23 of the Getting Started Guide -- Start VMware Player
 +
==== Installing Guest Operating System ====
 +
I used page 21 -- Windows XP
 +
=== Setting VMware options ===
 +
I left all the options stock, 512MB ram and all.  I did change the audio to ALSA as I use digital sound.  For details on setting up digital audio in MythTV and ALSA, see the [[Digital Audio Tutorial]].
 +
=== Install Windows ===
 +
Follow the instructions from VMware. It is also very simple and the extensions install automatically so don't worry bout that when you read it in the instructions. Be sure to update your SPs and IE.
 +
=== Setup Windows ===
 +
Run IE and set Netflix.com as the home page.  IE runs Silverlight faster than Firefox or Chrome.
 +
=== Setup Netflix ===
 +
When you run Netflix you will need to sign in and when you try your first movie, you will need to install Silverlight. They guide you through the process so it is painless.
 +
=== Put IE in start ===
 +
Put IE in the start menu so that it will start automatically.
 +
=== Create button in MythTV ===
 +
  <button>
 +
    <type>VIDEO</type>
 +
    <text>Netflix Streaming VM</text>
 +
    <action>EXEC DISPLAY=":0.1"  /usr/bin/vmplayer /home/dad/vmware/WindowsXP/WindowsXP.vmx</action>
 +
  </button>
 +
 +
WindowsXP is the name I gave my virtual machine
 +
 +
I copied the mainmenu.xml file into my home directory under .mythtv.  I edited it there to add the button.  This way it will not be changed with updates to myth.
 +
=== Running ===
 +
From myth, click the menu button you just created.  You will probably need a keyboard and for sure a mouse to actually select the movie.  Click on Full Screen and enjoy the movie. 
 +
=== Shutdown ===
 +
You can suspend the session by clicking on the "X" in the top VMware Player control panel that shows up when the mouse goes to the center top of the screen.  In this way the session will continue when you start next time, even if in the middle of a movie.  For a normal shutdown, shutdown windows like you would on any windows computer.
 +
 
== How to watch Netflix instant movies in Firefox in XP in Ubuntu ==
 
== How to watch Netflix instant movies in Firefox in XP in Ubuntu ==
 +
Note: I consider this part out of date but leave it here until I get the above method fully documented
  
I recently installed Netflix and can now watch streaming movies in Ubuntu.  This tells how I installed on my Ubuntu 8.04LTS Myth System.  My hardware is an Asus M3A with an AMD 5400+ processor and a Nvidia based 6200 graphics card with SPDIF audio.  For spdif sound install see [http://www.mythtv.org/wiki?title=AllensDigitalAudioHowto]<br>
+
I recently installed Netflix and can now watch streaming movies in Ubuntu.  This tells how I installed on my Ubuntu 8.04LTS Myth System.  My hardware is an Asus M3A with an AMD 5400+ processor and a Nvidia based 6200 graphics card with SPDIF audio.  For spdif sound install see [[AllensDigitalAudioHowto]]<br>
 
This setup really taxes my hardware.  TOP shows 106% cpu which is about 5x the load for Netflix streaming directly.
 
This setup really taxes my hardware.  TOP shows 106% cpu which is about 5x the load for Netflix streaming directly.
 
<br>Allen Edwards (2/17/2009)
 
<br>Allen Edwards (2/17/2009)
Line 41: Line 158:
 
=== Install Silverlight and Netflix Streaming ===
 
=== Install Silverlight and Netflix Streaming ===
 
Get the Netflix streaming plugin for firefox using Silverlight by going to:<br>
 
Get the Netflix streaming plugin for firefox using Silverlight by going to:<br>
Netflix.com/silverlightoptin
+
http://Netflix.com/silverlightoptin
 +
You need to be in the XP version of firefox!
  
 
=== Integrate into Myth Menu System ===
 
=== Integrate into Myth Menu System ===
Line 49: Line 167:
 
   $ sudo cp /usr/share/mythtv/mainmenu.xml  /home/<your home directory>/.mythtv/mainmenu.xml
 
   $ sudo cp /usr/share/mythtv/mainmenu.xml  /home/<your home directory>/.mythtv/mainmenu.xml
 
Edit your menu as desired putting this command in the menu<br>
 
Edit your menu as desired putting this command in the menu<br>
 
 
 
   <button>
 
   <button>
 
     <type>VIDEO</type>
 
     <type>VIDEO</type>
 
     <text>Netflix Streaming</text>
 
     <text>Netflix Streaming</text>
     <action>EXEC /usr/bin/VBoxSDL -fullscreen -vm  "VirtualDad"</action>
+
     <action>EXEC DISPLAY=":0.1"  /usr/bin/VBoxSDL -fullscreen -vm  "VirtualDad"</action>
 
   </button>
 
   </button>
  
  
 
"VirtualDad" is the name of my Windows XP VM
 
"VirtualDad" is the name of my Windows XP VM
 +
The DISPLAY instruction is optional.  In my case, myth runs on display 1 and display 0 is a control center.
  
 
==== Set up Windows XP to autostart Firefox ====
 
==== Set up Windows XP to autostart Firefox ====
Line 84: Line 201:
  
 
Start a movie
 
Start a movie
 +
 +
[[Category:HOWTO]]

Latest revision as of 09:36, 23 December 2014

Use Native Google Chrome

The simplest and smoothest way to watch Netflix is with the latest Chrome browser. Complete instructions are at Netflix_Native_Integration.

Use Wine, Silverlight, and Firefox for watching Netflix under MythTV

It is possible to watch Netflix on linux using wine. Note using wine in this manner may break other applications which use wine.

Full Install instructions With Scripts to Integrate Lirc

http://www.mythtv.org/wiki/Netflix_Streaming_LIRC_Integration

Ubuntu Install

see http://www.iheartubuntu.com/2012/11/ppa-for-netflix-desktop-app.html

Gentoo Install

  1. download silverlight.patch from this page to /etc/portage/patches/app-emulation/wine
  2. echo ">app-emulation/wine-1.5.18" >> /etc/portage/package.mask
  3. Unmask wine and winetricks: echo "app-emulation/wine ~amd64" >> /etc/portage/package.keywords && echo "app-emulation/winetricks ~amd64" >> /etc/portage/package.keywords
  4. emerge -av wine winetricks
  5. install firefox in wine:
  6. install silverlight in wine:
  7. wget -O Firefox-14.0.1.exe http://download.mozilla.org/?product=firefox-14.0.1-funnelcake13&os=win&lang=en-US; wine Firefox-14.0.1.exe /S (more recent versions of FF should work too)
  8. wget -O Silverlight-4.exe http://silverlight.dlservice.microsoft.com/download/6/A/1/6A13C54D-3F35-4082-977A-27F30ECE0F34/10329.00/runtime/Silverlight.exe; wine Silverlight-4.exe /q
  9. install fonts: winetricks allfonts
  10. Verify extended attribute support
    1. cd ~/.wine
    2. touch tt
    3. setfattr -n "user.testAttr" -v "attribute value" tt
    4. getfattr tt
  11. For me I have to set opengl to x11-org: select opengl set xorg-x11
  12. Start firefox in wine: wine "C:\Program Files (x86)\Mozilla Firefox\firefox.exe" http://netflix.com/
  13. login to netflix as you normally would and try to stream something
  14. Troubleshooting
    1. error N8156-6022: I got this error when extended attributes weren't enabled.
      1. Check that your kernel supports it: zcat /proc/config.gz | grep XATTR
      2. Try remounting your fs with mount / -o remount,user_xattr
    2. error N8156-6013: find mspr.hds under ~/.wine and delete it
  15. References/external sites
    1. http://www.iheartubuntu.com/2012/11/netflix-on-ubuntu-is-here.html
    2. https://forums.gentoo.org/viewtopic.php?p=7197880#7197880

HDMI Sound

It may be necessary to do the following in order to get sound working across the HDMI interface.

First, list the available sound devices.

 ~$ aplay -l
 **** List of PLAYBACK Hardware Devices ****
 card 0: NVidia [HDA NVidia], device 0: ALC662 rev1 Analog [ALC662 rev1 Analog]
 Subdevices: 0/1
 Subdevice #0: subdevice #0
 card 0: NVidia [HDA NVidia], device 1: ALC662 rev1 Digital [ALC662 rev1 Digital]
 Subdevices: 1/1
 Subdevice #0: subdevice #0
 card 0: NVidia [HDA NVidia], device 3: NVIDIA HDMI [NVIDIA HDMI]
 Subdevices: 1/1
 Subdevice #0: subdevice #0 

Next, create /etc/asound.conf with the HDMI device set as default (alter the value based on the output of the above command):

 defaults.pcm.device 3

Myth Install

Add button to Myth Menu System

Copy the myth menu you wish to overide to your .mythtv directory

 $ sudo cp /usr/share/mythtv/themes/defaultmenu/mainmenu.xml  /home/<your home directory>/.mythtv/mainmenu.xml

Edit the XML file and add a new section after "Watch TV". Beware that a tag mismatch will prevent the MythTV frontend from starting up properly.

 <button>
    <type>VIDEO</type>
    <text>Watch Netflix</text>
    <action>EXEC DISPLAY=":0" netflix-desktop</action>
 </button>

or

 <button>
    <type>VIDEO</type>
    <text>Watch Netflix</text>
    <action>EXEC DISPLAY=":0.1"  wine "C:\Program Files (x86)\Mozilla Firefox\firefox.exe" http://netflix.com/</action>
 </button>

Options for navigating in firefox with the remote

    1. Use X Mouse Keys (should work with all window managers)
      1. install xkbset if necessary
      2. enable Mouse Keys: xkbset a ;xkbset m
      3. test that can now use the keys on your numeric key pad to move the mouse and click (5)
      4. then map those keys to your remove as needed

Use VMware and IE for watching Netflix in Windows XP under MythTV

I just updated my system using VMware and IE and the CPU usage went down to 80% and now the movies have no jitter. The first section of this wiki covers that. My hardware is an Asus M3A with an AMD 5400+ processor and a Nvidia based 6200 graphics card with SPDIF audio. For spdif sound install see AllensDigitalAudioHowto Allen (4/16/2010) PS. I am the author of the original VirtualBox/ Firefox system but seem to be logged in under a different user name.

Install VMware and Windows

Go to their web site and follow the instructions. The version you want is VMware Player and it is free. [1] You will need to register. Be sure to download the instructions but they are really easy.

Documentation needed

Getting Started Guide

Page 22 of the Getting Started Guide -- Installing VMware Player on a Linux Host

Page 23 of the Getting Started Guide -- Start VMware Player

Installing Guest Operating System

I used page 21 -- Windows XP

Setting VMware options

I left all the options stock, 512MB ram and all. I did change the audio to ALSA as I use digital sound. For details on setting up digital audio in MythTV and ALSA, see the Digital Audio Tutorial.

Install Windows

Follow the instructions from VMware. It is also very simple and the extensions install automatically so don't worry bout that when you read it in the instructions. Be sure to update your SPs and IE.

Setup Windows

Run IE and set Netflix.com as the home page. IE runs Silverlight faster than Firefox or Chrome.

Setup Netflix

When you run Netflix you will need to sign in and when you try your first movie, you will need to install Silverlight. They guide you through the process so it is painless.

Put IE in start

Put IE in the start menu so that it will start automatically.

Create button in MythTV

  <button>
    <type>VIDEO</type>
    <text>Netflix Streaming VM</text>
    <action>EXEC DISPLAY=":0.1"  /usr/bin/vmplayer /home/dad/vmware/WindowsXP/WindowsXP.vmx</action>
  </button>

WindowsXP is the name I gave my virtual machine

I copied the mainmenu.xml file into my home directory under .mythtv. I edited it there to add the button. This way it will not be changed with updates to myth.

Running

From myth, click the menu button you just created. You will probably need a keyboard and for sure a mouse to actually select the movie. Click on Full Screen and enjoy the movie.

Shutdown

You can suspend the session by clicking on the "X" in the top VMware Player control panel that shows up when the mouse goes to the center top of the screen. In this way the session will continue when you start next time, even if in the middle of a movie. For a normal shutdown, shutdown windows like you would on any windows computer.

How to watch Netflix instant movies in Firefox in XP in Ubuntu

Note: I consider this part out of date but leave it here until I get the above method fully documented

I recently installed Netflix and can now watch streaming movies in Ubuntu. This tells how I installed on my Ubuntu 8.04LTS Myth System. My hardware is an Asus M3A with an AMD 5400+ processor and a Nvidia based 6200 graphics card with SPDIF audio. For spdif sound install see AllensDigitalAudioHowto
This setup really taxes my hardware. TOP shows 106% cpu which is about 5x the load for Netflix streaming directly.
Allen Edwards (2/17/2009)

Install VirtualBox

I selected the not-free version not the open source one. It is advisable to download directly from VirtualBox.org as it is very well organized and more up to date than other sources. I would advise using the gui version of the install and not a command line or an get-apt version as the gui version guides you through the process and all the command line guides seem to be out of date.


From inside your Ubuntu system open a browser

Go to VirtualBox.org

Select Downloads

Select (at least as of this date) VirtualBox 2.1.4 for Linux hosts

Click on i386 on this line: Ubuntu 8.04 LTS ("Hardy Heron") i386 | AMD64
Note: if you should actually click on the AMD64, you will know it.

It will put an icon on your desktop. Click on it and install VirtualBox

Set up your virtual machine

Install a virtual machine
Just follow the on screen installation guide. It is as good as anything on the web that guides you through it and I am sure has the advantage of being up to date. I followed the default suggestions with the exception of setting the memory to 512MB.
I set up a Windows XP machine with CD-ROM and ALSA sound.

Install Windows XP

It takes forever but just do it like you would on any computer. Don't forget the updates and service packs.

Install Guest Edition Drivers

I did this to get the ability to go full screen and any screen resolution.
Select DEVICE at the top of the VirtualBox window toolbar
The "Install Guest Additions"

Install Firefox

Open IE, Download and install Firefox.

Install Silverlight and Netflix Streaming

Get the Netflix streaming plugin for firefox using Silverlight by going to:

http://Netflix.com/silverlightoptin

You need to be in the XP version of firefox!

Integrate into Myth Menu System

Add button to Myth Menu System

Copy the myth menu you wish to overide to your .mythtv directory

 $ sudo cp /usr/share/mythtv/mainmenu.xml  /home/<your home directory>/.mythtv/mainmenu.xml

Edit your menu as desired putting this command in the menu

 <button>
    <type>VIDEO</type>
    <text>Netflix Streaming</text>
    <action>EXEC DISPLAY=":0.1"  /usr/bin/VBoxSDL -fullscreen -vm   "VirtualDad"</action>
 </button>


"VirtualDad" is the name of my Windows XP VM The DISPLAY instruction is optional. In my case, myth runs on display 1 and display 0 is a control center.

Set up Windows XP to autostart Firefox

To add Windows Task Manager (or any program) to your Startup folder (that will make it work each time you start the windows and you will see it in the system tray), please follow the below instructions:

1. Click Start>Programs, then right click on Startup folder and choose Open.

2. On the Startup window, go to File menu and choose New>Shortcut.

3. In the dialog box click the Browse button to specify the Task Manager program, it's by default at C:\windows\system32\taskmgr.exe (Where C is the partition that your windows XP is installed on).

4. After specifying the program path, click next and finish. Then you will see a new shortcut (computer icon) in the Startup folder.

5. Right click on that shortcut and choose Properties, select Minimized from the Run combo box, and click Ok, then close the Startup folder.

6. At the next time you start your computer the program will run automatically and you will see it in the system tray.

Setup Firefox start page to Netflix Watch now

Alternatively, you can edit the instructions in the start menu above. This exercise is left to the reader

Watch Instantly

To watch manually:

Start a movie