<?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>Libre Things &#187; MPD</title>
	<atom:link href="http://positon.org/tag/mpd/feed" rel="self" type="application/rss+xml" />
	<link>http://positon.org</link>
	<description></description>
	<lastBuildDate>Tue, 23 Feb 2016 20:01:11 +0000</lastBuildDate>
	<language>en-US</language>
		<sy:updatePeriod>hourly</sy:updatePeriod>
		<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.7.1</generator>
	<item>
		<title>MPD clients for AdaFruit Character LCD Keypad on Raspberry Pi</title>
		<link>http://positon.org/mpd-clients-for-adafruit-character-lcd-keypad-on-raspberry-pi</link>
		<comments>http://positon.org/mpd-clients-for-adafruit-character-lcd-keypad-on-raspberry-pi#comments</comments>
		<pubDate>Wed, 09 Jul 2014 21:10:51 +0000</pubDate>
		<dc:creator><![CDATA[dooblem]]></dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[GitHub]]></category>
		<category><![CDATA[MPD]]></category>
		<category><![CDATA[Raspberry Pi]]></category>

		<guid isPermaLink="false">http://positon.org/?p=195</guid>
		<description><![CDATA[I just pushed some small python Music Player Daemon clients on github. It may be of use for MPD fans using the device! https://github.com/dooblem/adampd]]></description>
				<content:encoded><![CDATA[<p>I just pushed some small python Music Player Daemon clients on github.</p>
<p>It may be of use for MPD fans using the device!</p>
<p><a href="https://github.com/dooblem/adampd" title="https://github.com/dooblem/adampd">https://github.com/dooblem/adampd</a></p>
<p><a href="http://positon.org/wp-content/uploads/2014/07/adampd_pi.jpg"><img src="http://positon.org/wp-content/uploads/2014/07/adampd_pi-300x234.jpg" alt="adampd_pi" width="300" height="234" class="alignnone size-medium wp-image-198" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://positon.org/mpd-clients-for-adafruit-character-lcd-keypad-on-raspberry-pi/feed</wfw:commentRss>
		<slash:comments></slash:comments>
		</item>
		<item>
		<title>Listen to mouse events in Linux (text mode)</title>
		<link>http://positon.org/listen-to-mouse-events-in-linux-text-mode</link>
		<comments>http://positon.org/listen-to-mouse-events-in-linux-text-mode#comments</comments>
		<pubDate>Sat, 08 Sep 2012 22:59:00 +0000</pubDate>
		<dc:creator><![CDATA[dooblem]]></dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[MPD]]></category>
		<category><![CDATA[Raspberry Pi]]></category>

		<guid isPermaLink="false">http://positon.org:81/?p=119</guid>
		<description><![CDATA[A small script to listen to mouse events with the mev command using gpm (General Purpose Mouse). Can be used for example on the Raspberry Pi to run mpd commands, to use a mouse as a remote control. I didn&#8217;t find how to isolate the wheel events in order to control the volume. Any idea [&#8230;]]]></description>
				<content:encoded><![CDATA[<p>A small script to listen to mouse events with the <code>mev</code> command using <code>gpm</code> (General Purpose Mouse).</p>
<p>Can be used for example on the Raspberry Pi to run mpd commands, to use a mouse as a remote control.</p>
<p>I didn&#8217;t find how to isolate the wheel events in order to control the volume. Any idea somebody?</p>
<p>In Archlinux, you can add the following command in <code>/etc/rc.local</code> to start it at boot time:</p>
<pre>
nohup /usr/local/bin/mpd_mouse.sh &gt; /tmp/mpd_mouse.log 2&gt;&amp;1 &amp;
</pre>
<pre>
#!/bin/sh
# This script listen to mouse events with the mev command using gpm.
# Can be used for example on the Raspberry Pi to run mpd commands, to use a mouse as a remote control.
# You can start it as a daemon with:
# nohup /usr/local/bin/mpd_mouse.sh &gt; /tmp/mpd_mouse.log 2&gt;&amp;1 &amp;

# start gpm if not already started
gpm -m /dev/input/mice -t imps2

# unset TERM variable, otherwise mev refuses to start when detecting xterm
unset TERM

echo &quot;Listening to mouse events...&quot;

# we use script to fake a tty for mev, otherwise it exits (note: mev logs errors in syslog)
script -qc &quot;mev -E&quot; /dev/null &lt;/dev/null | grep --line-buffered -v &quot;mouse-movement&quot; | while read LINE
do
        echo
        echo &quot;$LINE&quot;

        EVENT=$(echo &quot;$LINE&quot; | cut -d' ' -f1 | cut -d'(' -f2)

        if [ &quot;$EVENT&quot; = &quot;down-mouse-1&quot; ]
        then
                echo mpc stop
                mpc stop
        elif [ &quot;$EVENT&quot; = &quot;down-mouse-2&quot; ]
        then
                echo mpc toggle
                mpc toggle
        elif [ &quot;$EVENT&quot; = &quot;down-mouse-3&quot; ]
        then
                echo mpc next
                mpc next
        else
                echo &quot;nothing&quot;
        fi

done
</pre>
]]></content:encoded>
			<wfw:commentRss>http://positon.org/listen-to-mouse-events-in-linux-text-mode/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
