<?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>Anrusal&#039;s Blog</title>
	<atom:link href="http://anrusal.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://anrusal.wordpress.com</link>
	<description>Just another WordPress.com weblog</description>
	<lastBuildDate>Thu, 29 Oct 2009 23:10:50 +0000</lastBuildDate>
	<language>es</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='anrusal.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>Anrusal&#039;s Blog</title>
		<link>http://anrusal.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://anrusal.wordpress.com/osd.xml" title="Anrusal&#039;s Blog" />
	<atom:link rel='hub' href='http://anrusal.wordpress.com/?pushpress=hub'/>
		<item>
		<title>Arduino: Interrupción en Timer2</title>
		<link>http://anrusal.wordpress.com/2009/10/29/arduino-interrupcion-en-timer2/</link>
		<comments>http://anrusal.wordpress.com/2009/10/29/arduino-interrupcion-en-timer2/#comments</comments>
		<pubDate>Thu, 29 Oct 2009 23:10:50 +0000</pubDate>
		<dc:creator>anrusal</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://anrusal.wordpress.com/?p=7</guid>
		<description><![CDATA[Hace unos meses adquirí una placa de evaluación Arduino Duemilanove con la cual pretendia trastear un poco y experimentar con el desarrollo de aplicaciones en microprocesador.  Anteriormente habia trabajado con microprocesadores PIC y con un Motorola 68k, con el cual que acostumbre a trabajar mediante interrupciones temporizadas de 5ms empleando una VIA 6522 mapeada en memoria. Ahora [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=anrusal.wordpress.com&amp;blog=8867479&amp;post=7&amp;subd=anrusal&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Hace unos meses adquirí una placa de evaluación Arduino Duemilanove con la cual pretendia trastear un poco y experimentar con el desarrollo de aplicaciones en microprocesador.  Anteriormente habia trabajado con microprocesadores PIC y con un Motorola 68k, con el cual que acostumbre a trabajar mediante interrupciones temporizadas de 5ms empleando una VIA 6522 mapeada en memoria. Ahora adjunto el código necesario para poder realizar una interrupción temporizada con la cual controlar el led integrado en el pin digital 13 de la placa Arduino.</p>
<blockquote>
<div id="_mcePaste">#include &lt;avr/interrupt.h&gt;</div>
<div id="_mcePaste">#include &lt;avr/io.h&gt;</div>
<div id="_mcePaste">#define INIT_TIMER_COUNT 6</div>
<div id="_mcePaste">#define RESET_TIMER2 TCNT2 = INIT_TIMER_COUNT</div>
<div id="_mcePaste">int ledPin = 13;</div>
<div id="_mcePaste">int int_counter = 0;</div>
<div id="_mcePaste">volatile int second = 0;</div>
<div id="_mcePaste">int oldSecond = 0;</div>
<div id="_mcePaste">long starttime = 0;</div>
<div id="_mcePaste">// Aruino runs at 16 Mhz, so we have 1000 Overflows per second&#8230;</div>
<div id="_mcePaste">// 1/ ((16000000 / 64) / 256) = 1 / 1000</div>
<div id="_mcePaste">ISR(TIMER2_OVF_vect) {</div>
<div id="_mcePaste">RESET_TIMER2;</div>
<div id="_mcePaste">int_counter += 1;</div>
<div id="_mcePaste">if (int_counter == 1000) {</div>
<div id="_mcePaste">second+=1;</div>
<div id="_mcePaste">int_counter = 0;</div>
<div id="_mcePaste">}</div>
<div id="_mcePaste">if( int_counter &lt; 500)</div>
<div id="_mcePaste">digitalWrite( ledPin, HIGH);</div>
<div id="_mcePaste">if( int_counter &gt;500)</div>
<div id="_mcePaste">digitalWrite( ledPin, LOW);</div>
<div id="_mcePaste">};</div>
<div id="_mcePaste">void setup() {</div>
<div id="_mcePaste">//Timer2 Settings: Timer Prescaler /64,</div>
<div id="_mcePaste">TCCR2A |= ((1&lt;&lt;CS22) | (0&lt;&lt;CS21) | (0&lt;&lt;CS20));</div>
<div id="_mcePaste">// Use normal mode</div>
<div id="_mcePaste">TCCR2A |= (0&lt;&lt;WGM21) | (0&lt;&lt;WGM20);</div>
<div id="_mcePaste">// Use internal clock &#8211; external clock not used in Arduino</div>
<div id="_mcePaste">ASSR |= (0&lt;&lt;AS2);</div>
<div id="_mcePaste">TIMSK2 |= (1&lt;&lt;TOIE2) | (0&lt;&lt;OCIE2A);	  //Timer2 Overflow Interrupt Enable</div>
<div id="_mcePaste">RESET_TIMER2;</div>
<div id="_mcePaste">sei();</div>
<div id="_mcePaste">starttime = millis();</div>
<div id="_mcePaste">}</div>
<div id="_mcePaste">void loop() {</div>
<div id="_mcePaste">}</div>
</blockquote>
<p>Referencias:</p>
<p><a href="http://gonium.net/md/2006/12/27/i-will-think-before-i-code/">http://gonium.net/md/2006/12/27/i-will-think-before-i-code/</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/anrusal.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/anrusal.wordpress.com/7/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/anrusal.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/anrusal.wordpress.com/7/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/anrusal.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/anrusal.wordpress.com/7/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/anrusal.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/anrusal.wordpress.com/7/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/anrusal.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/anrusal.wordpress.com/7/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/anrusal.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/anrusal.wordpress.com/7/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/anrusal.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/anrusal.wordpress.com/7/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=anrusal.wordpress.com&amp;blog=8867479&amp;post=7&amp;subd=anrusal&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://anrusal.wordpress.com/2009/10/29/arduino-interrupcion-en-timer2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/20e632bdb673fb70abef2937a3d61c1b?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">anrusal</media:title>
		</media:content>
	</item>
		<item>
		<title>Hello world!</title>
		<link>http://anrusal.wordpress.com/2009/08/04/hello-world/</link>
		<comments>http://anrusal.wordpress.com/2009/08/04/hello-world/#comments</comments>
		<pubDate>Tue, 04 Aug 2009 15:54:11 +0000</pubDate>
		<dc:creator>anrusal</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[Welcome to WordPress.com. This is your first post. Edit or delete it and start blogging!<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=anrusal.wordpress.com&amp;blog=8867479&amp;post=1&amp;subd=anrusal&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Welcome to <a href="http://wordpress.com/">WordPress.com</a>. This is your first post. Edit or delete it and start blogging!</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/anrusal.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/anrusal.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/anrusal.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/anrusal.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/anrusal.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/anrusal.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/anrusal.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/anrusal.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/anrusal.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/anrusal.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/anrusal.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/anrusal.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/anrusal.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/anrusal.wordpress.com/1/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=anrusal.wordpress.com&amp;blog=8867479&amp;post=1&amp;subd=anrusal&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://anrusal.wordpress.com/2009/08/04/hello-world/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/20e632bdb673fb70abef2937a3d61c1b?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">anrusal</media:title>
		</media:content>
	</item>
	</channel>
</rss>
