<?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>ScratchMyTail.com</title>
	<atom:link href="http://www.scratchmytail.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.scratchmytail.com</link>
	<description>My little tech blog</description>
	<lastBuildDate>Tue, 17 Jan 2012 21:21:15 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>FIX: Battlefield 3 crash to desktop without error</title>
		<link>http://www.scratchmytail.com/2012/01/17/fix-battlefield-3-crash-to-desktop-without-error/</link>
		<comments>http://www.scratchmytail.com/2012/01/17/fix-battlefield-3-crash-to-desktop-without-error/#comments</comments>
		<pubDate>Tue, 17 Jan 2012 21:20:22 +0000</pubDate>
		<dc:creator>ScratchMyTail</dc:creator>
				<category><![CDATA[Hardware]]></category>
		<category><![CDATA[580 gtx]]></category>
		<category><![CDATA[artifacts]]></category>
		<category><![CDATA[battlefield 3]]></category>
		<category><![CDATA[bf3]]></category>
		<category><![CDATA[crash]]></category>
		<category><![CDATA[fix]]></category>
		<category><![CDATA[gainward]]></category>
		<category><![CDATA[gainward 580 gtx]]></category>
		<category><![CDATA[no error]]></category>
		<category><![CDATA[problem]]></category>
		<category><![CDATA[triangular artifacts]]></category>

		<guid isPermaLink="false">http://www.scratchmytail.com/?p=388</guid>
		<description><![CDATA[I have been having a lot of trouble getting Battlefield 3 stable on my computer. I&#8217;ve been experiencing triangular artifacts acting wierd, and most annoying, regular crashes. I have a Gainward Geforce 580 GTX graphics card. The solution that worked for me was simply to clock down the card from 783MHz to 583 MHz. I [...]]]></description>
			<content:encoded><![CDATA[<p>I have been having a lot of trouble getting Battlefield 3 stable on my computer. I&#8217;ve been experiencing triangular artifacts acting wierd, and most annoying, regular crashes. I have a Gainward Geforce 580 GTX graphics card. The solution that worked for me was simply to clock down the card from <strong>783MHz to 583 MHz. </strong>I used a program called EXPERTool to do this. EXPERTool is developed by Gainward and is recommended for use on their card. There are several other methods of underclocking a graphics card. Search for it on Google, add your graphics card name on to the search string.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.scratchmytail.com/2012/01/17/fix-battlefield-3-crash-to-desktop-without-error/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Grouped/section-based listview in Android</title>
		<link>http://www.scratchmytail.com/2011/10/19/groupedsection-baed-listview-in-android/</link>
		<comments>http://www.scratchmytail.com/2011/10/19/groupedsection-baed-listview-in-android/#comments</comments>
		<pubDate>Wed, 19 Oct 2011 14:57:18 +0000</pubDate>
		<dc:creator>ScratchMyTail</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[group based]]></category>
		<category><![CDATA[listview]]></category>

		<guid isPermaLink="false">http://www.scratchmytail.com/?p=350</guid>
		<description><![CDATA[Found a nice tutorial on how to create section/grouped-based listviews for android. Article written by Jeff Sharkey.]]></description>
			<content:encoded><![CDATA[<p>Found a nice tutorial on how to create section/grouped-based listviews for android. <a title="Grouped listview" href="http://jsharkey.org/blog/2008/08/18/separating-lists-with-headers-in-android-09/">Article</a> written by Jeff Sharkey.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.scratchmytail.com/2011/10/19/groupedsection-baed-listview-in-android/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The Ultimate 10 step setup: Eclipse (STS) + Android + Maven</title>
		<link>http://www.scratchmytail.com/2011/08/26/the-ultimate-10-step-setup-eclipse-sts-android-maven/</link>
		<comments>http://www.scratchmytail.com/2011/08/26/the-ultimate-10-step-setup-eclipse-sts-android-maven/#comments</comments>
		<pubDate>Fri, 26 Aug 2011 11:48:14 +0000</pubDate>
		<dc:creator>ScratchMyTail</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[adt]]></category>
		<category><![CDATA[android]]></category>
		<category><![CDATA[eclipse]]></category>
		<category><![CDATA[import.android.r]]></category>
		<category><![CDATA[m2e-android-integration]]></category>
		<category><![CDATA[m2eclipse]]></category>
		<category><![CDATA[maven]]></category>
		<category><![CDATA[setting up android and maven]]></category>
		<category><![CDATA[setup]]></category>
		<category><![CDATA[springsource]]></category>
		<category><![CDATA[sts]]></category>
		<category><![CDATA[tutorial]]></category>

		<guid isPermaLink="false">http://www.scratchmytail.com/?p=351</guid>
		<description><![CDATA[After a lot of struggling and frustration getting Android SDK, Maven and Eclipse working together I have decided to create the ultimate tutorial. I have not found a single page online describing how all the pieces should work together. I have only found bits and pieces of information at various sites. So this should be a [...]]]></description>
			<content:encoded><![CDATA[<p>After a lot of struggling and frustration getting Android SDK, Maven and Eclipse working together I have decided to create the <em>ultimate </em>tutorial. I have not found a single page online describing how all the pieces should work together. I have only found bits and pieces of information at various sites. So this should be a post merging it all together. Read on if you want to know how I got it working. My goal is to create a post containing everything from installation requirements to getting the first project up and running.</p>
<p><span id="more-351"></span></p>
<h3>1. Initial setup</h3>
<p>The first step in this process is of course downloading the IDE. I am currently using SpringSource STS version 2.5.2.SR1. SpringSource is an IDE based on Eclipse adapted for the SpringFramework (<a title="SpringSource STS download" href="http://www.springsource.com/landing/best-development-tool-enterprise-java" target="_blank">download here</a>). I am sure the newest version of Eclipse should work fine as well. You must also check that Maven is installed, I am using version 2.2.1. I am working on an Ubuntu machine so some steps may differ if you are using Mac or Windows.</p>
<h3>2. Downloading the Android SDK</h3>
<p>The second step is to download and unpack the Android SDK. It can be <a title="Android SDK" href="http://developer.android.com/sdk/index.html" target="_blank">found here</a>. Unpack it and remember where you put it. You will need the path later on when you install the Android ADT plugin in SpringSource/Eclipse, and when you are going to set the path of where it is located.</p>
<h3>3. Setting the PATH variable</h3>
<p>You must also update the PATH variable telling it where the Android SDK is located. I added these strings to my .bashrc file. If you are not using Ubuntu or Linux you will have to use your platforms way of setting the PATH. (Search for it in google).</p>
<blockquote>
<pre>export ANDROID_HOME=&lt;path to Android SDK&gt;
PATH=$ANDROID_HOME/tools:$ANDROID_HOME/platform-tools:$ANDROID_HOME/platforms:$PATH</pre>
</blockquote>
<h3>4. Installing the Android Development Tools (ADT) for SpringSource/Eclipse</h3>
<p>The fourth step is to install the ADT plugin in Eclipse. Open eclipse and follow the steps provided in <a title="Installing ADT Plugin" href="http://developer.android.com/sdk/eclipse-adt.html#installing" target="_blank">this link</a>. It should be pretty straightforward. Remember to tell the ADT plugin where your Android SDK is stored.</p>
<h3>5. m2eclipse plugin for SpringSource/Eclipse</h3>
<p>The fifth step is to install the m2eclipse plugin in eclipse. This is a plugin that binds Maven 2 and Eclipse together. If you are using <strong>SpringSource STS you already have m2eclipse</strong>, but if you&#8217;re using eclipse you have to install the plugin. Click Help &lt; Install new software and add this repository.</p>
<blockquote><p>http://m2eclipse.sonatype.org/sites/m2e</p></blockquote>
<p>Then select the <em>Maven Integration for Eclipse </em>option. Then proceed the installation. Read more about this plugin <a title="m2eclipse" href="http://eclipse.org/m2e/" target="_blank">here</a>.</p>
<h3>6. Installing m2eclipse-android-integration in SpringSource/Eclipse</h3>
<p>The sixth step is installing a plugin that binds android and maven together, m2eclipse-android-integration. This plugin is not included in SpringSource nor Eclipse so you have to install it manually. Click Help &lt; Install new software and add this repository.</p>
<blockquote><p>https://svn.codespot.com/a/eclipselabs.org/m2eclipse-android-integration/updates/m2eclipse-android-integration/</p></blockquote>
<p>Save it and select Maven Integration For Android Development Tools, proceed with the installation. Read more about this plugin <a title="m2eclipse-android-integration" href="http://code.google.com/a/eclipselabs.org/p/m2eclipse-android-integration/" target="_blank">here</a>.</p>
<h3>7. Creating an Emulator and downloading the SDK platform</h3>
<p>The seventh step in this tutorial is creating an emulator (like the iPhone simulator) where you will be running and testing your applications. Click Window &lt; Android SDK and AVD Manager. A new window will now appear. Select virtual devices in the left menu, then click the new button. You can now specify and create your own emulator. The most important step here is the target you choose, ie. the selected Android version you want to use on your emulator. I am currently using 2.2 or API level 8. But if you are developing for newer devices I recommend you to choose a higher API level. While you have the Android SDK and AVD Manager open you should also download your selected platform. Click Available packages &lt; Then expand the Android Repository &lt; Check the platform(s) you want &lt; Click install selected. The platforms will then be installed. To make things easy you can check the whole Android repository, this will of course use more harddrive space on your computer, but will of course give you the opportunity to develop against all the different API levels.</p>
<h3>8. Create your project with a Maven archetype</h3>
<p>We are now ready to create the Maven project you will be working on. Open eclipse or STS. Select New &lt; Other &lt; Maven project  &lt; Use default Workspace and select next &lt; We are going to use an archetype to simply create your project but we have to add the one we are using first &lt; Select add archetype and fill in this information.</p>
<blockquote>
<ol>
<li>In Archetype Group Id enter &#8220;de.akquinet.android.archetypes&#8221;</li>
<li>In Archetype Artifact Id&#8221; enter &#8220;android-quickstart&#8221;</li>
<li>In Archetype Version enter &#8220;1.0.5&#8243;</li>
</ol>
</blockquote>
<div>Click Ok and select the archetype you just created &lt; Click next &lt; Fill inn your project details, group id, artifact id, package name and your selected platform or API level. Click finish and your project is now created. The project will now appear in Eclipse or STS.</div>
<h3>9. What the POM should look like</h3>
<p>If you open your POM.xml now, you will see that the project will be built as an .apk package, wich is an Android specific package. You will also notice the Android dependency, and the Android Maven plugin.</p>
<h3>10. Running your project in SpringSource/Eclipse</h3>
<p>The application you now have should be runnable, try right-clicking the project and select run as android application. Hopefully you will now see a black screen and Hello &lt;your artifact id&gt; in your emulator.</p>
<h3>Troubleshooting</h3>
<h4>No Android SDK Found</h4>
<p>If you get this error read this <a title="No Android SDK Found" href="http://www.scratchmytail.com/2011/08/12/eclipse-no-android-sdk-path-could-be-found/" target="_blank">post</a>.</p>
<h4>The R problem</h4>
<p>&#8220;The R problem&#8221; is probably the most widespread  issue Android developers will stumble upon. The most common reason why you will get this error in your activity is because you have this import line.</p>
<blockquote><p>import android.R</p></blockquote>
<p>If you have this line, remove it. You should also check that the gen folder is generated in your project. Read more about this issue <a title="The R problem" href="http://stackoverflow.com/questions/885009/r-cannot-be-resolved-android-error" target="_blank">here</a>.</p>
<p><strong>Conversion to dalvik format failed: &#8230;.</strong></p>
<p>If you get this error open up eclipse.ini or STS.ini and change -Xms and -Xmx to these values:</p>
<blockquote><p>-Xms512m</p>
<p>-Xmx1024m</p></blockquote>
<h3>Conclusion</h3>
<p>I hope this guide may have helped you getting Eclipse/STS, Maven 2 and Android working like it should. Feel free to leave a comment below for an open and good discussion.</p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.scratchmytail.com/2011/08/26/the-ultimate-10-step-setup-eclipse-sts-android-maven/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Eclipse: No Android SDK path could be found</title>
		<link>http://www.scratchmytail.com/2011/08/12/eclipse-no-android-sdk-path-could-be-found/</link>
		<comments>http://www.scratchmytail.com/2011/08/12/eclipse-no-android-sdk-path-could-be-found/#comments</comments>
		<pubDate>Fri, 12 Aug 2011 07:28:08 +0000</pubDate>
		<dc:creator>ScratchMyTail</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[eclipse]]></category>
		<category><![CDATA[maven]]></category>
		<category><![CDATA[maven-android-plugin]]></category>
		<category><![CDATA[No Android SDK path could be found]]></category>
		<category><![CDATA[settings.xml]]></category>

		<guid isPermaLink="false">http://www.scratchmytail.com/?p=338</guid>
		<description><![CDATA[Life goes on and so does my Android development. Here is a solution for a common problem when Maven struggles to find the Android SDK. The error message that occurs: No Android SDK path could be found. You should create a settings.xml file in your ~.m2/ folder. (~/.m2/settings.xml). The file should contain the following content: [...]]]></description>
			<content:encoded><![CDATA[<p>Life goes on and so does my Android development. Here is a solution for a common problem when Maven struggles to find the Android SDK. The error message that occurs:</p>
<blockquote><p>No Android SDK path could be found.</p></blockquote>
<p>You should create a settings.xml file in your ~.m2/ folder. (~/.m2/settings.xml). The file should contain the following content:</p>
<blockquote>
<pre>&lt;settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd"&gt;
  &lt;profiles&gt;
    &lt;profile&gt;
      &lt;id&gt;android&lt;/id&gt;
        &lt;properties&gt;
          &lt;android.sdk.path&gt;
            PATH / TO / THE / ANDROID / SDK
          &lt;/android.sdk.path&gt;
        &lt;/properties&gt;
	  &lt;/profile&gt;
    &lt;/profiles&gt;
	&lt;activeProfiles&gt; &lt;!--make the profile active all the time --&gt;
      &lt;activeProfile&gt;android&lt;/activeProfile&gt;
	&lt;/activeProfiles&gt;
&lt;/settings&gt;</pre>
</blockquote>
<p>Replace the &#8220;PATH / TO..&#8221; with the path of your Android SDK folder. Read more over <a title="Maven-quick-start" href="http://pivotal.github.com/robolectric/maven-quick-start.html" target="_blank">here</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.scratchmytail.com/2011/08/12/eclipse-no-android-sdk-path-could-be-found/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>JUnit + maven-android-plugin</title>
		<link>http://www.scratchmytail.com/2011/08/08/junit-maven-android-plugin/</link>
		<comments>http://www.scratchmytail.com/2011/08/08/junit-maven-android-plugin/#comments</comments>
		<pubDate>Mon, 08 Aug 2011 12:18:03 +0000</pubDate>
		<dc:creator>ScratchMyTail</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[android]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[java.lang.RuntimeException: Stub!]]></category>
		<category><![CDATA[maven-android-plugin]]></category>

		<guid isPermaLink="false">http://www.scratchmytail.com/?p=334</guid>
		<description><![CDATA[The recommended way of performing tests on an Android project is to create a so called Android Test Project. I&#8217;m used to creating test packages the regular way with JUnit, by simply creating classes and putting them in the src/test/java folder. But this is not that smart when it comes to the Android platform. If [...]]]></description>
			<content:encoded><![CDATA[<p>The recommended way of performing tests on an Android project is to create a so called Android Test Project. I&#8217;m used to creating test packages the regular way with JUnit, by simply creating classes and putting them in the src/test/java folder. But this is not that smart when it comes to the Android platform. If you are going to use Android specific libraries in your test classes you should put them in the src/main/java path. If you don&#8217;t you will be ending up with this exception:</p>
<blockquote><p><tt>java.lang.RuntimeException: Stub!</tt></p></blockquote>
<p>But if you are not using any Android libraries in your tests you can put your test classes in the src/test/java folder. Then the JVM will execute them as regular tests. I think I will take a closer look on the Android Test Project way of doing tests.</p>
<p>Read more about this over <a title="Google Code - maven-android-plugin" href="http://code.google.com/p/maven-android-plugin/wiki/GettingStarted" target="_blank">here</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.scratchmytail.com/2011/08/08/junit-maven-android-plugin/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Compilation unit is not on the build path, Eclipse and STS Springsource</title>
		<link>http://www.scratchmytail.com/2011/07/27/compilation-unit-is-not-on-the-build-path-eclipse-and-sts-springsource/</link>
		<comments>http://www.scratchmytail.com/2011/07/27/compilation-unit-is-not-on-the-build-path-eclipse-and-sts-springsource/#comments</comments>
		<pubDate>Wed, 27 Jul 2011 10:02:46 +0000</pubDate>
		<dc:creator>ScratchMyTail</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[build path error]]></category>
		<category><![CDATA[checkout]]></category>
		<category><![CDATA[Compilation unit is not on the build path]]></category>
		<category><![CDATA[eclipse]]></category>
		<category><![CDATA[java project]]></category>
		<category><![CDATA[maven]]></category>
		<category><![CDATA[springsource]]></category>
		<category><![CDATA[sts]]></category>
		<category><![CDATA[subversion]]></category>
		<category><![CDATA[svn]]></category>

		<guid isPermaLink="false">http://www.scratchmytail.com/?p=325</guid>
		<description><![CDATA[Recently I&#8217;ve been struggling with an annoying error in SpringSource (Eclipse + Spring Framework). The error causes auto-completion to stop working, and a popup to occur containing this error message: &#8220;Compilation unit is not on the build path&#8221;. In this post I will share my solution to this problem. Most of the projects I&#8217;m working on are [...]]]></description>
			<content:encoded><![CDATA[<p>Recently I&#8217;ve been struggling with an annoying error in SpringSource (Eclipse + Spring Framework). The error causes auto-completion to stop working, and a popup to occur containing this error message: <em>&#8220;Compilation unit is not on the build path&#8221;. </em>In this post I will share my solution to this problem.</p>
<p><span id="more-325"></span>Most of the projects I&#8217;m working on are controlled by a Subversion repository. They are also using Maven for dependency management. I searched a bit around the web and didn&#8217;t really find that many solutions for this problem. The first thing I found out was that I needed to create a new local Java Project when checking out the project from svn. So this is basically how you should checkout your projects from SVN in eclipse or SpringSource STS to avoid this problem.</p>
<blockquote><p>File &lt; Import &lt; SVN &#8211; Checkout Projects From SVN &lt; Choose your repository &lt; Select the folder/trunk you want to checkout &lt; The crucial point, select the &#8220;&#8230;New Project Wizard&#8221; and Finish &lt; Now select Java and Java Project &lt; Finish.</p></blockquote>
<p>You should now have a local Java project containing the selected svn folder. You can now add Maven Dependency Management and Spring Project Nature to your project. Try opening a .java file and press ctrl-space. The error message should now be gone and auto-completion should be working.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.scratchmytail.com/2011/07/27/compilation-unit-is-not-on-the-build-path-eclipse-and-sts-springsource/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Using Maven 2 during Android development with Eclipse</title>
		<link>http://www.scratchmytail.com/2011/04/08/using-maven-2-during-android-development-with-eclipse/</link>
		<comments>http://www.scratchmytail.com/2011/04/08/using-maven-2-during-android-development-with-eclipse/#comments</comments>
		<pubDate>Fri, 08 Apr 2011 11:28:13 +0000</pubDate>
		<dc:creator>ScratchMyTail</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[android]]></category>
		<category><![CDATA[eclipse]]></category>
		<category><![CDATA[maven 2]]></category>
		<category><![CDATA[plugin]]></category>

		<guid isPermaLink="false">http://www.scratchmytail.com/?p=285</guid>
		<description><![CDATA[Here is a quick and clean tutorial on how to set up and use Maven 2 when developing for Android in Eclipse. This tutorial will not cover the steps of installing Eclipse 2.6 and the Android SDK. Step 1: Installing Maven 2 in Eclipse Before you can start creating your own Maven 2 projects you [...]]]></description>
			<content:encoded><![CDATA[<p>Here is a quick and clean tutorial on how to set up and use Maven 2 when developing for Android in Eclipse. This tutorial will not cover the steps of installing Eclipse 2.6 and the Android SDK.</p>
<p><span id="more-285"></span></p>
<h3>Step 1: Installing Maven 2 in Eclipse</h3>
<p>Before you can start creating your own Maven 2 projects you need to install a plug-in. The plug-in is called AIM. So open Eclipse and follow this steps.</p>
<p>Press Help &lt; Install new software &lt; Press Add &lt; Location &#8220;http://q4e.googlecode.com/svn/trunk/updatesite-iam/&#8221; &lt; Give it a name &lt; Press OK &lt; Select the newly added site &#8220;Work with&#8221; &lt; A couple of navigators will appear, select Core features and select Eclipse AIM &lt; Click next. Continue clicking next and finish until it is installed &lt; Restart Eclipse.</p>
<p>The Maven 2 plug-in AIM is now installed. You can now open and create Maven 2 projects in Eclipse. The next step is to create a project.</p>
<p>&nbsp;</p>
<h3>Step 2: Creating a Maven 2 project</h3>
<p>You can easily create a Maven 2 project in the terminal by typing these commands:</p>
<blockquote><p>mvn archetype:generate \<br />
-DarchetypeArtifactId=android-quickstart \<br />
-DarchetypeGroupId=de.akquinet.android.archetypes \<br />
-DarchetypeVersion=1.0.5 \<br />
-DgroupId=your.company \<br />
-DartifactId=my-android-application</p></blockquote>
<p>These commands will create a simple &#8220;Hello World&#8221; application that can run on a phone or in the emulator. The next step is deploying the application.</p>
<p>&nbsp;</p>
<h3>Step 3: Deploying the application</h3>
<p>Navigate into the application folder in your workspace and type this command:</p>
<blockquote><p>mvn clean install android:deploy</p></blockquote>
<p>The application will now be installed on the connected device.</p>
<p>&nbsp;</p>
<p><span style="font-size: 15px; font-weight: bold;">Tips</span></p>
<p>Before you deploy the application on the device you must start the ADB service as root. Navigate to your Android SDK folder and into the platform-tools folder. Run these commands to check that everything is ready for deployment.</p>
<blockquote><p>sudo ./adb kill-server<br />
sudo ./adb start-server<br />
sudo ./adb devices</p></blockquote>
<p>When you execute the devices command you should see an ID referring to the connected device. If you get question marks something is wrong, try the same commands over again. If you try the maven deploy command with question marks you will get some errors from Maven.</p>
<p>You should also remember to change the platform number in the pom.xml file. For instance, if you&#8217;re using SDK 2.2.1 it should be:</p>
<blockquote><p>&lt;sdk&gt;<br />
&lt;platform&gt;8&lt;/platform&gt;<br />
&lt;/sdk&gt;</p></blockquote>
<p>&nbsp;</p>
<p>Sources:</p>
<ul>
<li><a href="http://code.google.com/p/q4e/wiki/Installation">http://code.google.com/p/q4e/wiki/Installation</a></li>
<li><a href="https://github.com/akquinet/android-archetypes/wiki">https://github.com/akquinet/android-archetypes/wiki</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.scratchmytail.com/2011/04/08/using-maven-2-during-android-development-with-eclipse/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Make your code look beautiful with Pygmentize</title>
		<link>http://www.scratchmytail.com/2010/05/23/make-your-code-look-beautiful-with-pygmentize/</link>
		<comments>http://www.scratchmytail.com/2010/05/23/make-your-code-look-beautiful-with-pygmentize/#comments</comments>
		<pubDate>Sun, 23 May 2010 12:18:35 +0000</pubDate>
		<dc:creator>ScratchMyTail</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[latex]]></category>
		<category><![CDATA[listings]]></category>
		<category><![CDATA[minted]]></category>
		<category><![CDATA[pretty]]></category>
		<category><![CDATA[pygmentize]]></category>
		<category><![CDATA[pygments]]></category>
		<category><![CDATA[source code]]></category>

		<guid isPermaLink="false">http://www.scratchmytail.com/?p=249</guid>
		<description><![CDATA[Ever wanted your source code listings to look the same in your blog as in your favorite IDE? It&#8217;s now possible with a Python syntax highlighter, called Pygmentize. Pygmentize is a syntax highlighter written in Python. It can be used as a simple command line tool, as well as being reached from Python scripts. In [...]]]></description>
			<content:encoded><![CDATA[<p>Ever wanted your source code listings to look the same in your blog as in your favorite IDE? It&#8217;s now possible with a Python syntax highlighter, called <em>Pygmentize</em>.</p>
<p><a title="Pygmentize home page" href="http://pygments.org/">Pygmentize</a> is a syntax highlighter written in Python. It can be used as a simple command line tool, as well as being reached from Python scripts.</p>
<p>In the following example I want to highlight a JavaScript file. I tell pygmentize to output HTML:</p>
<blockquote><p>pygmentize -f html -o example.html example.js</p></blockquote>
<p>The command above generated this output (I simply imported the HTML created by Pygmentize into my blog post).</p>
<p><b></p>
<blockquote>
<style type="text/css">
td.linenos { background-color: #f0f0f0; padding-right: 10px; }
span.lineno { background-color: #f0f0f0; padding: 0 5px 0 5px; }
pre { line-height: 125%; }
body .hll { background-color: #ffffcc }
body  { background: #f8f8f8; }
body .c { color: #408080; font-style: italic } /* Comment */
body .err { border: 1px solid #FF0000 } /* Error */
body .k { color: #008000; font-weight: bold } /* Keyword */
body .o { color: #666666 } /* Operator */
body .cm { color: #408080; font-style: italic } /* Comment.Multiline */
body .cp { color: #BC7A00 } /* Comment.Preproc */
body .c1 { color: #408080; font-style: italic } /* Comment.Single */
body .cs { color: #408080; font-style: italic } /* Comment.Special */
body .gd { color: #A00000 } /* Generic.Deleted */
body .ge { font-style: italic } /* Generic.Emph */
body .gr { color: #FF0000 } /* Generic.Error */
body .gh { color: #000080; font-weight: bold } /* Generic.Heading */
body .gi { color: #00A000 } /* Generic.Inserted */
body .go { color: #808080 } /* Generic.Output */
body .gp { color: #000080; font-weight: bold } /* Generic.Prompt */
body .gs { font-weight: bold } /* Generic.Strong */
body .gu { color: #800080; font-weight: bold } /* Generic.Subheading */
body .gt { color: #0040D0 } /* Generic.Traceback */
body .kc { color: #008000; font-weight: bold } /* Keyword.Constant */
body .kd { color: #008000; font-weight: bold } /* Keyword.Declaration */
body .kn { color: #008000; font-weight: bold } /* Keyword.Namespace */
body .kp { color: #008000 } /* Keyword.Pseudo */
body .kr { color: #008000; font-weight: bold } /* Keyword.Reserved */
body .kt { color: #B00040 } /* Keyword.Type */
body .m { color: #666666 } /* Literal.Number */
body .s { color: #BA2121 } /* Literal.String */
body .na { color: #7D9029 } /* Name.Attribute */
body .nb { color: #008000 } /* Name.Builtin */
body .nc { color: #0000FF; font-weight: bold } /* Name.Class */
body .no { color: #880000 } /* Name.Constant */
body .nd { color: #AA22FF } /* Name.Decorator */
body .ni { color: #999999; font-weight: bold } /* Name.Entity */
body .ne { color: #D2413A; font-weight: bold } /* Name.Exception */
body .nf { color: #0000FF } /* Name.Function */
body .nl { color: #A0A000 } /* Name.Label */
body .nn { color: #0000FF; font-weight: bold } /* Name.Namespace */
body .nt { color: #008000; font-weight: bold } /* Name.Tag */
body .nv { color: #19177C } /* Name.Variable */
body .ow { color: #AA22FF; font-weight: bold } /* Operator.Word */
body .w { color: #bbbbbb } /* Text.Whitespace */
body .mf { color: #666666 } /* Literal.Number.Float */
body .mh { color: #666666 } /* Literal.Number.Hex */
body .mi { color: #666666 } /* Literal.Number.Integer */
body .mo { color: #666666 } /* Literal.Number.Oct */
body .sb { color: #BA2121 } /* Literal.String.Backtick */
body .sc { color: #BA2121 } /* Literal.String.Char */
body .sd { color: #BA2121; font-style: italic } /* Literal.String.Doc */
body .s2 { color: #BA2121 } /* Literal.String.Double */
body .se { color: #BB6622; font-weight: bold } /* Literal.String.Escape */
body .sh { color: #BA2121 } /* Literal.String.Heredoc */
body .si { color: #BB6688; font-weight: bold } /* Literal.String.Interpol */
body .sx { color: #008000 } /* Literal.String.Other */
body .sr { color: #BB6688 } /* Literal.String.Regex */
body .s1 { color: #BA2121 } /* Literal.String.Single */
body .ss { color: #19177C } /* Literal.String.Symbol */
body .bp { color: #008000 } /* Name.Builtin.Pseudo */
body .vc { color: #19177C } /* Name.Variable.Class */
body .vg { color: #19177C } /* Name.Variable.Global */
body .vi { color: #19177C } /* Name.Variable.Instance */
body .il { color: #666666 } /* Literal.Number.Integer.Long */
</style>
<div class="highlight">
<pre>
<span class="k">if</span> <span class="p">(</span><span class="nx">time</span> <span class="o">&lt;</span> <span class="mi">10</span><span class="p">)</span>
<span class="p">{</span>
    <span class="nb">document</span><span class="p">.</span><span class="nx">write</span><span class="p">(</span><span class="s2">&quot;&lt;b&gt;Good morning&lt;/b&gt;&quot;</span><span class="p">);</span>
<span class="p">}</span>
<span class="k">else</span>
<span class="p">{</span>
    <span class="nb">document</span><span class="p">.</span><span class="nx">write</span><span class="p">(</span><span class="s2">&quot;&lt;b&gt;Good day&lt;/b&gt;&quot;</span><span class="p">);</span>
<span class="p">}</span></pre>
</div>
</blockquote>
<p></b><br />
Take a closer look in the <a href="http://pygments.org/docs/quickstart/">quickstart</a> guide for more details on the command line tool, and how to use it in Python scripts. A package  called <a href="http://code.google.com/p/minted/">Minted</a> that utilizes pygmentize can be used to list source code in <em>LaTeX</em>. I used it in my Master thesis, and it looks so much better than the default <em>lstlistings</em>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.scratchmytail.com/2010/05/23/make-your-code-look-beautiful-with-pygmentize/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>My first iPhone application</title>
		<link>http://www.scratchmytail.com/2010/03/13/my-first-iphone-application/</link>
		<comments>http://www.scratchmytail.com/2010/03/13/my-first-iphone-application/#comments</comments>
		<pubDate>Sat, 13 Mar 2010 18:15:45 +0000</pubDate>
		<dc:creator>ScratchMyTail</dc:creator>
				<category><![CDATA[development]]></category>
		<category><![CDATA[iPhone]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[tv-lista]]></category>

		<guid isPermaLink="false">http://www.scratchmytail.com/?p=244</guid>
		<description><![CDATA[My first application developed for the iPhone is now available in AppStore. Read more about the application here. You can also take a closer look in iTunes via this link.]]></description>
			<content:encoded><![CDATA[<p>My first application developed for the iPhone is now available in AppStore. Read more about the application <a href="http://www.scratchmytail.com/tvlista">here</a>. You can also take a closer look in iTunes via this <a href="http://appsto.re/TV-Lista">link</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.scratchmytail.com/2010/03/13/my-first-iphone-application/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Storing custom objects to disk on the iPhone</title>
		<link>http://www.scratchmytail.com/2009/11/06/storing-custom-objects-to-disk-on-the-iphone/</link>
		<comments>http://www.scratchmytail.com/2009/11/06/storing-custom-objects-to-disk-on-the-iphone/#comments</comments>
		<pubDate>Fri, 06 Nov 2009 13:18:13 +0000</pubDate>
		<dc:creator>ScratchMyTail</dc:creator>
				<category><![CDATA[development]]></category>
		<category><![CDATA[iPhone]]></category>
		<category><![CDATA[load array]]></category>
		<category><![CDATA[NSCoder]]></category>
		<category><![CDATA[NSCoding]]></category>
		<category><![CDATA[save array]]></category>
		<category><![CDATA[serialize objects]]></category>

		<guid isPermaLink="false">http://www.scratchmytail.com/?p=181</guid>
		<description><![CDATA[In this tutorial I will show you how you can store custom objects to disk on the iPhone. I will create a simple array containing custom Person objects. Then I will store the array to disk and afterwards load the array. The clue is to implement the NSCoding protocol in the Person class, or the [...]]]></description>
			<content:encoded><![CDATA[<p>In this tutorial I will show you how you can store custom objects to disk on the iPhone. I will create a simple array containing custom Person objects. Then I will store the array to disk and afterwards load the array. The clue is to implement the NSCoding protocol in the Person class, or the classes of the objects that we have in our array or dictionary. It&#8217;s quite simple actually.</p>
<p><span id="more-181"></span></p>
<h3>Person.h</h3>
<p>In the code below we define the interface of the Person class. Notice the NSCoding protocol in the interface header.</p>
<blockquote><p>@interface Person : NSObject &lt;NSCoding&gt; { NSString *firstName; NSString *secondName; NSString *phone; } @property (nonatomic, retain)NSString *firstName; @property (nonatomic, retain)NSString *lastName; @property (nonatomic, retain)NSString *phone;</p></blockquote>
<h3>Person.m</h3>
<p>In the code below we can see the person implementation. Notice the implementation of the NSCoding protocol. We have to implement two methods, <em>encodeWithCoder</em> and <em>initWithCoder</em>. We tell the NSCoding protocol that we want to decode and encode all of the person&#8217;s members. We give the objects keys in the first method so that we are able to find them again later when we decode.</p>
<blockquote><p>@implementation Person @synthesize firstName, secondName, phone; &#8211; (void)encodeWithCoder:(NSCoder *)encoder { [encoder encodeObject:firstName forKey:@"firstName"]; [encoder encodeObject:lastName forKey:@"lastName"]; [encoder encodeObject:phone forKey:@"phone"]; } &#8211; (id)initWithCoder:(NSCoder *)decoder { if (self = [super init]) { self.firstName = [decoder decodeObjectForKey:@"firstName"]; self.lastName = [decoder decodeObjectForKey:@"lastName"]; self.phone = [decoder decodeObjectForKey:@"phone"]; } return self; }</p></blockquote>
<h3>Saving and loading an array</h3>
<p>In the code below we populate an array with two person objects, then we save the array to disk and afterwards load it.</p>
<blockquote><p>// Create two person objects Person *person1 = [[Person alloc] init]; person1.firstName = @&#8221;Peter&#8221;; person1.lastName = @&#8221;Peterson&#8221;; person1.phone = @&#8221;12345678&#8243;; Person *person2 = [[Person alloc] init]; person2.firstName = @&#8221;Andrea&#8221;; person2.lastName = @&#8221;Peterson&#8221;; person2.phone = @&#8221;12345687&#8243;; // Put them into an array NSArray *array = [[NSArray alloc] initWithObjects:person1, person2, nil]; // Save the array NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES); NSString *docDir = [paths objectAtIndex:0]; NSString *fullFileName = [NSString stringWithFormat:@"%@/ourArray", docDir]; [NSKeyedArchiver archiveRootObject:array toFile:fullFileName]; // Load the array NSMutableArray *arrayFromDisk = [NSKeyedUnarchiver unarchiveObjectWithFile:fullFileName];</p></blockquote>
<h3>Conclusion</h3>
<p>Follow this tutorial if you want to save your arrays or dictionaries to disk for later use. Following this method is very simple and it actually works. I&#8217;ve read alot of different tutorials on the web, most of them suggest storing your objects either as .plist files or by using SQLite. I think following this method is both easy and efficient. Read more about the NSCoding protocol <a title="NSCoding" href="http://developer.apple.com/mac/library/documentation/cocoa/Reference/Foundation/Protocols/NSCoding_Protocol/Reference/Reference.html">here</a>.</p>
<p>EDIT: There was a bug in my code. fullFileName was missing %@/ in the stringWithFormat message.</p>
<p>EDIT 2: For storing a lot of data I will recommend CoreData. Store and retrieve regular objects.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.scratchmytail.com/2009/11/06/storing-custom-objects-to-disk-on-the-iphone/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	<img style='margin:0;padding:0;border:0;' width='1px' height='1px' src="http://www.scratchmytail.com/wp-content/plugins/mystat/mystat.php?act=time_load&id=87129&rnd=227873400" /></channel>
</rss>

