Dashticz - Module - Spotify (new version!)

Dashticz, alternative dashboard based on HTML, CSS, jQuery

Moderators: leecollings, htilburgs, robgeerts

Post Reply
robgeerts
Posts: 1273
Joined: Saturday 24 January 2015 22:12
Target OS: NAS (Synology & others)
Domoticz version: 3.7067
Location: NL
Contact:

Re: Dashticz - Module - Spotify

Post by robgeerts »

Guys, believe it or not but I finally started rewriting the Spotify Plugin ;)
joostnl
Posts: 68
Joined: Wednesday 03 February 2016 19:22
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Dashticz - Module - Spotify

Post by joostnl »

Great! Looking forward
robgeerts wrote: Tuesday 01 May 2018 21:41 Guys, believe it or not but I finally started rewriting the Spotify Plugin ;)
freakshock
Posts: 64
Joined: Friday 14 April 2017 13:39
Target OS: NAS (Synology & others)
Domoticz version:
Location: The Netherlands
Contact:

Re: Dashticz - Module - Spotify

Post by freakshock »

Awesome can't wait! ;)
robgeerts
Posts: 1273
Joined: Saturday 24 January 2015 22:12
Target OS: NAS (Synology & others)
Domoticz version: 3.7067
Location: NL
Contact:

Re: Dashticz - Module - Spotify

Post by robgeerts »

Latest version just pushed to BETA.
Could you please test this? Unfortunately, it only works when you have a premium account (playback functions like prev/next etc).
freakshock
Posts: 64
Joined: Friday 14 April 2017 13:39
Target OS: NAS (Synology & others)
Domoticz version:
Location: The Netherlands
Contact:

Re: Dashticz - Module - Spotify

Post by freakshock »

Good start Rob, thanks :)

Test results:
  • Playlist selection works once, not multiple times. Need a page refresh to be able to switch playlists more than once.
  • Controlling playback on the device Spotify is currently playing on works fine.
  • Switching output device however does not seem to work at all.
    Also I was hoping the plugin would be able to find 'all' Spotify Connect devices, it does not in my case.
    It finds 2 devices on which spotify has recently been playing. If I have not used a spotify connect device (chromecast audio in my case) it does not show up in the devices list anymore.
Martijn89
Posts: 2
Joined: Wednesday 02 May 2018 21:49
Target OS: -
Domoticz version:
Contact:

Re: Dashticz - Module - Spotify

Post by Martijn89 »

Hi Rob,

First of all; great work! Absolutely amazing what you delivered with Dashticz.

I saw your post and tried the update in the beta, but for some reason I have the following issues:
- I don't see any control buttons, just the currently played song and playlist/device. Which I both can select though.
- When I activate the 'spotify' block all other blocks just disappear. When I remove it from the columns[] again the other blocks work as they did before. This goes for all the blocks which come from Domoticz, but the weather, calendar and buienradar still do work. Interesting: the sunrise and sunset and fullscreen button also disappear when I activate spotify. Any idea what can go wrong here?
robgeerts
Posts: 1273
Joined: Saturday 24 January 2015 22:12
Target OS: NAS (Synology & others)
Domoticz version: 3.7067
Location: NL
Contact:

Re: Dashticz - Module - Spotify

Post by robgeerts »

Martijn89 wrote: Wednesday 02 May 2018 21:52 Hi Rob,

First of all; great work! Absolutely amazing what you delivered with Dashticz.

I saw your post and tried the update in the beta, but for some reason I have the following issues:
- I don't see any control buttons, just the currently played song and playlist/device. Which I both can select though.
- When I activate the 'spotify' block all other blocks just disappear. When I remove it from the columns[] again the other blocks work as they did before. This goes for all the blocks which come from Domoticz, but the weather, calendar and buienradar still do work. Interesting: the sunrise and sunset and fullscreen button also disappear when I activate spotify. Any idea what can go wrong here?
Sounds like you're not using the latest version...
If you really do, do you get any errors in console?
freakshock wrote: Wednesday 02 May 2018 20:00 Good start Rob, thanks :)

Test results:
  • Playlist selection works once, not multiple times. Need a page refresh to be able to switch playlists more than once.
  • Controlling playback on the device Spotify is currently playing on works fine.
  • Switching output device however does not seem to work at all.
    Also I was hoping the plugin would be able to find 'all' Spotify Connect devices, it does not in my case.
    It finds 2 devices on which spotify has recently been playing. If I have not used a spotify connect device (chromecast audio in my case) it does not show up in the devices list anymore.
