<?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>Cory Hardman&#039;s Blog &#187; Help</title>
	<atom:link href="http://www.coryhardman.com/category/help/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.coryhardman.com</link>
	<description></description>
	<lastBuildDate>Mon, 07 Nov 2011 04:51:13 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Dual Monitor Aero Snap in Ubuntu</title>
		<link>http://www.coryhardman.com/2010/12/dual-monitor-aero-snap-in-ubuntu/</link>
		<comments>http://www.coryhardman.com/2010/12/dual-monitor-aero-snap-in-ubuntu/#comments</comments>
		<pubDate>Sun, 19 Dec 2010 00:14:49 +0000</pubDate>
		<dc:creator>Cory Hardman</dc:creator>
				<category><![CDATA[Help]]></category>

		<guid isPermaLink="false">http://www.coryhardman.com/?p=241</guid>
		<description><![CDATA[I think the coolest thing about Windows 7 is Aero Snap. It really helps you get more efficient use of your screen real estate without you have to manually resize your windows. The good people at OMG! Ubuntu posted a great tutorial on how to get Aero Snap in Ubuntu. I followed the tutorial and got my laptop [...]]]></description>
			<content:encoded><![CDATA[<p>I think the coolest thing about Windows 7 is Aero Snap. It really helps you get more efficient use of your screen real estate without you have to manually resize your windows. The good people at <a href="http://www.omgubuntu.co.uk/">OMG! Ubuntu</a> posted a great tutorial on how to <a href="http://www.omgubuntu.co.uk/2009/11/get-aero-snap-in-ubuntu/">get Aero Snap in Ubuntu</a>. I followed the tutorial and got my laptop snapping perfectly. I was not so lucky on my dual monitor desktop. So I have modified the script slightly to make it so it will now work on dual screen monitors. Most of this is exactly the same as the OMG! Ubuntu tutorial, so if you feel I didn't explain something clearly you should reference theirs.</p>
<p>Step 1 - Install Compiz Config</p>
<pre class="bash">&nbsp;
<span style="color: #c20cb9; font-weight: bold;">sudo</span> apt-get <span style="color: #c20cb9; font-weight: bold;">install</span> compizconfig-settings-manager wmctrl
&nbsp;</pre>
<p>Step 2 - Set up the commands</p>
<ul>
<li>Open the Compiz Config manager (System -&gt; preferences -&gt; CompizConfig Settings Manager)</li>
<li>Select the "Commands" option</li>
<li>In "Command Line 0" past:</li>
</ul>
<pre class="bash">&nbsp;
<span style="color: #007800;">WIDTH=</span>`xdpyinfo | <span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #ff0000;">'dimensions:'</span> | <span style="color: #c20cb9; font-weight: bold;">cut</span> -f <span style="color: #000000;">2</span> -d <span style="color: #ff0000;">':'</span> | <span style="color: #c20cb9; font-weight: bold;">cut</span> -f <span style="color: #000000;">1</span> -d <span style="color: #ff0000;">'x'</span>` &amp;&amp; <span style="color: #007800;">HALF=</span>$<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #007800;">$WIDTH</span>/<span style="color: #000000;">4</span><span style="color: #7a0874; font-weight: bold;">&#41;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> &amp;&amp; wmctrl -r :ACTIVE: -b add,maximized_vert &amp;&amp; wmctrl -r :ACTIVE: -e <span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #007800;">$HALF</span>,<span style="color: #000000;">-1</span>
&nbsp;</pre>
<ul>
<li>In "Command Line 1" past:</li>
</ul>
<pre class="bash">&nbsp;
<span style="color: #007800;">WIDTH=</span>`xdpyinfo | <span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #ff0000;">'dimensions:'</span> | <span style="color: #c20cb9; font-weight: bold;">cut</span> -f <span style="color: #000000;">2</span> -d <span style="color: #ff0000;">':'</span> | <span style="color: #c20cb9; font-weight: bold;">cut</span> -f <span style="color: #000000;">1</span> -d <span style="color: #ff0000;">'x'</span>` &amp;&amp; <span style="color: #007800;">HALF=</span>$<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #007800;">$WIDTH</span>/<span style="color: #000000;">4</span><span style="color: #7a0874; font-weight: bold;">&#41;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> &amp;&amp; <span style="color: #007800;">LOCATION=</span>$<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #007800;">$WIDTH</span>-<span style="color: #007800;">$HALF</span><span style="color: #7a0874; font-weight: bold;">&#41;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> &amp;&amp; wmctrl -r :ACTIVE: -b add,maximized_vert &amp;&amp; wmctrl -r :ACTIVE: -e <span style="color: #000000;">0</span>,<span style="color: #007800;">$LOCATION</span>,<span style="color: #000000;">0</span>,<span style="color: #007800;">$HALF</span>,<span style="color: #000000;">-1</span>
&nbsp;</pre>
<ul>
<li>In "Command Line 2" past:</li>
</ul>
<pre class="bash">&nbsp;
wmctrl -r :ACTIVE: -b add,maximized_vert,maximized_horz
&nbsp;</pre>
<p>Step 3 - Enable the commands<br />
Go to the 'Edge Bindings' tab and set the following:</p>
<ul>
<li>Run Command 0 - Set to Left</li>
<li>Run Command 1 - Set to Right</li>
<li>Run Command 2 - Set to Top</li>
</ul>
<p>Good luck, let me know if you have any questions.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.coryhardman.com/2010/12/dual-monitor-aero-snap-in-ubuntu/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>in_addr to string(char*)</title>
		<link>http://www.coryhardman.com/2010/12/in_addr-to-stringchar/</link>
		<comments>http://www.coryhardman.com/2010/12/in_addr-to-stringchar/#comments</comments>
		<pubDate>Sat, 04 Dec 2010 23:56:39 +0000</pubDate>
		<dc:creator>Cory Hardman</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Help]]></category>

		<guid isPermaLink="false">http://www.coryhardman.com/?p=217</guid>
		<description><![CDATA[The other day I needed to turn a IPv4 address to a string in C. I figured some others would find it useful: &#160; char* hexToCharIP&#40;struct in_addr addrIP&#41; &#123; char* ip; unsigned int intIP; memcpy&#40;&#38;intIP, &#38;addrIP,sizeof&#40;unsigned int&#41;&#41;; int a = &#40;intIP &#62;&#62; 24&#41; &#38; 0xFF; int b = &#40;intIP &#62;&#62; 16&#41; &#38; 0xFF; int c [...]]]></description>
			<content:encoded><![CDATA[<p>The other day I needed to turn a IPv4 address to a string in C. I figured some others would find it useful:</p>
<pre class="c">&nbsp;
<span style="color: #993333;">char</span>* hexToCharIP<span style="color: #66cc66;">&#40;</span><span style="color: #993333;">struct</span> in_addr addrIP<span style="color: #66cc66;">&#41;</span>
<span style="color: #66cc66;">&#123;</span>
  <span style="color: #993333;">char</span>* ip;
  <span style="color: #993333;">unsigned</span> <span style="color: #993333;">int</span> intIP;
  memcpy<span style="color: #66cc66;">&#40;</span>&amp;intIP, &amp;addrIP,<span style="color: #993333;">sizeof</span><span style="color: #66cc66;">&#40;</span><span style="color: #993333;">unsigned</span> <span style="color: #993333;">int</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#41;</span>;
  <span style="color: #993333;">int</span> a = <span style="color: #66cc66;">&#40;</span>intIP &gt;&gt; <span style="color: #cc66cc;">24</span><span style="color: #66cc66;">&#41;</span> &amp; 0xFF;
  <span style="color: #993333;">int</span> b = <span style="color: #66cc66;">&#40;</span>intIP &gt;&gt; <span style="color: #cc66cc;">16</span><span style="color: #66cc66;">&#41;</span> &amp; 0xFF;
  <span style="color: #993333;">int</span> c = <span style="color: #66cc66;">&#40;</span>intIP &gt;&gt; &lt;img src=<span style="color: #ff0000;">'http://www.coryhardman.com/wp-includes/images/smilies/icon_cool.gif'</span> alt=<span style="color: #ff0000;">'8)'</span> class=<span style="color: #ff0000;">'wp-smiley'</span> /&gt; &amp; 0xFF;
  <span style="color: #993333;">int</span> d = intIP &amp; 0xFF;
  <span style="color: #b1b100;">if</span><span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#40;</span>ip = <span style="color: #66cc66;">&#40;</span><span style="color: #993333;">char</span>*<span style="color: #66cc66;">&#41;</span>malloc<span style="color: #66cc66;">&#40;</span><span style="color: #cc66cc;">16</span>*<span style="color: #993333;">sizeof</span><span style="color: #66cc66;">&#40;</span><span style="color: #993333;">char</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#41;</span> == <span style="color: #000000; font-weight: bold;">NULL</span><span style="color: #66cc66;">&#41;</span>
  <span style="color: #66cc66;">&#123;</span>
    <span style="color: #b1b100;">return</span> <span style="color: #000000; font-weight: bold;">NULL</span>;
  <span style="color: #66cc66;">&#125;</span>
  sprintf<span style="color: #66cc66;">&#40;</span>ip, <span style="color: #ff0000;">&quot;%d.%d.%d.%d&quot;</span>, d,c,b,a<span style="color: #66cc66;">&#41;</span>;
  <span style="color: #b1b100;">return</span> ip;
<span style="color: #66cc66;">&#125;</span>
&nbsp;</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.coryhardman.com/2010/12/in_addr-to-stringchar/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Syncing Music to Nexus One in Ubuntu 10.04</title>
		<link>http://www.coryhardman.com/2010/08/syncing-music-to-nexus-one-in-ubuntu-10-04/</link>
		<comments>http://www.coryhardman.com/2010/08/syncing-music-to-nexus-one-in-ubuntu-10-04/#comments</comments>
		<pubDate>Thu, 12 Aug 2010 15:40:28 +0000</pubDate>
		<dc:creator>Cory Hardman</dc:creator>
				<category><![CDATA[Help]]></category>

		<guid isPermaLink="false">http://www.coryhardman.com/?p=186</guid>
		<description><![CDATA[Ubuntu 10.04 has really improved over previous versions of Ubuntu in the syncing to devices support. In particular support for syncing music to IPhones and ITouches. They have also added support to Rhythmbox to reconize when a Nexus One has been connected to the machine (this may also work on other Android devices, I've just [...]]]></description>
			<content:encoded><![CDATA[<p>Ubuntu 10.04 has really improved over previous versions of Ubuntu in the syncing to devices support. In particular support for syncing music to IPhones and ITouches. They have also added support to <a href="http://projects.gnome.org/rhythmbox/">Rhythmbox</a> to reconize when a Nexus One has been connected to the machine (this may also work on other Android devices, I've just not tested others).</p>
<p>When you plug your phone into your Ubuntu 10.04 box, on your Nexus One an alert will appear asking you if you'd like to enable USB storage. Once you have enabled this, the Ubuntu system will see the phone has a USB mass storage device. Now you should be able to download all of your pictures and in Rhythmbox the phone appear on the device list. You can just drag and drop your music like you would for a playlist.</p>
<p>Since Ubuntu is treating the phone as a mass storage device, Rhytmbox does not know by default where to upload the music. So it defaults to the root of the SD card. If you would like to not fill the root up with all of your music you can opt to put all of your music into a music folder. To do this, you need to upload one song to the Nexus One, then open up the device in a file manager. Create a new directory called "music" and move the one song you uploaded to that folder. Now Rhythmbox will be smart enough to know to upload to the "music" folder and all the media applications on the Nexus One will auto detect the music in the "music" folder.</p>
<p>If you are looking for a good music player I have become a big fan of <a href="http://www.doubletwist.com/dt/Home/Index.dt">DoubleTwist</a>. Plus if you are on Windows or a Mac you can use the DoubleTwist desktop client to manage music on the phone.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.coryhardman.com/2010/08/syncing-music-to-nexus-one-in-ubuntu-10-04/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>OpenVPN in Windows 7</title>
		<link>http://www.coryhardman.com/2010/07/openvpn-in-windows-7/</link>
		<comments>http://www.coryhardman.com/2010/07/openvpn-in-windows-7/#comments</comments>
		<pubDate>Fri, 09 Jul 2010 06:13:39 +0000</pubDate>
		<dc:creator>Cory Hardman</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Help]]></category>

		<guid isPermaLink="false">http://www.coryhardman.com/?p=150</guid>
		<description><![CDATA[I often need to work remotely from work, luckily my work has a VPN server that allows me to get access to the companies internal resources. I have been using OpenVPN in Windows XP for a long time to do this, through the use of OpenVPN GUI. Well when I got a new laptop it [...]]]></description>
			<content:encoded><![CDATA[<p>I often need to work remotely from work, luckily my work has a VPN server that allows me to get access to the companies internal resources. I have been using <a href="http://openvpn.net/">OpenVPN</a> in Windows XP for a long time to do this, through the use of <a href="http://openvpn.se/">OpenVPN GUI</a>. Well when I got a new laptop it came with Windows 7 installed. So one of the first things I did was set up my development environment which required me to get into some of the file shares inside of my companies network. I thought it wouldn't be a problem at all to do, I installed OpenVPN GUI and just copied over my configuration and key files. When I went to connect I got quite an interesting error:</p>
<blockquote>
<div id="_mcePaste">Thu Jul 08 23:05:33 2010 ROUTE: route addition failed using CreateIpForwardEntry: One or more arguments are not correct.   [if_index=16]</div>
</blockquote>
<div>It turns out to be very simple to fix. In Windows 7 and I believe in Vista you need to do a few extra steps to get OpenVPN GUI to work with Windows 7. First you need to go C:\Program Files\OpenVPN\Bin and make sure openvpn-gui.exe is always started as Administrator (in the compatibility menu of the file properties). Then you will need to edit your configuration file and add two lines after the line that describes your cipher:</div>
<blockquote>
<div>
<div>route-method exe</div>
<div>route-delay 2</div>
</div>
</blockquote>
<div>That should do it. Let me know if you have any questions.</div>
]]></content:encoded>
			<wfw:commentRss>http://www.coryhardman.com/2010/07/openvpn-in-windows-7/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Nexus One Support in Ubuntu 10.04</title>
		<link>http://www.coryhardman.com/2010/07/nexus-one-support-in-ubuntu-10-04/</link>
		<comments>http://www.coryhardman.com/2010/07/nexus-one-support-in-ubuntu-10-04/#comments</comments>
		<pubDate>Wed, 07 Jul 2010 01:16:09 +0000</pubDate>
		<dc:creator>Cory Hardman</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Help]]></category>

		<guid isPermaLink="false">http://www.coryhardman.com/?p=139</guid>
		<description><![CDATA[I recently purchased the Nexus One from Google. It is quite an amazing phone and I've been really happy with it. I've taken interest in developing for the Android platform now that I have one. Luckily Google has provided a very good resource for Android app development at http://developer.android.com/. Today I was working on allowing [...]]]></description>
			<content:encoded><![CDATA[<p>I recently purchased the Nexus One from Google. It is quite an amazing phone and I've been really happy with it. I've taken interest in developing for the Android platform now that I have one. Luckily Google has provided a very good resource for Android app development at <a href="http://developer.android.com/index.html">http://developer.android.com/</a>.</p>
<p>Today I was working on allowing me to upload my applications onto my Nexus One so that I could test the software on a real device. Well I ran into an issue after following Google's tutorial on how to do it located <a href="http://developer.android.com/guide/developing/device.html">here</a>. I run Ubuntu 10.04 on my main development machine and so I followed the instructs for how to do it for Linux. Well when I got to the end of the tutorial when it tells you to test your the setup with the following command:</p>
<blockquote><p>adb devices</p></blockquote>
<p>I got the following output:</p>
<blockquote>
<div id="_mcePaste">List of devices attached</div>
<div id="_mcePaste">????????????	no permissions</div>
</blockquote>
<div>It turns out that Google's instructions have not been updated so reflect how to get the Nexus One to work under Linux. Well after a bit of research I came across the following blog <a href="http://dansyrstad.com/2010/01/09/getting-nexus-one-working-with-usb-on-ubuntu/">post</a> that explained it. Basically the list of USB Vendor IDs does not have listed the proper value for the Nexus One. I had selected to use HTC's Vendor ID ("0bb4"<span style="font-family: 'Lucida Grande', Verdana, Arial, sans-serif; color: #333333; font-size: small;"><span style="line-height: 16px;">)</span></span> being that the Nexus One is actually produced by HTC, however that is incorrect. Instead you need to use the Vendor ID of "18d1". So the following line should be in /etc/udev/rules.d/51-android.rules</div>
<blockquote>
<div>SUBSYSTEM=="usb", SYSFS{idVendor}=="18d1", MODE="0666"</div>
</blockquote>
<div>NOTE: Be sure not to capitalize the D in 18<strong>d</strong>1, doing this will cause this solution not to work.</div>
<div>Now that you have added that line to the file, you will simply need to restart udev. With the Nexus One unplugged from your system run this command:</div>
<blockquote>
<div>
<div>sudo service udev restart</div>
</div>
</blockquote>
<div>Now you can plug in your Nexus One and run:</div>
<blockquote>
<div>adb devices</div>
</blockquote>
<div>You should see something like this:</div>
<blockquote>
<div>List of devices attached</div>
<div>????????????????<span style="white-space: pre;"> </span>device</div>
</blockquote>
<div>I hope this helps and post below if you need any further help.</div>
]]></content:encoded>
			<wfw:commentRss>http://www.coryhardman.com/2010/07/nexus-one-support-in-ubuntu-10-04/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

