Notez l’underscore dans le premier nom de fichier, que l’on ne retrouve pas dans le second.
Editez maintenant le fichier lastfm.php et modifiez les informations avec l’identifiant et le mot de passe de votre compte last.fm.
Vérifiez le chemin du fichier lastfm.html. C’est la partie la plus importante à configurer !
Notez l’underscore dans le premier nom de fichier, que l’on ne retrouve pas dans le second.
Etape 3 : lancement du plugin
Notez que “matt” est mon nom d’utilisateur donc vous aurez à changer cela pour mettre votre nom d’utilisateur. Pour lancer le plugin, lancez ceci dans un terminal :
php /home/matt/.wine/drive_c/webroot/lastfm.php
Ce qui nous donne :
09-05-20 18:27:15 | Logging in...
09-05-20 18:27:15 | The client is up to date.
09-05-20 18:30:27 | Submitting Is It Ever Easy/Charlemagne/Charlemagne/4:23 for stats
09-05-20 18:30:28 | submitsong returned OK (int=1)
09-05-20 18:53:37 | Submitting Open Car/Porcupine Tree/Deadwing/3:46 for stats
09-05-20 18:53:37 | submitsong returned OK (int=1)
09-05-20 18:56:37 | Submitting /Boris Skalsky/First Songs/2:28 for stats
09-05-20 18:56:38 | submitsong returned OK (int=1)
Voilà, le plugin envoie les informations sur votre compte Last.fm à chaque changement de chanson (à peu près au milieu de la chanson).
Note: il vous faut garder la fenêtre du terminale ouverte pour ne pas interrompre le transfert des données.
Fonctionnement du plugin
Voici le principe du plugin : dans la configuration de SAM, nous définissons un fichier maquette (_lastfm.html) dont SAM se servira pour créer un fichier à chaque changement de chanson (lastfm.html).
Le plugin PHP (lastfm.php), lancé via l’interpréteur PHP, va alors rechercher ce fichier et contacter les serveurs last.fm afin de procéder à une mise à jour du profil membre.
Bonne diffusion !
Vous souhaitez réaliser un nouveau projet WordPress ou WooCommerce, ajouter de nouvelles fonctionnalités, ou améliorer les performances de votre site?
2 thoughts on “Plugin Last.fm pour SAM Broadcaster sous Ubuntu”
Excusez moi, mon francais es pas beau – Is it possible to put more songs into the lastfm.html file? I work as a dj and would like to write down all songs I play a night. I managed that with the normal HTML output by altering the the line to so it keeps the last 500 songs – your html file does not have a loop option.
What do you mean by “Pour lancer le plugin, lancez ceci dans un terminal :” a terminal prog. like old hyper terminal?
We use cookies on our website. Some of them are essential, while others help us to improve this website and your experience.If you are under 16 and wish to give consent to optional services, you must ask your legal guardians for permission.We use cookies and other technologies on our website. Some of them are essential, while others help us to improve this website and your experience.Personal data may be processed (e.g. IP addresses), for example for personalized ads and content or ad and content measurement.You can find more information about the use of your data in our privacy policy.You can revoke or adjust your selection at any time under Settings.
If you are under 16 and wish to give consent to optional services, you must ask your legal guardians for permission.We use cookies and other technologies on our website. Some of them are essential, while others help us to improve this website and your experience.Personal data may be processed (e.g. IP addresses), for example for personalized ads and content or ad and content measurement.You can find more information about the use of your data in our privacy policy.You can revoke or adjust your selection at any time under Settings.Here you will find an overview of all cookies used. You can give your consent to whole categories or display further information and select certain cookies.
Excusez moi, mon francais es pas beau – Is it possible to put more songs into the lastfm.html file? I work as a dj and would like to write down all songs I play a night. I managed that with the normal HTML output by altering the the line to so it keeps the last 500 songs – your html file does not have a loop option.
What do you mean by “Pour lancer le plugin, lancez ceci dans un terminal :” a terminal prog. like old hyper terminal?
Please help!
Merci
Hi again,
There’s no loop as this is for live scrobbling. As for terminal, this article is linux-oriented, Windows users should stick to this guide : https://www.skyminds.net/plugin-lastfm-pour-sam-broadcaster/