Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: HOW TO: synchronise your last.fm playback stats with foobar (Read 388111 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

HOW TO: synchronise your last.fm playback stats with foobar

Reply #425
ah it might be the script then. at first i thought you copy/pasted that error from the foobar console which made me think it was a component problem.

are you saying it's the command prompt window with blue background that comes up with that error?

loving a track works because the script works like a macro. it simply triggers the playlist context menu action to set the database value. however, updating the playcount means using the windows command line which could be the cause of failure due to these cyrillic symbols.

i'll have a think on how to get around that.

edit: i can't test this as i'm using a restricted machine with no access to the user profile folder but try this....

close foobar

1) move the file "lastfm_sql.cmd" from the main foobar directory in to your foobar profile folder (%appdata%\foobar2000)
2) move the file "test.sql" from your "profile folder\wsh_lastfm" into the of the profile folder (this should save you from downloading the data all over again)
3) now in %appdata%\foobar2000 there should be 3 files...

customdb_sqlite.db
lastfm_sql.cmd
test.sql

4) start foobar, right click the panel and choose "configure". now replace lines 20 and 21 with this....

Code: [Select]
var sql_file = fb.ProfilePath + "test.sql";
var batch_file = fb.ProfilePath + "lastfm_sql.cmd customdb_sqlite.db test.sql";

5) now right click the panel and select "import sql file", closing foobar as instructed.

HOW TO: synchronise your last.fm playback stats with foobar

Reply #426
Can I import all my previous plays from foobar to Last.fm profile?
(all PLAY_COUNTER infos from each file)
I've searched on Google but it seems to be possible only with iTunes, Windows Media Player or Winamp.

I post it because i thought "synchronise" means last.fm <-> foobar, and if i understand it's only last.fm -> foobar

HOW TO: synchronise your last.fm playback stats with foobar

Reply #427
I'd guess that if it is ever going to be possible, will be up to foo_audioscrobble to do that. I'm no expert, but batch scrobbles may be a little sketchy, specially with past plays due to Last.fm's anti-spam (a.k.a anti-"cheat") system. iTunes, WMP and Winamp can probably do that since they use the official plugins and have "closed" databases, while foobar2000 uses a third-party plugin to scrobble AND despite having the default playback statistics database, it is not actually mandatory, you can choose not to use it or even worse (for LFM to control), you have N options of third-party databases to choose from.

BTW, syncs are not necessarily two-way. Actually more than often they are only one-way like this script (or google calendar and outlook without the google separate program, for that matter)

HOW TO: synchronise your last.fm playback stats with foobar

Reply #428
Thanks
I hope someone is working on it (a way to import all previous plays from foobar to Last.fm). It could be useful for many people, at least for those who use this player... maybe not numerous enough to interest last.fm.

HOW TO: synchronise your last.fm playback stats with foobar

Reply #429
Hello,

Yes, It'd be great to have this working on Foobar 1.1

I just switched from 9.x, and now with all plugings disabled and deprecated components uninstalled... I feel a bit sad with the fact my playcounts are gone, although they remain on Last.fm (good lord, thankfully I started using it a long time ago  )

HOW TO: synchronise your last.fm playback stats with foobar

Reply #430
new version uploaded.

http://cid-649d3bfeaf541fbb.office.live.co...ount%20sync.zip

contains new foo_softplaylists component which allows you to unlove tracks.

@audionoob, i'm not really sure what your point is. this script does import playcounts from last.fm into foobar. it works fine in 1.1 (i always use the latest foobar version/components available).

it's the thing CaptainTrips is asking for that it can't do. only the last.fm client app with WMP/itunes/winamp can import playback stats into a new last.fm account.

HOW TO: synchronise your last.fm playback stats with foobar

Reply #431
marc2003: Is it possible to save the stats inside the MP3 itself, in the new version? I know in the old version it was possible.

Thanks for your great work

HOW TO: synchronise your last.fm playback stats with foobar

Reply #432
just continue using the old version. all recent updates are related to foo_customdb / importing the whole last.fm library which it isn't possible to do when file tagging.

i suppose one option is to use the new version to import all playcounts into foo_customdb. then you could use the properties dialog and use "format from other fields" to transfer data from %LASTFM_PLAYCOUNT_DB% into your own file tag. then you can go back to the old version for the continuous background updates.

HOW TO: synchronise your last.fm playback stats with foobar

Reply #433
Holy Guacamole!!!!!!!!!!!!!!!!!!!!!!!!

Man this is so great hahahhaa... love you marc2003. Will have to sit down and install the plugin and else this weekend but you just gave me some amazing news this cold night!!!

