<?xml version="1.0" encoding="utf-8"?>
				<!-- generator="e107" -->
				<!-- content type="Forum / topic" -->
				<rss  version="2.0">
				<channel>
				<title>8051 Microcontroller Projects AVR PIC Projects Tutorials Ebooks Libraries codes : Forum / topic</title>
				<link>http://www.8051projects.net/</link>
				<description>Learn to make simple microcontroller projects, pic, 8051, avr and arm projects. download 8051 projects, tutorials, libraries, sample codes. join the microcontroller discussion forum and ask doubts regarding electronics. the best source for 8051 over internet.</description>

<language>en-gb</language>
				<copyright>2008 Rickey's World</copyright>
				<managingEditor>contact@nospam.com (Ajay Bhargav)</managingEditor>
				<webMaster>contact@nospam.com (Ajay Bhargav)</webMaster>
				<pubDate>Wed, 07 Jan 2009 13:36:42 -0800</pubDate>
				<lastBuildDate>Wed, 07 Jan 2009 13:36:42 -0800</lastBuildDate>
				<docs>http://backend.userland.com/rss</docs>
				<generator>e107 (http://e107.org)</generator>
				<ttl>60</ttl>
				<textInput>
				<title>Search</title>
				<description>Search 8051 Microcontroller Projects AVR PIC Projects Tutorials Ebooks Libraries codes</description>
				<name>query</name>
				<link>http://www.8051projects.net/search.php</link>
				</textInput>
						<item>
						<title>doubts</title>
<link>http://www.8051projects.net/forum-t11744.html</link>
<description><![CDATA[What >> and &lt;&lt; do in C programming ??]]></description>
<pubDate>Fri, 15 Aug 2008 06:12:27 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t11744.html</guid>
</item>
						<item>
						<title>Re: doubts</title>
<link>http://www.8051projects.net/forum-t11744.html</link>
<description><![CDATA[less then greater than]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Fri, 15 Aug 2008 10:14:15 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t11744.html</guid>
</item>
						<item>
						<title>Re: doubts</title>
<link>http://www.8051projects.net/forum-t11744.html</link>
<description><![CDATA[<div class='quote_top'>۞ TPS ۞ wrote ...</div><div class='quote'><br />less then greater than <br /></div><br /><br /><br />Are you sure that it is greater or less than?? According to my textbook. >> means shift right and &lt;&lt; shift left. But i don know where to apply both of them and how are are used...]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Sat, 16 Aug 2008 04:13:38 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t11744.html</guid>
</item>
						<item>
						<title>Re: doubts</title>
<link>http://www.8051projects.net/forum-t11744.html</link>
<description><![CDATA[yes nismo,<br />u are right. these are indeed left/right shift operators. The most general use of these operators in our embedded c programming is to set/clear an individual bit of a single byte.<br />the left shift operator &lt;&lt; is used in this case.<br />suppose u want to set the 'n' th bit of a register say reg1. then u can write the following instruction:<br />reg1 |=(1&lt;&lt;n);<br />similarly if u want to reset/clear a bit of the register u can use the instruction:<br />reg1 &amp;=~(1&lt;&lt;n);<br />this logic is extensively used in AVR programming as AVRs have only byte level operations unlike 8051 which supports bit level manipulations .<br />the AVR library also included a macro _BV(n) which is equivalent to (1&lt;&lt;n) for this very reason.<br /><br />]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Sat, 16 Aug 2008 06:37:19 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t11744.html</guid>
</item>
						<item>
						<title>Re: doubts</title>
<link>http://www.8051projects.net/forum-t11744.html</link>
<description><![CDATA[pdi33  is right<br /><br />x>>1   <br />means the value of x be shifted one times towards right<br />like in<br />0000 0010 >>1   will give 0000 0001<br />similarly,<br /><br /><br />x<<1   <br />means the value of x be shifted one times towards left<br />like in<br />0000 0010 <<1   will give 0000 0100<br /><br /><br />in some micro controllers  bit addressing is not provided  (ex. lpc2138)<br />there the whole (8 bit /32 bit) register  needs to be read or written to.<br />in such a case you will need these  (<<,>>) operators   also known as bitwise  shift operators.<br /><br />ex.  writing 1 to 5 bit of resister A<br />A =  0x01 << 5 ;<br />that will make   A= 0010 0000 = 0x20<br />similarly if you want to read the status of the 5th bit of A register <br />(A>>5)&&(0x01) = result;<br /><br />if the fifth bit is one  u get result as 1<br />if not the result will be a zero..<br /><br />hope that will make there use clearer!<br /> <img src='http://www.8051projects.net/e107_images/emotes/yahoo/1.gif' alt='' style='vertical-align:middle; border:0' />]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Sat, 16 Aug 2008 22:10:28 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t11744.html</guid>
</item>
				</channel>
				</rss>