<?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>FettesPS</title>
	<atom:link href="http://www.fettesps.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.fettesps.com</link>
	<description>Fettes Programming Solutions</description>
	<lastBuildDate>Sun, 22 Jan 2012 18:21:51 +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>Download Every File of a Certain Extension on a Site</title>
		<link>http://www.fettesps.com/download-every-file-of-a-certain-extension-on-a-site/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=download-every-file-of-a-certain-extension-on-a-site</link>
		<comments>http://www.fettesps.com/download-every-file-of-a-certain-extension-on-a-site/#comments</comments>
		<pubDate>Sun, 22 Jan 2012 18:21:51 +0000</pubDate>
		<dc:creator>FettesPS</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[stock music]]></category>
		<category><![CDATA[video]]></category>
		<category><![CDATA[wget]]></category>

		<guid isPermaLink="false">http://www.fettesps.com/?p=1754</guid>
		<description><![CDATA[Today I was editing some video for Youtube and was looking for some free stock music. I ended up at a site I&#8217;ve seen many times before, DanoSongs.com, but haven&#8217;t really ended up using since finding a song involves going through a long list and playing them in an embedded player and then downloading the [...]]]></description>
			<content:encoded><![CDATA[<p>Today I was editing some video for Youtube and was looking for some free stock music. I ended up at a site I&#8217;ve seen many times before, <a href="http://www.danosongs.com">DanoSongs.com</a>, but haven&#8217;t really ended up using since finding a song involves going through a long list and playing them in an embedded player and then downloading the one you want.  What I wanted to do was download every MP3 and put them in a folder that I have full of stock music and then when inside my video editing software I can preview it along with the rest.  So here&#8217;s the command I used:</p>
<pre class="brush: plain; title: ; notranslate">wget -r -l1 -H -t1 -nd -N -np -A.mp3 -erobots=off http://www.danosongs.com/</pre>
<p>This is of course done with wget, a powerful command line utility for Linux. To tweak the command all you need to do is replace the URL with the page you&#8217;d like to scrape and then replace &#8220;mp3&#8243; with whatever file you&#8217;d like to grab. So you could easily scrape a page for all .png files or .docx files if you wanted. </p>
<p>Enjoy</p>
]]></content:encoded>
			<wfw:commentRss>http://www.fettesps.com/download-every-file-of-a-certain-extension-on-a-site/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Uninstalling Visual Studio&#8217;s Productivity Power Tools</title>
		<link>http://www.fettesps.com/uninstalling-visual-studios-productivity-power-tools/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=uninstalling-visual-studios-productivity-power-tools</link>
		<comments>http://www.fettesps.com/uninstalling-visual-studios-productivity-power-tools/#comments</comments>
		<pubDate>Fri, 13 Jan 2012 04:00:52 +0000</pubDate>
		<dc:creator>FettesPS</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[2010]]></category>
		<category><![CDATA[asp.net]]></category>
		<category><![CDATA[c++]]></category>
		<category><![CDATA[microsoft]]></category>
		<category><![CDATA[productivity tools]]></category>
		<category><![CDATA[visual studio]]></category>
		<category><![CDATA[vs.net]]></category>

		<guid isPermaLink="false">http://www.fettesps.com/?p=1750</guid>
		<description><![CDATA[Took me far too long to find this option. Powertools had some annoying quirks that I just couldn&#8217;t get passed and I wasn&#8217;t using any of it&#8217;s good features. Plus either it or the SP1 upgrade has left Visual Studio 2010 in a less than stable state, I find it crashing several times a day. [...]]]></description>
			<content:encoded><![CDATA[<p>Took me far too long to find this option. Powertools had some annoying quirks that I just couldn&#8217;t get passed and I wasn&#8217;t using any of it&#8217;s good features.  Plus either it or the SP1 upgrade has left Visual Studio 2010 in a less than stable state, I find it crashing several times a day.  So today I have removed Productivity Power Tools using the following method:</p>
<p><strong>Tools -> Extension Manager -> Productivity Power Tools -> Uninstall</strong></p>
]]></content:encoded>
			<wfw:commentRss>http://www.fettesps.com/uninstalling-visual-studios-productivity-power-tools/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Converting ACSM files to ePub for the Sony eReader</title>
		<link>http://www.fettesps.com/converting-acsm-files-to-epub-for-the-sony-ereader/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=converting-acsm-files-to-epub-for-the-sony-ereader</link>
		<comments>http://www.fettesps.com/converting-acsm-files-to-epub-for-the-sony-ereader/#comments</comments>
		<pubDate>Fri, 30 Dec 2011 03:40:19 +0000</pubDate>
		<dc:creator>FettesPS</dc:creator>
				<category><![CDATA[Miscellaneous]]></category>

		<guid isPermaLink="false">http://www.fettesps.com/?p=1747</guid>
		<description><![CDATA[I was fortunate to be gifted a Sony eReader (PRS-T01) for the holiday season and have so far spent much more time playing with the damn thing than I have reading books on it. I have been plugging away at the first Game of Thrones book as well but today I decided to buy another [...]]]></description>
			<content:encoded><![CDATA[<p>I was fortunate to be gifted a Sony eReader (PRS-T01) for the holiday season and have so far spent much more time playing with the damn thing than I have reading books on it.  I have been plugging away at the first Game of Thrones book as well but today I decided to buy another one for more casual reading. Unfortunately this book did not come as an ePub file or even a PDF, as I am used to, but rather a ACSM file.  I did not realize this until after I had paid for it and downloaded it.  Now the file did launch the Sony eReader software when double clicked but I don&#8217;t use that software, rather Calibre, and wanted to import it there.  It would not recognize the file so I was forced to find a method to convert it.</p>
<p>After some research I was told to first install Adobe&#8217;s Digital Edition.  This is not ideal as it involves yet another program, and a crappy flash one at that, but it was my only option.  Once installed I was able to open the ACSM file which then downloaded the book. It turns out that this file is not really the eBook itself, but rather a voucher for the actual book which you can only redeem using Adobe&#8217;s software.  After it has been downloaded I suggest you close the program and never revisit it unless to fetch another ACSM as it is terrible.  It will reveal to you no method to access the ePub file it just downloaded, but alas it has done just that.  You will now find an ePub file in your <em>My Documents</em> folder under <em>My Digital Editions</em>.  Take that file and import it to Calibre, and go ahead and delete Adobe Digital Editions after that.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.fettesps.com/converting-acsm-files-to-epub-for-the-sony-ereader/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The system administrator has set policies to prevent this installation</title>
		<link>http://www.fettesps.com/the-system-administrator-has-set-policies-to-prevent-this-installation/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=the-system-administrator-has-set-policies-to-prevent-this-installation</link>
		<comments>http://www.fettesps.com/the-system-administrator-has-set-policies-to-prevent-this-installation/#comments</comments>
		<pubDate>Sun, 11 Dec 2011 20:17:49 +0000</pubDate>
		<dc:creator>FettesPS</dc:creator>
				<category><![CDATA[Windows]]></category>
		<category><![CDATA[Windows 7]]></category>
		<category><![CDATA[Windows Vista]]></category>
		<category><![CDATA[Windows XP]]></category>
		<category><![CDATA[installer]]></category>
		<category><![CDATA[msi]]></category>
		<category><![CDATA[nsis]]></category>

		<guid isPermaLink="false">http://www.fettesps.com/?p=1740</guid>
		<description><![CDATA[While I was installing Arduino for Visual Studio I encountered this annoying message: There are a few ways to fix it, including deactivating User Account Control (UAC) or logging in as the Administrator user (and not a regular user with Administrator privileges), but the method I chose to handle it was the following. I chose [...]]]></description>
			<content:encoded><![CDATA[<p>While I was installing Arduino for Visual Studio I encountered this annoying message:</p>
<p><a href="http://www.fettesps.com/wp-content/uploads/2011/12/the-system-administrator-has-set-policies-to-prevent-this-installation.jpg"><img src="http://www.fettesps.com/wp-content/uploads/2011/12/the-system-administrator-has-set-policies-to-prevent-this-installation-300x130.jpg" alt="" title="the-system-administrator-has-set-policies-to-prevent-this-installation" width="300" height="130" class="alignright size-medium wp-image-1745" /></a></p>
<p>There are a few ways to fix it, including deactivating User Account Control (UAC) or logging in as the Administrator user (and not a regular user with Administrator privileges), but the method I chose to handle it was the following.  I chose this method because it didn&#8217;t not open any needless security risks such as turning off UAC and I didn&#8217;t feel like logging into another user.</p>
<ol>
<li>Open <b>Administrative Tools</b></li>
<li>Open <b>Local Security Settings</b></li>
<li>Click on <b>Software Restriction Policies</b></li>
<li>If there are no software restrictions defined, <b>right click</b> on Restriction Policies and<br />
select <b>New Software Restriction Policy</b></li>
<li>Double click on the new enforcement and select <b>All Users Except Local Administrators</b></li>
<li>Click <b>OK</b></li>
<li>Reboot your computer and run the installer again</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://www.fettesps.com/the-system-administrator-has-set-policies-to-prevent-this-installation/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to find the Path of an Installed Program in Ubuntu</title>
		<link>http://www.fettesps.com/how-to-find-the-path-of-an-installed-program-in-ubuntu/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=how-to-find-the-path-of-an-installed-program-in-ubuntu</link>
		<comments>http://www.fettesps.com/how-to-find-the-path-of-an-installed-program-in-ubuntu/#comments</comments>
		<pubDate>Tue, 06 Dec 2011 23:34:47 +0000</pubDate>
		<dc:creator>FettesPS</dc:creator>
				<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://www.fettesps.com/?p=1736</guid>
		<description><![CDATA[Back in my FreeBSD days I relied heavily on the locate command to find out where things were installed. Since switching to Debian based Linux I&#8217;ve found that command to be far less reliable. The reason for this is it relies on a database that is almost always out of date. Now this is also [...]]]></description>
			<content:encoded><![CDATA[<p>Back in my FreeBSD days I relied heavily on the <i>locate</i> command to find out where things were installed.  Since switching to Debian based Linux I&#8217;ve found that command to be far less reliable.  The reason for this is it relies on a database that is almost always out of date.  Now this is also true for FreeBSD however I never had any issues locating files with it, which makes me wonder if they automatically called it after installing apps through ports or if it ran periodically via a cron job.  So you may ask yourself, why am I not recommending this approach?  The first is that it&#8217;s slow, it takes time to update this database so running updatedb before each locate command will eat up a good 30 seconds or more (you could schedule it with cron though). The second is that it is a security risk which exposes file locations to any non root user. Well then, what do I recommend instead?</p>
<pre class="brush: bash; title: ; notranslate">dpkg -L program</pre>
<p>This will work with any program installed with apt-get, synaptic or dpkg.  It is almost much faster and secure &#8212; it will only expose installed programs and not personal files.  So let&#8217;s see an example of it&#8217;s output:</p>
<pre class="brush: bash; title: ; notranslate">fettesps@athlon3200 ~ $ dpkg -L eggdrop
/.
/usr
/usr/share
/usr/share/doc
/usr/share/doc/eggdrop
/usr/share/doc/eggdrop/NEWS.gz
/usr/share/doc/eggdrop/README.Debian
/usr/share/doc/eggdrop/copyright
/usr/share/doc/eggdrop/README.gz
/usr/share/doc/eggdrop/changelog.Debian.gz
/usr/bin
/usr/bin/eggdrop
/usr/lib
/usr/lib/eggdrop
/usr/lib/eggdrop/modules
/usr/lib/eggdrop/modules/assoc.so
/usr/lib/eggdrop/modules/blowfish.so
/usr/lib/eggdrop/modules/channels.so
/usr/lib/eggdrop/modules/compress.so
/usr/lib/eggdrop/modules/console.so
/usr/lib/eggdrop/modules/ctcp.so
/usr/lib/eggdrop/modules/dns.so
/usr/lib/eggdrop/modules/filesys.so
/usr/lib/eggdrop/modules/irc.so
/usr/lib/eggdrop/modules/notes.so
/usr/lib/eggdrop/modules/seen.so
/usr/lib/eggdrop/modules/server.so
/usr/lib/eggdrop/modules/share.so
/usr/lib/eggdrop/modules/transfer.so
/usr/lib/eggdrop/modules/uptime.so
/usr/lib/eggdrop/modules/wire.so
/usr/share/doc/eggdrop/upstream</pre>
<p>Just by skimming over this I can see that the program has documentation in /usr/share/doc/eggdrop and the binary is in /usr/bin/eggdrop and lastly there are libraries in /usr/lib/eggdrop. Of course parsing this mentally requires some knowledge of the Linux file structure, but even without you should still be able to find what you need by looking in those folders.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.fettesps.com/how-to-find-the-path-of-an-installed-program-in-ubuntu/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Arduino and the USBTinyISP</title>
		<link>http://www.fettesps.com/arduino-and-the-usbtinyisp/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=arduino-and-the-usbtinyisp</link>
		<comments>http://www.fettesps.com/arduino-and-the-usbtinyisp/#comments</comments>
		<pubDate>Sat, 26 Nov 2011 03:02:27 +0000</pubDate>
		<dc:creator>FettesPS</dc:creator>
				<category><![CDATA[Arduino]]></category>
		<category><![CDATA[ardiuno]]></category>
		<category><![CDATA[ATmega]]></category>
		<category><![CDATA[atmel]]></category>
		<category><![CDATA[isp]]></category>

		<guid isPermaLink="false">http://www.fettesps.com/?p=1732</guid>
		<description><![CDATA[I&#8217;ve been monkeying around with different ways of uploading the sketches and bootloaders to ATmega chips and one of those ways is with the USBTinyISP which I picked up for about $10 on eBay. Even though once my bootloader was installed I never really needed to use the ISP programmer on my Arduino again I [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been monkeying around with different ways of uploading the sketches and bootloaders to ATmega chips and one of those ways is with the USBTinyISP which I picked up for about $10 on eBay. Even though once my bootloader was installed I never really needed to use the ISP programmer on my Arduino again I did find it was useful for programming chips when I had it bread-boarded out. To do that, I had to make a few tweaks to my config files, which were the following on my various computers:</p>
<p>Linux: /usr/share/arduino/hardware/arduino/boards.txt<br />
Windows 7: C:\Program Files (x86)\Arduino\hardware\arduino\boards.txt<br />
Windows XP: C:\Program Files\Arduino-0022\hardware\arduino\boards.txt</p>
<p>With my favourite text editor I openned them up and appended the following lines:</p>
<pre class="brush: plain; title: ; notranslate">
##############################################################

atmega168bb.name=ATmega168 on a breadboard (8 MHz internal clock)

atmega168bb.upload.protocol=stk500
atmega168bb.upload.maximum_size=14336
atmega168bb.upload.speed=57600

atmega168bb.bootloader.low_fuses=0xE2
atmega168bb.bootloader.high_fuses=0xD9
atmega168bb.bootloader.extended_fuses=0x07
atmega168bb.bootloader.path=arduino:atmega
atmega168bb.bootloader.file=ATmegaBOOT_168_pro_8MHz.hex
atmega168bb.bootloader.unlock_bits=0x3F
atmega168bb.bootloader.lock_bits=0x0F

atmega168bb.build.mcu=atmega168
atmega168bb.build.f_cpu=8000000L
atmega168bb.build.core=arduino:arduino 

##############################################################

atmega328bb.name=ATmega328 on a breadboard (8 MHz internal clock)

atmega328bb.upload.protocol=stk500
atmega328bb.upload.maximum_size=32720
atmega328bb.upload.speed=57600

atmega328bb.bootloader.low_fuses=0xE2
atmega328bb.bootloader.high_fuses=0xDA
atmega328bb.bootloader.extended_fuses=0x05
atmega328bb.bootloader.path=arduino:atmega
atmega328bb.bootloader.file=ATmegaBOOT_168_atmega328_pro_8MHz.hex
atmega328bb.bootloader.unlock_bits=0x3F
atmega328bb.bootloader.lock_bits=0x0F

atmega328bb.build.mcu=atmega328p
atmega328bb.build.f_cpu=8000000L
atmega328bb.build.core=arduino:arduino 

##############################################################

usbtiny168.name=[usbtinyisp]ATmega168

usbtiny168.upload.using=usbtinyisp
usbtiny168.upload.maximum_size=14336

usbtiny168.build.mcu=atmega168
usbtiny168.build.f_cpu=8000000L
usbtiny168.build.core=arduino

##############################################################

usbtiny328.name=[usbtinyisp]ATmega328

usbtiny328.upload.using=usbtinyisp
usbtiny328.upload.maximum_size=32768

usbtiny328.build.mcu=atmega328p
usbtiny328.build.f_cpu=16000000L
usbtiny328.build.core=arduino</pre>
<p>After that, I saved the file and restarted the Arduino software. Now I had four new menu items available. Go to Tools -> Board and you will find your new options.  The two prefixed with USBTinyISP will not upload a sketch over the USB to Serial connection but rather it will require the 6 pin ISP header and will wipe out your bootloader. Of course, you can always rebootload your ATmega with your ISP programmer so that shouldn&#8217;t be an issue.  The benefit to doing it this way is that it&#8217;s a little bit faster to upload and it takes up less memory on the chip so there&#8217;s no wasted space and less of a boot time when the micro powers up.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.fettesps.com/arduino-and-the-usbtinyisp/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Burning the Arduino Bootloader with an AVR STK500 Development Board</title>
		<link>http://www.fettesps.com/burning-the-arduino-bootloader-with-an-avr-stk500-development-board/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=burning-the-arduino-bootloader-with-an-avr-stk500-development-board</link>
		<comments>http://www.fettesps.com/burning-the-arduino-bootloader-with-an-avr-stk500-development-board/#comments</comments>
		<pubDate>Tue, 15 Nov 2011 01:29:19 +0000</pubDate>
		<dc:creator>FettesPS</dc:creator>
				<category><![CDATA[Arduino]]></category>
		<category><![CDATA[ATmega]]></category>
		<category><![CDATA[atmel]]></category>
		<category><![CDATA[attiny]]></category>
		<category><![CDATA[avr]]></category>
		<category><![CDATA[bootloader]]></category>
		<category><![CDATA[isp]]></category>
		<category><![CDATA[STK500]]></category>

		<guid isPermaLink="false">http://www.fettesps.com/?p=1345</guid>
		<description><![CDATA[I recently discovered that we had an old AVR STK500 development board lying around at work and when I had some free time I decided to play with it and see if I could use it to burn the Arduino Bootloader onto some old ATmega168 chips we had lying around. I was somewhat overwhelmed by [...]]]></description>
			<content:encoded><![CDATA[<p>I recently discovered that we had an old AVR STK500 development board lying around at work and when I had some free time I decided to play with it and see if I could use it to burn the Arduino Bootloader onto some old ATmega168 chips we had lying around.  I was somewhat overwhelmed by this board as it had so many jumpers and connectors on it that I didn&#8217;t have a clue where to begin, on top of that there was no manual to be found or even a model number on it to look up &#8212; the only identifier it had on the board was the Atmel AVR logo.  I was only able to find a model number for it after digging through pages of images that came up on a Google search, once I found a picture of the same board I found my way back to <a href="http://www.efo.ru/ftp/pub/atmel/_AVR_MCUs_8bit/_Technical_Library/tools/stk/stk500/index.html">this page</a> which gave me the information I needed.  From there I was able to <a href="http://www.atmel.com/dyn/resources/prod_documents/doc1925.pdf">dig up the manual</a> as well as a few extremely outdated guides on setting it up to program an ATmega chip with a bootloader. After much frustration I finally managed to get the code to flash.</p>
<h3>You Will Need</h3>
<ul>
<li>Atmel AVR STK-500 Development Board</li>
<li>An ATMEGA or ATTiny chip</a>
<li><a href="http://www.atmel.com/products/avr/default.asp?category_id=163&#038;family_id=607&#038;source=redirect">AVR Studio 4 Software</a></li>
<li><a href="http://arduino.cc/en/Main/Software">Arduino 0022 Software</a></li>
<li><a href="http://code.google.com/p/leaflabs/source/browse/trunk/maple/hardware/arduino/bootloaders/?r=154">Arduino Bootloader HEX File</a></li>
</ul>
<p></p>
<h3>Configuring the STK-500</h3>
<p>This is the trickiest part of the setup, if you have the manual you&#8217;ll be following the directions for the ATmega8 device.  The configuration is exactly the same for the ATmega168 as well as the ATmega328.  To make sure there is no confusion, if I say <i>to the right</i> I&#8217;m referring to the side with the power and two RS232 ports, and the <i>left</i> would be the opposite side where you&#8217;ll see a row of push buttons.  Though this should go without saying, make sure you have the power disconnected from the board and you are properly grounded so that you do not cause any E.S.D. damage to your board or components.</p>
<p>First you&#8217;ll be setting some jumpers.  Place a jumper across the pins for VTARGET, AREF, RESET and XTAL1.  Next you&#8217;ll place a jumper over the two right-most pins of OSCSEL.  You&#8217;ll also be installing two jumpers on the PJUMP pins, be sure to connect the top two pins with one jumper and the bottom two with another, so the jumpers will be running left to right.  The next jumper will be one of the trickier ones, you will need a longer jumper wire and you will be running it from the right most pin of BSEL2 to the pin labeled PC2 which is located in the bank of pins labeled PORTC which is to the bottom left side of the development board.</p>
<p>Next you&#8217;ll be running two ribbon cables across the board (as seen in section 3.7.2.1 of the manual).  You&#8217;ll be connecting the PROG DATA header to the PORTB header as well as connecting the PROG CTRL header to the PORTD header.  I&#8217;ve included figure 3-17 from the manual to demonstrate this:</p>
<p><a href="http://www.fettesps.com/wp-content/uploads/2011/02/stk-500-ribbon-cables.png"><img src="http://www.fettesps.com/wp-content/uploads/2011/02/stk-500-ribbon-cables-300x250.png" alt="Arduino STK500 " title="stk-500-ribbon-cables" width="300" height="250" class="alignright size-medium wp-image-1352" /></a></p>
<p>Finish up by placing the chip into the socket labeled SCKT3200A2 which is the one outlined in Green. Pay attention to the small notch on the <i>left</i> edge of the socket, this will match up with a notch on one end of the chip.</p>
<h3>Burning the Bootloader</h3>
<div style="float:right;padding: 5px 0px 5px 15px;width:150px;border-left: 1px solid left;">
<strong>Quick Sheet:</strong></p>
<ul>
<li>Tools</li>
<li>Program AVR</li>
<li>Connect&#8230;</li>
<li>Platform: STK500</li>
<li>Port: COM1</li>
<li>Connect&#8230;</li>
<li>Tab: Main</li>
<li>Device: ATMega168 (or as desired)</li>
<li>Programming Mode and Target Settings: PP/HVSP mode</li>
<li>Tab: Program</li>
<li>Select the HEX file for your chip </li>
<li>Click Program</li>
<li>Tab: Fuses</li>
<li>Extended: 0xF8</li>
<li>High: 0xDF</li>
<li>Low: 0xFF</li>
<li>Program</li>
<li>Tab: LockBits</li>
<li>Lockbit: 0xFF</li>
<li>Program</li>
</ul>
</div>
<p>Unlike when using an ISP programmer through the Arduino software there are a few more things to do than just click &#8220;Burn Bootloader.&#8221;  For just the cliff notes follow the list on the right, or to jump to the video, otherwise keep reading. If you&#8217;ve just opened the software for the first time and it&#8217;s asking you to start a new project or open one, you&#8217;ll actually want to hit cancel.  Now in your IDE select the <b>Tools</b> menu and then <b>Program AVR</b> and then select <b>Connect&#8230;</b>  Now you&#8217;ll be presented with a screen asking about the LockBits, click back to the <b>Main</b> tab and select your Device and set the programming mode to HVSP. Before leaving this tab I recommend hitting Read Signature to to see if it reads the device fine, if it&#8217;s not hooked up right it will likely fail at this point.</p>
<p>Move on to the <b>Program</b> tab and then load your hex file.  You&#8217;re going to need the right hex file for the chip and board you&#8217;re going to be working with.  So go into your Arduino folder (e.g. C:\Program Files\Arduino\) under the <strong>Hardware\arduino\bootloaders\</strong> and start looking for one that makes the most sense.  If you don&#8217;t have the Arduino software installed yet or on this computer then another good source is <a href="http://code.google.com/p/leaflabs/source/browse/trunk/maple/hardware/arduino/bootloaders/?r=154">LeafLabs on Google Code</a>.  To be honest I&#8217;m not sure what the difference is between all the bootloaders, I just use the one in the atmega8 folder and have had no issues.  It&#8217;s also only 3kb verses 30kb which is the one whose name best maches the ATMega168 chips I&#8217;m using in this example. Once you&#8217;ve loaded the file into the AVR Studio under the Flash heading you can go ahead and hit program.  I always have the options to erase the chip and verify afterwards, so if you don&#8217;t you may want to do that manually.  If there are no errors in the bottom text move on to the Fuses tab.</p>
<p>Under the <b>Fuses</b> tab you will have to set some hex values. For the ATMega18 I was using in this example I had to set <b>Extended to 0xF8 then High to 0xDF and Low to 0xFF</b>.  This may vary depending on the chip so make sure to <a href="http://www.arduino.cc/playground/Learning/Burn168">look it up</a> before hand. Before moving on click <b>Program</b> and check the log for errors.</p>
<p>Finally, check the LockBits page.  These seem to reset to 0xFF after every program action so set them to 0xCF and hit <b>Program</b>.</p>
<p>At this point your bootloader should be burnt onto your ATMega chip and you should now be able to use it in your Arduino board. So pop it out of the STK500 and back into your Arduino board and fire up the software. From the examples menu select Blink and upload it to your device.  If the LED alternates between on and off endlessly then you are ready to rock.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.fettesps.com/burning-the-arduino-bootloader-with-an-avr-stk500-development-board/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Burning the Arduino Bootloader with the AVR Dragon</title>
		<link>http://www.fettesps.com/burning-the-arduino-bootloader-with-the-avr-dragon/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=burning-the-arduino-bootloader-with-the-avr-dragon</link>
		<comments>http://www.fettesps.com/burning-the-arduino-bootloader-with-the-avr-dragon/#comments</comments>
		<pubDate>Sun, 13 Nov 2011 21:28:11 +0000</pubDate>
		<dc:creator>FettesPS</dc:creator>
				<category><![CDATA[Arduino]]></category>
		<category><![CDATA[ATmega]]></category>
		<category><![CDATA[atmel]]></category>
		<category><![CDATA[attiny]]></category>
		<category><![CDATA[avr]]></category>
		<category><![CDATA[AVR Dragon]]></category>
		<category><![CDATA[bootloader]]></category>
		<category><![CDATA[USBTinyISP]]></category>
		<category><![CDATA[youtube]]></category>

		<guid isPermaLink="false">http://www.fettesps.com/?p=1626</guid>
		<description><![CDATA[The AVR Dragon is a little more of an expensive route to go if you&#8217;re looking to burn Arduino Bootloaders. They can ring in around $50 per unit, though they do come in a beautiful red box with a dragon painted on it. The USBTinyISP is about $10, for comparison, and will get the job [...]]]></description>
			<content:encoded><![CDATA[<p>The AVR Dragon is a little more of an expensive route to go if you&#8217;re looking to burn Arduino Bootloaders.  They can ring in around $50 per unit, though they do come in a beautiful red box with a dragon painted on it.  The USBTinyISP is about $10, for comparison, and will get the job done just as easily &#8212; actually, it&#8217;s easier.  So if you&#8217;re going out to buy a programmer I&#8217;d recommend the USBTinyISP, however, if you&#8217;re lucky like me and have tons of gadgets like this lying around at work to play with then it&#8217;s certainly a viable option. I found this unit hiding in a dusty box on a shelf, seemingly forgotten as no one in knew what it was or why we had it, even though I already had an STK500 hooked up and ready to go as well as a USBTinyISP at home I thought I&#8217;d fire it up just for the experience.</p>
<p>The first thing you&#8217;re going to need is <a href="http://www.atmel.com/microsite/avr_studio_5/">AVR Studio</a>.  Even if you&#8217;ll be burning your bootloader through the Arduino program you&#8217;ll still need AVR Studio for the drivers.  Unfortunately I could not locate stand alone drivers and was forced to download all 600mb of AVR Studio for this purpose only, so I suggest starting that process first so you can get everything else ready while it downloads.</p>
<h3>You Will Need</h3>
<ul>
<li>Atmel AVR Dragon Board</li>
<li>An ATMEGA or ATTiny chip</li>
<li>An Arduino board (or breadboard)</li>
<li>6 pin ISP Programming Cable</li>
<li><a href="http://www.atmel.com/products/avr/default.asp?category_id=163&#038;family_id=607&#038;source=redirect">AVR Studio 4/5 Software</a></li>
<li><a href="http://code.google.com/p/leaflabs/source/browse/trunk/maple/hardware/arduino/bootloaders/?r=154">Arduino Bootloader HEX File</a></li>
</ul>
<h3>Setup the AVR Dragon</h3>
<p>In this example I&#8217;ll be using the 6 pin ISP header which I will connect to my Arduino board.  The AVR Dragon can do High Voltage Programming (HVSP) if you solder on a DIP or ZIF socket on the breadboard area to the right side.  See <a href="http://www.instructables.com/id/Help%3A-An-Absolute-Beginner-s-Guide-to-8-Bit-AVR-Pr/">this Instructables</a> Guide for instructions on how to do that.  </p>
<p>Unlike setting up the STK500 for HVSP programming the setup for the AVR Dragon in ISP mode is a breeze. The only &#8220;gotchya&#8221; is when hooking up the ISP cable make sure to align the cable so the wire with the red stripe matches the Pin 1 marker on each end.  The AVR Dragon does provide power to the destination board via the VCC headers but I found it&#8217;s easier to power the Arduino by hooking it up to another USB cable or via a walwart adapter. Once both boards have power and are connected via the ISP header you are ready to fire up AVR Studio and program the bootloader onto the chip.</p>
<h3>Programming it in AVR Studio 4</h3>
<p>AVR Studio is a free program that only requires you register with AVR in order to download it.  AVR Studio 5 is now available, and is the recommended software for this task, but this guide will stand for all who have not yet chosen to update.  </p>
<p>After loading the program you will be prompted to create a new project or load an old one.  We will do neither so hit Cancel and then on the main menu select <strong>Tools -> Program AVR -> Connect&#8230;</strong>.  Now select the <b>AVR Dragon</b> as your platform and the <b>USB Port</b> and then click <b>Connect</b> again. </p>
<p>On the next screen <b>select your device</b>, in this case the ATmega168, and select <b>ISP as your Programming Mode</b>. I always hit Read Signature to make sure everything is connected properly.  Now move on to the Program tab and under the Flash section select your HEX file.  They can be found in your Arduino installation directory, check <b>/hardware/arduino/bootloaders</b> and you will find several variations there, more can be found online.  After you have loaded the correct one hit <b>Program</b> and then when complete move to the next tab.</p>
<p>Next you&#8217;ll sit the Fuse settings.  The correct settings for the ATmega168 chip are <b>0xF8, 0xDF, 0xFF</b> but make sure to use the correct settings for the chip you are using. Click <b>Program</b> then go to the Fuse Bits tab and set it to <b>0xCF</b> and hit <b>Program</b> again.</p>
<p><object width="500" height="300"  style="margin-bottom:25px"><param name="movie" value="http://www.youtube.com/v/BNypIMxc1RM?version=3&amp;hl=en_US"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/BNypIMxc1RM?version=3&amp;hl=en_US" type="application/x-shockwave-flash" width="500" height="300" allowscriptaccess="always" allowfullscreen="true"></embed></object></center></p>
<p>At this point your Arduino is ready.  You can plug it in as per usual and upload a Sketch in the Arduino software.  I usually start by loading the Blink program as it is a quick and easy way to test the bootloader as the built in LED on Pin 13 will allow you to easily access if the program is running.  Make sure to upload a sketch again to make sure your lock bits were set properly, as if they are not the sketch will overwrite the bootloader and a subsequent upload will fail. </p>
<h3>Programming it in AVR Studio 5</h3>
<p>AVR Studio 5 is the new and improved way to build your AVR programs.  It runs off the Visual Studio Shell which gives .Net developers an &#8220;at home&#8221; feeling when using the software.  Beyond that I couldn&#8217;t tell you what the extra features are as I only use it for programming the bootloaders and everything else I do right in the Arduino software.  The software can still be downloaded for free after registering, and is unfortunately about 600mb to download, which is a lot for what we&#8217;ll be doing today.</p>
<p><center><object width="500" height="300" style="margin-bottom:25px"><param name="movie" value="http://www.youtube.com/v/nSSjn618_cY?version=3&amp;hl=en_US"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/nSSjn618_cY?version=3&amp;hl=en_US" type="application/x-shockwave-flash" width="500" height="300" allowscriptaccess="always" allowfullscreen="true"></embed></object></center></p>
<p>Uploading the bootloader is pretty much the same.  Start off by going to <b>Tools</b> then <b>AVR Programming</b>.  On the next window select <b>AVR Dragon</b> as your <b>Tool</b> and <b>ATmega168</b> as your <b>Device</b>. Then <b>ISP</b> as your <b>Interface</b> then click <b>Apply</b>.  Click <b>Read</b> for both <b>Device ID</b> and <b>Target Voltage</b> to make sure everything is hooked up correctly and to initialize some settings.</p>
<p>Jump to the <b>Memories</b> tab and under Flash <b>select your HEX file</b> from the Arduino folder.  They can be found in <b>/hardware/arduino/bootloaders</b> or easily found online.  Make sure to load the proper HEX file for the chip you are working with, in this case we are using an ATmega168 chip so the file I use is <b>ATmegaBOOT_168_atmega328.hex</b> since I was too lazy to complile the ATmegaBOOT_168.c file.  Once the proper file is loaded click <b>Program</b>.</p>
<p>Now move on to the <b>Fuses</b> tab and set them to <b>0xF8, 0xDF, 0xFF</b> and then hit <b>Program</b> before moving on to the <b>Lockbits</b> tab where you will set it to <b>0xCF</b> before hitting <b>Program</b> again. Once again, verify the settings for your chip as they will vary. You may also want to tweak them to your own needs, for instance you may want to use the internal oscillator to run the chip at 8 MHz instead of the 16 MHz you get with the external crystal.  The lockbits will be configured to prevent the bootloader from being wiped each time you upload a sketch, so if you&#8217;re bootloaded chip only works once through the Arduino software&#8217;s upload method, then you likely forgot to set the lockbits or didn&#8217;t set them correctly.</p>
<h3>Testing Your Bootloaded Chip</h3>
<p>After flashing the bootloader you can disconnect the ISP header and plug the Arduino board into your USB port before loading the Arduino software.  Once it is loaded <b>open the Blink sketch </b>and then select your board and port before uploading.  The blink sketch is the best tool for testing a chip as Arduinos now come with a mini LED and a resistor already installed on Pin 13 which this sketch is configured to use.  Please note that older versions of the Arduino only had the 1k ohm resistor preinstalled so it will still need an external LED on Pin 13.  If your sketch uploads without an error you shouldn&#8217;t have any problems, but either way I suggest watching the LED for a few seconds to ensure that it alternates between on and off, if it does this then upload the sketch one more time to make sure you didn&#8217;t set the lockbits wrong.  If it works the second time then your bootloaded ATmega is ready to go!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.fettesps.com/burning-the-arduino-bootloader-with-the-avr-dragon/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to Reset a Drupal 7 Password</title>
		<link>http://www.fettesps.com/how-to-reset-a-drupal-7-password/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=how-to-reset-a-drupal-7-password</link>
		<comments>http://www.fettesps.com/how-to-reset-a-drupal-7-password/#comments</comments>
		<pubDate>Sun, 16 Oct 2011 01:41:17 +0000</pubDate>
		<dc:creator>FettesPS</dc:creator>
				<category><![CDATA[Drupal]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[reset password]]></category>

		<guid isPermaLink="false">http://www.fettesps.com/?p=1586</guid>
		<description><![CDATA[After abandoning one of my Drupal 7 sites for some time I decided to buy a domain for it and start working on it again. I immediately ran into a case of &#8220;Oops I forgot the password&#8221; and could not log in, eventually getting my account locked out. This is what happens every time I [...]]]></description>
			<content:encoded><![CDATA[<p>After abandoning one of my Drupal 7 sites for some time I decided to buy a domain for it and start working on it again. I immediately ran into a case of &#8220;Oops I forgot the password&#8221; and could not log in, eventually getting my account locked out.  This is what happens every time I try and come up with a more clever password.  Unlike in previous versions of Drupal it&#8217;s not a matter of just slapping an MD5 around a password when updating the database.  With Drupal 7 you have to make use of a salted sha512 hash, the easiest way to do that is to create a file in your installation server with the password you want to convert and when you run it you will get your encrypted password echoed out to you.  Simple enough! So here&#8217;s the code:</p>
<pre class="brush: php; title: ; notranslate">&lt;?php
// $Id: index.php,v 1.99 2009/10/15 14:07:25 dries Exp $

/**
 * @file
 * The PHP page that serves all page requests on a Drupal installation.
 *
 * The routines here dispatch control to the appropriate handler, which then
 * prints the appropriate page.
 *
 * All Drupal code is released under the GNU General Public License.
 * See COPYRIGHT.txt and LICENSE.txt.
 */

/**
 * Root directory of Drupal installation.
 */
define('DRUPAL_ROOT', getcwd());

require_once DRUPAL_ROOT . '/includes/bootstrap.inc';
drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);

require_once 'includes/password.inc';
echo user_hash_password('your_new_password');
die();

menu_execute_active_handler();

?&gt;</pre>
<p>Simple browse to this file in your web browser and it will output your new salted password.  Take that password and then go into PHPMyAdmin (or your favourite MySQL client) and then browse to your users table, there you can paste it in as the new password. Make sure not to use the password() or md5() functions when editing the field as it needs to be stored as plain text.</p>
<p>Thanks to <a href="http://drupal.org/node/992400">Conclusion on Drupal.org</a> for presenting this conclusion.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.fettesps.com/how-to-reset-a-drupal-7-password/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Steve Jobs is Dead</title>
		<link>http://www.fettesps.com/steve-jobs-is-dead/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=steve-jobs-is-dead</link>
		<comments>http://www.fettesps.com/steve-jobs-is-dead/#comments</comments>
		<pubDate>Thu, 06 Oct 2011 04:42:08 +0000</pubDate>
		<dc:creator>FettesPS</dc:creator>
				<category><![CDATA[Apple]]></category>
		<category><![CDATA[Browser Wars]]></category>
		<category><![CDATA[iPhone]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[disney]]></category>
		<category><![CDATA[pixar]]></category>

		<guid isPermaLink="false">http://www.fettesps.com/?p=1573</guid>
		<description><![CDATA[Well, it&#8217;s official &#8212; Steve Jobs is dead. Not a huge surprise to everyone with him recently stepping down as CEO, but certainly a game changing event in the tech industry. Known to many as a visionary, to some the leader of a cult, whatever you consider the main to have been you can&#8217;t deny [...]]]></description>
			<content:encoded><![CDATA[<p>Well, it&#8217;s official &#8212; Steve Jobs is dead.  Not a huge surprise to everyone with him recently stepping down as CEO, but certainly a game changing event in the tech industry.  Known to many as a visionary, to some the leader of a cult, whatever you consider the main to have been you can&#8217;t deny his incredible contributions to the industry. With Apple&#8217;s new CEO Tim Cook failing to impress many of Apple&#8217;s following and this recent blow one can&#8217;t help but wonder what is in store for this booming company.  </p>
<div style="text-align:justified;padding: 0px 50px 0px 50px;">I&#8217;m truly saddened to learn of Steve Jobs&#8217; death. Melinda and I extend our sincere condolences to his family and friends, and to everyone Steve has touched through his work. Steve and I first met nearly 30 years ago, and have been colleagues, competitors and friends over the course of more than half our lives. The world rarely sees someone who has had the profound impact Steve has had, the effects of which will be felt for many generations to come. For those of us lucky enough to get to work with him, it&#8217;s been an insanely great honor. I will miss Steve immensely.<br />

<div style="float:right">-Bill Gates</div>
</div>
<p><br style="clear:all;"></p>
<p>Job&#8217;s dominance in the market stretched out well beyond that of Apple.  He owned considerable shares in Disney after it&#8217;s acquisition of Pixar for which we can thank for making digital animation what it is today. With over 100 million people owning an iPhone and numerous other gadgets such as the iMac, iPod, AppleTV or the MacBook his legacy can be found world wide, piece by piece in everyone&#8217;s homes.</p>
<p>But what will become of what he has left behind? Will Apple continue to push forward with new technologies that continue to redefine the market?  Will Tim Cook be able to develop the same cult like following in America&#8217;s youth?  Or will Apple once again fade away into just a memory?  Although I have never been the biggest fan of Apple, and can often quite vocal about my distaste for some of their practices, I hope that Cook does manage to do what Jobs has done, and hopefully even more. The more super powers we have in the tech industry the more competition there is, the more growth there is, and the more fun gadgets and services there are for all of us peons out there to play with.</p>
<p>Currently Apple&#8217;s site is quite displaying a picture of Jobs with the years 1955-2011 written next to it.  After clicking the image one is presented with the following text:</p>
<div style="text-align:justified;padding: 0px 50px 0px 50px;">Apple has lost a visionary and creative genius, and the world has lost an amazing human being. Those of us who have been fortunate enough to know and work with Steve have lost a dear friend and an inspiring mentor. Steve leaves behind a company that only he could have built, and his spirit will forever be the foundation of Apple.</div>
<p>These are the words of his successor, Tim Cook, who now holds the reins in his hands.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.fettesps.com/steve-jobs-is-dead/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