HOW TO: synchronise your last.fm playback stats with foobar

Reply #434
Thanx marc2003 for the Last.fm Love Button script!
I use it wit my config called Silent Night here... http://arnie77.deviantart.com/art/Silent-N...V-5-1-154667359
When I first aply the script the only thing i see is an white WHS pannel.
I want to have an transparent pannel with an transparent *.png from startup...
...is it possible to change that? I am no Jscript coding expert.

HOW TO: synchronise your last.fm playback stats with foobar

Reply #435
the original script already uses transparent png files just fine. i'm guessing the theme author has replaced my images/file locations with his own so you'll have to ask him. i'm not providing support for that. i'm not installing all that guff just to check it out.





HOW TO: synchronise your last.fm playback stats with foobar

Reply #436
the original script already uses transparent png files just fine. i'm guessing the theme author has replaced my images/file locations with his own so you'll have to ask him. i'm not providing support for that. i'm not installing all that guff just to check it out.


I got it!
It was my fault. 
When noting is in the libary or in the playlist no image will be displayed.
could be this...
function on_metadb_changed() {
   if(!g_metadb) return;...

Thanx !

HOW TO: synchronise your last.fm playback stats with foobar

Reply #437
Thanks for this! This is awesome. One problem though. I don't have that heart in my character map or whatever, so instead of showing a heart, it shows a little box. It even does this when I copy the heart from the readme.pdf into the script. I'm on XP Service Pack 3 if it matters.

Thanks in advance!

HOW TO: synchronise your last.fm playback stats with foobar

Reply #438
You ought to use a font that has that character mapped, otherwise it will show the box you're getting.
Tip: Open up windows character map (%windir%\system32\charmap.exe), select a font in the dropdown list and search for "heart" in the proper box, if it's there you can use that font on your playlist and the loved status will display just fine. You could also change the heart to something else your current font supports, like S2, <3 or any other regular symbol/character, but that could be kind of lame 

HOW TO: synchronise your last.fm playback stats with foobar

Reply #439
install "east asian" character support through "regional settings" in the control panel then you should get that character with all fonts.

(you'll need your XP installation cd to do this)

HOW TO: synchronise your last.fm playback stats with foobar

Reply #440
Alright, thanks fore the help guys! 

HOW TO: synchronise your last.fm playback stats with foobar

Reply #441
i suppose one option is to use the new version to import all playcounts into foo_customdb. then you could use the properties dialog and use "format from other fields" to transfer data from %LASTFM_PLAYCOUNT_DB% into your own file tag. then you can go back to the old version for the continuous background updates.

Thank you very much for this hint.

HOW TO: synchronise your last.fm playback stats with foobar

Reply #442
thank you for this.  i managed install and retrieve my info but i have two issues.

1. not all loved tracks are shown.  this might be because i've moved a bunch of tracks around so no big deal, i don't have many loved tracks anyway.

2. when i click the heart to love a track, the component (but not foobar) crashes "aw, crashed ):"

using foobar 1.1, win7 32bit, and music files are on a network drive.  i put the component in a default skin tab - it shows the heart.

thanks for help.

HOW TO: synchronise your last.fm playback stats with foobar

Reply #443
Error: WSH Panel Mod (Playcount Sync by marc2003): Microsoft JScript runtime error:
Invalid procedure call or argument
Ln: 93, Col: 2
<source text only available in compile time>


EDIT--added a toolbar button as described in this thread--works great, so disregard #2.

HOW TO: synchronise your last.fm playback stats with foobar

Reply #444
sorry for writing this garbage. i think the missing loved tracks are those that i loved while listening online, so i don't have those tracks. 

thanks again

HOW TO: synchronise your last.fm playback stats with foobar

Reply #445
Hi marc2003,

would it be possible, to get the "lastfm_firstplayed" by the lastfm database, too?

 

HOW TO: synchronise your last.fm playback stats with foobar

Reply #447
Hum, possible, but ugly like hell, track.getinfo should have returned that info instead.

HOW TO: synchronise your last.fm playback stats with foobar

Reply #448
would it be possible, to get the "lastfm_firstplayed" by the lastfm database, too?


it's possible in theory, but not implemented yet (afaik)
http://www.hydrogenaudio.org/forums/index....st&p=719890

I see - it's a pity, thx for the link.

HOW TO: synchronise your last.fm playback stats with foobar

Reply #449
sorry for writing this garbage. i think the missing loved tracks are those that i loved while listening online, so i don't have those tracks. 

thanks again


so long as the tracks that you loved online exist on your pc somewhere with the exact same artist/track tags then they will show in your foobar library/playlists.