Kodi Community Forum
[WIP] XBMC + Spotify = True (an XBMC implementation that uses Spotify's official API) - Printable Version

+- Kodi Community Forum (http://forum.kodi.tv)
+-- Forum: Announcements, Info, and General Discussion (/forumdisplay.php?fid=85)
+--- Forum: Kodi General Discussion (/forumdisplay.php?fid=6)
+--- Thread: [WIP] XBMC + Spotify = True (an XBMC implementation that uses Spotify's official API) (/showthread.php?tid=67012)



[WIP] XBMC + Spotify = True (an XBMC implementation that uses Spotify's official API) - raki - 2013-08-22 10:04

Wrong thread ;-). But try updating the repo, they shall be there after that


RE: [WIP] XBMC + Spotify = True (an XBMC implementation that uses Spotify's official API) - Jz123 - 2013-08-22 19:34

Ok here is v12.2! It seems skipping song and such is working. I guess on the latest git the merge wasn't 100% good which i needed to take a few files and lines from v12.1.

If you encounter errors please let me know mayby i can go see what i can do. I'm running this now on my laptop to.
(Again i'm not a coder, and yes my english could be a little better Tongue )

Download Link:
http://uploaded.net/file/8a99abrg

Notes: 2 extra EULA's agreements added to the installer for 2 tools i added to do the API change/injection as user friendly as possible in some sort kind of patch way. (So don't be scared if u see it!) (hexpatcher to edit XBMC.exe and Swiss File Knife to convert the binary to hex)

Instructions
1. Install spotyXBMCSetup-v12.2-custom-pvr.exe and don't start XBMC yet.
2. Download your BINARY API Key from here:
https://developer.spotify.com/technologies/libspotify/keys/
https://developer.spotify.com/technologies/libspotify/
3. Name it "spotify_appkey.key" and place it in your root dir of XBMC. (Proberly C:\Program Files\XBMC\ or C:\Program Files (x86)\XBMC\)
4. Now execute runpatch.bat IN ADMINISTRATOR MODE!!! (Otherways i'm not allowed to edit XBMC.exe)
5. When everything is ok. Start using XBMC and configure the spotify addon.
6. Dont forget to restart xbmc after its configured.

And again if i'm not allowed to post this or forgot something or what ever, i'm sorry just send me a message and i'll remove it or take actions.
Also i'm not responsible for anything.

If you are updating from v12.0 you must re-run the patcher to again ofcourse Tongue And like last release no pvr addons with it since you can download it anyway from the repo.

Credits to all coders and fixers and people!


RE: [WIP] XBMC + Spotify = True (an XBMC implementation that uses Spotify's official API) - Peleke - 2013-08-22 23:40

Is there something similar for Raspbmc instead of Windows?


RE: [WIP] XBMC + Spotify = True (an XBMC implementation that uses Spotify's official API) - Jonass - 2013-08-23 14:11

Normaly im just a forum reader, but at this point i had to register at XBMC forum. I just had to say thanks for this lovley piece of Spotify integration! What an amazing feature for Xbmc to have Spotify fully working without the need to go into a seperate addon. And another thank to Jz123 that made it even easier to install. This 12.2 patch work like a charm!

The only little thing that are missing now, is the remote controller functionality (yatsee, pump or xbmc official). Is the search function. I suspect thats not on Spotyxbmc's side but on the remote developers side. But now with Jz123's patch i suspect spotyxbmc will explode in popularity! And all the smart people will continue to bring more amazing stuff to the community. Such as the search function in the Andriod/iOS remotes.

Once again.. Thanks for this amazing feature! Much love from northern Sweden! =)


[WIP] XBMC + Spotify = True (an XBMC implementation that uses Spotify's official API) - raki - 2013-08-23 23:29

(2013-08-18 11:29)raki Wrote:  Hey guys, thanks for this addon!

Before I'm messing with my system I have a few question since I don't think I've understood every single step.

I've already cloned the git repository and installed libspotify. Next step it says I have to put the appkey.h file into the xbmc source folder. This is the folder under spotyxbmc2, right? But when I compile xbmc with

Code:
Configure, make and install xbmc $ ./bootstrap $ ./configure $ make $ sudo make install

will a complete new xbmc build? Or will there only be extra files compiled? eg. if I'm running an own xbmc build, what happens?

Thanks!

May anyone answer to this?


PVR + Jz123 Spotify - MatLCFC - 2013-08-24 16:31

(2013-08-22 19:34)Jz123 Wrote:  If you are updating from v12.0 you must re-run the patcher to again ofcourse Tongue And like last release no pvr addons with it since you can download it anyway from the repo.

Great work Jz123, 12.2 working as described..
Sorry to be thick (again!) How do I add the PVR? I use VU+/Enigma 2 client - I can't install "dependencies not met"... Do I have to install something else firstConfused


RE: [WIP] XBMC + Spotify = True - zepol - 2013-08-25 01:03

Hi guys..
I've been trying to install spotixbmc for last few weeks and no luck by now Sad
First - ubuntu 12.04.. there was too old verision of taglib and 'configure' imposible
Now - ubuntu 12.10 and compilation seems to go fine - configure, make, make install - everything is finished.
When I try to run xbmc, it goes fine for a fist time, but when I try to launch it once again there is only crash message: "Segmentation fault (core dumped)" and a crash report in a log file:
Code:
############## XBMC CRASH LOG ###############

################ SYSTEM INFO ################
Date: nie, 25 sie 2013, 00:35:10 CEST
XBMC Options:
Arch: x86_64
Kernel: Linux 3.5.0-39-generic #60-Ubuntu SMP Tue Aug 13 18:33:05 UTC 2013
Release:
    Distributor ID:    Ubuntu
    Description:    Ubuntu 12.10
    Release:    12.10
    Codename:    quantal
############## END SYSTEM INFO ##############

############### STACK TRACE #################
=====>  Core file: /home/lopez/core (2013-08-25 00:35:10.761186225 +0200)
        =========================================
[New LWP 2148]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Core was generated by `/usr/local/lib/xbmc/xbmc.bin'.
Program terminated with signal 11, Segmentation fault.
#0  0x00007fb7acdf23b1 in vfprintf () from /lib/x86_64-linux-gnu/libc.so.6

Thread 1 (Thread 0x7fb7a507f780 (LWP 2148)):
#0  0x00007fb7acdf23b1 in vfprintf () from /lib/x86_64-linux-gnu/libc.so.6
#1  0x00007fb7aceafc14 in __vsprintf_chk () from /lib/x86_64-linux-gnu/libc.so.6
#2  0x00007fb7aceafb5d in __sprintf_chk () from /lib/x86_64-linux-gnu/libc.so.6
#3  0x00007fb7ae704380 in ?? () from /usr/lib/x86_64-linux-gnu/libasound.so.2
#4  0x00007fb7ae70545d in snd_device_name_hint () from /usr/lib/x86_64-linux-gnu/libasound.so.2
#5  0x0000000000aec004 in CAESinkALSA::EnumerateDevicesEx (list=..., force=<optimized out>) at Sinks/AESinkALSA.cpp:708
#6  0x0000000000ad8c39 in CAESinkFactory::EnumerateEx (list=..., force=<optimized out>) at AESinkFactory.cpp:150
#7  0x0000000000adeff5 in CSoftAE::CSoftAE (this=0x1bb5580) at Engines/SoftAE/SoftAE.cpp:79
#8  0x0000000000ad787a in CAEFactory::LoadEngine (engine=engine@entry=AE_ENGINE_SOFT) at AEFactory.cpp:96
#9  0x0000000000ad79ff in CAEFactory::LoadEngine () at AEFactory.cpp:78
#10 0x0000000000ea1da0 in CApplication::Create (this=0x1b60ea0) at Application.cpp:694
#11 0x0000000000f364d4 in XBMC_Run (renderGUI=<optimized out>) at xbmc.cpp:44
#12 0x00000000006f0666 in main (argc=1, argv=0x7fffb0a0da48) at main.cpp:84
############# END STACK TRACE ###############

################# LOG FILE ##################

00:35:10 T:140426724505472  NOTICE: -----------------------------------------------------------------------
00:35:10 T:140426724505472  NOTICE: Starting XBMC (12.1 Git:20130323-83ff49d), Platform: Linux (Ubuntu 12.10, 3.5.0-39-generic x86_64). Built on Aug 24 2013
00:35:10 T:140426724505472  NOTICE: special://xbmc/ is mapped to: /usr/local/share/xbmc
00:35:10 T:140426724505472  NOTICE: special://xbmcbin/ is mapped to: /usr/local/lib/xbmc
00:35:10 T:140426724505472  NOTICE: special://masterprofile/ is mapped to: /home/lopez/.xbmc/userdata
00:35:10 T:140426724505472  NOTICE: special://home/ is mapped to: /home/lopez/.xbmc
00:35:10 T:140426724505472  NOTICE: special://temp/ is mapped to: /home/lopez/.xbmc/temp
00:35:10 T:140426724505472  NOTICE: The executable running is: /usr/local/lib/xbmc/xbmc.bin
00:35:10 T:140426724505472  NOTICE: Local hostname: lopez-desktop
00:35:10 T:140426724505472  NOTICE: Log File is located: /home/lopez/.xbmc/temp/xbmc.log
00:35:10 T:140426724505472  NOTICE: -----------------------------------------------------------------------
00:35:10 T:140426724505472    INFO: Selected UPower as PowerSyscall


############### END LOG FILE ################

############ END XBMC CRASH LOG #############
I was trying to compile with master branch and with Frodo_12.1 branch.
With the secong one I was able to run xbmc for a while with spotify working, but it crashed after few songs and hard reboot was needed.
After that the "Segmentation fault (core dumped)" problem appears again.

When I delete .xbmc home folder, I'm able to run xbmc again. Unfortunatelly spotify addon need to be run at the beginning and there is no way to launch xbmc after that Sad

Can anybody tell me, what the hell I'm doing wrong ?
Pure ubuntu 12.10 installation, all dependencies needed installed, compilation exactly as it is described in readme, and it does not work Sad
help


RE: [WIP] XBMC + Spotify = True (an XBMC implementation that uses Spotify's official API) - Jz123 - 2013-08-25 17:06

Thanks for the kind words Jonass
(2013-08-24 16:31)MatLCFC Wrote:  
(2013-08-22 19:34)Jz123 Wrote:  If you are updating from v12.0 you must re-run the patcher to again ofcourse Tongue And like last release no pvr addons with it since you can download it anyway from the repo.

Great work Jz123, 12.2 working as described..
Sorry to be thick (again!) How do I add the PVR? I use VU+/Enigma 2 client - I can't install "dependencies not met"... Do I have to install something else firstConfused


Cheers i've updated the link again, now compiled with the pvr addons. Should work now if u install it (don't forget to repatch the exe, since the installer will overwrite it again).
http://uploaded.net/file/8a99abrg

Also forked a git (still figuring it out but i think i did it right Tongue ):
https://github.com/jz1/spotyxbmc2
and
https://github.com/jz1/spotyxbmc2/tree/CustomInstaller


[WIP] XBMC + Spotify = True (an XBMC implementation that uses Spotify's official API) - raki - 2013-08-25 22:21

(2012-09-23 22:33)fldc Wrote:  
(2012-09-08 22:02)Balthazar Wrote:  I would be more interested in finding out if there has been any work to move this to a binary add-on? I've had to abandon it since xvba support was more important in my case than Spotify integration. I couldn't figure out how to merge the two projects, so I've been stuck missing all of the Spotify features I love. I do hope it happens someday.

https://github.com/fldc/spotyxbmc2/commits/master

I did this quick merge, it contains spotyxbmc2/master, fernetmenta/master and xbmc/master, fernetmenta contains xvba and vdpau rewrite. Big Grin

This tree uses libspotify12, so no radio, those commits can easily be reverted though, but this fixes random crashes xbmc suffers from while playing video here. Big Grin

Could somebody update this merge with the latest masters? Would really appreciate it :-)


RE: [WIP] XBMC + Spotify = True (an XBMC implementation that uses Spotify's official API) - Skank - 2013-08-29 13:52

New here (not to xbmc though)

I 've got some questions..
I'm considering an account from spotify or deezer
Perhaps spotify


Now i have all my mp3s on a local server.

Is it possible with spotify and this addon to:
- replace all my local music..
- Meaning that, when i look into my music library.. i see all the same albums but from spotify (including artwork)
But it should contain only albums that i like, not all albums currently playing from spotify... or top 100 from spotify
if you know what i mean..

say for example
i want albums from dire straits, the cure, texas and so on... in my album view, and not all the ones spotify brings up
- have a seach box to look for new content, then add it to my albums..


That would rock so much, ideal combination, and i dont need anymore storage then. and more content Smile


RE: [WIP] XBMC + Spotify = True (an XBMC implementation that uses Spotify's official API) - Skank - 2013-08-29 16:37

Also, doesnt this work for unlimited accounts?
I dont see why it shouldnt?

And does , when selecting for example album in library, contain appropriate artist background?

And any plans to make this as a plugin instead of a rebuild xbmc exe?


XBMC + Spotify = True (an XBMC implementation that uses Spotify's official API) - StefanK - 2013-08-30 23:07

Hey Skank - you are asking some good questions, let me try to be the first to answer Smile

(2013-08-29 13:52)Skank Wrote:  Is it possible with spotify and this addon to:
- replace all my local music..
Yes, to the extent that the artists are available on spotify. Most are, but some (mostly alternative?) artists are not. In which case you just keep your local files.

(2013-08-29 13:52)Skank Wrote:  - Meaning that, when i look into my music library.. i see all the same albums but from spotify (including artwork)
But it should contain only albums that i like, not all albums currently playing from spotify... or top 100 from spotify
if you know what i mean..

say for example
i want albums from dire straits, the cure, texas and so on... in my album view, and not all the ones spotify brings up
- have a seach box to look for new content, then add it to my albums..
When using spotify (you can practice with the free version) it is possible to star both artists, albums and songs. The way I have setup my spotify-xbmc-library is by starring the albums I want in my library. And then setting XBMC music library to be showing albums. XBMC library shows only the albums that have been star marked (+ your local albums).

And you can search for and add new content - either directly in xbmc or "outside" in spotify (or on your smartphone etc.)

(2013-08-29 16:37)Skank Wrote:  And does , when selecting for example album in library, contain appropriate artist background?
As for artwork - you might find some limitations. I have the album cover art showing up when browsing through the library, but no artist fanart (full screen background). The same applies when clicking an album to choose song. I will see the album cover, but the background will be either green spotify or your regular music fallback background. Does any one have a better solution to fanart?

During playback I have the fanart slideshow addon (available with the Transparency! skin - don't remember if it is standard) working just fine.

(2013-08-29 16:37)Skank Wrote:  Also, doesnt this work for unlimited accounts?
I dont see why it shouldnt?
You will need a premium account, but you can use the same premium account on an unlimited number of appliances (as long as you don't use them simultaneously).

(2013-08-29 16:37)Skank Wrote:  And any plans to make this as a plugin instead of a rebuild xbmc exe?
I am not a programmer so I really don't understand if an addon is possible or the rebuild is necessary. But the way it works now with spotify integrated in the ordinary library and xbmc setup is IMHO a lot better than the spotimc addon, where spotify is contained to an addon. And with the installer made by your fellow Dutchman Jz123 the rebuild is now a relatively easy (not to mention quick) step to take.


RE: [WIP] XBMC + Spotify = True (an XBMC implementation that uses Spotify's official API) - ToneStrife - 2013-08-31 00:41

Hi!

First of all i want to say i'm a noob. I've read almost all the topic and I can't make it works.

I have frodo 12.2 and i tried with the compiled installer. But when I tried to run xbmc.exe i had an error and it crashed.

What can i do?


RE: [WIP] XBMC + Spotify = True (an XBMC implementation that uses Spotify's official API) - Skank - 2013-08-31 09:55

@StefanK thx for your answers...
Although some i don't like, but you can't help that lol.

About artwork.. how come background is always the green spotify bacckground... this is limited by the addon right? cause spotify has nothing to do with xbmc

You know why unlimited doenst work and premium does? Cause its the same program right?

Yeah im doubting between spotimc addon and this one.. but i definately want it in my library.


Is this compiled version working with all other xbmc addons?


RE: [WIP] XBMC + Spotify = True (an XBMC implementation that uses Spotify's officia - Zebbe152 - 2013-08-31 14:52

(2013-08-30 23:07)StefanK Wrote:  
(2013-08-29 16:37)Skank Wrote:  And does , when selecting for example album in library, contain appropriate artist background?
As for artwork - you might find some limitations. I have the album cover art showing up when browsing through the library, but no artist fanart (full screen background). The same applies when clicking an album to choose song. I will see the album cover, but the background will be either green spotify or your regular music fallback background. Does any one have a better solution to fanart?

During playback I have the fanart slideshow addon (available with the Transparency! skin - don't remember if it is standard) working just fine.

To get the fullscreen fanart you need to enable "Download fanarts from HTBackdrops" and then restart XBMC.
[Image: q0s.png]


The first time you start XBMC after enabling this setting the addon will need to go through all of your playlists, this might take a while... No playlists will show up during this process.

HOWEVER, HTBackdrops recently changed the url from .com to .org. So you need to make a small change in \xbmc\music\spotyXBMC\thumb\ThumbStore.cpp before compiling.

Change
Code:
"http://htbackdrops.com/api/afb0f6cdbd412a7888005de34f86e4a5/searchXML?keywords=%s&default_operator=and&aid=1&fields=title,keywords,caption,mb_name,mb_alias&inc=keywords,caption,mb_name,mb_aliases&limit=1",

and

Code:
"http://htbackdrops.com/api/afb0f6cdbd412a7888005de34f86e4a5/download/%s/fullsize/%s"

to


Code:
"http://htbackdrops.org/api/afb0f6cdbd412a7888005de34f86e4a5/searchXML?keywords=%s&default_operator=and&aid=1&fields=title,keywords,caption,mb_name,mb_alias&inc=keywords,caption,mb_name,mb_aliases&limit=1",

and

Code:
"http://htbackdrops.org/api/afb0f6cdbd412a7888005de34f86e4a5/download/%s/fullsize/%s"

Then it should work Smile
[Image: 1qt5.png]