<?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>Thu, 08 Jan 2009 23:13:48 -0800</pubDate>
				<lastBuildDate>Thu, 08 Jan 2009 23:13:48 -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>AT89C51 using proteus ISIS</title>
<link>http://www.8051projects.net/forum-t10135.html</link>
<description><![CDATA[4 years back I did a project Home Automations using AT89C51, I need to do something similar to it. But I am facing a very strange problem this time.<br /><br />I am reffering Embedded C book by Michael Pont, I used a very basic program (provided with the book) as under and compiled it using Keil compiler.<br /><br /> <div class='code_box'>CODE:</div><div class='code_highlight' style='unicode-bidi: embed; direction: ltr'><div class="c" style="font-family: monospace;"><br /><span style="color: #808080; font-style: italic;">/*------------------------------------------------------------*-<br />Hello.C (v1.00)<br />-------------------------------------------------------------<br />A &quot;Hello Embedded World&quot; test program for 8051.<br />-*------------------------------------------------------------*/</span><br /><br /><span style="color: #339933;">#include &lt;reg52.h&gt;</span><br /><br /><span style="color: #808080; font-style: italic;">// LED is to be connected to this pin</span><br />sbit LED_pin = P1^<span style="color: #cc66cc;">5</span>;<br /><br /><span style="color: #808080; font-style: italic;">// Stores the LED state</span><br />bit LED_state_G;<br /><br /><span style="color: #808080; font-style: italic;">// Function prototypes</span><br /><span style="color: #993333;">void</span> LED_FLASH_Init<span style="color: #66cc66;">&#40;</span><span style="color: #993333;">void</span><span style="color: #66cc66;">&#41;</span>;<br /><span style="color: #993333;">void</span> LED_FLASH_Change_State<span style="color: #66cc66;">&#40;</span><span style="color: #993333;">void</span><span style="color: #66cc66;">&#41;</span>;<br /><span style="color: #993333;">void</span> DELAY_LOOP_Wait<span style="color: #66cc66;">&#40;</span><span style="color: #993333;">const</span> <span style="color: #993333;">unsigned</span> <span style="color: #993333;">int</span><span style="color: #66cc66;">&#41;</span>;<br /><br /><span style="color: #808080; font-style: italic;">/*............................................................*/</span><br /><br /><span style="color: #993333;">void</span> main<span style="color: #66cc66;">&#40;</span><span style="color: #993333;">void</span><span style="color: #66cc66;">&#41;</span><br /><span style="color: #66cc66;">&#123;</span><br />&nbsp; &nbsp; &nbsp; &nbsp; LED_FLASH_Init<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;<br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #b1b100;">while</span><span style="color: #66cc66;">&#40;</span><span style="color: #cc66cc;">1</span><span style="color: #66cc66;">&#41;</span><br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #66cc66;">&#123;</span><br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #808080; font-style: italic;">// Change the LED state (OFF to ON, or vice versa)</span><br />&nbsp; &nbsp; &nbsp; &nbsp; LED_FLASH_Change_State<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;<br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #808080; font-style: italic;">// Delay for *approx* 1000 ms</span><br />&nbsp; &nbsp; &nbsp; &nbsp; DELAY_LOOP_Wait<span style="color: #66cc66;">&#40;</span><span style="color: #cc66cc;">1000</span><span style="color: #66cc66;">&#41;</span>;<br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #66cc66;">&#125;</span><br /><span style="color: #66cc66;">&#125;</span><br /><br /><span style="color: #808080; font-style: italic;">/*------------------------------------------------------------*-<br />LED_FLASH_Init()<br />Prepare for LED_Change_State() function – see below.<br />-*------------------------------------------------------------*/</span><br /><br /><span style="color: #993333;">void</span> LED_FLASH_Init<span style="color: #66cc66;">&#40;</span><span style="color: #993333;">void</span><span style="color: #66cc66;">&#41;</span><br /><span style="color: #66cc66;">&#123;</span><br />&nbsp; &nbsp; &nbsp; &nbsp; LED_state_G = <span style="color: #cc66cc;">0</span>;<br /><span style="color: #66cc66;">&#125;</span><br /><br /><span style="color: #808080; font-style: italic;">/*------------------------------------------------------------*-<br />LED_FLASH_Change_State()<br />Changes the state of an LED (or pulses a buzzer, etc) on a<br />specified port pin.<br />Must call at twice the required flash rate: thus, for 1 Hz<br />flash (on for 0.5 seconds, off for 0.5 seconds),<br />this function must be called twice a second.<br />-*------------------------------------------------------------*/</span><br /><br /><span style="color: #993333;">void</span> LED_FLASH_Change_State<span style="color: #66cc66;">&#40;</span><span style="color: #993333;">void</span><span style="color: #66cc66;">&#41;</span><br /><span style="color: #66cc66;">&#123;</span><br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #808080; font-style: italic;">// Change the LED from OFF to ON (or vice versa)</span><br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span>LED_state_G == <span style="color: #cc66cc;">1</span><span style="color: #66cc66;">&#41;</span><br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #66cc66;">&#123;</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; LED_state_G = <span style="color: #cc66cc;">0</span>;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; LED_pin = <span style="color: #cc66cc;">0</span>;<br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #66cc66;">&#125;</span><br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #b1b100;">else</span><br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #66cc66;">&#123;</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; LED_state_G = <span style="color: #cc66cc;">1</span>;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; LED_pin = <span style="color: #cc66cc;">1</span>;<br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #66cc66;">&#125;</span><br /><span style="color: #66cc66;">&#125;</span><br /><br /><span style="color: #808080; font-style: italic;">/*------------------------------------------------------------*-<br />DELAY_LOOP_Wait()<br />Delay duration varies with parameter.<br />Parameter is, *ROUGHLY*, the delay, in milliseconds,<br />on 12MHz 8051 (12 osc cycles).<br />You need to adjust the timing for your application!<br />-*------------------------------------------------------------*/</span><br /><br /><span style="color: #993333;">void</span> DELAY_LOOP_Wait<span style="color: #66cc66;">&#40;</span><span style="color: #993333;">const</span> <span style="color: #993333;">unsigned</span> <span style="color: #993333;">int</span> DELAY<span style="color: #66cc66;">&#41;</span><br /><span style="color: #66cc66;">&#123;</span><br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #993333;">unsigned</span> <span style="color: #993333;">int</span> x, y;<br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #b1b100;">for</span> <span style="color: #66cc66;">&#40;</span>x = <span style="color: #cc66cc;">0</span>; x &lt;= DELAY; x++<span style="color: #66cc66;">&#41;</span><br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #66cc66;">&#123;</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #b1b100;">for</span> <span style="color: #66cc66;">&#40;</span>y = <span style="color: #cc66cc;">0</span>; y &lt;= <span style="color: #cc66cc;">120</span>; y++<span style="color: #66cc66;">&#41;</span>;<br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #66cc66;">&#125;</span><br /><span style="color: #66cc66;">&#125;</span><br /><br /><span style="color: #808080; font-style: italic;">/*------------------------------------------------------------*-<br />---- END OF FILE --------------------------------------------<br />-*------------------------------------------------------------*/</span><br />&nbsp;</div></div> <br /><br /><br />The code compiled successfully without any errors and without any warning. Then I used BIN2HEX by Keil to convert the object (compiled) file to the HEX code.<br /><br />Then I added the HEX file to the microcontroller in ISIS. Find below the image of the design.<br /><br /><br /><a class='bbcode' href='http://www.8051projects.net/e107_files/public/1213876815_8461_FT0_8051.jpg' rel='external'  target='_blank'><img src='http://www.8051projects.net/e107_files/public/1213876815_8461_FT0_8051_.jpg' class='bbcode' alt='' width='500' height='566'  /></a><br /><br /><br /><br /><span style='font-size:14px'>I checked the code in the Keil simulator and it is working. I don't know why it is <strong class='bbcode bold'><span class='bbcode underline' style='text-decoration:underline'>NOT</span></strong> working in ISIS. Please help me. Let me know where I am going wrong!</span><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br />]]></description>
<pubDate>Thu, 19 Jun 2008 05:01:45 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t10135.html</guid>
</item>
						<item>
						<title>Re: AT89C51 using proteus ISIS</title>
<link>http://www.8051projects.net/forum-t10135.html</link>
<description><![CDATA[<div class='quote_top'>Colin Mac wrote ...</div><div class='quote'><br />The crystal and supply isn't necessary in Isis and neither is the reset pin. Remove everything. Get a dc supply, resistor and use a red led instead of that led so only<br />P1.5 is being used. <br /></div><br /><br />Dear Colin,<br /><br /><span style='font-size:13px'>I did as you said and the result is same. Please see the below image. </span><br /><br /><br /><a class='bbcode' href='http://www.8051projects.net/e107_files/public/1213898255_8461_FT10135_8051_1.jpg' rel='external'  target='_blank'><img src='http://www.8051projects.net/e107_files/public/1213898255_8461_FT10135_8051_1_.jpg' class='bbcode' alt='' width='500' height='367'  /></a><br />]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Thu, 19 Jun 2008 10:58:29 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t10135.html</guid>
</item>
						<item>
						<title>Re: AT89C51 using proteus ISIS</title>
<link>http://www.8051projects.net/forum-t10135.html</link>
<description><![CDATA[The crystal and supply isn't necessary in Isis and neither is the reset pin. Remove everything. Get a dc supply, resistor and use a red led instead of that led so only<br />P1.5 is being used.]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Thu, 19 Jun 2008 08:05:54 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t10135.html</guid>
</item>
						<item>
						<title>Re: AT89C51 using proteus ISIS</title>
<link>http://www.8051projects.net/forum-t10135.html</link>
<description><![CDATA[Dear pdi33,<br /><br />I am trying as Arun said,  but still unable to get the desired results.<br /><br />Can you please do it for me, find attached the required DSN files.<br /><br />http://www.8051projects.net/e107_files/public/1213937567_8461_FT10135_8051.zip]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Thu, 19 Jun 2008 21:51:26 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t10135.html</guid>
</item>
						<item>
						<title>Re: AT89C51 using proteus ISIS</title>
<link>http://www.8051projects.net/forum-t10135.html</link>
<description><![CDATA[Hello say2paul<br /><br />in the above layout you have 3 errors:<br />1) LED should be connected other way round  i,e cathode to pin p1.5, bcoz  micros  like 8051 can sink current better than source<br /><br />2) change resistor value to 100ohms<br /><br />3) connect the other end of  resistor to  5+ VCC not -5V<br /><br /><br />even if it doesn't work, then check the following :<br /><br />1) double click on the red LED and its properties box will pop up, there find  minimum trigger current field and change it to 2mA , by default it will be 10mA<br /><br />2) since you are using external complier to produce hex file, are you loading it correctly into micro, double click the micro component and a see its properties box, there you'll find path of the hex file to loaded  on the micro, browse for the correct hex file and update.<br /><br />3) check if the port pin you have declared in the code is the same  you have used in the schematic, save your design file and run the simulator, if every thing is right  it should work.<br /><br /><br />all the best<br /><br />Arun<br />]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Thu, 19 Jun 2008 20:52:09 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t10135.html</guid>
</item>
						<item>
						<title>Re: AT89C51 using proteus ISIS</title>
<link>http://www.8051projects.net/forum-t10135.html</link>
<description><![CDATA[hi paul,<br />do as arun says and if u still do not get it, attach the DSN file and let me simulate the same on my PC and find the error for u.<br />Hope it works at ur place. <img src='http://www.8051projects.net/e107_images/emotes/yahoo/1.gif' alt='' style='vertical-align:middle; border:0' />  <br />Good luck]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Thu, 19 Jun 2008 21:48:05 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t10135.html</guid>
</item>
						<item>
						<title>Re: AT89C51 using proteus ISIS</title>
<link>http://www.8051projects.net/forum-t10135.html</link>
<description><![CDATA[<div class='quote_top'>say2paul wrote ...</div><div class='quote'><br />Dear pdi33,<br /><br />I am trying as Arun said,  but still unable to get the desired results.<br /><br />Can you please do it for me, find attached the required DSN files.<br /></div><br /><br /><a href='http://www.8051projects.net/e107_files/public/1213937567_8461_FT10135_8051.zip'><img src='http://www.8051projects.net/e107_images/generic/lite/file.png' alt='' style='border:0; vertical-align:middle' /></a> <a href='http://www.8051projects.net/e107_files/public/1213937567_8461_FT10135_8051.zip'>8051.zip</a>]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Thu, 19 Jun 2008 21:52:47 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t10135.html</guid>
</item>
						<item>
						<title>Re: AT89C51 using proteus ISIS</title>
<link>http://www.8051projects.net/forum-t10135.html</link>
<description><![CDATA[hello Say2paul<br /><br />in your zip file there is no hex file that is to be loaded into the micro, but any way i made a simple blink program and could run it on the your Design, and  here is the error you made <br /><br /><br /><br /><a class='bbcode' href='http://www.8051projects.net/e107_files/public/1213968260_426_FT10135_direct_short.jpg' rel='external'  target='_blank'><img src='http://www.8051projects.net/e107_files/public/1213968260_426_FT10135_direct_short_.jpg' class='bbcode' alt='' width='500' height='361'  /></a><br /><br /><br />DIRECT SHORT to the port pin , try dragging the resistor in your DSN file and you'll see the blunder.<br /><br /><br /><br /><br /><a class='bbcode' href='http://www.8051projects.net/e107_files/public/1213968380_426_FT10135_working.jpg' rel='external'  target='_blank'><img src='http://www.8051projects.net/e107_files/public/1213968380_426_FT10135_working_.jpg' class='bbcode' alt='' width='500' height='304'  /></a><br /><br /><br /><br />Now its Working !<br /><br />there's a thanks button you could use <br /><br /><br />Arun]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Fri, 20 Jun 2008 06:30:20 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t10135.html</guid>
</item>
						<item>
						<title>Re: AT89C51 using proteus ISIS</title>
<link>http://www.8051projects.net/forum-t10135.html</link>
<description><![CDATA[hi paul,<br />Arun is right. just connect the LED correctly and ur code will work just fine . I have compiled ur code posted previously and tested it in ur ciruit after correcting the LED connections and it worked just as fine.<br />]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Fri, 20 Jun 2008 08:13:33 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t10135.html</guid>
</item>
						<item>
						<title>Re: AT89C51 using proteus ISIS</title>
<link>http://www.8051projects.net/forum-t10135.html</link>
<description><![CDATA[I hope you have loaded the code in controller before running on proteus <img src='http://www.8051projects.net/e107_images/emotes/yahoo/4.gif' alt='' style='vertical-align:middle; border:0' />]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Fri, 20 Jun 2008 08:38:22 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t10135.html</guid>
</item>
						<item>
						<title>Re: AT89C51 using proteus ISIS</title>
<link>http://www.8051projects.net/forum-t10135.html</link>
<description><![CDATA[Well.. all of you guys were really helpful. It was a mistake, I didn't know that Keil compiler can directly generate the HEX code by compiling the C file. What I was doing is generating a HEX file from the compiled Object file using BIN2HEX.<br /><br />Ajay guided me a way to directly generate HEX file from Keil compiler and now everything is working so smooth.<br /><br />Thanks every one!<br /><br />Now my next challenge is to make Infrared as an interface to the AT89C51 so that if I send some data to the Infrared sensor, the AT89C51 should process it accordingly.<br /><br />I don't have any idea how to start. If some one from you guide me through it!]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Fri, 20 Jun 2008 10:07:27 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t10135.html</guid>
</item>
						<item>
						<title>Re: AT89C51 using proteus ISIS</title>
<link>http://www.8051projects.net/forum-t10135.html</link>
<description><![CDATA[Thanks!]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Mon, 23 Jun 2008 05:24:23 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t10135.html</guid>
</item>
				</channel>
				</rss>