Skip to content

Enable Google Play Music GMusic

Micz Flor edited this page May 25, 2019 · 3 revisions

See this thread for details: https://github.com/MiczFlor/RPi-Jukebox-RFID/issues/522

You can connect your Phoniebox to Google Play Music.

You need to extend mopidy to work with Gmusic.

You can manage GMusic the same way you are doing this with Spotify (using the iris-interface activate GMusic at the top right search). Then you need to copy the GMusic URI instead of the Spotify URI. The cover won't be added automaticall, everything else seems to work.

How to add Gmusic

Using the 2 factor authentification (as you should), you first need to create an application password in your account. That way, you don't need to add your own password during the configuration - and can block the access easily any time for the application.

  • go to https://myaccount.google.com/
  • go to Security --> App Passwords --> (Login) --> β€œGenerate”
  • where it says Custon App add your name
  • use the generated password

Install mopidy-gmusic

One of these steps can require up to 15 minutes, so be patient, get a cup of tea.

sudo apt-get install libxml2-dev libxslt-dev python-dev
sudo pip install mopidy-gmusic
sudo pip install pyasn1==0.4.1
sudo easy_install pyasn1==0.4.1

Edit /etc/mopidy/mopidy.conf:

sudo nano /etc/mopidy/mopidy.conf

Add your configuration:

If you don't have "All Access" (the streaming subscription), Set this to false in this step.

[gmusic]
username = your.name@gmail.com
password = your_password
deviceid = mac
all_access = true
bitrate = 160

Mopidy fix for interrupted streams

See Issue 161 for details.

Simply change /usr/lib/python2.7/dist-packages/mopidy/audio/actor.py so that this line:

_GST_PLAY_FLAGS_AUDIO = 0x02

Looks like this:

_GST_PLAY_FLAGS_AUDIO = 0x02 + 0x80

Home

πŸ”₯ Version 3

Version 3 Pages

Nothing yet

🎢 Version 2

Version 2 Pages

Installation

Specials

RFID Reader

Sound card configurations

Hardware Buttons

Displays (LED, LCD, Matrix, etc.)

Hacks

Bluetooth

AirPlay

MPD tricks

For Developers

Clone this wiki locally