<?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>Kris Barrett</title>
	<atom:link href="http://www.krisbarrett.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.krisbarrett.com</link>
	<description>Programming, electronics, and other nerdiness.</description>
	<lastBuildDate>Thu, 31 May 2012 21:40:33 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=</generator>
		<item>
		<title>Audio output selector</title>
		<link>http://www.krisbarrett.com/2009/10/22/audio-output-selector/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=audio-output-selector</link>
		<comments>http://www.krisbarrett.com/2009/10/22/audio-output-selector/#comments</comments>
		<pubDate>Thu, 22 Oct 2009 23:10:39 +0000</pubDate>
		<dc:creator>Kris</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[3.5mm jack]]></category>
		<category><![CDATA[audio]]></category>
		<category><![CDATA[diy]]></category>
		<category><![CDATA[dpdt]]></category>
		<category><![CDATA[switch]]></category>

		<guid isPermaLink="false">http://www.krisbarrett.com/?p=117</guid>
		<description><![CDATA[Using my headphones with my computer is frustrating.  Whenever I want to use my headphones, I have to move my computer so I can access the back panel, unplug my computer speakers, and plug-in my headphones.  Okay, maybe it isn&#8217;t that difficult, but it should be easier.  How about a device that allows you to [&#8230;]]]></description>
				<content:encoded><![CDATA[<p><a href="http://www.flickr.com/photos/krisbarrett/4036018470/"><img class="alignnone" title="Audio Ouput Selector" src="http://farm3.static.flickr.com/2729/4036018470_f21805a1cf.jpg" alt="" width="500" height="375" /></a></p>
<p>Using my headphones with my computer is frustrating.  Whenever I want to use my headphones, I have to move my computer so I can access the back panel, unplug my computer speakers, and plug-in my headphones.  Okay, maybe it isn&#8217;t <em>that</em> difficult, but it should be easier.  How about a device that allows you to select between headphones or computer speakers?<span id="more-117"></span></p>
<p><strong>Solution</strong></p>
<p>After some careful thought, I realized such a device could be implemented using three 3.5mm jacks and one dual-pole dual-throw (DPDT) switch (see the schematic below).</p>
<p><strong><a href="http://www.krisbarrett.com/wp-content/uploads/2009/10/audio-output-selector.png"><img class="alignnone size-large wp-image-128" style="border: 1px solid black;" title="audio-output-selector" src="http://www.krisbarrett.com/wp-content/uploads/2009/10/audio-output-selector-1024x654.png" alt="audio-output-selector" width="500" height="319" /></a><br />
</strong></p>
<p>As you can see, the DPDT switch simply selects whether the input is connected to the headphones or the computer speakers.</p>
<p><strong>Other Possibilities</strong></p>
<p>A similar device can be implemented using two dual-pole single-throw (DPST) switches.  This would allow the user to select headphones, computer speakers, or both.  A much more sophisticated implementation might include operational amplifiers allowing the user to adjust the gain on each output.</p>
<p><strong><br />
</strong></p>
]]></content:encoded>
			<wfw:commentRss>http://www.krisbarrett.com/2009/10/22/audio-output-selector/feed/</wfw:commentRss>
		<slash:comments>12</slash:comments>
		</item>
		<item>
		<title>Catalan numbers</title>
		<link>http://www.krisbarrett.com/2009/08/30/catalan-numbers/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=catalan-numbers</link>
		<comments>http://www.krisbarrett.com/2009/08/30/catalan-numbers/#comments</comments>
		<pubDate>Mon, 31 Aug 2009 01:16:28 +0000</pubDate>
		<dc:creator>Kris</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[math]]></category>

		<guid isPermaLink="false">http://www.krisbarrett.com/?p=87</guid>
		<description><![CDATA[Recently I was trying to count the number of n-bit numbers that have an equal number of 1&#8242;s and 0&#8242;s.  For example, there are 6 such numbers for 4-bit long numbers (0011, 0101, 0110, 1001, 1010, 1100).  I wrote a simple program to count such numbers for arbitrarily long numbers.  However, the program was computationally [&#8230;]]]></description>
				<content:encoded><![CDATA[<p><img class="alignnone size-full wp-image-89" title="Image courtesy of Wikipedia" src="http://www.krisbarrett.com/wp-content/uploads/2009/08/690px-Catalan_number_4x4_grid_example.svg.png" alt="690px-Catalan_number_4x4_grid_example.svg" width="500" height="254" /></p>
<p>Recently I was trying to count the number of n-bit numbers that have an equal number of 1&#8242;s and 0&#8242;s.  For example, there are 6 such numbers for 4-bit long numbers (0011, 0101, 0110, 1001, 1010, 1100).  I wrote a simple program to count such numbers for arbitrarily long numbers.  However, the program was computationally complex and it took a long time to compute the result for large values of n.  After spending some time trying to figure out the equation myself, I searched the internet and stumbled upon Catalan numbers.  I determined that the equation is related to Catalan numbers.  I included the equation below because I couldn&#8217;t find it anywhere else.  Also, I don&#8217;t have a formal proof, but it seems to work.  Enjoy!</p>
<p>Number of n-bit numbers that have an equal number of 1&#8242;s and 0&#8242;s = (m+1) * Cm, where m = n/2 and Cm = mth Catalan number</p>
]]></content:encoded>
			<wfw:commentRss>http://www.krisbarrett.com/2009/08/30/catalan-numbers/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to make your own Arduino shield</title>
		<link>http://www.krisbarrett.com/2008/09/03/make-a-custom-arduino-shield/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=make-a-custom-arduino-shield</link>
		<comments>http://www.krisbarrett.com/2008/09/03/make-a-custom-arduino-shield/#comments</comments>
		<pubDate>Thu, 04 Sep 2008 00:47:58 +0000</pubDate>
		<dc:creator>Kris</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[arduino]]></category>
		<category><![CDATA[arduino shield]]></category>
		<category><![CDATA[button]]></category>
		<category><![CDATA[diy]]></category>
		<category><![CDATA[eagle]]></category>
		<category><![CDATA[led]]></category>
		<category><![CDATA[pcb]]></category>
		<category><![CDATA[transistor]]></category>

		<guid isPermaLink="false">http://www.krisbarrett.com/2008/09/03/make-a-custom-arduino-shield/</guid>
		<description><![CDATA[After many months of working on my Arduino based project, I decided to finalize my project by making my own custom PCB.  At first I wanted to design a PCB that connected to the Arduino through a series of cables.  After some thought however, I realized that a shield would be better because it would [&#8230;]]]></description>
				<content:encoded><![CDATA[<p><a href="http://www.flickr.com/photos/krisbarrett/2826187914/"></a> <a href="http://www.flickr.com/photos/krisbarrett/2826187914/"><img src="http://farm4.static.flickr.com/3030/2826187914_4ef6f81bfb.jpg?v=0" alt="Arduino Shield" width="500" height="375" /></a></p>
<p>After many months of working on my Arduino based project, I decided to finalize my project by making my own custom PCB.  At first I wanted to design a PCB that connected to the Arduino through a series of cables.  After some thought however, I realized that a shield would be better because it would eliminate the need for cables.  This tutorial assumes an understanding of Cadsoft Eagle.  For more information about Eagle, see the Eagle Tutorials section below.  Here are the steps to make your own Arduino shield:<span id="more-37"></span></p>
<ol>
<li><strong>Part Selection</strong>- Carefully select your parts. Ensure that your parts meet your performance and power requirements.  It is better to carefully choose your parts now, than wish you chose something else later.</li>
<li><strong>Prototype</strong> &#8211; Prototype your design on a breadboard.  Ensure that your functional, performance, and power requirements are being met.  Change your design as necessary.  Do not begin designing the PCB until you are completely satisfied with your prototype.<a href="http://www.flickr.com/photos/krisbarrett/2712458517/in/photostream/"><img src="http://farm4.static.flickr.com/3065/2712458517_a1d41dc70b.jpg?v=0" alt="" width="500" height="375" /></a><br />
<strong>Figure 1:<br />
</strong>Breadboard prototype</li>
<li><strong>Schematic Capture </strong>
<ol>
<li style="list-style-type: lower-alpha;"><strong>Add Custom Parts to Eagle</strong> &#8211; Place all of your parts in the schematic before drawing any wires.  This allows you to identify which parts you will need to create yourself.  I had to create a custom part for the Arduino.  Drawing a symbol for the Arduino was easy.  Drawing the package was a little bit more difficult because I had to determine the spacing between the headers.  I easily obtained this information from the Arduino Eagle files which I downloaded from the Arduino website.  Download my Eagle Arduino library <a href="http://www.krisbarrett.com/arduino.lbr">here</a>.<a href="http://www.flickr.com/photos/krisbarrett/2826317564/"><img src="http://farm4.static.flickr.com/3077/2826317564_28413c8771.jpg?v=0" alt="" width="500" height="392" /></a><br />
<strong>Figure 2:</strong><br />
Header locations relative to one another.  I obtained this information from the Eagle file.</p>
<p><a href="http://farm4.static.flickr.com/3027/2825309347_dff89b099f_o.jpg"><img src="http://farm4.static.flickr.com/3027/2825309347_7b7f2b8aa1.jpg?v=0" alt="" width="500" height="279" /></a><strong><br />
Figure 3:<br />
</strong>Arduino symbol and package that I created in Eagle.</li>
<li style="list-style-type: lower-alpha;"><strong>Connect Parts </strong>- After placing all of your parts in the schematic, carefully connect your parts together using the wire tool.  If you make a mistake on your schematic, it will ultimately show up on your PCB.</li>
</ol>
</li>
<li><strong>PCB Layout </strong>- Place the parts on the board.  If your PCB is long enough, the PCB will rest on top of the USB connector on the Arduino.  Parts and traces should not be placed here because it could potentially short out your PCB.  I accidentally placed the DC power connector in this area. Fortunately,  I was able to insulate the USB connector with a piece of electrical tape.  Also, follow PCB layout guidelines.  I learned this the hard way when I discovered that the rapid switching of the transistors was inducing a voltage in one of the traces connected to the button.<a href="http://www.flickr.com/photos/krisbarrett/2825398079/"> </a><a href="http://www.flickr.com/photos/krisbarrett/2825398079/"><img src="http://farm4.static.flickr.com/3237/2825398079_67bbd3335f.jpg?v=0" alt="" width="500" height="375" /></a><strong><br />
Figure 4</strong>:<br />
I made the mistake of placing a part above the USB connector.  I prevented the part from shorting out by placing some electrical tape on top of the USB connector.</p>
<p><a href="http://www.flickr.com/photos/krisbarrett/2825399045"><img src="http://farm4.static.flickr.com/3235/2825399045_04db0b39b5.jpg?v=0" alt="" width="500" height="375" /><br />
</a><strong>Figure 5: </strong><br />
The shield also doesn&#8217;t sit properly because of my poor layout.</li>
<li><strong>PCB Fabrication</strong> &#8211; Generate the CAM files.  You could fabricate the PCB yourself, but I highly recommend BatchPCB.  BatchPCB fabricates inexpensive, production quality PCBs.  The only drawback is that you have to wait three weeks to a month to receive your order.  BatchPCB has a tutorial on generating the files that they need to fabricate your PCB.<a href="http://www.flickr.com/photos/krisbarrett/2796528389"><img src="http://farm4.static.flickr.com/3108/2796528389_e9960b7935.jpg?v=0" alt="" width="500" height="375" /><br />
</a><strong>Figure 6</strong>:<br />
Final product from BatchPCB.</li>
</ol>
<p><strong>Final Thoughts<br />
</strong>Although I am not happy with the way my PCB turned out, I learned valuable information about PCB design.  I am sure that if I follow PCB layout guidelines, I can get this PCB to work properly.  I hope people can learn from my mistakes on this project and design a better Arduino shield of their own.</p>
<p><strong>Eagle Tutorials</strong><br />
<a href="http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=57&amp;sipp=1&amp;page=8">Schematic Capture</a><br />
<a href="http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=57&amp;sipp=1&amp;page=10">Creating Custom Parts</a><br />
<a href="http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=57&amp;sipp=1&amp;page=9">PCB Layout</a><br />
<a href="http://www.batchpcb.com/eagle-tutorial.php?osCsid=6fafc3f166d30af2bc9598efd0d9c71f">Generating CAM Files</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.krisbarrett.com/2008/09/03/make-a-custom-arduino-shield/feed/</wfw:commentRss>
		<slash:comments>28</slash:comments>
		</item>
		<item>
		<title>Fun with FFT</title>
		<link>http://www.krisbarrett.com/2008/08/25/fast-fourier-transform/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=fast-fourier-transform</link>
		<comments>http://www.krisbarrett.com/2008/08/25/fast-fourier-transform/#comments</comments>
		<pubDate>Mon, 25 Aug 2008 22:55:03 +0000</pubDate>
		<dc:creator>Kris</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[audio]]></category>
		<category><![CDATA[breadboard]]></category>
		<category><![CDATA[fft]]></category>

		<guid isPermaLink="false">http://www.krisbarrett.com/2008/08/25/fast-fourier-transform/</guid>
		<description><![CDATA[This is a project that I threw together one weekend.  The FFT is calculated using Processing. The FFT is then sent to the Freeduino via the serial port. The Freeduino displays the FFT on the dot matrix display using shift registers and a Darlington transistor array.]]></description>
				<content:encoded><![CDATA[<p><object width="500" height="375" type="application/x-shockwave-flash" data="http://www.vimeo.com/moogaloop.swf?clip_id=1601790&amp;server=www.vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=00ADEF&amp;fullscreen=1"><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://www.vimeo.com/moogaloop.swf?clip_id=1601790&amp;server=www.vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=00ADEF&amp;fullscreen=1" /></object></p>
<p>This is a project that I threw together one weekend.  The FFT is calculated using <a href="http://www.processing.org">Processing</a>.  The FFT is then sent to the Freeduino via the serial port.  The Freeduino displays the FFT on the dot matrix display using shift registers and a Darlington transistor array.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.krisbarrett.com/2008/08/25/fast-fourier-transform/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Improved light bar controller</title>
		<link>http://www.krisbarrett.com/2008/07/29/improved-light-bar-controller/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=improved-light-bar-controller</link>
		<comments>http://www.krisbarrett.com/2008/07/29/improved-light-bar-controller/#comments</comments>
		<pubDate>Tue, 29 Jul 2008 07:22:25 +0000</pubDate>
		<dc:creator>Kris</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[arduino]]></category>
		<category><![CDATA[button]]></category>
		<category><![CDATA[led]]></category>
		<category><![CDATA[transistor]]></category>

		<guid isPermaLink="false">http://www.krisbarrett.com/2008/07/29/improved-light-bar-controller/</guid>
		<description><![CDATA[I made several improvements to my light bar controller.  I added a push button that pauses the controller on a desired color. I added a red LED to indicate if the controller is paused.  I also modified the light bar so that it easily plugs into the breadboard.  I did this by replacing the polarized [&#8230;]]]></description>
				<content:encoded><![CDATA[<p><a href="http://www.flickr.com/photos/28071658@N02/2712458517/"><img src="http://farm4.static.flickr.com/3065/2712458517_a1d41dc70b.jpg?v=0" alt="Improved Light Bar Controller" /></a></p>
<p>I made several improvements to my light bar controller.  I added a push button that pauses the controller on a desired color. I added a red LED to indicate if the controller is paused.  I also modified the light bar so that it easily plugs into the breadboard.  I did this by replacing the polarized right angle connectors with non polarized headers (one straight and one right angle).  The improved controller also uses the Bare Bones Board from the Modern Device Company instead of the Diecimila.  Below is an updated schematic of the controller.<span id="more-35"></span> Get the code <a href="http://www.krisbarrett.com/wp-content/uploads/2008/07/rgb2.c">here</a>.</p>
<p><a href="http://www.flickr.com/photos/28071658@N02/2712530385/in/set-72157606430368078/"><img src="http://farm4.static.flickr.com/3045/2712530385_646806f68a.jpg?v=0" alt="Schematic" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.krisbarrett.com/2008/07/29/improved-light-bar-controller/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Breadboard friendly Arduino</title>
		<link>http://www.krisbarrett.com/2008/06/17/freedunio-bare-bones-board/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=freedunio-bare-bones-board</link>
		<comments>http://www.krisbarrett.com/2008/06/17/freedunio-bare-bones-board/#comments</comments>
		<pubDate>Tue, 17 Jun 2008 21:21:03 +0000</pubDate>
		<dc:creator>Kris</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[arduino]]></category>
		<category><![CDATA[diy]]></category>

		<guid isPermaLink="false">http://www.krisbarrett.com/2008/06/17/freedunio-bare-bones-board/</guid>
		<description><![CDATA[I just assembled the Bare-Bones Board (BBB) from the Modern Device Company. The BBB is a &#8220;low-cost, breadboard-friendly Arduino-compatible&#8221; board. The BBB is cheaper than the popular Diecimila. This is because it doesn&#8217;t have the USB to UART chip from FTDI. Instead, the board connects to a cable that contains the FTDI chip. This means [&#8230;]]]></description>
				<content:encoded><![CDATA[<p><a title="Freeduino" href="http://www.krisbarrett.com/wp-content/uploads/2008/06/p6160012.JPG"><img src="http://www.krisbarrett.com/wp-content/uploads/2008/06/p6160012.JPG" alt="Freeduino" width="399" height="300" /></a></p>
<p>I just assembled the <a href="http://www.moderndevice.com/index.shtml">Bare-Bones Board (BBB)</a> from the Modern Device Company.  The BBB is a &#8220;low-cost, breadboard-friendly              <a href="http://www.arduino.cc">Arduino</a>-compatible&#8221; board.  The BBB is cheaper than the popular Diecimila.  This is because it doesn&#8217;t have the USB to UART chip from FTDI.   Instead, the board connects to a cable that contains the FTDI chip.  This means that if you plan on buying multiple boards, then you only pay for the FTDI chip once.   The board is also cheaper because you can buy it as a kit and build it yourself. The startup kit which includes the cable costs $33, $2 cheaper than the Diecimila.  Additional kits, not including the cable, cost only $15.<span id="more-33"></span></p>
<p>The BBB is very easy to build.  All of the components are through-hole except for one 15 uH inductor, so the components are easy to solder.  Also, the board requires a minimal amount of tools.  All you need is a soldering iron, diagonal cutters, and needle nose pliers.  Tweezers are also handy for soldering the surface mount inductor, but not completely necessary.  You also of course need solder.  I used lead free solder with a diameter of .032 inches.  Solder containing lead is easier to work with because of its lower melting temperature, but also more toxic, duh!  Desoldering braid is also important in case you make a mistake, I made a couple myself.</p>
<p>I am really happy with my new BBB. The BBB is cheap and easily plugs into a breadboard.  Also, I take more pride in it than my Diecimila because I built it myself.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.krisbarrett.com/2008/06/17/freedunio-bare-bones-board/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to un-clutter your desk with fluorescent lighting</title>
		<link>http://www.krisbarrett.com/2008/04/04/un-clutter-your-desk-with-fluorescent-lighting/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=un-clutter-your-desk-with-fluorescent-lighting</link>
		<comments>http://www.krisbarrett.com/2008/04/04/un-clutter-your-desk-with-fluorescent-lighting/#comments</comments>
		<pubDate>Sat, 05 Apr 2008 01:59:55 +0000</pubDate>
		<dc:creator>Kris</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[desk]]></category>
		<category><![CDATA[fluorescent light]]></category>

		<guid isPermaLink="false">http://www.krisbarrett.com/2008/04/04/un-clutter-your-desk-with-fluorescent-lighting/</guid>
		<description><![CDATA[If you have limited room on your desk, the last thing you need is a bulky desk lamp taking up space. I recently replaced my desk lamp with an under-cabinet fluorescent light fixture. This works well if you have shelves over your desk. If not, you might want to consider another alternative. This project involves [&#8230;]]]></description>
				<content:encoded><![CDATA[<p><img src="http://www.krisbarrett.com/wp-content/uploads/2008/04/p4040167.JPG" alt="Before" /></p>
<p><img src="http://www.krisbarrett.com/wp-content/uploads/2008/04/p4040163.JPG" alt="After" /></p>
<p>If you have limited room on your desk, the last thing you need is a bulky desk lamp taking up space.  I recently replaced my desk lamp with an under-cabinet fluorescent light fixture.  This works well if you have shelves over your desk.  If not, you might want to consider another alternative.  This project involves wiring so please be careful.<span id="more-23"></span></p>
<p><strong>Materials</strong></p>
<ul>
<li><!--[if !supportLists]-->Under-Cabinet Fluorescent Light Fixture &#8211; $21 – I bought this particular fixture because it has a pre-installed switch.  Also, it has a nice diffuser that covers the bulb.</li>
<li><!--[if !supportLists]--><!--[endif]-->Grounded Power Cord &#8211; $7 – For safety reasons, the light fixture must be grounded.</li>
<li><!--[if !supportLists]-->T8 Cool White Fluorescent Light Bulb &#8211; $7 – In retrospect, I should have bought the soft white bulb instead.  The cool white bulb is better suited for the garage.   Soft white would probably look better in the  home.</li>
<li><!--[if !supportLists]-->Total &#8211; $35</li>
</ul>
<p><strong>Tools</strong></p>
<ul>
<li>Drill</li>
<li>Screwdrivers</li>
<li>Wire cutters/strippers</li>
</ul>
<p><strong>Procedure</strong></p>
<p>Installing the light fixture took about 2 hours and was extremely easy.  The light fixture I bought contained detailed instructions on how to install it.  I recommend following the instructions included with the light fixture, but here are some general instructions just to give you an idea of how easy it is:</p>
<ol>
<li>Take apart the fixture</li>
<li>Mark the locations of the 2 mounting screws using the fixture housing as a template.</li>
<li>Drill 2 pilot holes for the mounting screws using a 5/32 inch drill bit.</li>
<li>Mount the fixture housing using the 2 mounting screws provided.</li>
<li>Connect the green, white, and black wires of the grounded power cord to the green, white, and black wires of the light fixture using the 3 wire nuts provided.</li>
<li>Put the fixture back together.</li>
<li>Install the fluorescent light bulb and the diffuser.</li>
<li>Your new fluorescent light is ready for use.</li>
</ol>
<p><strong>Final Thoughts</strong></p>
<p>I am happy with my new fluorescent light fixture.  It was easy to install and fairly cheap.  It only consumes 15 watts of power and provides plenty of light.  One thing that I don&#8217;t like is the ugly power cord running down my wall.  The next step in this project will be to find a way to conceal it.  Regardless, my desk looks much better than it did before.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.krisbarrett.com/2008/04/04/un-clutter-your-desk-with-fluorescent-lighting/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Fun with RGB LEDs</title>
		<link>http://www.krisbarrett.com/2008/01/15/tri-color-led-light-bar/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=tri-color-led-light-bar</link>
		<comments>http://www.krisbarrett.com/2008/01/15/tri-color-led-light-bar/#comments</comments>
		<pubDate>Tue, 15 Jan 2008 08:54:31 +0000</pubDate>
		<dc:creator>Kris</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[arduino]]></category>
		<category><![CDATA[led]]></category>
		<category><![CDATA[transistor]]></category>

		<guid isPermaLink="false">http://www.krisbarrett.com/2008/01/15/tri-color-led-light-bar/</guid>
		<description><![CDATA[&#160; I recently connected an Arduino to a Tri-Color LED Light Bar that I bought from SparkFun Electronics. I used pulse width modulation to control the brightness of each color. The individual colors combine to make the desired color. Download the code here and see the schematic below. &#160; &#160; &#160; R1 &#8211; R9: Current [&#8230;]]]></description>
				<content:encoded><![CDATA[<p><object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="425" height="344" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="src" value="http://www.youtube.com/v/FmoXM8m7e54&amp;hl=en" /><embed type="application/x-shockwave-flash" width="425" height="344" src="http://www.youtube.com/v/FmoXM8m7e54&amp;hl=en"></embed></object></p>
<p>&nbsp;</p>
<p>I recently connected an <a href="http://www.arduino.cc">Arduino</a> to a <a href="http://www.sparkfun.com/commerce/product_info.php?products_id=697">Tri-Color LED Light Bar</a> that I bought from <a href="http://www.sparkfun.com">SparkFun Electronics</a>.  I used pulse width modulation to control the brightness of each color.  The individual colors combine to make the desired color.  Download the code <a title="rgb.c" href="http://www.krisbarrett.com/wp-content/uploads/2008/01/rgb.c">here</a> and see the schematic below.<span id="more-20"></span></p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p><a title="Schematic" href="http://www.krisbarrett.com/wp-content/uploads/2008/01/rgb.png"><img src="http://www.krisbarrett.com/wp-content/uploads/2008/01/rgb.png" alt="Schematic" width="468" height="345" /></a></p>
<p>&nbsp;</p>
<ul>
<li><strong>R1 &#8211; R9: </strong>Current limiting resistors soldered directly to the light bar.  Using a multimeter, I determined that each resistor is about 453 ohms.</li>
<li><strong>LED1 &#8211; LED9: </strong>Red, green, and blue LED&#8217;s contained in 3 superflux packages.</li>
<li><strong>T1 &#8211; T3: </strong>The 2N3904 general purpose NPN transistors serve several purposes. First and foremost, the transistors increase the maximum current limit per color. Also, the transistors enable the Arduino&#8217;s smaller output voltage to switch a larger 12 volt source. Lastly, the LED&#8217;s are common anode.  This means that the cathodes must be pulled low to turn on the LED&#8217;s. The transistors simplify the code in that positive logic is used instead.</li>
</ul>
<p>I plan to buy more light bars, some higher current transistors, and a 12 volt power source for use on a larger scale.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.krisbarrett.com/2008/01/15/tri-color-led-light-bar/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to build a PC (on the cheap)</title>
		<link>http://www.krisbarrett.com/2007/11/09/build-walmarts-199-pc/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=build-walmarts-199-pc</link>
		<comments>http://www.krisbarrett.com/2007/11/09/build-walmarts-199-pc/#comments</comments>
		<pubDate>Fri, 09 Nov 2007 21:38:17 +0000</pubDate>
		<dc:creator>Kris</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[gos]]></category>
		<category><![CDATA[pc]]></category>

		<guid isPermaLink="false">http://www.krisbarrett.com/2007/11/09/build-walmarts-199-pc/</guid>
		<description><![CDATA[Last month, WalMart began selling a PC for under $200. This made me wonder, can you build it yourself for cheaper. I did a little bit of research and here is a breakdown of the cost: Motherboard &#8211; $59.99 Case &#8211; $29.99 Kingston 512 MB Memory &#8211; $14.99 Seagate 80 GB Hard Drive &#8211; $43.99 [&#8230;]]]></description>
				<content:encoded><![CDATA[<p><img src="http://www.krisbarrett.com/wp-content/uploads/2007/11/everex.jpg" alt="everex.jpg" width="467" height="304" /></p>
<p>Last month, WalMart began selling a PC for under $200.  This made me wonder, can you build it yourself for cheaper.  I did a little bit of research and here is a breakdown of the cost:</p>
<ul>
<li><!--[if !supportLists]--> <!--[endif]-->Motherboard &#8211; $59.99</li>
<li><!--[if !supportLists]--> <!--[endif]-->Case &#8211; $29.99</li>
<li><!--[if !supportLists]--> <!--[endif]-->Kingston 512 MB Memory &#8211; $14.99</li>
<li><!--[if !supportLists]--> <!--[endif]-->Seagate 80 GB Hard Drive &#8211; $43.99</li>
<li><!--[if !supportLists]--> <!--[endif]-->DVD-ROM/CD-RW Drive &#8211; $24.99</li>
<li><!--[if !supportLists]--> <!--[endif]--><a href="http://www.thinkgos.com/downloads.html">gOS</a> &#8211; free</li>
<li><!--[if !supportLists]--> <!--[endif]-->Logitech Keyboard &#8211; $9.25</li>
<li><!--[if !supportLists]-->Logitech Mouse &#8211; $7.29</li>
<li><!--[if !supportLists]--><!--[endif]-->Creative Speakers &#8211; $9.99</li>
<li><!--[if !supportLists]-->Total &#8211; $200.48</li>
</ul>
<p>As you can see, it costs about the same to build the PC yourself.  However, you are getting better quality hardware from major brands such as Kingston, Seagate, Logitech, and Creative.  When buying a PC off the shelf, you don’t usually know what hardware you are getting.  Also, if you think WalMart is evil, as many people do, then you don’t have to support them.  But above anything else, it is simply more fun to build it yourself than buy one off the shelf.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.krisbarrett.com/2007/11/09/build-walmarts-199-pc/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
	</channel>
</rss>
