Running Netflix on Raspberry Pi 3
Download and install Raspbian onto the SD card
- Download zip file for Raspbian Stretch Lite from: https://downloads.raspberrypi.org/raspbian_lite_latest
- Check the SHA256 hash of the downloaded zip file to make sure it has not been tampered with: sha256sum 2018-04-18-raspbian-stretch-lite.zip
- Expected value for SHA256 hash can be found here: https://www.raspberrypi.org/downloads/raspbian/
- Unzip image file: unzip 2018-04-18-raspbian-stretch-lite.zip && rm -f 2018-04-18-raspbian-stretch-lite.zip
- Write image file to SD card: sudo dd bs=1M if=2018-04-18-raspbian-stretch-lite.img of=/dev/mmcblk0
- Insert the SD card in the Raspberry Pi and boot
- Once the Pi is booted, open a terminal and execute the following commands:
- sudo systemctl enable ssh
- sudo systemctl start ssh
- From now on, you should be able to log in using SSH. Username: pi, password: raspberry. The IP address should be shown while booting. Please note I am using wired ethernet.
- Chaning the password for user pi is highly recommended! This can be done using raspi-config
- sudo systemctl disable avahi-daemon.service bluetooth.service bthelper.service console-setup.service rpi-display-backlight.service rsync.service hciuart.service
- sudo apt-get update
- sudo apt-get upgrade
- sudo systemctl disable avahi-daemon.service bluetooth.service bthelper.service rpi-display-backlight.service rsync.service hciuart.service
- sudo update-rc.d -f console-setup remove
- sudo apt-get install xserver-xorg xinit xserver-xorg-video-fbdev lightdm unclutter ratpoison upower xfonts-100dpi xfonts-75dpi xfonts-scalable lxterminal dbus-x11
- Run the command alsamixer and set the volume for PCM to 100%
- In a terminal, run "sudo raspi-config" and:
- 3 Boot Options -> B1 Desktop / CLI -> B4 Desktop Autologin
- 4 Localisation Options -> I1 Change Locale, enable:
- en_US ISO-8859-1
- en_US.ISO-8859-15 ISO-8859-15
- en_US.UTF-8 UTF-8
- your country locales
- Select the default locale you want to use, I use en_US.UTF-8
- 4 Localisation Options -> I2 Change Timezone
- 4 Localisation Options -> I3 Change Keyboard Layout. I use Generic 104-key PC, English (US), English (US), The default for the keyboard layout, No compose key
- 5 Interfacing Options -> P6 Serial -> Would you like a login shell to be accessible over serial?: No, Would you like the serial port hardware to be enabled?: No
- 7 Advanced Options -> A1 Expand Filesystem (This should have been done at first boot)
- 7 Advanced Options -> A3 Memory Split -> How much memory (MB) should the GPU have? 256MB
- Edit /boot/config and change (or add) the following lines:
- hdmi_force_hotplug=1
- hdmi_group=1
- hdmi_mode=4 (720p, 60Hz)
- hdmi_ignore_cec_init=1
- reboot the Pi
- Download and install a version of chromium with WideVine decryption support:
- Edit /etc/lightdm/lightdm.conf and add the following lines:
- [Seat:*]
- xserver-command=X -s 0 dpms
- Create the file /home/pi/.xsession containing:
- ratpoison &
- sleep 1
- while true; do
- chromium-browser
- done
- In Chromium, go to More Tools -> Extensions, go the Chrome Web Store to install the User-Agent Switcher for Chrome (by google.com)
- Right click on the User-Agent Switcher icon and click Options to add a new User Agent:
- Name: Netflix
- User Agent string: Mozilla/5.0 (X11; CrOS armv7l 6946.63.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/47.0.2526.106 Safari/537.36
- Group: Chrome
- Append?: Replace
- Indicator Flag: IE
- Click Add
- Once configured, click on the User-Agent Switcher icon and select Chrome -> Netflix
- Sign in to Netflix to see if it now works. Make sure to save the Netflix username and password in Chromium
- Once it does, edit /home/pi/.xsession and change the chromium-browser command to
- chromium-browser --no-startup-window --disable-sync-preferences --kiosk -disk-cache-dir=/dev/shm --disable-reading-from-canvas --start-maximized --app=https://www.netflix.com/
--
Ivo van Geel - 16 Jun 2018
This topic: Main
> WebHome > RaspberryNetflix
Topic revision: r2 - 16 Jun 2018 - IvoVanGeel