EXT‐Spotify - bugsounet/MMM-Bugsounet GitHub Wiki

This module show current playback of any devices

This module is an Extented plugins for MMM-Bugsounet

In addition, you can use some plugins:

  • EXT-Librespot for playing spotify music on MagicMirror² with a Premium account (optional)
  • EXT-TelegramBot for controling music with the bot (optional)
  • EXT-SmartHome for controling with google home app (optional)

Screenshot

screenshot

Installation

Execute npm run setup:EXT-Spotify in the MMM-Bugsounet's folder.

cd ~/MagicMirror/modules/MMM-Bugsounet
npm run setup:EXT-Spotify

Configuration

To display the module insert it in the config.js file.

{
  module: 'MMM-Bugsounet/EXTs/EXT-Spotify',
  position: 'top_left',
  animateIn: "flipInX",
  animateOut: "flipOutX",
  config: {
    updateInterval: 1000,
    idleInterval: 10000,
    CLIENT_ID: "",
    CLIENT_SECRET: "",
    mini: true
  }
},
field description type default value
updateInterval Update interval when playing (refresh) NUMBER 1000
idleInterval Update interval when idle (check if Spotify active) NUMBER 10000
useBottomBar Activate visual of the current playback in the bottom bar BOOLEAN false
CLIENT_ID Client ID of your Spotify account STRING ""
CLIENT_SECRET Client Secret of your Spotify account STRING ""
mini Activate mini style instead of big style BOOLEAN true

Generate Token

Pre-installing

Visual Spotify setup

  1. Go to https://developer.spotify.com
  2. Navigate to DASHBOARD > Create an app (fill information as your thought)
  3. Setup the app created, (EDIT SETTINGS)
    • Redirect URIs. : http://localhost:8888/callback
    • That's all you need. Just save it.
  4. Now copy your Client ID and Client Secret to any memo
  5. Past your CLIENT_ID and CLIENT_SECRET in the configuration

Note: Spotify Free member can ONLY display the visual of any device that plays music

Post-installing

Create a token

In RPI Desktop, log in in a Terminal (you can use VNC)

cd ~/MagicMirror/modules/MMM-Bugsounet
npm run setup:EXT-Spotify:token

Then, Allowance dialog popup will be opened. You MUST LOG IN and accept connect to create a token.

That's all. tokenSpotify.json will be created, if success.

EXT-TelegramBot Commands

EXT-Spotify have some telegramBot command.

Just try /spotify:

  • /spotify play: Launch music (last title)
  • /spotify pause: Pause music
  • /spotify stop: Stop music
  • /spotify next: Next track
  • /spotify previous: Previous track
  • /spotify volume [0-100]: Volume control, it need a value 0-100
  • /spotify to [device name]: Transfert music to another device (case sensitive)

Spotify Free Members Restrictions

  • You can ONLY display the visual of any device that plays music.
  • You CAN'T play any music in the Mirror
  • You CAN'T use Vocal Control or telegramBot commands