Scrobbling the Radio Stream — remapping example

    • xzk ha detto...
    • Utente
    • Gen 31 2011, 11:37

    Scrobbling the Radio Stream — remapping example

    Great feature of foo_audioscrobbler is ability to scrobble radio streams. But many radios are putting some characters in tracks info, and they can't be scrobbled correctly.

    But foo_audioscrobbler has another great feature: remapping!

    In this thread I want to give you example of remapping string that I'm using to scrobble the Engine Radio stream (

    They puts "|O| -" characters in the track titles. Scrobbled track looks like this: Blues Brothers – |O| - GIMME SOME LOVIN`
    We should exclude those extra characters, so remapping should be: [$replace(%title%,'|O| - ',)]

    Scrobbled track will be: Blues Brothers – GIMME SOME LOVIN`
    (You can also use [$swapprefix(%title%,'|O| - ')] which is more correct, but less intuitive.)

    Also many tracks came in upper-case, so I've just added $caps before $replace: [$caps($replace(%title%,'|O| - ',))]

    Same with Artist: [$caps(%artist%)]

    Finally, scrobbled track info looks much better: Blues Brothers – Gimme Some Lovin' has Auto-correct option, so finally track will be displayed as: The Blues Brothers – Gimme Some Lovin'

    • picia98 ha detto...
    • Utente
    • Lug 30 2011, 17:01


    where i can find all of this "words" (i dont know how to name it, things like $caps or $replace) that i use in audioscrobbler field remapping ??

    • picia98 ha detto...
    • Utente
    • Lug 30 2011, 17:04
    • picia98 ha detto...
    • Utente
    • Apr 3 2012, 7:00

    [$replace(%title%, radionamepart,, ortherradionamepart,, radionamepart3,)]

  • I'm beating myself up over this, if anyone can help I'd be pretty grateful.
    The radio I'm streaming from appends the Album name at the end of the title surrounded by parenthesis.

    Kalafina – in your eyes (After Eden)

    This would be pretty easy to handle.
    To set the Album tag I would do this:

    Already tested it out it works.

    For title almost the same thing pretty simple.

    But it's not that simple. It screws up in the following example
    Cécile Corbel – Our House Below (Instrumental Version) (Karigurashi no Arrietty)

    So it would be saved as
    Title: Our House Below
    Album: Instrumental Version) (Karigurashi no Arrietty OST

    When what I want is
    Title: Our House Below (Instrumental Version)
    Album: Karigurashi no Arrietty OST

    Honestly I can live without the album. But messing up the titles would drive me crazy.

    I could figure it out if I could figure out how to count the occurrences of a character.

    Does anyone know of any solutions to the problem as a whole OR how to possibly count characters? I was thinking there might be a way to use repeat and substring to count up to a certain number of characters. For instance I can assume there will not be more than 3 left parenthesis.

  • I actually think I have a janky solution but it requires four assumptions and I don't know if these assumptions hold true.

    1. No album name contains any parenthesis. Left, right, or both.
    2. Every Left Parenthesis has a matched Right Parenthesis. Thus there is an equal number of left parenthesis and right parenthesis and a left parenthesis appears before a right parenthesis.
    3. No song title has more than one pair of parenthesis. For instance "Call Me (Club Mix)" is fine but "Call Me (Instrumental Version) (Club Mix)" is invalid
    4. Parenthesis pairs must be at the end of the song title. This would be invalid "Sing (of) Rain"

    So at the very least this will work for 99% of the songs and I have yet to find a case to prove these assumptions wrong but that doesn't mean they aren't there.

    I've also used a small check at the beginning to check if the filepath is the address of the radio I use. If not it just uses the standard %title% or %album% as normal.

    To get the lines to work just put everything on the same line and replace the radio url.

    For Title I am now using:

    For Album:

    For the AnimeNfo Radio replace the URL with

  • Whoa I am way over complicating this. So every song was getting the album appended onto the end of the %title% tag.

    So I should be able to just grab the last parenthesis pair and set that as the album. And i should be able to grab everything to the left of the last left parenthesis and make that the title.

    This only makes one assumption unlike the earlier 4 assumptions. Which is No album name in the radio library contains any parenthesis. Which seems to be holding true.

    I've updated the tags here:


Gli utenti anonimi non possono inviare messaggi. Per inserire messaggi nei forum, accedi o crea il tuo account.