Thanks for your feedback, wil fix this a.s.a.p.
I knew the change of device wasnt working yet.
About the amount of devices, I did only see my devices where spotify was active (or in background on android).
I simply did not get more devices but will try again later :)
robgeerts
Posts: 1273
Joined: Saturday 24 January 2015 22:12
Target OS: NAS (Synology & others)
Domoticz version: 3.7067
Location: NL
Contact:

Re: Dashticz - Module - Spotify

Post by robgeerts »

In latest beta, switching output device is fixed!! :)
I test with playlist selection, I tried multiple times without refreshing and it works... do you get any error?
freakshock
Posts: 64
Joined: Friday 14 April 2017 13:39
Target OS: NAS (Synology & others)
Domoticz version:
Location: The Netherlands
Contact:

Re: Dashticz - Module - Spotify

Post by freakshock »

Both are fixed indeed :)!

The only thing missing for me is that not all spotify connect devices show if if they have not been active recently.
This might not be easy to fix perhaps. For instance, the Windows Spotify client also does not support this. The android app however always shows all connect devices.

This causes me to always have to 'initiate' music play from another device than my Dashticz dashboard (because I have a tablet for this on my wall)

But I'm very happy with this plugin ! :)
tontze
Posts: 317
Joined: Thursday 12 January 2017 15:30
Target OS: Linux
Domoticz version: Beta Ch
Location: Finland
Contact:

Re: Dashticz - Module - Spotify

Post by tontze »

Awesome ! Thnx !
-----------------------------------------
Smartthings
zigbee2mqtt
RFLink 433mhz / Nrf 2.4Ghz
Mi Light
esp8266MiLight Hub
OpenHab/HomeAssistant/Domoticz
HP T610 & Debian 5.10.19-1 x86_64[/b]
robgeerts
Posts: 1273
Joined: Saturday 24 January 2015 22:12
Target OS: NAS (Synology & others)
Domoticz version: 3.7067
Location: NL
Contact:

Re: Dashticz - Module - Spotify

Post by robgeerts »

freakshock wrote: Thursday 03 May 2018 10:32 Both are fixed indeed :)!

The only thing missing for me is that not all spotify connect devices show if if they have not been active recently.
This might not be easy to fix perhaps. For instance, the Windows Spotify client also does not support this. The android app however always shows all connect devices.

This causes me to always have to 'initiate' music play from another device than my Dashticz dashboard (because I have a tablet for this on my wall)

But I'm very happy with this plugin ! :)
Indeed, its not easy to fix...
Maybe the android app scans the network for devices?
By the way, my Android-app also only shows the current active devices...
freakshock
Posts: 64
Joined: Friday 14 April 2017 13:39
Target OS: NAS (Synology & others)
Domoticz version:
Location: The Netherlands
Contact:

Re: Dashticz - Module - Spotify (new version!)

Post by freakshock »

Do you have Chromecast Audio or Google home devices?

I think there's a difference between 'cast targets' like the Chromecast audio, and normal devices like smartphones, PC's and tablets.
My Spotify android app always shows all Chromecast Audio targets, but only devices like my PC when it has recently been playing something.

Anyway, no biggie if it's not doable;)
robgeerts
Posts: 1273
Joined: Saturday 24 January 2015 22:12
Target OS: NAS (Synology & others)
Domoticz version: 3.7067
Location: NL
Contact:

Re: Dashticz - Module - Spotify (new version!)

Post by robgeerts »

I have chromecast devices, but I only see those when they are on ...
User avatar
gielie
Posts: 290
Joined: Tuesday 12 January 2016 11:40
Target OS: Raspberry Pi / ODroid
Domoticz version: latest β
Location: The Netherlands (Alkmaar)
Contact:

Re: Dashticz - Module - Spotify (new version!)

Post by gielie »

I can get spotify to work on my pc (safari) but on my iPad something strange is happening, i loose all my icons and +/- symbols.
- Aeon Labs USB Stick met Z-wave plus
- Aeotec MultiSensor 6
- FIBARO FGS223
- FIBARO FGWPE Wall Plug
- Neo CoolCam Power plug
- Popp Smoke Detector
- Toon
- Kodi Media Server
robgeerts
Posts: 1273
Joined: Saturday 24 January 2015 22:12
Target OS: NAS (Synology & others)
Domoticz version: 3.7067
Location: NL
Contact:

Re: Dashticz - Module - Spotify (new version!)

