<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Defective Semantics &#187; audioscrobbler</title>
	<atom:link href="http://scarff.id.au/blog/tag/audioscrobbler/feed/" rel="self" type="application/rss+xml" />
	<link>http://scarff.id.au</link>
	<description>Dean Scarff's perpetual struggle with technology, and other anecdotes</description>
	<lastBuildDate>Thu, 03 Nov 2011 22:39:55 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>ruby-mp3info utf-8 support</title>
		<link>http://scarff.id.au/blog/2008/ruby-mp3info-utf-8-support/</link>
		<comments>http://scarff.id.au/blog/2008/ruby-mp3info-utf-8-support/#comments</comments>
		<pubDate>Tue, 05 Feb 2008 17:16:32 +0000</pubDate>
		<dc:creator>Dean</dc:creator>
				<category><![CDATA[Problems]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[audioscrobbler]]></category>
		<category><![CDATA[ruby]]></category>
		<category><![CDATA[ruby-mp3info]]></category>
		<category><![CDATA[unicode]]></category>

		<guid isPermaLink="false">http://scarff.id.au/blog/10/ruby-mp3info-utf-8-support/</guid>
		<description><![CDATA[<p>While apparently there are plans to improve ruby&#8217;s support for unicode, the 1.8 stdlib doesn&#8217;t make working with encodings <em>transparent</em>.  The historically poor support has had its toll on ruby libraries, as I discovered while updating scroball.rb to do the right thing with utf-8.</p>
<p>It led to this patch.  On the whole though, it&#8217;s of limited use.  You don&#8217;t see the Id3v2 class from the Mp3Info class, so you don&#8217;t get an opportunity to set the encoding up.  Even if you did, the implicit assumption that the user deals solely in iso-8559-1 isn&#8217;t comforting.  Fortunately the characterspace isn&#8217;t always truncated into iso-8559-1: strings which fail the iconv transcoding get left alone.</p>
<p>The situation with ruby-mp3info is symptomatic of several legacies: id3v2 and its ad hoc unicode extensions, and second-class support of unicode strings in ruby before 1.9.</p>
]]></description>
			<content:encoded><![CDATA[<p>While apparently there are plans to improve ruby&#8217;s support for unicode, the 1.8 stdlib doesn&#8217;t make working with encodings <em>transparent</em>.  The historically poor support has had its toll on ruby libraries, as I discovered while updating scroball.rb to do the right thing with utf-8.</p>
<p>It led to <a href="http://rubyforge.org/tracker/index.php?func=detail&#038;aid=17798&#038;group_id=62&#038;atid=325">this patch</a>.  On the whole though, it&#8217;s of limited use.  You don&#8217;t see the Id3v2 class from the Mp3Info class, so you don&#8217;t get an opportunity to set the encoding up.  Even if you did, the implicit assumption that the user deals solely in iso-8559-1 isn&#8217;t comforting.  Fortunately the characterspace isn&#8217;t always truncated into iso-8559-1: strings which fail the iconv transcoding get left alone.</p>
<p>The situation with ruby-mp3info is symptomatic of several legacies: id3v2 and its ad hoc unicode extensions, and second-class support of unicode strings in ruby before 1.9.</p>
]]></content:encoded>
			<wfw:commentRss>http://scarff.id.au/blog/2008/ruby-mp3info-utf-8-support/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>scroball.rb: an audioscrobbler client</title>
		<link>http://scarff.id.au/blog/2007/scroball-an-audioscrobbler-client/</link>
		<comments>http://scarff.id.au/blog/2007/scroball-an-audioscrobbler-client/#comments</comments>
		<pubDate>Fri, 21 Dec 2007 14:05:31 +0000</pubDate>
		<dc:creator>Dean</dc:creator>
				<category><![CDATA[Software]]></category>
		<category><![CDATA[audioscrobbler]]></category>
		<category><![CDATA[last.fm]]></category>

		<guid isPermaLink="false">http://scarff.id.au/blog/9/scroball-an-audioscrobbler-client/</guid>
		<description><![CDATA[<p>After discovering the awesomeness that is last.fm I became annoyed at it indexing the misrepresentative contents of my local iTunes library.  This gave the false impression that I spend most of my time listening to Kanye West&#8217;s <em>Gold Digger</em> (catchy though it is).</p>
<p>I play most of my music using iTunes Shared Libraries and an mt-daapd server running on scant.  If there&#8217;s a way to make last.fm scrobble music iTunes accesses from a DAAP server, I couldn&#8217;t find it.  Then there&#8217;s all the music I listen to with players that lack audioscrobbler plugins.  Why wait for last.fm to work out what my tastes are?  I needed a way to let audioscrobbler catch up with me: manual scrobbling.</p>
<p>Fortunately audioscrobbler provides documentation of the Audioscrobbler Realtime Submission Protocol.  From this, I hacked together a ruby script to scrobble my music directories: scroball.rb.  It does do a little bit of subterfuge: it&#8230; <a href="http://scarff.id.au/blog/2007/scroball-an-audioscrobbler-client/" class="read_more">more</a></p>]]></description>
			<content:encoded><![CDATA[<p>After discovering the awesomeness that is <a href="http://last.fm">last.fm</a> I became annoyed at it indexing the misrepresentative contents of my local iTunes library.  This gave the false impression that I spend most of my time listening to Kanye West&#8217;s <em>Gold Digger</em> (catchy though it is).</p>
<p>I play most of my music using iTunes Shared Libraries and an mt-daapd server running on <a href="/hosts#scant">scant</a>.  If there&#8217;s a way to make last.fm scrobble music iTunes accesses from a DAAP server, I couldn&#8217;t find it.  Then there&#8217;s all the music I listen to with players that lack audioscrobbler plugins.  Why wait for last.fm to work out what my tastes are?  I needed a way to let audioscrobbler catch up with me: manual scrobbling.</p>
<p>Fortunately audioscrobbler provides documentation of the <a href="http://www.audioscrobbler.net/development/protocol/">Audioscrobbler Realtime Submission Protocol</a>.  From this, I hacked together a ruby script to scrobble my music directories: <a href="http://scarff.id.au/file/scroball.rb">scroball.rb</a>.  It does do a little bit of subterfuge: it backdates and calculates the start times to avoid collisions that audioscrobbler would pick up in sanity checking.  This can legitimately be used to retroactively scrobble a listening session.</p>
<pre class="codeblock sh">
ruby ~/scroball.rb p00ya `/bin/date -d 'last wednesday' +%s` .
</pre>
<p>yay!  Hopefully the last.fm folks like it; it&#8217;s not intended for abuse.</p>
]]></content:encoded>
			<wfw:commentRss>http://scarff.id.au/blog/2007/scroball-an-audioscrobbler-client/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

