<?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>Ben&#039;s Place</title>
	<atom:link href="http://www.hardill.me.uk/wordpress/?feed=rss2" rel="self" type="application/rss+xml" />
	<link>http://www.hardill.me.uk/wordpress</link>
	<description>Somewhere to keep notes on my projects</description>
	<lastBuildDate>Fri, 20 Apr 2012 09:44: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>Tracks2Miles 1.1.16</title>
		<link>http://www.hardill.me.uk/wordpress/?p=882</link>
		<comments>http://www.hardill.me.uk/wordpress/?p=882#comments</comments>
		<pubDate>Mon, 27 Feb 2012 17:50:59 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Android]]></category>
		<category><![CDATA[dailymile]]></category>
		<category><![CDATA[mytracks]]></category>
		<category><![CDATA[tracks2miles]]></category>

		<guid isPermaLink="false">http://www.hardill.me.uk/wordpress/?p=882</guid>
		<description><![CDATA[I pushed a new update to the market at the weekend. It should hopefully fix a problem where Tracks2Miles would<a href="http://www.hardill.me.uk/wordpress/?p=882" class="searchmore">Read the Rest...</a><div class="clr"></div>]]></description>
			<content:encoded><![CDATA[<p>I pushed a new update to the market at the weekend.</p>
<p>It should hopefully fix a problem where <a href="https://market.android.com/details?id=uk.me.hardill.dailymile">Tracks2Miles</a> would complain it could not access <a href="https://market.android.com/details?id=com.google.android.maps.mytracks">My Tracks</a> data even when sharing was allowed. This looks to be down to a change in the My Tracks <a href="http://code.google.com/p/mytracks/wiki/MyTracksApi">API</a> with the My Tracks 1.1.15.</p>
<p>I&#8217;ve also tweaked the &#8220;Like&#8221; handling a little to only work for posts that are videos or pictures as this seams to be the only type of posts this works.</p>
<p>Recently a college has been having a look at the code to see if there are some things he wants to add. Hopefully I should have something from him soon.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.hardill.me.uk/wordpress/?feed=rss2&#038;p=882</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Playing with touchatag reader</title>
		<link>http://www.hardill.me.uk/wordpress/?p=858</link>
		<comments>http://www.hardill.me.uk/wordpress/?p=858#comments</comments>
		<pubDate>Fri, 10 Feb 2012 16:00:21 +0000</pubDate>
		<dc:creator>Ben Hardill</dc:creator>
				<category><![CDATA[Projects]]></category>
		<category><![CDATA[Work]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[nfc]]></category>
		<category><![CDATA[rfid]]></category>
		<category><![CDATA[touchatag]]></category>

		<guid isPermaLink="false">http://www.hardill.me.uk/wordpress/?p=858</guid>
		<description><![CDATA[We got a bunch of Touchatag NFC readers in the office just after Christmas and I said I would have<a href="http://www.hardill.me.uk/wordpress/?p=858" class="searchmore">Read the Rest...</a><div class="clr"></div>]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.hardill.me.uk/wordpress/wp-content/uploads/2012/02/IMG_20120210_143738.jpg"><img class="alignright size-medium wp-image-886" title="Touchatag reader" src="http://www.hardill.me.uk/wordpress/wp-content/uploads/2012/02/IMG_20120210_143738-225x300.jpg" alt="Touchatag reader" width="225" height="300" /></a><br />
We got a bunch of <a href="http://www.touchatag.com/">Touchatag</a> NFC readers in the office just after Christmas and I said I would have a play with one to see what we could use them for. I had seen one before (in fact I borrowed one from <a href="https://twitter.com/#!/andypiper">Andy Piper</a> for a little while) but didn&#8217;t get much further than trying to read my work id card.</p>
<p>To get it work on Linux you need to use <a href="http://pcsclite.alioth.debian.org/">PCSC Lite</a> and download the driver from ASC (the guys that actually make the readers that Touchatag use). You can grab the download <a href="http://www.acs.com.hk/index.php?pid=product&amp;id=ACR122U">here</a>. Once you&#8217;ve built these (standard &#8220;configure; make; sudo make install&#8221;) you will need to update one of the PCSC config files. There is a patch linked to from this page: <a href="http://idefix.net/~koos/rfid-touchatag.html">http://idefix.net/~koos/rfid-touchatag.html</a></p>
<p>PCSC Lite is packaged for Fedora and Ubuntu, but I couldn&#8217;t find <a href="http://www.libnfc.org/">libnfc</a> in the standard repos for Ubuntu so ended up building it myself for one of the machines in the office. Again this was a simple &#8220;configure; make; sudo make install&#8221;. With that done I was able to use the nfc-mfclassic tool from the libnfc samples to read data from a tag.</p>
<pre class="brush: bash; gutter: false">$ nfc-mfclassic r a test.out
Connected to NFC reader: ACS ACR122U 00 00 / ACR122U103 - PN532 v1.6 (0x07)
Found MIFARE Classic 4k card with UID: 9e2bcaea
Reading out 256 blocks |.....................................|</pre>
<p>Which gets me a file with all the data stored on a tag (assuming I know the right keys to access all the blocks), but most of the time just having the tag id is enough to trigger an event. After a bit more poking around I found <a href="http://code.google.com/p/nfc-tools/wiki/NfcEventD">nfc-eventd</a> which seamed to fit the bill perfectly.</p>
<p>This allows you to specify commands to be run when a tag is placed on the reader and when it is removed and it will pass the tag id to the command. Here is the config file I used</p>
<pre class="brush: bash; gutter: false">nfc-eventd {

  # Run in background? Implies debug=false if true
  daemon = false;

  # show debug messages?
  debug = true;

  # polling time in seconds
  polling_time = 1;

  # expire time in seconds
  # default = 0 ( no expire )
  expire_time = 0;

  device my_touchatag {
    driver = &quot;ACR122&quot;;
    name = &quot;ACS ACR 38U-CCID 01 00&quot;;
  }

  # which device to use ? note: if this part is commented out,
  # nfc-eventd will try to pick up device automagically...
  #nfc_device = &quot;my_touchatag&quot;;

  # list of events and actions
  module nem_execute {
    # Tag inserted
    event tag_insert {
      # what to do if an action fail?
      # ignore  : continue to next action
      # return  : end action sequence
      # quit    : end program
      on_error = ignore ;

      # You can enter several, comma-separated action entries
      # they will be executed in turn
      action = &quot;publish &#039;wmqtt://nfc@broker:1883/nfc/tagid?qos=0&amp;retain=n&amp;debug=0&#039; $TAG_UID&quot;
    }

    # Tag has been removed
    event tag_remove {
      on_error = ignore;
      action = &quot;(echo -n &#039;Tag (uid=$TAG_UID) removed at: &#039; &amp;&amp; date) &gt;&gt; /tmp/nfc-eventd.log&quot;;
    }

    # Too much time card removed
    event expire_time {
      on_error = ignore;
      action = &quot;/bin/false&quot;;
    }
  }

}</pre>
<p>Here I have used the publish command from the <a href="http://www-01.ibm.com/support/docview.wss?rs=171&#038;uid=swg24006525&#038;loc=en_US&#038;cs=utf-8&#038;lang=en">IBM IA93 C</a> <a href="http://mqtt.org" title="Tracks2Miles 1.1.14">MQTT</a> package to publish a message with the tag id to the nfc topic. You can do something similar with <a href="http://mosquitto.org/man/mosquitto_pub-1.html">mosquitto_pub</a> like this:</p>
<p>mosquitto_pub -h broker -i nfc -t nfc -m $TAG_ID</p>
<p>The plan is to use this now to allow the guys in ETS to log into various demos in the lab with their id badges.</p>
<p>Next on the list is to see if I can get the reader to respond to my Galaxy Nexus when it&#8217;s in tag mode.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.hardill.me.uk/wordpress/?feed=rss2&#038;p=858</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>MQTT Inside Sticker Engine</title>
		<link>http://www.hardill.me.uk/wordpress/?p=857</link>
		<comments>http://www.hardill.me.uk/wordpress/?p=857#comments</comments>
		<pubDate>Fri, 03 Feb 2012 23:02:16 +0000</pubDate>
		<dc:creator>Ben Hardill</dc:creator>
				<category><![CDATA[Projects]]></category>
		<category><![CDATA[MQTT]]></category>
		<category><![CDATA[OAuth]]></category>

		<guid isPermaLink="false">http://www.hardill.me.uk/wordpress/?p=857</guid>
		<description><![CDATA[For a bit of fun round a project last year I created some Moo &#8220;MQTT Inside&#8221; stickers to put on<a href="http://www.hardill.me.uk/wordpress/?p=857" class="searchmore">Read the Rest...</a><div class="clr"></div>]]></description>
			<content:encoded><![CDATA[<p>For a bit of fun round a <a title="MQTT Powered Video Wall" href="http://eightbar.co.uk/2011/09/16/mqtt-powered-video-wall/">project</a> last year I created some <a title="Moo.com" href="http://www.moo.com">Moo</a> &#8220;MQTT Inside&#8221; stickers to put on the cases.</p>
<p><a title="First sticker deployed by hardillb, on Flickr" href="http://www.flickr.com/photos/hardillb/6143434166/"><img src="http://farm7.staticflickr.com/6189/6143434166_4cf426ac18.jpg" alt="First sticker deployed" width="299" height="500" /></a></p>
<p>These became very popular around the office, with everybody wanting to label up their <a title="Tracks2Miles 1.1.14" href="http://mqtt.org">MQTT</a> enabled projects and the first batch of 90 quickly disappeared.</p>
<p>Given demand was so high <a href="http://andypiper.co.uk/" title="The Lost Outpost">Andy Piper</a> suggested it might be worth making it possible for others to order their own sets and pointed me at the <a title="Moo API" href="http://uk.moo.com/api">Moo API</a>.</p>
<p>The Moo API Doc is pretty good, but there aren&#8217;t any examples so it took a bit of trial and error. The API works by building up an object called a &#8216;<a title="pack object model" href="http://uk.moo.com/api/docs/pack-object-model.html">pack</a>&#8216;. The Moo website uses the same API for the wizard you use to manually create any of their products and there is a very nice little <a href="https://addons.mozilla.org/en-US/firefox/addon/greasemonkey/">Greasemonkey</a> script called &#8216;Show API JSON&#8217; which shows you the state of the pack object at each step. The API also lets you skip any steps in the process by just uploading a pack object already filled in. This meant I could reproduce the stickers by choosing to edit my original set and then using the script to save the pack.json file.</p>
<pre class="brush: javascript; gutter: true">{
    &quot;productVersion&quot; : &quot;1&quot;,
    &quot;cards&quot; : [
    ],
    &quot;numCards&quot; : 90,
    &quot;extras&quot; : [
        {
            &quot;value&quot; : &quot;blue&quot;,
            &quot;key&quot; : &quot;pack_colour&quot;
        }
    ],
    &quot;imageBasket&quot; : {
        &quot;name&quot; : null,
        &quot;immutable&quot; : false,
        &quot;items&quot; : [
            {
                &quot;cacheId&quot; : &quot;partner_interface_uploader:e34bb9c2-637b-558545db-4e61502d-ff34.png&quot;,
                &quot;imageBox&quot; : null,
                &quot;imageItems&quot; : [
                    {
                        &quot;rotation&quot; : 0,
                        &quot;height&quot; : 297,
                        &quot;resourceUri&quot; : &quot;http://www.moo.com/is/o/e34bb9c2-637b-558545db-4e61502d-ff34.png&quot;,
                        &quot;width&quot; : 297,
                        &quot;type&quot; : &quot;print&quot;
                    },
                    {
                        &quot;rotation&quot; : 0,
                        &quot;height&quot; : 1024,
                        &quot;resourceUri&quot; : &quot;http://www.moo.com/is/r/1024/e34bb9c2-637b-558545db-4e61502d-ff34.png&quot;,
                        &quot;width&quot; : 1024,
                        &quot;type&quot; : &quot;preview&quot;
                    },
                    {
                        &quot;rotation&quot; : 0,
                        &quot;height&quot; : 75,
                        &quot;resourceUri&quot; : &quot;http://www.moo.com/is/t/75/e34bb9c2-637b-558545db-4e61502d-ff34.png&quot;,
                        &quot;width&quot; : 75,
                        &quot;type&quot; : &quot;thumbnail&quot;
                    }
                ],
                &quot;copyrightOwner&quot; : null,
                &quot;resourceUri&quot; : &quot;filestore://image_original/e34bb9c2-637b-558545db-4e61502d-ff34.png&quot;,
                &quot;croppable&quot; : true,
                &quot;shouldEnhance&quot; : false,
                &quot;type&quot; : &quot;front&quot;,
                &quot;removable&quot; : true
            }
        ],
        &quot;type&quot; : null
    },
    &quot;productCode&quot; : &quot;sticker&quot;,
    &quot;sides&quot; : [
        {
            &quot;type&quot; : &quot;image&quot;,
            &quot;data&quot; : [
                {
                    &quot;imageStoreFileId&quot; : &quot;e34bb9c2-637b-558545db-4e61502d-ff34&quot;,
                    &quot;resourceUri&quot; : &quot;filestore://image_original/e34bb9c2-637b-558545db-4e61502d-ff34.png&quot;,
                    &quot;linkId&quot; : &quot;variable_image_front&quot;,
                    &quot;enhance&quot; : false,
                    &quot;imageBox&quot; : {
                        &quot;center&quot; : {
                            &quot;y&quot; : 12,
                            &quot;x&quot; : 12
                        },
                        &quot;height&quot; : 20.88,
                        &quot;width&quot; : 20.88,
                        &quot;angle&quot; : 0
                    },
                    &quot;type&quot; : &quot;imageData&quot;
                }
            ],
            &quot;templateCode&quot; : &quot;sticker_image&quot;,
            &quot;sideNum&quot; : 1
        }
    ]
}</pre>
<p>Resubmitting this with the &#8216;<a href="http://uk.moo.com/api/docs/methods.html#moo.pack.createPack">moo.pack.createPack</a>&#8216; method and then using the &#8216;finish&#8217; <a href="http://uk.moo.com/api/docs/drop-in-points.html">Drop in point</a> to direct the user to Moo checkout page to pay for their new stickers.</p>
<p>I used a little library called <a href="https://github.com/fernandezpablo85/scribe-java">scrib</a> to do the oAuth and the whole thing can be done with just these few lines:</p>
<pre class="brush: java; gutter: true">protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
	String authTokenString = request.getParameter(&quot;oauth_token&quot;);
	String authVerifyString = request.getParameter(&quot;oauth_verifier&quot;);

	Token authToken = MemoryStore.data.get(authTokenString);
	MemoryStore.data.remove(authTokenString);

	Verifier verifier = new Verifier(authVerifyString);
	Token accessToken = service.getAccessToken(authToken, verifier);

	String createPack = rootURL + &quot;method=moo.pack.createPack&amp;product=sticker&amp;pack=&quot; + pack;
	createPack = createPack + &quot;&amp;friendlyName=&quot; + URLEncoder.encode(&quot;MQTT Inside&quot;, &quot;UTF-8&quot;);

	OAuthRequest oAuthRequest = new OAuthRequest(Verb.POST, createPack);

	service.signRequest(accessToken, oAuthRequest);
	Response oAuthResponse = oAuthRequest.send();
	if (oAuthResponse.getCode() == 200) {
		System.err.println(oAuthResponse.getBody());
		JSONTokener tok = new JSONTokener(oAuthResponse.getBody());
		try {
			JSONObject json = new JSONObject(tok);
			JSONObject dropings = json.getJSONObject(&quot;dropIns&quot;);
			String finishURL = dropings.getString(&quot;finish&quot;);
			response.sendRedirect(finishURL);
		} catch (JSONException e) {
			e.printStackTrace();
		}
	} else {
		System.err.println(oAuthResponse.getBody());
	}
}
</pre>
<p>Andy is working to get a page set up on the <a href="http://mqtt.org">mqtt.org</a> site, but in the mean time you can click on the image bellow to order own set.</p>
<p><a href="http://www.hardill.me.uk/mqtt/"><img src="http://www.hardill.me.uk/mqtt-inside.png"/></a></p>
<p>EDIT:</p>
<p>Andy has now added a <a href="http://mqtt.org/goodies">Goodies</a> page to the mqtt.org site that you can use to order stickers</p>
]]></content:encoded>
			<wfw:commentRss>http://www.hardill.me.uk/wordpress/?feed=rss2&#038;p=857</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Tracks2Miles 1.1.14</title>
		<link>http://www.hardill.me.uk/wordpress/?p=807</link>
		<comments>http://www.hardill.me.uk/wordpress/?p=807#comments</comments>
		<pubDate>Fri, 20 Jan 2012 15:31:40 +0000</pubDate>
		<dc:creator>Ben Hardill</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[Exercise]]></category>
		<category><![CDATA[Projects]]></category>
		<category><![CDATA[dailymile]]></category>
		<category><![CDATA[mytracks]]></category>
		<category><![CDATA[tracks2miles]]></category>

		<guid isPermaLink="false">http://www.hardill.me.uk/wordpress/?p=807</guid>
		<description><![CDATA[Finally got round to spending some more time on Tracks2Miles. This release is an attempt to make use of a<a href="http://www.hardill.me.uk/wordpress/?p=807" class="searchmore">Read the Rest...</a><div class="clr"></div>]]></description>
			<content:encoded><![CDATA[<p>Finally got round to spending some more time on Tracks2Miles.</p>
<p>This release is an attempt to make use of a lot of what is left of the API.</p>
<p>New features:</p>
<ol>
<li>New Workout types:
<ul>
<li>- Commute</li>
<li>- Spinning</li>
<li>- Rowing</li>
<li>- Cross Training</li>
</ul>
</li>
<li>Support for multi-media posts, Uploaded Images and links to Youtube and Vimeo are now shown in your timeline</li>
<li>Like your friends workouts</li>
<li>See when you get Motivational comments</li>
<li>Added pull to refresh support to the timeline</li>
<li>Slightly improved look and feel, the white background looks better</li>
</ol>
<p>All that plus a couple of bugs I spotted along the way.</p>
<p>There is a new introduction video with a walk through of all the features</p>
<p><a href="http://www.hardill.me.uk/wordpress/?p=807"><em>Click here to view the embedded video.</em></a></p>
<p>As always you can get the very latest version from the Android Market here: <a href="https://market.android.com/details?id=uk.me.hardill.dailymile">https://market.android.com/details?id=uk.me.hardill.dailymile</a></p>
<p>The next version should have better support for tablets and ICS devices that support Activity Fragments to make better use of large screens. I&#8217;ve also managed to arrange to borrow a Sony Ericsson X10 mini to see about trying to improve the UI for those of you with really small screen devices.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.hardill.me.uk/wordpress/?feed=rss2&#038;p=807</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Timelapse photography</title>
		<link>http://www.hardill.me.uk/wordpress/?p=784</link>
		<comments>http://www.hardill.me.uk/wordpress/?p=784#comments</comments>
		<pubDate>Wed, 28 Dec 2011 18:31:42 +0000</pubDate>
		<dc:creator>Ben Hardill</dc:creator>
				<category><![CDATA[Projects]]></category>
		<category><![CDATA[camera]]></category>
		<category><![CDATA[gphoto2]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[video]]></category>

		<guid isPermaLink="false">http://www.hardill.me.uk/wordpress/?p=784</guid>
		<description><![CDATA[As I mentioned at the end of my last post I have been playing around with gphoto2 to create some<a href="http://www.hardill.me.uk/wordpress/?p=784" class="searchmore">Read the Rest...</a><div class="clr"></div>]]></description>
			<content:encoded><![CDATA[<p>As I mentioned at the end of my <a title="Christmas Project" href="http://www.hardill.me.uk/wordpress/?p=751">last post</a> I have been playing around with gphoto2 to create some time lapse videos of the assembly of one of my Christmas gifts.</p>
<p>I have played with making time lapse video before, when I set up my <a title="How to get personal CCTV MMS’d to your phone" href="http://www.hardill.me.uk/wordpress/?p=17">MMS CCTV system</a> with motion I enabled a feature that creates a video from a sample image every 30 seconds. Motion uses the web cam (or other Video4Linux src) and all the web cams I had access to up at my folks are pretty low resolution so this wasn&#8217;t what I was looking for.</p>
<p>I did have my Canon 350D and the little point and shoot Canon A520 that lives on the end of my work bag so I thought I&#8217;d see what I could do with them. The 350D is 8 Megapixel and the A520 is 4 Megapixel so both will take a frame way bigger than 720p that I can crop down.</p>
<p>I had a bit of a look round and found an app called gphoto2 that claimed to be able to drive both cameras via the USB port to take images at a set interval. I plugged the 350D in and tried to get it to work but I kept getting the following error*:</p>
<pre class="brush: bash; gutter: false">*** Error ***
Sorry, your camera does not support generic capture
ERROR: Could not capture.
*** Error (-6: &#039;Unsupported operation&#039;) ***</pre>
<p>So I swapped over to the A520 and things seamed to work fine. So I set it up on the tripod and fired off the following command:</p>
<pre class="brush: bash; gutter: false">[hardillb@bagend ~]$ gphoto2 --capture-image -I 120</pre>
<p>This triggers the camera every 2 mins which I thought should be enough time to see some progress in each frame.</p>
<p>Apart from having to swap the batteries twice it all went rather well, I soon started to ignore the little beep from the camera as it took each shot. At the end I copied all the images off the SD card for processing. Each image started out at 2272&#215;1704 so they would have been big enough to use in 1080p video but I decided to shrink them down to 720p.</p>
<p>The following little ImageMagik script resizes the images down and adds 2 black bars down the sides to pad it out to a full 16:9 720p frame size.</p>
<pre class="brush: bash; gutter: false">#!/bin/sh
for x in `ls *.JPG`
do
   convert $x -resize 1280x720 -bordercolor black -border 160x0 resized/$x
done</pre>
<p>The first bit <em>-resize 1280&#215;720</em> resized the original image down to 720 pixels high and the second bit <em>-bordercolor black -border 160&#215;0</em> adds on the 2 x 160 pixel wide black bars to pad the image up to the required 1280 pixels wide before writing a copy out to the resized directory.</p>
<p>And this mencoder line to stitch them together as a video with 2 frame per second so each second of video is equivalent to about 4 minutes of real time.</p>
<pre class="brush: bash; gutter: false">mencoder &quot;mf://*.JPG&quot; -mf fps=2 -o day1.avi -ovc lavc -lavcopts \\
vcodec=msmpeg4v2:vbitrate=800</pre>
<p>Here is a sample of the output</p>
<p><a href="http://www.hardill.me.uk/wordpress/?p=784"><em>Click here to view the embedded video.</em></a></p>
<p>*I have since found this <a href="http://old.nabble.com/-gphoto-bugs----gphoto-Bugs-2249796---Canon-EOS-350-no-capture-support-td20765092.html">gphoto bug report</a> that mentioned changing the camera&#8217;s USB mode from PTP mode to normal mode. After finding this setting on the camera I managed to get the 350D to work with gphoto2 as well.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.hardill.me.uk/wordpress/?feed=rss2&#038;p=784</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Christmas Project</title>
		<link>http://www.hardill.me.uk/wordpress/?p=751</link>
		<comments>http://www.hardill.me.uk/wordpress/?p=751#comments</comments>
		<pubDate>Tue, 27 Dec 2011 18:23:44 +0000</pubDate>
		<dc:creator>Ben Hardill</dc:creator>
				<category><![CDATA[Projects]]></category>
		<category><![CDATA[Lego]]></category>

		<guid isPermaLink="false">http://www.hardill.me.uk/wordpress/?p=751</guid>
		<description><![CDATA[I&#8217;ve always been a fan of Lego*, Technic especially. As a kid I was lucky enough to get hold of<a href="http://www.hardill.me.uk/wordpress/?p=751" class="searchmore">Read the Rest...</a><div class="clr"></div>]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve always been a fan of Lego*, Technic especially. As a kid I was lucky enough to get hold of a few different sets to build, some of them can still be found in my old room at home.</p>
<p>On Christmas morning I was lucky enough to unwrap one of <a href="http://technic.lego.com/en-GB/Products/default.aspx#8258">these</a>.</p>
<p><a href="http://www.hardill.me.uk/wordpress/wp-content/uploads/2011/12/IMAG0281.jpg"><img src="http://www.hardill.me.uk/wordpress/wp-content/uploads/2011/12/IMAG0281-300x179.jpg" alt="" title="Truck" width="300" height="179" class="aligncenter size-medium wp-image-780" /></a></p>
<p>The kits have been getting more and more complex over the years this one comes with 4 volumes of assembly instructions</p>
<p><a href="http://www.hardill.me.uk/wordpress/wp-content/uploads/2011/12/IMG_1574.jpg"><img src="http://www.hardill.me.uk/wordpress/wp-content/uploads/2011/12/IMG_1574-300x224.jpg" alt="" title="Assembly Instructions" width="300" height="224" class="aligncenter size-medium wp-image-775" /></a></p>
<p>And enough parts to set up a shop.</p>
<p><a href="http://www.hardill.me.uk/wordpress/wp-content/uploads/2011/12/IMG_1581.jpg"><img src="http://www.hardill.me.uk/wordpress/wp-content/uploads/2011/12/IMG_1581-300x224.jpg" alt="" title="Parts" width="300" height="224" class="aligncenter size-medium wp-image-777" /></a></p>
<p>So come Boxing day I set about putting it all together.</p>
<p>4 Hours on Day 1 and I managed to get through the first 2 sets of instructions<br />
<p><a href="http://www.hardill.me.uk/wordpress/?p=751"><em>Click here to view the embedded video.</em></a></p></p>
<p>Day 2 finishing off<br />
<p><a href="http://www.hardill.me.uk/wordpress/?p=751"><em>Click here to view the embedded video.</em></a></p></p>
<p>It was great fun putting it all together and seeing how the tech has moved on. The gear box in the middle of this model that makes it all work is amazing, with just one motor it drives the stabilizers and the crane jib arm.</p>
<div class="alignright">
<a href="http://www.amazon.co.uk/gp/product/B001U3ZMKO/ref=as_li_ss_il?ie=UTF8&#038;tag=bespl-21&#038;linkCode=as2&#038;camp=1634&#038;creative=19450&#038;creativeASIN=B001U3ZMKO"><img border="0" src="http://ws.assoc-amazon.co.uk/widgets/q?_encoding=UTF8&#038;Format=_SL110_&#038;ASIN=B001U3ZMKO&#038;MarketPlace=GB&#038;ID=AsinImage&#038;WS=1&#038;tag=bespl-21&#038;ServiceVersion=20070822" ></a><img src="http://www.assoc-amazon.co.uk/e/ir?t=bespl-21&#038;l=as2&#038;o=2&#038;a=B001U3ZMKO" width="1" height="1" border="0" alt="" style="border:none !important; margin:0px !important;" />
</div>
<p>The videos were made using <a href="http://www.gphoto.org/">gphoto2</a> hooked up to my old Canon Powershot A520 (I couldn&#8217;t get it to work with my 350D) to take a picture every 2mins. The images were then resized down to 720p and black bars added before being stitched together with <a href="http://www.mplayerhq.hu/">mencoder</a>. I&#8217;ll try and remember to do a post about the details later</p>
<p>* Yes that&#8217;s right Lego, not &#8216;Legos&#8217; my American friends, it&#8217;s a trade mark and the singular is a Lego Brick. While we&#8217;re on the subject it&#8217;s Maths, not Math&#8230;.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.hardill.me.uk/wordpress/?feed=rss2&#038;p=751</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Final Gingerbread House 2011</title>
		<link>http://www.hardill.me.uk/wordpress/?p=770</link>
		<comments>http://www.hardill.me.uk/wordpress/?p=770#comments</comments>
		<pubDate>Mon, 26 Dec 2011 21:47:20 +0000</pubDate>
		<dc:creator>Ben Hardill</dc:creator>
				<category><![CDATA[Food]]></category>
		<category><![CDATA[gingerbread]]></category>

		<guid isPermaLink="false">http://www.hardill.me.uk/wordpress/?p=770</guid>
		<description><![CDATA[As mentioned in my last post it&#8217;s that time of year again so it&#8217;s time. So here is this years<a href="http://www.hardill.me.uk/wordpress/?p=770" class="searchmore">Read the Rest...</a><div class="clr"></div>]]></description>
			<content:encoded><![CDATA[<p>As mentioned in my <a href="http://www.hardill.me.uk/wordpress/?p=745" title="Gingerbread Architecture">last post</a> it&#8217;s that time of year again so it&#8217;s time. So here is this years creation.</p>
<p><a href="http://www.flickr.com/photos/hardillb/6576214699/" title="This years gingerbread house by hardillb, on Flickr"><img src="http://farm8.staticflickr.com/7006/6576214699_661e0fbca5_z.jpg" width="383" height="640" alt="This years gingerbread house"></a></p>
<p>The key point learnt this year is how to make extra strength icing by using egg whites and icing sugar.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.hardill.me.uk/wordpress/?feed=rss2&#038;p=770</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Gingerbread Architecture</title>
		<link>http://www.hardill.me.uk/wordpress/?p=745</link>
		<comments>http://www.hardill.me.uk/wordpress/?p=745#comments</comments>
		<pubDate>Sun, 18 Dec 2011 14:31:54 +0000</pubDate>
		<dc:creator>Ben Hardill</dc:creator>
				<category><![CDATA[Food]]></category>
		<category><![CDATA[christmas]]></category>
		<category><![CDATA[cooking]]></category>
		<category><![CDATA[food]]></category>
		<category><![CDATA[gingerbread]]></category>

		<guid isPermaLink="false">http://www.hardill.me.uk/wordpress/?p=745</guid>
		<description><![CDATA[Last years Gingerbread Christmas Tree was OK, but not up to the standard of the previous efforts. This led me<a href="http://www.hardill.me.uk/wordpress/?p=745" class="searchmore">Read the Rest...</a><div class="clr"></div>]]></description>
			<content:encoded><![CDATA[<p>Last years <a href="http://www.hardill.me.uk/wordpress/?p=347" title="Gingerbread Engineering">Gingerbread Christmas Tree</a> was OK, but not up to the standard of the previous efforts. This led me to have a bit of a look round and I spotted this book &#8211; <a href="http://www.amazon.co.uk/gp/product/0307406784/ref=as_li_ss_tl?ie=UTF8&#038;tag=bespl-21&#038;linkCode=as2&#038;camp=1634&#038;creative=19450&#038;creativeASIN=0307406784">The Gingerbread Architect</a><img src="http://www.assoc-amazon.co.uk/e/ir?t=bespl-21&#038;l=as2&#038;o=2&#038;a=0307406784" width="1" height="1" border="0" alt="" style="border:none !important; margin:0px !important;" /></p>
<p>I started out just getting my eye in with a little Gingerbread Cottage this weekend.</p>
<p><a href="http://www.flickr.com/photos/hardillb/6527285709/" title="Gingerbread Cottage by hardillb, on Flickr"><img src="http://farm8.staticflickr.com/7034/6527285709_63ee77fdd1.jpg" width="500" height="333" alt="Gingerbread Cottage"></a></p>
<p>I&#8217;ll stick an update online once this years proper edifice is complete.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.hardill.me.uk/wordpress/?feed=rss2&#038;p=745</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Tracks2Miles 1.1.10</title>
		<link>http://www.hardill.me.uk/wordpress/?p=742</link>
		<comments>http://www.hardill.me.uk/wordpress/?p=742#comments</comments>
		<pubDate>Sun, 20 Nov 2011 16:52:30 +0000</pubDate>
		<dc:creator>Ben Hardill</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[Projects]]></category>
		<category><![CDATA[dailymile]]></category>
		<category><![CDATA[my tracks]]></category>
		<category><![CDATA[tracks2miles]]></category>

		<guid isPermaLink="false">http://www.hardill.me.uk/wordpress/?p=742</guid>
		<description><![CDATA[Just a quick update while I&#8217;m still working on a 2.x release*. This release has 2 updates: A small update<a href="http://www.hardill.me.uk/wordpress/?p=742" class="searchmore">Read the Rest...</a><div class="clr"></div>]]></description>
			<content:encoded><![CDATA[<p>Just a quick update while I&#8217;m still working on a 2.x release*.</p>
<p>This release has 2 updates:</p>
<p><a href="http://www.hardill.me.uk/wordpress/wp-content/uploads/2011/11/prefs.png"><img src="http://www.hardill.me.uk/wordpress/wp-content/uploads/2011/11/prefs-180x300.png" alt="" title="Preferences Page" width="180" height="300" class="alignright size-medium wp-image-747" /></a></p>
<ol>
<li>A small update to the import code to make use of the <a href="http://www.hardill.me.uk/wordpress/?p=734" title="New My Tracks Patch">patch</a> I managed to get included in the latest (1.1.11) release of <a href="https://market.android.com/details?id=com.google.android.maps.mytracks" title="My Tracks">My Tracks</a></li>
<li>A new setting in the preferences to block uploading GPX data with a workout imported from My Tracks. This was a feature requested to help people with privacy concerns</li>
</ol>
<p>You can download Tracks2Miles here: <a href="https://market.android.com/details?id=uk.me.hardill.dailymile">https://market.android.com/details?id=uk.me.hardill.dailymile</a></p>
<p>* The plan is for 2.x to have a updated UI making use of fragments for tablet and ICS devices.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.hardill.me.uk/wordpress/?feed=rss2&#038;p=742</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>New My Tracks Patch</title>
		<link>http://www.hardill.me.uk/wordpress/?p=734</link>
		<comments>http://www.hardill.me.uk/wordpress/?p=734#comments</comments>
		<pubDate>Tue, 01 Nov 2011 09:38:34 +0000</pubDate>
		<dc:creator>Ben Hardill</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[Exercise]]></category>
		<category><![CDATA[Projects]]></category>
		<category><![CDATA[dailymile]]></category>
		<category><![CDATA[my tracks]]></category>
		<category><![CDATA[titanxt]]></category>
		<category><![CDATA[tracks2miles]]></category>
		<category><![CDATA[tracks2titanxt]]></category>

		<guid isPermaLink="false">http://www.hardill.me.uk/wordpress/?p=734</guid>
		<description><![CDATA[After my last My Tracks patch had to be pulled (to be honest it did break sharing routes by anything<a href="http://www.hardill.me.uk/wordpress/?p=734" class="searchmore">Read the Rest...</a><div class="clr"></div>]]></description>
			<content:encoded><![CDATA[<p>After my <a title="My Tracks patch pulled" href="http://www.hardill.me.uk/wordpress/?p=564">last My Tracks patch</a> had to be pulled (to be honest it did break sharing routes by anything other than <a href="https://market.android.com/details?id=uk.me.hardill.dailymile">Tracks2Miles</a>) a new (safe) patch was accepted a few days ago.</p>
<p>This patch passes just the My Tracks track id along with the URL for the exported file in the SHARE intent. The key for the extra reuses the same key that is used by the My Tracks library when sending Broadcasts on starting and stopping recording a new track. The track id can be recovered from the intent with the following code:</p>
<pre class="brush: java; gutter: true">long track_id =
    intent.getLongExtra(getString(R.string.track_id_broadcast_extra), -1);</pre>
<p>Once you have the track id then looking up all the details of that track using the <a href="http://code.google.com/p/mytracks/wiki/MyTracksApi">My Tracks Library</a> project is trivial (<a title="Tracks2Miles 1.1.9 release" href="http://www.hardill.me.uk/wordpress/?p=714">Once you got the user to allow 3rd party apps access</a>).</p>
<pre class="brush: java; gutter: true">MyTracksProviderUtils utils =
    new MyTracksProviderUtilsImpl(this.getContentResolver());
Track track = utils.getTrack(track_id);
TripStatistics stats = track.getStatistics();
double totalDistance = stats.getTotalDistance();
long movingTime = stats.getMovingTime();
String cat = track.getCategory();
String desc = track.getDescription();
long lastLocId = utils.getLastLocationId(track_id);
Location loc = utils.getLocation(lastLocId);</pre>
<p>The latest version of <a href="https://market.android.com/details?id=uk.me.hardill.titanxt">Tracks2TitanXT</a> has already been updated to use this method and Tracks2Miles will get an update for this as well as some better tablet support before the next version of My Tracks ships.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.hardill.me.uk/wordpress/?feed=rss2&#038;p=734</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

