<?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/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Microcontrollers and Electronics Project</title>
	<atom:link href="http://ermicroblog.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://ermicroblog.wordpress.com</link>
	<description>ermicro Microntrollers and Electronics Project Blog</description>
	<lastBuildDate>Sat, 17 Dec 2011 15:29:35 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='ermicroblog.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>Microcontrollers and Electronics Project</title>
		<link>http://ermicroblog.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://ermicroblog.wordpress.com/osd.xml" title="Microcontrollers and Electronics Project" />
	<atom:link rel='hub' href='http://ermicroblog.wordpress.com/?pushpress=hub'/>
		<item>
		<title>Building your own Simple Laser Projector using the Microchip PIC12F683 Microcontroller</title>
		<link>http://ermicroblog.wordpress.com/2010/10/16/building-your-own-simple-laser-projector-using-the-microchip-pic12f683-microcontroller/</link>
		<comments>http://ermicroblog.wordpress.com/2010/10/16/building-your-own-simple-laser-projector-using-the-microchip-pic12f683-microcontroller/#comments</comments>
		<pubDate>Sat, 16 Oct 2010 12:48:37 +0000</pubDate>
		<dc:creator>ermicroblog</dc:creator>
				<category><![CDATA[Microcontrollers]]></category>

		<guid isPermaLink="false">http://ermicroblog.wordpress.com/?p=87</guid>
		<description><![CDATA[The 8 pins PIC12F683 microcontroller is one of the smallest members of the Microchip 8-bit microcontroller families but equipped with powerful peripherals such as ADC and PWM capabilities. This make this tiny microcontroller is suitable for controlling the DC motor &#8230; <a href="http://ermicroblog.wordpress.com/2010/10/16/building-your-own-simple-laser-projector-using-the-microchip-pic12f683-microcontroller/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=87&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>The 8 pins PIC12F683 microcontroller is one of the smallest members of  the Microchip 8-bit microcontroller families but equipped with powerful  peripherals such as ADC and PWM capabilities. This make this tiny  microcontroller is suitable for controlling the DC motor speed. In order  to demonstrate the PIC12F683 capabilities and to make this tutorial  more attractive, I decided to use the PIC12F683 microcontroller to  generate simple and yet fascinating laser light show from a cheap  keychain laser pointer. You could read more information at <a title="ermicroblog link" href="http://www.ermicro.com/blog/?p=1622" target="_blank">ermicroblog</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ermicroblog.wordpress.com/87/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ermicroblog.wordpress.com/87/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ermicroblog.wordpress.com/87/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ermicroblog.wordpress.com/87/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/ermicroblog.wordpress.com/87/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/ermicroblog.wordpress.com/87/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/ermicroblog.wordpress.com/87/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/ermicroblog.wordpress.com/87/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ermicroblog.wordpress.com/87/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ermicroblog.wordpress.com/87/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ermicroblog.wordpress.com/87/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ermicroblog.wordpress.com/87/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ermicroblog.wordpress.com/87/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ermicroblog.wordpress.com/87/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=87&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://ermicroblog.wordpress.com/2010/10/16/building-your-own-simple-laser-projector-using-the-microchip-pic12f683-microcontroller/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/6940128413e2f524cee223c4ebaffcd0?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ermicroblog</media:title>
		</media:content>
	</item>
		<item>
		<title>Working with the Comparator Circuit</title>
		<link>http://ermicroblog.wordpress.com/2010/03/15/working-with-the-comparator-circuit/</link>
		<comments>http://ermicroblog.wordpress.com/2010/03/15/working-with-the-comparator-circuit/#comments</comments>
		<pubDate>Mon, 15 Mar 2010 02:55:46 +0000</pubDate>
		<dc:creator>ermicroblog</dc:creator>
				<category><![CDATA[Electronics]]></category>

		<guid isPermaLink="false">http://ermicroblog.wordpress.com/?p=81</guid>
		<description><![CDATA[Sometimes in the embedded system world we need to process the analog world and sending the signal to the microcontroller when the analog signal exceed some predetermine limit we’ve set. Some example of this situation is to send the interrupt &#8230; <a href="http://ermicroblog.wordpress.com/2010/03/15/working-with-the-comparator-circuit/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=81&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Sometimes in the embedded system world we need to process the analog  world and sending the signal to the microcontroller when the analog  signal exceed some predetermine limit we’ve set.  Some example of this  situation is to send the interrupt signal to the microcontroller  operation when the temperature is already exceeds certain limit or the  light intensity exceeds certain bright level. This is when the  comparator circuit becomes handy as it’s designed specially for this  purpose. You could read more information at <a title="ermicroblog official website" href="http://www.ermicro.com/blog/?p=1578" target="_blank">ermicroblog</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ermicroblog.wordpress.com/81/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ermicroblog.wordpress.com/81/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ermicroblog.wordpress.com/81/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ermicroblog.wordpress.com/81/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/ermicroblog.wordpress.com/81/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/ermicroblog.wordpress.com/81/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/ermicroblog.wordpress.com/81/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/ermicroblog.wordpress.com/81/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ermicroblog.wordpress.com/81/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ermicroblog.wordpress.com/81/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ermicroblog.wordpress.com/81/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ermicroblog.wordpress.com/81/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ermicroblog.wordpress.com/81/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ermicroblog.wordpress.com/81/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=81&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://ermicroblog.wordpress.com/2010/03/15/working-with-the-comparator-circuit/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/6940128413e2f524cee223c4ebaffcd0?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ermicroblog</media:title>
		</media:content>
	</item>
		<item>
		<title>Build Your Own Simple and Easy PICAXE Microcontroller Based Photovore Robot</title>
		<link>http://ermicroblog.wordpress.com/2010/02/04/build-your-own-simple-and-easy-picaxe-microcontroller-based-photovore-robot/</link>
		<comments>http://ermicroblog.wordpress.com/2010/02/04/build-your-own-simple-and-easy-picaxe-microcontroller-based-photovore-robot/#comments</comments>
		<pubDate>Thu, 04 Feb 2010 02:33:02 +0000</pubDate>
		<dc:creator>ermicroblog</dc:creator>
				<category><![CDATA[Microcontrollers]]></category>

		<guid isPermaLink="false">http://ermicroblog.wordpress.com/?p=54</guid>
		<description><![CDATA[Building a simple and easy microcontroller based robot is always a fascinating topic to be discussed, especially for the robotics newbie enthusiast. On this tutorial I will show you how to build your own microcontroller based robot which known as &#8230; <a href="http://ermicroblog.wordpress.com/2010/02/04/build-your-own-simple-and-easy-picaxe-microcontroller-based-photovore-robot/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=54&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Building a simple and easy microcontroller based robot is always a  fascinating topic to be discussed, especially for the robotics newbie  enthusiast. On this tutorial I will show you how to build your own  microcontroller based robot which known as a photovore or you could call  it as the light chaser robot using the simplest possible circuit for  the microcontroller based robot brain, locomotion motor and the sensor. You could read more information at <a title="ermicroblog official website" href="http://www.ermicro.com/blog/?p=1549" target="_blank">ermicroblog</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ermicroblog.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ermicroblog.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ermicroblog.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ermicroblog.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/ermicroblog.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/ermicroblog.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/ermicroblog.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/ermicroblog.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ermicroblog.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ermicroblog.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ermicroblog.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ermicroblog.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ermicroblog.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ermicroblog.wordpress.com/54/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=54&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://ermicroblog.wordpress.com/2010/02/04/build-your-own-simple-and-easy-picaxe-microcontroller-based-photovore-robot/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/6940128413e2f524cee223c4ebaffcd0?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ermicroblog</media:title>
		</media:content>
	</item>
		<item>
		<title>Make your own Microcontroller Printed Circuit Board (PCB) using the Toner Transfer Method</title>
		<link>http://ermicroblog.wordpress.com/2010/01/03/make-your-own-microcontroller-printed-circuit-board-pcb-using-the-toner-transfer-method/</link>
		<comments>http://ermicroblog.wordpress.com/2010/01/03/make-your-own-microcontroller-printed-circuit-board-pcb-using-the-toner-transfer-method/#comments</comments>
		<pubDate>Sun, 03 Jan 2010 02:27:15 +0000</pubDate>
		<dc:creator>ermicroblog</dc:creator>
				<category><![CDATA[Electronics]]></category>

		<guid isPermaLink="false">http://ermicroblog.wordpress.com/?p=47</guid>
		<description><![CDATA[As the electronics hobbyist one of knowledge that we have to be familiar with is how to make our own printed circuit board (PCB). Making our own simple single side PCB actually is not require a sophisticated technique and technology &#8230; <a href="http://ermicroblog.wordpress.com/2010/01/03/make-your-own-microcontroller-printed-circuit-board-pcb-using-the-toner-transfer-method/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=47&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>As the electronics hobbyist one of knowledge that we have to be familiar  with is how to make our own printed circuit board (PCB). Making our own  simple single side PCB actually is not require a sophisticated  technique and technology as you might think, instead most of the  required materials is already available at your home. I’ve started make  my first single side through-hole PCB for a simple two transistors  astable multivibrator project using just a water proof marker and draw  the PCB layout directly on the PCB copper surface. You could read more information at <a title="Ermicroblog Official Website" href="http://www.ermicro.com/blog/?p=1526" target="_blank">ermicroblog</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ermicroblog.wordpress.com/47/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ermicroblog.wordpress.com/47/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ermicroblog.wordpress.com/47/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ermicroblog.wordpress.com/47/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/ermicroblog.wordpress.com/47/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/ermicroblog.wordpress.com/47/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/ermicroblog.wordpress.com/47/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/ermicroblog.wordpress.com/47/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ermicroblog.wordpress.com/47/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ermicroblog.wordpress.com/47/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ermicroblog.wordpress.com/47/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ermicroblog.wordpress.com/47/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ermicroblog.wordpress.com/47/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ermicroblog.wordpress.com/47/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=47&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://ermicroblog.wordpress.com/2010/01/03/make-your-own-microcontroller-printed-circuit-board-pcb-using-the-toner-transfer-method/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/6940128413e2f524cee223c4ebaffcd0?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ermicroblog</media:title>
		</media:content>
	</item>
		<item>
		<title>PIC18 Pulse Width Modulation (PWM) DC Motor Speed Controller with the RPM Counter Project</title>
		<link>http://ermicroblog.wordpress.com/2009/12/09/pic18-pulse-width-modulation-pwm-dc-motor-speed-controller-with-the-rpm-counter-project/</link>
		<comments>http://ermicroblog.wordpress.com/2009/12/09/pic18-pulse-width-modulation-pwm-dc-motor-speed-controller-with-the-rpm-counter-project/#comments</comments>
		<pubDate>Wed, 09 Dec 2009 02:30:12 +0000</pubDate>
		<dc:creator>ermicroblog</dc:creator>
				<category><![CDATA[Microcontrollers]]></category>

		<guid isPermaLink="false">http://ermicroblog.wordpress.com/?p=51</guid>
		<description><![CDATA[Equipped with sophisticated Enhanced Capture/Compare/PWM (ECCP) peripheral the Microchip PIC18F14K50 microcontroller could produce up to four PWM channels output. The enhanced PWM (Pulse Width Modulation) mode in ECCP peripheral is capable to drive the full bridge DC Motor circuit directly &#8230; <a href="http://ermicroblog.wordpress.com/2009/12/09/pic18-pulse-width-modulation-pwm-dc-motor-speed-controller-with-the-rpm-counter-project/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=51&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Equipped with sophisticated Enhanced Capture/Compare/PWM (ECCP)  peripheral the Microchip PIC18F14K50 microcontroller could produce up to  four PWM channels output. The enhanced PWM (Pulse Width Modulation)  mode in ECCP peripheral is capable to drive the full bridge DC Motor  circuit directly both in forward or reverse direction. It also could  generate single PWM output on the selectable PIC18F14K50 pins when it  configured in pulse steering mode. You could read more information at <a title="ermicroblog official website" href="http://www.ermicro.com/blog/?p=1461" target="_blank">ermicroblog</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ermicroblog.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ermicroblog.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ermicroblog.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ermicroblog.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/ermicroblog.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/ermicroblog.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/ermicroblog.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/ermicroblog.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ermicroblog.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ermicroblog.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ermicroblog.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ermicroblog.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ermicroblog.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ermicroblog.wordpress.com/51/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=51&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://ermicroblog.wordpress.com/2009/12/09/pic18-pulse-width-modulation-pwm-dc-motor-speed-controller-with-the-rpm-counter-project/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/6940128413e2f524cee223c4ebaffcd0?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ermicroblog</media:title>
		</media:content>
	</item>
		<item>
		<title>Transforming your AVR Microcontroller to the I2C or TWI Slave I/O Expander Project</title>
		<link>http://ermicroblog.wordpress.com/2009/09/27/transforming-your-avr-microcontroller-to-the-i2c-or-twi-slave-io-expander-project/</link>
		<comments>http://ermicroblog.wordpress.com/2009/09/27/transforming-your-avr-microcontroller-to-the-i2c-or-twi-slave-io-expander-project/#comments</comments>
		<pubDate>Sun, 27 Sep 2009 02:38:27 +0000</pubDate>
		<dc:creator>ermicroblog</dc:creator>
				<category><![CDATA[Microcontrollers]]></category>

		<guid isPermaLink="false">http://ermicroblog.wordpress.com/?p=60</guid>
		<description><![CDATA[The I2C bus (read as I squared C) is one of the most important embedded system serial bus interface first introduced by Philips in 1980; using just two lines called SCL (serial clock) and SDA (serial data) respectively make the &#8230; <a href="http://ermicroblog.wordpress.com/2009/09/27/transforming-your-avr-microcontroller-to-the-i2c-or-twi-slave-io-expander-project/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=60&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>The I2C bus (read as I squared C) is one of the most important embedded  system serial bus interface first introduced by Philips in 1980; using  just two lines called SCL (serial clock) and SDA (serial data)  respectively make the I2C bus is a perfect choice to provide additional  I/O capabilities to your microcontroller project without changing your  microcontroller type and design in order to increase the I/O port pins. You could read more information at <a title="ermicroblog official website" href="http://www.ermicro.com/blog/?p=1239" target="_blank">ermicroblog</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ermicroblog.wordpress.com/60/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ermicroblog.wordpress.com/60/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ermicroblog.wordpress.com/60/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ermicroblog.wordpress.com/60/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/ermicroblog.wordpress.com/60/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/ermicroblog.wordpress.com/60/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/ermicroblog.wordpress.com/60/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/ermicroblog.wordpress.com/60/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ermicroblog.wordpress.com/60/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ermicroblog.wordpress.com/60/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ermicroblog.wordpress.com/60/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ermicroblog.wordpress.com/60/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ermicroblog.wordpress.com/60/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ermicroblog.wordpress.com/60/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=60&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://ermicroblog.wordpress.com/2009/09/27/transforming-your-avr-microcontroller-to-the-i2c-or-twi-slave-io-expander-project/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/6940128413e2f524cee223c4ebaffcd0?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ermicroblog</media:title>
		</media:content>
	</item>
		<item>
		<title>Build Your Own Transistor Based Mobile Line Follower Robot (LFR) – First Part</title>
		<link>http://ermicroblog.wordpress.com/2009/07/11/build-your-own-transistor-based-mobile-line-follower-robot-lfr-%e2%80%93-first-part/</link>
		<comments>http://ermicroblog.wordpress.com/2009/07/11/build-your-own-transistor-based-mobile-line-follower-robot-lfr-%e2%80%93-first-part/#comments</comments>
		<pubDate>Sat, 11 Jul 2009 02:41:19 +0000</pubDate>
		<dc:creator>ermicroblog</dc:creator>
				<category><![CDATA[Electronics]]></category>

		<guid isPermaLink="false">http://ermicroblog.wordpress.com/?p=63</guid>
		<description><![CDATA[The mobile line follower robot is a type of mobile robot with only has one specific task which is to follow the line made with black tape over the white background or vise verse. The LFR perhaps is one of &#8230; <a href="http://ermicroblog.wordpress.com/2009/07/11/build-your-own-transistor-based-mobile-line-follower-robot-lfr-%e2%80%93-first-part/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=63&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>The mobile line follower robot is a type of mobile robot with only has  one specific task which is to follow the line made with black tape over  the white background or vise verse. The LFR perhaps is one of the most  popular robot build by the roboticists. What makes this LFR is so  popular, I think because of its simplicity and yet it could be used as  the teaching tools of how we could implement the industrial standard  control system such as the PID (Proportional Integral Deferential)  control system on this robot. Another factor probably is the increase of  the LFR annual tournament conducted in many countries. You could read more information at <a title="ermicroblog official website" href="http://www.ermicro.com/blog/?p=1097" target="_blank">ermicroblog</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ermicroblog.wordpress.com/63/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ermicroblog.wordpress.com/63/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ermicroblog.wordpress.com/63/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ermicroblog.wordpress.com/63/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/ermicroblog.wordpress.com/63/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/ermicroblog.wordpress.com/63/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/ermicroblog.wordpress.com/63/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/ermicroblog.wordpress.com/63/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ermicroblog.wordpress.com/63/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ermicroblog.wordpress.com/63/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ermicroblog.wordpress.com/63/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ermicroblog.wordpress.com/63/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ermicroblog.wordpress.com/63/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ermicroblog.wordpress.com/63/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=63&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://ermicroblog.wordpress.com/2009/07/11/build-your-own-transistor-based-mobile-line-follower-robot-lfr-%e2%80%93-first-part/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/6940128413e2f524cee223c4ebaffcd0?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ermicroblog</media:title>
		</media:content>
	</item>
		<item>
		<title>Using Serial Peripheral Interface (SPI) Master and Slave with Atmel AVR Microcontroller</title>
		<link>http://ermicroblog.wordpress.com/2009/06/25/using-serial-peripheral-interface-spi-master-and-slave-with-atmel-avr-microcontroller/</link>
		<comments>http://ermicroblog.wordpress.com/2009/06/25/using-serial-peripheral-interface-spi-master-and-slave-with-atmel-avr-microcontroller/#comments</comments>
		<pubDate>Thu, 25 Jun 2009 02:44:06 +0000</pubDate>
		<dc:creator>ermicroblog</dc:creator>
				<category><![CDATA[Microcontrollers]]></category>

		<guid isPermaLink="false">http://ermicroblog.wordpress.com/?p=68</guid>
		<description><![CDATA[Sometimes we need to extend or add more I/O ports to our microcontroller based project; the question is how fast the response we need for these new I/O ports. Because usually we only have a limited I/O port left than &#8230; <a href="http://ermicroblog.wordpress.com/2009/06/25/using-serial-peripheral-interface-spi-master-and-slave-with-atmel-avr-microcontroller/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=68&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Sometimes we need to extend or add more I/O ports to our microcontroller  based project; the question is how fast the response we need for these  new I/O ports. Because usually we only have a limited I/O port left than  the logical choice is to use the serial data transfer method; which  usually only required maximum one to four ports for doing the data  transfer. Currently there are few types of modern embedded system serial  data transfer interface widely supported by most of the chip’s  manufactures such as I2C (read as I square C), SPI (Serial Peripheral  Interface), 1-Wire (One Wire), Controller Area Network (CAN), USB  (Universal Serial Bus) and the RS-232 families (RS-423, RS-422 and  RS-485). The last three interface types is used for quiet long  connection between the microcontroller and the devices, up to 1200  meters for the RS-485 specification, while the first three is used for  short range connection. You could read more information at <a title="ermicroblog official website" href="http://www.ermicro.com/blog/?p=1050" target="_blank">ermicroblog</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ermicroblog.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ermicroblog.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ermicroblog.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ermicroblog.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/ermicroblog.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/ermicroblog.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/ermicroblog.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/ermicroblog.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ermicroblog.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ermicroblog.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ermicroblog.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ermicroblog.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ermicroblog.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ermicroblog.wordpress.com/68/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=68&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://ermicroblog.wordpress.com/2009/06/25/using-serial-peripheral-interface-spi-master-and-slave-with-atmel-avr-microcontroller/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/6940128413e2f524cee223c4ebaffcd0?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ermicroblog</media:title>
		</media:content>
	</item>
		<item>
		<title>Using Maxim DS1307 Real Time Clock with Atmel AVR Microcontroller</title>
		<link>http://ermicroblog.wordpress.com/2009/05/11/using-maxim-ds1307-real-time-clock-with-atmel-avr-microcontroller/</link>
		<comments>http://ermicroblog.wordpress.com/2009/05/11/using-maxim-ds1307-real-time-clock-with-atmel-avr-microcontroller/#comments</comments>
		<pubDate>Mon, 11 May 2009 02:47:44 +0000</pubDate>
		<dc:creator>ermicroblog</dc:creator>
				<category><![CDATA[Microcontrollers]]></category>

		<guid isPermaLink="false">http://ermicroblog.wordpress.com/?p=73</guid>
		<description><![CDATA[Building our own digital clock is one of the dreamed project by most of the hobbyist or anyone that want to learn or involve seriously in the embedded system world; the ability to integrate time, day and date to the &#8230; <a href="http://ermicroblog.wordpress.com/2009/05/11/using-maxim-ds1307-real-time-clock-with-atmel-avr-microcontroller/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=73&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Building our own digital clock is one of the dreamed project by most of  the hobbyist or anyone that want to learn or involve seriously in the  embedded system world; the ability to integrate time, day and date to  the embedded system is one of the important knowledge that should be  known by any embedded system designer. Today’s technology makes life  easier as all these capabilities has already built nicely inside the  Maxim (Dallas) DS1307 Real Time Clock (RTC) chip. You could read more information at <a title="ermicroblog official website" href="http://www.ermicro.com/blog/?p=950" target="_blank">ermicroblog</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ermicroblog.wordpress.com/73/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ermicroblog.wordpress.com/73/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ermicroblog.wordpress.com/73/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ermicroblog.wordpress.com/73/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/ermicroblog.wordpress.com/73/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/ermicroblog.wordpress.com/73/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/ermicroblog.wordpress.com/73/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/ermicroblog.wordpress.com/73/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ermicroblog.wordpress.com/73/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ermicroblog.wordpress.com/73/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ermicroblog.wordpress.com/73/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ermicroblog.wordpress.com/73/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ermicroblog.wordpress.com/73/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ermicroblog.wordpress.com/73/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=73&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://ermicroblog.wordpress.com/2009/05/11/using-maxim-ds1307-real-time-clock-with-atmel-avr-microcontroller/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/6940128413e2f524cee223c4ebaffcd0?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ermicroblog</media:title>
		</media:content>
	</item>
		<item>
		<title>Beginners AVR Assembler Language Programming 2</title>
		<link>http://ermicroblog.wordpress.com/2008/11/30/beginners-avr-assembler-language-programming-2/</link>
		<comments>http://ermicroblog.wordpress.com/2008/11/30/beginners-avr-assembler-language-programming-2/#comments</comments>
		<pubDate>Sun, 30 Nov 2008 17:27:53 +0000</pubDate>
		<dc:creator>ermicroblog</dc:creator>
				<category><![CDATA[Microcontrollers]]></category>

		<guid isPermaLink="false">http://ermicroblog.wordpress.com/?p=33</guid>
		<description><![CDATA[From her house&#8217;s window, she could see David holding his notebook walking across the street towards her house. She runs down the stair to open the door (click here for first tutorial) David: Hi&#8230; sorry for being late, I&#8217;ve had &#8230; <a href="http://ermicroblog.wordpress.com/2008/11/30/beginners-avr-assembler-language-programming-2/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=33&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>From her house&#8217;s window, she could see David holding his notebook walking across the street towards her house. She runs down the stair to open the door (click <a title="Beginners AVR Assembler Language Programming 1" href="http://ermicroblog.wordpress.com/2008/11/30/beginners-avr-assembler-language-programming-1/" target="_blank">here</a> for first tutorial)</p>
<p><strong>David:</strong><br />
Hi&#8230; sorry for being late, I&#8217;ve had trouble downloaded the Atmel AVR Studio 4 and the ATtiny 2313 microcontroller datasheet as you asked me yesterday; You know it&#8217;s seem my internet provider always has a problem when I need it most.<span id="more-33"></span></p>
<p><strong>Susan:</strong><br />
Did you manage to download it, because this is very important if you want to code in AVR microcontroller&#8217;s assembler language you must have this tools and the datasheet near you.</p>
<p><strong>David:</strong><br />
Yeah, I went to the free hotspot at the mall near here and download it.</p>
<p><strong>Susan:</strong><br />
Ok&#8230; let&#8217;s continue our AVR assembler language microcontroller programming lesson; I like to begin first with the registers. The microcontroller&#8217;s register actually is the special memory inside the microcontroller that functioning similar to the control panel. You just imagine the control panel with the switches and the indicator lamps. Whatever you want the microcontroller to do something, you just turn on or turn off some of these switches on the panel.</p>
<p><strong>David:</strong><br />
It&#8217;s seems like operating my DVD player; if I want to play a movie, I just press the play button.</p>
<p><strong>Susan:</strong><br />
The idea it similar, but this sophisticated AVR microcontroller registers contain more then just one switch. The ATtiny2313 is 8-bit microcontroller this mean this microcontroller process the data in the 8-bit form. Now take a look on the <strong>registers summary</strong> of the AVR ATtiny2313 microcontroller datasheet on page 215.</p>
<p><strong>David:</strong><br />
It looks quite a lot of registers there; but all of registers is 8-bit wide and they also have a funny name. Do I have to remember all this names?</p>
<p><strong>Susan:</strong><br />
No you don&#8217;t by the time you become acquainted with this AVR microcontroller than automatically you will remember the names and their functions. Another type of registers is called <strong>general purpose registers</strong> see datasheet on page 9 and 12; this registers is directly connected to the microcontroller&#8217;s ALU (Arithmetic Logical Unit), so it can be used to perform these following tasks:</p>
<p>1.      Arithmetic operation e.g. adding (ADD) and subtract (SUB)<br />
2.      Logical operation e.g. AND and OR<br />
3.      Bit function operation e.g. set bit(s) register (SBR) and clear bit(s) register (CBR)</p>
<p><strong>David:</strong><br />
So what is the different between the first register you&#8217;ve mentioned and the general purpose registers.</p>
<p><strong>Susan:</strong><br />
The first register on the page 215 is called <strong>instruction registers</strong>; while the general purpose register is used for ALU arithmetic, logical and bit functions operation and there are 32 general purpose registers see the datasheet on page 12; named R0 to R31.</p>
<p>For example if you want to instruct AVR microcontroller to add the number 9 and 6, than you have to do this in the general purpose registers; and if you want to present the result which is 15 to the outside world than you have to use the instruction registers.</p>
<p><strong>David:</strong><br />
Ok&#8230; can we do this example first before I&#8217;m getting more confuse.</p>
<p><strong>Susan:</strong><br />
First I&#8217;ll write down the instruction on the paper so I could explain this code straightforward to you, later on we will put this code to the Atmel AVR Studio 4:</p>
<p><strong> </strong></p>
<pre>LDI R16,9
LDI R17,6
ADD R17,R16

LDI R18,255
OUT DDRB,R18
OUT PORTB,R17</pre>
<p>The LDI, ADD and OUT command is called <strong>mnemonic</strong>; this is the syntax of assembler language in the form of human language. The LDI mean &#8220;<strong>load immediate</strong>&#8220;, therefore the command <strong>LDI R16,200</strong> means load immediately a constant number 9 to the general purpose register named R16.</p>
<p><strong>David:</strong><br />
Why you use R16 instead of R0, is it easier to remember always start with R0, R1 and so on.</p>
<p><strong>Susan:</strong><br />
Good question; this is because the AVR microcontroller general purpose registers from R0 to R15 could not be used for loading a constant directly; the <strong>load immediate</strong> (LDI) statement only works for registers R16 to R31</p>
<p><strong>David:</strong><br />
Ok&#8230; I understand now, It&#8217;s seems this general purpose registers similar to the variables in high level language such as assigning the constant to the variable in C language:</p>
<pre>unsigned char myvar1,myvar2;</pre>
<pre>myvar1 = 9;
myvar2 = 6;</pre>
<p>or if I write down in BASIC language:</p>
<pre>dim myvar1,myvar2</pre>
<pre>myvar1 = 9
myvar2 = 6</pre>
<p><strong>Susan:</strong><br />
Now you&#8217;ll see the similarity between assembler language and high level language; in the high level language we don&#8217;t care about where the compiler will put our variables; but in assembler we as programmer that make the decision where to put our constant. Ok let&#8217;s move on to the <strong>ADD R17,R16</strong> statement, this statement just simply adding the value of register R16 to the existing value of register R17; now the value of register R17 should be 15.</p>
<p><strong>David:</strong><br />
For my own reference I will write down this assembler statement in the form of C language statement:</p>
<pre>unsigned char myvar1,myvar2;</pre>
<pre>myvar1 = 9;                // LDI R16,9
myvar2 = 6;                // LDI R17,6
myvar2 = myvar2 + myvar1;  // ADD R17,R16</pre>
<p><strong>Susan:</strong><br />
You&#8217;ve seem making a progress now; some of the assembler programmers put the equivalent C syntax as the comment for their assembler program; this give them a clear picture of what the program do. The next three statements involving the AVR microcontroller I/O (input/output) instruction registers.</p>
<p>The AVR ATtiny2313&#8242;s have 18 programmable I/O lines; all of these I/O registers is a bidirectional I/O and it only can work one direction at a time. In order to control which direction of this I/O to be used, we have to set the <strong>data direction register</strong> for the Port B.</p>
<p><strong>David:</strong><br />
This data direction register is sound like the three state bidirectional bus logic to me that allow data to move only one direction at the time.</p>
<p><strong>Susan:</strong><br />
Yeah, you&#8217;ll right on page 50 of the ATtiny2313 datasheet you could see the schematic and the detail explanation of these I/O port. Therefore to enable each of this Port B bits as an output we have to put the logic one to all the Port B data direction register named DDRB bits as follow:</p>
<pre>LDI R18,255
OUT DDRB,R18</pre>
<p>The 255 value is equivalent to &#8220;<strong>1111 1111</strong>&#8221; in binary or &#8220;<strong>FF</strong>&#8221; in hexadecimal number.</p>
<p><strong>David:</strong><br />
Why you have to use the R18; why not just directly assign the value 255 to the DDRB?</p>
<p><strong>Susan:</strong><br />
There is no such statement in the AVR microcontroller assembler; the only way to put the value to the DDRB is through the general purpose register using the OUT statement and this also valid for the Port B. On our last example program statement; we assign the R17 value to the Port  B:</p>
<pre>OUT PORTB,R17</pre>
<p>Of course in C; we can assign the value to this direction register directly; that&#8217;s the job of the C compiler to convert it as we&#8217;ve done in assembler. Therefore the complete C equivalent syntax for your reference is</p>
<pre>unsigned char myvar1,myvar2;</pre>
<pre>myvar1 = 9;                // LDI R16,9
myvar2 = 6;                // LDI R17,6
myvar2 = myvar2 + myvar1;  // ADD R17,R16</pre>
<pre>DDRB = 255;                // LDI R18,255 + OUT DDRB,R18
PORTB = myvar2;            // OUT PORTB,R17</pre>
<p><strong>David:</strong><br />
Ok&#8230; let&#8217;s put the code into the Atmel AVR Studio 4.</p>
<p><strong>Susan:</strong><br />
When you first start the Atmel AVR Studio 4 it will show you the Project Wizard window, choose the new project button and It will prompt you to enter the Project type, Project name and the Project location:</p>
<p><a href="http://ermicroblog.files.wordpress.com/2008/11/basm_01.jpg"><img class="alignnone size-full wp-image-34" title="basm_01" src="http://ermicroblog.files.wordpress.com/2008/11/basm_01.jpg?w=584" alt="basm_01"   /></a></p>
<p>I Choose <strong>Atmel AVR Assembler</strong> for Project Type and <strong>myfirstasm</strong> as the Project name; and for the project location; I use the <strong>f:\avr</strong> directory. Press the Next button and the project wizard will show you the debug platform and device window:</p>
<p><a href="http://ermicroblog.files.wordpress.com/2008/11/basm_02.jpg"><img class="alignnone size-full wp-image-35" title="basm_02" src="http://ermicroblog.files.wordpress.com/2008/11/basm_02.jpg?w=584" alt="basm_02"   /></a></p>
<p>We use the AVR Simulator as the debugging tools and select ATtiny2313 from the device. Then press the Finish button.</p>
<p><a href="http://ermicroblog.files.wordpress.com/2008/11/basm_03.jpg"><img class="alignnone size-full wp-image-36" title="basm_03" src="http://ermicroblog.files.wordpress.com/2008/11/basm_03.jpg?w=584" alt="basm_03"   /></a></p>
<p>This will bring you to the Atmel AVR Studio 4 IDE (integrated development environment). Now I will write down our first example code to the program editor as follow:</p>
<pre>; Program         : myfirstasm.asm
; Description     : Lessons 1: Starting Assembler Program
; Last Updated    : 22  September 2008
; Author          : Susan</pre>
<pre>.include "2313def.inc"</pre>
<pre>; Start on the flash ram's address 0
.org 0</pre>
<pre>main: ldi  R16,9
      ldi  R17,6
      add  R17,R16
      ldi  R18,255
      out  DDRB,R18
      out  PORTB,R17
      rjmp main</pre>
<p><strong>David:</strong><br />
It&#8217;s seems you put a few new strange statement and my guessed the &#8220;<strong>;</strong>&#8221; sign is the comment mark for assembler language similar to C &#8220;<strong>//</strong>&#8221; or &#8220;<strong>/* */</strong>&#8221; marks.</p>
<p><strong>Susan:</strong><br />
The <strong>.include</strong> and <strong>.org</strong> statement is called a compiler directive; this is not the assembler language statement. This first statement is to instruct the compiler to include the ATtiny2313 definition library which you can found in <strong>c:\Program Files\Atmel\AVR Tools\AvrAssembler</strong> directory when compiling the code. The <strong>.org</strong> or <strong>originate</strong> statement is to instruct the compiler to put the code on AVR flash ram address 0 when compiling the code.</p>
<p>The <strong>rjmp</strong> is a <strong>relative jump instruction</strong>; this assembler statement simply tells the microcontroller program pointer to jump or pointing to the label main. This makes our program to always repeating this code forever.</p>
<p>Now let&#8217;s build and start debugging the code. On the menu <strong>Build</strong> -&gt; <strong>Build</strong> or Press <strong>F7</strong> to compile the code and start debugging from menu <strong>Debug</strong> -&gt; <strong>Start Debugging</strong>.</p>
<p><a href="http://ermicroblog.files.wordpress.com/2008/11/basm_04.jpg"><img class="alignnone size-full wp-image-37" title="basm_04" src="http://ermicroblog.files.wordpress.com/2008/11/basm_04.jpg?w=584" alt="basm_04"   /></a></p>
<p><strong>David:</strong><br />
Wow&#8230; this debugging facility on the Atmel AVR Studio 4 it&#8217;s very useful and informative; this means I could run and test the code even though there is no physical AVR microcontroller hardware.</p>
<p><strong>Susan:</strong><br />
That&#8217;s right; it&#8217;s also a good practice for all the microcontroller&#8217;s programmers to first debug their code before flashing it into the microcontroller. Now to continue execute the code we just use <strong>Step Into</strong> command; from menu <strong>Debug</strong> -&gt; <strong>Step Into</strong> or press <strong>F11</strong> repeatedly while watching the Registers status and the PORT B status windows.</p>
<p><a href="http://ermicroblog.files.wordpress.com/2008/11/basm_05.jpg"><img class="alignnone size-full wp-image-38" title="basm_05" src="http://ermicroblog.files.wordpress.com/2008/11/basm_05.jpg?w=584" alt="basm_05"   /></a></p>
<p><strong>David:</strong><br />
Ok, I think up to this point I&#8217;ve learned the basic Atmel AVR assembler language and how to use the AVR Studio 4 for building and debugging the code. Now it&#8217;s time to put it on the real hardware. What is your suggestion Susan?</p>
<p><strong>Susan:</strong><br />
First you have to build the basic AVR microcontroller ATtiny2313 hardware and find a good AVR programmer; which enable you to transfer the code created by AVR Studio 4 into the microcontroller. My suggestion is to use the Atmel AVRISP mkII for AVR programmer; because this programmer is fully integrated in AVR Studio 4 and can be used to program almost all the Atmel AVR microcontroller&#8217;s family. For the basic AVR ATtiny2313 hardware; you could use this following schematic:</p>
<p><a href="http://ermicroblog.files.wordpress.com/2008/11/basm_06.jpg"><img class="alignnone size-full wp-image-39" title="basm_06" src="http://ermicroblog.files.wordpress.com/2008/11/basm_06.jpg?w=584" alt="basm_06"   /></a></p>
<p><strong>David:</strong><br />
Thanks Susan; I&#8217;ll try to find the programmer and build this hardware first before we continue learning this AVR assembler language. Anyway are you free this Friday for a dinner?</p>
<p><strong>Susan:</strong><br />
Is a date?</p>
<p><strong>David:</strong><br />
Yes, will you? Please&#8230;</p>
<p><strong>Susan:</strong><br />
Ok, I&#8217;ll see you on Friday</p>
<p><strong>David:</strong><br />
Bye Susan and thanks for your time</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ermicroblog.wordpress.com/33/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ermicroblog.wordpress.com/33/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ermicroblog.wordpress.com/33/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ermicroblog.wordpress.com/33/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/ermicroblog.wordpress.com/33/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/ermicroblog.wordpress.com/33/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/ermicroblog.wordpress.com/33/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/ermicroblog.wordpress.com/33/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ermicroblog.wordpress.com/33/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ermicroblog.wordpress.com/33/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ermicroblog.wordpress.com/33/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ermicroblog.wordpress.com/33/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ermicroblog.wordpress.com/33/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ermicroblog.wordpress.com/33/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ermicroblog.wordpress.com&amp;blog=5666503&amp;post=33&amp;subd=ermicroblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://ermicroblog.wordpress.com/2008/11/30/beginners-avr-assembler-language-programming-2/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/6940128413e2f524cee223c4ebaffcd0?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ermicroblog</media:title>
		</media:content>

		<media:content url="http://ermicroblog.files.wordpress.com/2008/11/basm_01.jpg" medium="image">
			<media:title type="html">basm_01</media:title>
		</media:content>

		<media:content url="http://ermicroblog.files.wordpress.com/2008/11/basm_02.jpg" medium="image">
			<media:title type="html">basm_02</media:title>
		</media:content>

		<media:content url="http://ermicroblog.files.wordpress.com/2008/11/basm_03.jpg" medium="image">
			<media:title type="html">basm_03</media:title>
		</media:content>

		<media:content url="http://ermicroblog.files.wordpress.com/2008/11/basm_04.jpg" medium="image">
			<media:title type="html">basm_04</media:title>
		</media:content>

		<media:content url="http://ermicroblog.files.wordpress.com/2008/11/basm_05.jpg" medium="image">
			<media:title type="html">basm_05</media:title>
		</media:content>

		<media:content url="http://ermicroblog.files.wordpress.com/2008/11/basm_06.jpg" medium="image">
			<media:title type="html">basm_06</media:title>
		</media:content>
	</item>
	</channel>
</rss>