Post by robgeerts »

Could you clear cache/cookies?
User avatar
gielie
Posts: 290
Joined: Tuesday 12 January 2016 11:40
Target OS: Raspberry Pi / ODroid
Domoticz version: latest β
Location: The Netherlands (Alkmaar)
Contact:

Re: Dashticz - Module - Spotify (new version!)

Post by gielie »

I did clear my cache/cookies. I tried my iPhone and another iPad, it seems iOS specific. Once I // rule out my Spotify code the icons are back to normal.
- Aeon Labs USB Stick met Z-wave plus
- Aeotec MultiSensor 6
- FIBARO FGS223
- FIBARO FGWPE Wall Plug
- Neo CoolCam Power plug
- Popp Smoke Detector
- Toon
- Kodi Media Server
robgeerts
Posts: 1273
Joined: Saturday 24 January 2015 22:12
Target OS: NAS (Synology & others)
Domoticz version: 3.7067
Location: NL
Contact:

Re: Dashticz - Module - Spotify (new version!)

Post by robgeerts »

Ok, problem is, I dont have ios to check this...
Martijn89
Posts: 2
Joined: Wednesday 02 May 2018 21:49
Target OS: -
Domoticz version:
Contact:

Re: Dashticz - Module - Spotify

Post by Martijn89 »

robgeerts wrote: Wednesday 02 May 2018 22:38
Martijn89 wrote: Wednesday 02 May 2018 21:52 Hi Rob,

First of all; great work! Absolutely amazing what you delivered with Dashticz.

I saw your post and tried the update in the beta, but for some reason I have the following issues:
- I don't see any control buttons, just the currently played song and playlist/device. Which I both can select though.
- When I activate the 'spotify' block all other blocks just disappear. When I remove it from the columns[] again the other blocks work as they did before. This goes for all the blocks which come from Domoticz, but the weather, calendar and buienradar still do work. Interesting: the sunrise and sunset and fullscreen button also disappear when I activate spotify. Any idea what can go wrong here?
Sounds like you're not using the latest version...
If you really do, do you get any errors in console?
It works now Rob, I tried a git pull again with no results so downloaded the ZIP and uploaded it. Works like a charm now! What a great update!

Also checked the iOS issue; and indeed on iOS the icons are gone of all the blocks. The rest seems to work well however.

Two tips maybe;
- On a tablet the selector for the playlist and for the devices are really close together and pretty small. If one of them was on top and one at the bottom this would make it easier to use it. Users can change this of course as it is probably something personal.
- Do you think volume control would be an option in the future? I know Spotify Connect allows volume control for devices.

Great work Rob!
User avatar
gielie
Posts: 290
Joined: Tuesday 12 January 2016 11:40
Target OS: Raspberry Pi / ODroid
Domoticz version: latest β
Location: The Netherlands (Alkmaar)
Contact:

Re: Dashticz - Module - Spotify (new version!)

Post by gielie »

An other thing that is not working with Spotify enabled are the coloured icons, I have some code to make some icons in color, example the lightbulbs are yellow, but this doesn’t work either. Maybe this is a clue in the right direction.

Does someone know how I can get an debug log of dashticz on ios?
- Aeon Labs USB Stick met Z-wave plus
- Aeotec MultiSensor 6
- FIBARO FGS223
- FIBARO FGWPE Wall Plug
- Neo CoolCam Power plug
- Popp Smoke Detector
- Toon
- Kodi Media Server
Ectholian
Posts: 16
Joined: Thursday 26 April 2018 15:27
Target OS: Linux
Domoticz version:
Contact:

Re: Dashticz - Module - Spotify (new version!)

Post by Ectholian »

freakshock wrote: Thursday 03 May 2018 14:14 Do you have Chromecast Audio or Google home devices?

I think there's a difference between 'cast targets' like the Chromecast audio, and normal devices like smartphones, PC's and tablets.
My Spotify android app always shows all Chromecast Audio targets, but only devices like my PC when it has recently been playing something.

Anyway, no biggie if it's not doable;)
It is undo-able. It's the way the spotify api works. The API can't talk directly to your device like a phone. So instead, you need to fire up the application (Spotify) and the application keeps a connection to the api and 'listens'. So if you use the spotify plugin, and api request is being made to the spotify api which in turn talks to the spotify application.

When the spotify application is shut down, this communication channel is also down so the api can't talk to the spotify application anymore. It is different for cast-devices like chromecast, because they are always running and therefore always keep the communication line open.
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests