<?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 16:58:51 -0800</pubDate>
				<lastBuildDate>Wed, 07 Jan 2009 16:58:51 -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>query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[actually i want to see the display through ports of the microcontroller by connecting a 7-segment display to it,how will i connect this 7-segment display to port1 of the mirocontroller(8051),i am designing the circuit on a breadboard,what will be the program code???please helpme,its too urgent///]]></description>
<pubDate>Tue, 29 Apr 2008 17:45:19 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[Hi,<br /><br />From i want understand from your posts- the ADC value is displayed in Binary format <br /><br />on 8 LEDs on a port  ( 33H(hex)  - 00110011 (binary) -  led7. ........led0 (Display on port)<br /><br />1) you need a "Hex2BCD" conversion routine to display hex value into BCD on a 7 <br /><br />segment display  For Eg: 33H is displayed as 51Decimal  (BCD) on 2-digit 7seg display <br /><br />after conversion.<br /><br />2) if you just need the 2 digit 7 seg to display - 33, then instead of sending the <br /><br />processed ADC value to Port directly store it in some Register and make a look up table <br /><br />containing patterns for generating numbers from 0 to 9. i think this is where you are <br /><br />getting confused, i think you are aware of the segments in a 7 seg display - seg <br /><br />a,b,c,d,e,f,g,h (decimal point) -  to construct 0(zero) on a 7 seg display you have to <br /><br />output the port with - 11000000b or #0C0H  this will mean connecting segments "g" <br /><br />&amp; "h"(Decimal point) to + 5V and grounding all other segments. now lets try displaying <br /><br />"3" , so you out put -10110000b or #0B0H to the port - you ground the segs which are <br /><br />to be seen( by writing zeros-0) and connect  +5V  to the segs which have to be hidden(by writing 1s).<br /><br />i hope you are using Common Anode (LTS542) 7 seg display , if you are using Common <br /><br />Cathode (LTS543) then you have to do reverse logic with the binary number you  want <br /><br />to display.<br /><br />you draw the numbers you want to display on a paper and construct patterns 8 bit  for<br /><br />each number.<br /><br />Apart from having lookup table ready you should also have a  Compare subroutine to CJNE the value <br /><br />stored in a register( ADC value which is stored) to the look up table.<br /><br />for eg: 33H is 00110011b which is a packed BCD number which is made up of  two <br /><br />numbers - 3H and 3H  after unpacking(higher nibble and lower nibble)  you will get  - <br /><br />00000011b and 00000011 now store these two values in 2 variables  say HI_Byte and <br /><br />LO_Byte. now compare Hi_byte in the sub routine  with the Look up table and <br /><br />display1st  digit , same way compare Lo_byte in the lookup table  and display 2nd digit.<br /><br />you may have to mutliplex the digits or use CD4511 BCD decoders for each digit<br /><br />hope this will solve your problem<br /><br />ho boy it's been a lengthy Post - thanks to my patience <br /><br />Arun]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Thu, 01 May 2008 19:50:57 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[How many digits are u planning to connect to the uC?. Are u planning to display only numbers or also some alpha numeric characters? Please clarify.<br /><br />Actually, u need to interface a multiplexed LED display to the uC. If u clarify the above points, i can provide u a ciruit idea about the connection.]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Tue, 29 Apr 2008 19:12:01 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[actually i want to display some numbers only. my project is somewhat like this: i have interfaced adc(0804) and microcontroller(8051) .on appling a voltage say 2volts adc displays 033h and display is seen through port1 of microcontroller.at first i saw the display through leds connected on my trainer kit but now i want to see the display through a 7-segment display.i am providing my program code ,please tell me what changes are to be made in the code?<br />setb p2.5<br />setb p2.6<br />intr bit p2.7<br />setb intr<br />adc_port equ p1<br />adc_val equ 30h<br />voltage_val equ r3<br />back:  clr wr<br />         setb wr<br />         acall conversion<br /> read:   clr rd<br />         mov a,adc_val<br />         setb rd<br />         mov r3,#00h<br />         acall data_display1<br />         mov r3,#01h<br />         acall data_display2<br />         mov r3,#02h<br />         acall data_display3<br />         mov r3,#03h<br />         acall data_display4<br />         mov r3,#04h<br />         acall data_display5<br />         mov r3,#05h<br />         acall data_display6<br />         sjmp back<br />  data_display1:  mov a,#00h<br />   conversion:    mov b,#0ah<br />                   div ab<br />                   mov r7,b<br />                   mov b,#0ah<br />                   div ab<br />                   mov r6,b<br />                   mov r5,a<br />                   mov p1,r7<br />                   acall delay<br />                   mov p1,r6<br />                   acall delay<br />                   mov p1,r5<br />                   acall delay<br />                   ret<br />data_display2:     mov a,#33h<br />                    mov b,#0ah<br />                    div ab<br />                    mov r7,b<br />                    mov b,#0ah<br />                    div ab<br />                    mov r6,b<br />                    mov r5,a<br />                   mov p1,r7<br />                    acall delay<br />                    mov p1,r6<br />                    acall delay<br />                    mov p1,r5<br />                    acall delay<br />                    ret<br /> data_display3:    mov a,#67h<br />                   mov b,#0ah<br />                   div ab<br />                   mov r7,b<br />                   mov b,#0ah<br />                   div ab<br />                   mov r6,b<br />                   mov r5,a<br />                  mov p1,r7<br />                   acall delay<br />                   mov p1,r6<br />                   acall delay<br />                   mov p1,r5<br />                   acall delay<br />                   ret<br />  data_display4:   mov a,#97h<br />                    mov b,#0ah<br />                    div ab<br />                    mov r7,b<br />                    mov b,#0ah<br />                    div ab<br />                    mov r6,b<br />                    mov r5,a<br />                    mov p1,r7<br />                    acall delay<br />                    mov p1,r6<br />                    acall delay<br />                    mov p1,r5<br />                    acall delay<br />                    ret<br /> data_display5:     mov a,#99h<br />                    mov b,#0ah<br />                    div ab<br />                    mov r7,b<br />                    mov b,#0ah<br />                    div ab<br />                    mov r6,b<br />                    mov r5,a<br />                    mov p1,r7<br />                    acall delay<br />                    mov p1,r6<br />                    acall delay<br />                    mov p1,r5<br />                    acall delay<br />                     ret<br />  data_display6:    mov a,#0ffh<br />                      mov b,#0ah<br />                      div ab<br />                      mov r7,b<br />                      mov b,#0ah<br />                      div ab<br />                      mov r6,b<br />                      mov r5,a<br />                     mov p1,r7<br />                      acall delay<br />                      mov p1,r6<br />                      acall delay<br />                      mov p1,r5<br />                      acall delay<br />                      ret<br />        delay:         mov r4,#200<br />        here:          djnz r4,here<br />                        ret<br />                        end                                <br />                                                                                                                        <br />]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Tue, 29 Apr 2008 19:48:36 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[Hi Priya...<br />Plz do not make multiple posts of the same topic....you have posted the same question in 3 diff. threads!!<br />As for your problem...you would need to display 3 digits.So you need three multiplexed 7-seg displays  as pdi33 pointed out.<br />In multiplexing what you do is connect all the 7-seg displays in parallel,to one uc port,ie P1 in your case. Now Vcc to each display is provided by a transistor controlled by a port pin.So when the transistor connected to a particular display is switched on,only that display(out of the 3) will work.Similarly the next display will be made to turn on and the remaining will be off.When this cycle continues at a fast rate (greater than 20Hz) you get the impression that all 3 displays are on at the same time.<br />Look at the attached ckt.The display is a common anode one.To switch any display on you'll have to write a 0 to the particular port pin(P2.0,P2.1 or P2.2).<br /><br /><img src='http://www.8051projects.net/e107_files/public/1209542852_5870_FT9130_humidity.gif' class='bbcode' alt='' width='480' height='588'  />]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Wed, 30 Apr 2008 01:08:41 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[For writing digits you'll have to send the fol. values to P1.<br /><br />Digit........ P1value(in hex)<br />--------------------------------<br />0........... C0<br />1........... F9<br />2........... A4<br />3........... B0<br />4........... 99<br />5........... 92<br />6........... 82<br />7........... F8<br />8........... 80<br />9........... 98<br />]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Wed, 30 Apr 2008 01:19:10 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[here is a simple idea for writing the display routine: (w.r.t the hardware suggested by shashi)<br />first u define a byte say digit_count = 0. then folow the following steps<br /><br />step1:  disable all digits (p2.0=p2.1=p2.2 = 1)<br />step2: fetch seven-segment code for the particular digit corresponding to digit_count.<br />step3: output the seven-segment code to port1<br />step4: enable the selected digit (p2.0/p2.1/p2.2 = 0) depending upon the digit_count.<br />step 5: increment the digit_count and reset it if it is > = 3.<br />return.<br /><br />this routine should be called in the main loop and should be called continuously in real time.( rate of execution should be > 60hz. as the full display will be shown only when the routine is executed three times for the three digits.)<br />]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Wed, 30 Apr 2008 04:56:56 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[sir, i have another doubt------ the thing is that actually for a certain voltage say 2volts ,adc is reading 033h ,this data i am sending to the microcontroller and it is displaying 033h.i want 2 see 033h on the ports of the microcontroller through seven segment display. but here the digits 0-9 doesnt correspond to the values i have provided in my program. please help me clear this doubt.]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Thu, 01 May 2008 16:21:13 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[Plz go through the previous posts.Your answer is there.<br />For displaying digit '0' in the 7-seg,you have to send 'C0'.<br />For displaying digit '1',you have to send 'F9'.....and so on.<br />Read the above posts........]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Thu, 01 May 2008 17:29:22 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[please provide your circuit...]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Thu, 01 May 2008 17:40:03 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[here is a simple circuit for directly interfacing the 7 seg to uC without multiplexing which will require a little more hardware but the software is very easy. but note that the 7- segment display should be strictly common cathode.<br />just convert ur binary input from the ADc into BCD and output it to port p2 and lower nibble of p3. i.e two digits on p2 and one digit on port 3.0 to p3.3.<br /><a href='http://www.8051projects.net/e107_files/public/1209729886_1329_FT9130_direct_display.pdf'><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/1209729886_1329_FT9130_direct_display.pdf'>direct_display.pdf</a>]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Fri, 02 May 2008 05:04:46 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[sir,i hv enclosed the assembly language program code of my project,but at that time i was seeing the display through leds connected  on my trainer kit, but as now i want to se the display through 7-segment display so i think some changes are to be made in my program code ,sir please tell me what are the changes to be made?]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Mon, 05 May 2008 16:48:39 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[where is the code??]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Mon, 05 May 2008 17:18:53 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[i had posted the code but somehow it didn't appear,anyways i am resending the code,please go through it and help me to find out what changes should i do to see the display through a 7-segment display.l <br /><div class='code_asm'>CODE:</div><div class='code_highlight' style='unicode-bidi: embed; direction: ltr'><div class="asm" style="font-family: monospace;"><span style="color: #00007f; font-weight:bold;">setb</span> p2<span style="color: #ff0000;">.5</span><br /><span style="color: #00007f; font-weight:bold;">setb</span> p2<span style="color: #ff0000;">.6</span><br />intr <span style="color: #0000ff;">bit</span> p2<span style="color: #ff0000;">.7</span><br /><span style="color: #00007f; font-weight:bold;">setb</span> intr<br />adc_port <span style="color: #0000ff;">equ</span> <span style="color: #46aa03; font-weight:bold;">p1</span><br />adc_val <span style="color: #0000ff;">equ</span> 30h<br />voltage_val <span style="color: #0000ff;">equ</span> <span style="color: #46aa03; font-weight:bold;">r3</span><br />back: &nbsp;<span style="color: #00007f; font-weight:bold;">clr</span> wr<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">setb</span> wr<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">acall</span> conversion<br />&nbsp;read: &nbsp; <span style="color: #00007f; font-weight:bold;">clr</span> rd<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">a</span>,adc_val<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">setb</span> rd<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r3</span>,#<span style="color: #ff0000;">00h</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">acall</span> data_display1<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r3</span>,#<span style="color: #ff0000;">01h</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">acall</span> data_display2<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r3</span>,#<span style="color: #ff0000;">02h</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">acall</span> data_display3<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r3</span>,#<span style="color: #ff0000;">03h</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">acall</span> data_display4<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r3</span>,#<span style="color: #ff0000;">04h</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">acall</span> data_display5<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r3</span>,#<span style="color: #ff0000;">05h</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">acall</span> data_display6<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">sjmp</span> back<br />&nbsp; data_display1: &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">a</span>,#<span style="color: #ff0000;">00h</span><br />&nbsp; &nbsp;conversion: &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">b</span>,#<span style="color: #ff0000;">0ah</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">div</span> ab<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r7</span>,<span style="color: #46aa03; font-weight:bold;">b</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">b</span>,#<span style="color: #ff0000;">0ah</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">div</span> ab<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r6</span>,<span style="color: #46aa03; font-weight:bold;">b</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r5</span>,<span style="color: #46aa03; font-weight:bold;">a</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r7</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r6</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r5</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">ret</span><br />data_display2: &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">a</span>,#33h<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">b</span>,#<span style="color: #ff0000;">0ah</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">div</span> ab<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r7</span>,<span style="color: #46aa03; font-weight:bold;">b</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">b</span>,#<span style="color: #ff0000;">0ah</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">div</span> ab<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r6</span>,<span style="color: #46aa03; font-weight:bold;">b</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r5</span>,<span style="color: #46aa03; font-weight:bold;">a</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r7</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r6</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r5</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">ret</span><br />&nbsp;data_display3: &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">a</span>,#67h<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">b</span>,#<span style="color: #ff0000;">0ah</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">div</span> ab<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r7</span>,<span style="color: #46aa03; font-weight:bold;">b</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">b</span>,#<span style="color: #ff0000;">0ah</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">div</span> ab<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r6</span>,<span style="color: #46aa03; font-weight:bold;">b</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r5</span>,<span style="color: #46aa03; font-weight:bold;">a</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r7</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r6</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r5</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">ret</span><br />&nbsp; data_display4: &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">a</span>,#97h<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">b</span>,#<span style="color: #ff0000;">0ah</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">div</span> ab<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r7</span>,<span style="color: #46aa03; font-weight:bold;">b</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">b</span>,#<span style="color: #ff0000;">0ah</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">div</span> ab<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r6</span>,<span style="color: #46aa03; font-weight:bold;">b</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r5</span>,<span style="color: #46aa03; font-weight:bold;">a</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r7</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r6</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r5</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">ret</span><br />&nbsp;data_display5: &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">a</span>,#99h<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">b</span>,#<span style="color: #ff0000;">0ah</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">div</span> ab<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r7</span>,<span style="color: #46aa03; font-weight:bold;">b</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">b</span>,#<span style="color: #ff0000;">0ah</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">div</span> ab<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r6</span>,<span style="color: #46aa03; font-weight:bold;">b</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r5</span>,<span style="color: #46aa03; font-weight:bold;">a</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r7</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r6</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r5</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">ret</span><br />&nbsp; data_display6: &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">a</span>,#<span style="color: #ff0000;">0ffh</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">b</span>,#<span style="color: #ff0000;">0ah</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">div</span> ab<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r7</span>,<span style="color: #46aa03; font-weight:bold;">b</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">b</span>,#<span style="color: #ff0000;">0ah</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">div</span> ab<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r6</span>,<span style="color: #46aa03; font-weight:bold;">b</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r5</span>,<span style="color: #46aa03; font-weight:bold;">a</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r7</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r6</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r5</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">acall</span> delay<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">ret</span><br />&nbsp; &nbsp; &nbsp; &nbsp; delay: &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> r4,#<span style="color: #ff0000;">200</span><br />&nbsp; &nbsp; &nbsp; &nbsp; here: &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00007f; font-weight:bold;">djnz</span> r4,here<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">ret</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">end</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;</div></div>]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Mon, 05 May 2008 17:35:52 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[Hi Priya123, <br /><br />did you read my earlier post in this thread ?  it took a lot of my time to explain the whole <br /><br />concept in a simple way.  Again your are back to square One and all you do is ask the same question <br /><br />again and again. other members too have tried their best to explain to you the concept even with <br /><br />diagrams but you don't want to learn .<br /><br /><br /><br />Please Note: it is minimum courtesy for you to thank the members who are trying to help you before you <br /><br />start your new post <br /><br /><br />Arun<br /><br /><br /><br /><br />]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Mon, 05 May 2008 18:23:54 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[Is the code for the 7segment display or for the simple LED display which u have written? please add circuit diagram or atleast the connections used by u for connecting the LED display. else it is difficult to follow the logic u have used.<br /> For e.g. note the following code:<br />'data_display1: mov a,#00h<br />conversion: mov b,#0ah'<br />What does it exactly do? Is it the display driving routine or the ADC conversion routine <img src='http://www.8051projects.net/e107_images/emotes/yahoo/7.gif' alt='' style='vertical-align:middle; border:0' />  .<br />Always define the port pins with the respective functions as it makes the code more readable for u as well as for US <img src='http://www.8051projects.net/e107_images/emotes/yahoo/4.gif' alt='' style='vertical-align:middle; border:0' />  <br />Also mention whether u are using the direct display drive ( check circuit diagram posted by me in my previous post) or the multiplexed display as suggested by shashi. This is important as both methods require completely different code logic .<br />]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Mon, 05 May 2008 19:33:06 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[OK one last time.....<br />You can do it this way...<br /><br /> <div class='code_asm'>CODE:</div><div class='code_highlight' style='unicode-bidi: embed; direction: ltr'><div class="asm" style="font-family: monospace;">data_display6: <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">a</span>,#<span style="color: #ff0000;">0ffh</span><br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">b</span>,#<span style="color: #ff0000;">0ah</span><br /><span style="color: #00007f; font-weight:bold;">div</span> ab<br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r7</span>,<span style="color: #46aa03; font-weight:bold;">b</span><br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">b</span>,#<span style="color: #ff0000;">0ah</span><br /><span style="color: #00007f; font-weight:bold;">div</span> ab<br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r6</span>,<span style="color: #46aa03; font-weight:bold;">b</span><br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r5</span>,<span style="color: #46aa03; font-weight:bold;">a</span><br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r7</span><br /><span style="color: #00007f; font-weight:bold;">acall</span> delay<br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r6</span><br /><span style="color: #00007f; font-weight:bold;">acall</span> delay<br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r5</span><br /><span style="color: #00007f; font-weight:bold;">acall</span> delay</div></div> <br /><br />change to<br /> <div class='code_asm'>CODE:</div><div class='code_highlight' style='unicode-bidi: embed; direction: ltr'><div class="asm" style="font-family: monospace;">data_display6: <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">a</span>,#<span style="color: #ff0000;">0ffh</span><br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">b</span>,#<span style="color: #ff0000;">0ah</span><br /><span style="color: #00007f; font-weight:bold;">div</span> ab<br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r7</span>,<span style="color: #46aa03; font-weight:bold;">b</span><br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">b</span>,#<span style="color: #ff0000;">0ah</span><br /><span style="color: #00007f; font-weight:bold;">div</span> ab<br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r6</span>,<span style="color: #46aa03; font-weight:bold;">b</span><br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r5</span>,<span style="color: #46aa03; font-weight:bold;">a</span><br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">a</span>,<span style="color: #46aa03; font-weight:bold;">r7</span><br /><span style="color: #00007f; font-weight:bold;">acall</span> disp_7seg<br /><span style="color: #adadad; font-style: italic;">;mov p1,r7</span><br /><span style="color: #00007f; font-weight:bold;">acall</span> delay<br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">a</span>,<span style="color: #46aa03; font-weight:bold;">r6</span><br /><span style="color: #00007f; font-weight:bold;">acall</span> disp_7seg<br /><span style="color: #adadad; font-style: italic;">;mov p1,r6</span><br /><span style="color: #00007f; font-weight:bold;">acall</span> delay<br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">a</span>,<span style="color: #46aa03; font-weight:bold;">r5</span><br /><span style="color: #00007f; font-weight:bold;">acall</span> disp_7seg<br /><span style="color: #adadad; font-style: italic;">;mov p1,r5</span><br /><span style="color: #00007f; font-weight:bold;">acall</span> delay</div></div> <br /><br />for disp_7seg subroutine,you compare the value of 'a' with 0.If they match send 'CO' to P1.If not then compare 'a' with 1 and send 'F9' if they match.Similarly proceed with other digits upto 9.<br /><br />CJNE a,#0,D1<br />mov p1,#0C0h<br />D1:CJNE a,#1,D2<br />mov p1,#0F9h<br />D2:CJNE a,#2,D3<br />mov p1,#0A4h<br />   .<br />   .<br />   .<br />   .<br />ret]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Tue, 06 May 2008 04:00:09 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[after a match is found it can jmp to calling routine<br /><br /><br /><br /><div class='code_asm'>CODE:</div><div class='code_highlight' style='unicode-bidi: embed; direction: ltr'><div class="asm" style="font-family: monospace;">disp_7seg: &nbsp;<span style="color: #00007f; font-weight:bold;">CJNE</span> <span style="color: #46aa03; font-weight:bold;">a</span>,#<span style="color: #ff0000;">0</span>,D1<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,#<span style="color: #ff0000;">0C0h</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">sjmp</span> back<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />D1: <span style="color: #00007f; font-weight:bold;">CJNE</span> <span style="color: #46aa03; font-weight:bold;">a</span>,#<span style="color: #ff0000;">1</span>,D2<br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,#<span style="color: #ff0000;">0F9h</span> &nbsp;<br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">sjmp</span> back<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />D2: &nbsp;<span style="color: #00007f; font-weight:bold;">CJNE</span> <span style="color: #46aa03; font-weight:bold;">a</span>,#<span style="color: #ff0000;">2</span>,D3<br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,#<span style="color: #ff0000;">0A4h</span> &nbsp;<br />&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00007f; font-weight:bold;">sjmp</span> back<br />.<br />.<br />.<br />.<br />.<br />back: &nbsp;<span style="color: #00007f; font-weight:bold;">ret</span><br />&nbsp;</div></div><br /><br />Arun]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Tue, 06 May 2008 12:18:02 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[oops forgot the return after match.....thanks Arun for the correction.]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Tue, 06 May 2008 13:51:56 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[sir,i have tried to simulate my program by the way u suggested,i hv tried to write the program code in that way,but  i think still i hv made some mistakes,as its not working.when i am simulating my program it shows the following errors------in  the disp_7segment subroutine if i write sjmp back  then error shows ADDRESS OUT OF RANGE. Replacing sjmp back  by ret it gives  STACK OVERFLOW.Please sir help me to correct the errors.i am enclosing the code here-------   <br />setb p2.5<br />setb p2.6<br />intr bit p2.7<br />setb intr<br />adc_port equ p1<br />adc_val equ 30h<br />voltage_val equ r3<br />back:  clr wr<br />       setb wr<br />conversion:   acall conversion<br /> read:  clr rd<br />        mov a,adc_val<br />        setb rd<br />        mov r3,#00h<br />        acall data_display1<br />        mov r3,#01h<br />        acall data_display2<br />        mov r3,#02h<br />        acall data_display3<br />        mov r3,#03h<br />        acall data_display4<br />        mov r3,#04h<br />        acall data_display5<br />        mov r3,#05h<br />        acall data_display6<br />        sjmp back<br />   data_display1:  mov a,#00h<br />                   mov b,#0ah<br />                   div ab<br />                   mov r7,b<br />                   mov b,#0ah<br />                   div ab<br />                   mov r6,b<br />                   mov r5,a<br />                   mov a,r7<br />                   mov p1,r7<br />                   acall disp_7segment<br />                   acall delay<br />                   mov a,r6<br />                   mov p1,r6<br />                   acall disp_7segment<br />                   acall delay<br />                   mov a,r5<br />                   mov p1,r5<br />                   acall disp_7segment<br />                   acall delay<br />   data_display2:    mov a,#33h<br />                       mov b,#0ah<br />                       div ab<br />                       mov r7,b<br />                       mov b,#0ah<br />                       div ab<br />                       mov r6,b<br />                       mov r5,a<br />                       mov a,r7<br />                       mov p1,r7<br />                       acall disp_7segment<br />                       acall delay<br />                       mov a,r6<br />                       mov p1,r6<br />                       acall disp_7segment<br />                       acall delay<br />                       mov a,r5<br />                       mov p1,r5<br />                       acall disp_7segment<br />                       acall delay<br />     data_display3:     mov a,#67h<br />                        mov b,#0ah<br />                        div ab<br />                        mov r7,b<br />                        mov b,#0ah<br />                        div ab<br />                        mov r6,b<br />                        mov r5,a<br />                        mov a,r7<br />                        mov p1,r7<br />                        acall disp_7segment<br />                        acall delay<br />                        mov a,r6<br />                        mov p1,r6<br />                        acall disp_7segment<br />                        acall delay<br />                        mov a,r5<br />                        mov p1,r5<br />                        acall disp_7segment<br />                        acall delay<br />      data_display4:    mov a,#99h<br />                        mov b,#0ah<br />                        div ab<br />                        mov r7,b<br />                        mov b,#0ah<br />                        div ab<br />                        mov r6,b<br />                        mov r5,a<br />                        mov a,r7<br />                        mov p1,r7<br />                        acall disp_7segment<br />                        acall delay<br />                        mov a,r6<br />                        mov p1,r6<br />                        acall disp_7segment<br />                        acall delay<br />                        mov a,r5<br />                        mov p1,r5<br />                        acall disp_7segment<br />                        acall delay<br />      data_display5:    mov a,#97h<br />                        mov b,#0ah<br />                        div ab<br />                        mov r7,b<br />                        mov b,#0ah<br />                        div ab<br />                        mov r6,b<br />                        mov r5,a<br />                        mov a,r7<br />                        mov p1,r7 <br />                        acall disp_7segment<br />                        mov a,r6<br />                        mov p1,r6<br />                        acall disp_7segment<br />                        mov a,r5<br />                        mov p1,r5<br />                        acall disp_7segment<br />                        acall delay<br />     data_display6:       mov a,#0ffh<br />                          mov b,#0ah<br />                          div ab<br />                          mov r7,b<br />                          mov b,#0ah<br />                          div ab<br />                          mov r6,b<br />                          mov r5,a<br />                          mov a,r7<br />                          mov p1,r7<br />                          acall disp_7segment<br />                          mov a,r6<br />                          mov p1,r6<br />                          acall disp_7segment<br />                          mov a,r5<br />                          mov p1,r5<br />                          acall disp_7segment<br />                          acall delay<br />    disp_7segment:  cjne a,#0,d1<br />                            mov p1,#0c0h<br />                            ret<br />                 d1:     cjne a,#1,d2<br />                       mov p1,#0f9h<br />                       ret<br />               d2:     cjne a,#2,d3<br />                        mov p1,#0a4h<br />                        ret<br />               d3:    cjne a,#3,d4<br />                         mov p1,#0b0h<br />                         ret<br />               d4:     cjne a,#4,d5<br />                          mov p1,#99h<br />                          ret<br />               d5:     cjne a,#5,d6<br />                           mov p1,#92h<br />                           ret<br />               d6:     cjne a,#6,d7<br />                            mov p1,#82h<br />                            ret<br />               d7:      cjne a,#7,d8<br />                           mov p1,#0f8h<br />                           ret<br />               d8:     cjne a,#8,d9<br />                            mov p1,#80h<br />                            ret<br />               d9:     cjne a,#9,d10<br />               d10:             mov p1,#98h<br />                             ret  <br />                    delay:  mov r4,#200<br />                    here:   djnz r4,here<br />                             ret<br />                             end                                                                                <br />                                                                       <br />                                                                           thanking u,]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Wed, 07 May 2008 20:51:48 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[sir,once again i tried to simulate the program by removing the statement CONVERSION:ACALL CONVERSION,program after being simulated shows no error ,in the previous case it was showing STACK OVERFLOW.but i just want to confirmis it the correct way i am programming???lease send a quick reply.<br />                                                                                                       thanking u sir]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Wed, 07 May 2008 21:07:18 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[Hi Priya,<br /><br /><div class='code_asm'>CODE:</div><div class='code_highlight' style='unicode-bidi: embed; direction: ltr'><div class="asm" style="font-family: monospace;"><span style="color: #00007f; font-weight:bold;">setb</span> p2<span style="color: #ff0000;">.5</span><br /><span style="color: #00007f; font-weight:bold;">setb</span> p2<span style="color: #ff0000;">.6</span><br />intr <span style="color: #0000ff;">bit</span> p2<span style="color: #ff0000;">.7</span><br /><span style="color: #00007f; font-weight:bold;">setb</span> intr<br />adc_port <span style="color: #0000ff;">equ</span> <span style="color: #46aa03; font-weight:bold;">p1</span><br />&nbsp;adc_val <span style="color: #0000ff;">equ</span> 30h<br />voltage_val <span style="color: #0000ff;">equ</span> <span style="color: #46aa03; font-weight:bold;">r3</span><br />back: <span style="color: #00007f; font-weight:bold;">clr</span> wr<br /><span style="color: #00007f; font-weight:bold;">setb</span> wr<br />conversion: <span style="color: #00007f; font-weight:bold;">acall</span> conversion<br />read: <span style="color: #00007f; font-weight:bold;">clr</span> rd<br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">a</span>,adc_val<br /><span style="color: #00007f; font-weight:bold;">setb</span> rd</div></div><br /><br /><br />here are the  two bugs i found :<br /><br /><strong class='bbcode bold'><span style='color:#990000'>back: clr wr<br />setb wr<br />conversion: acall conversion</span></strong><br /><br />1) label name : <strong class='bbcode bold'>back</strong> is already defined once and you are using it again in the disp_7seg routine,<br /><br /> in my last post i used the sjmp back ( i didn't know that back label was already used )command just to <br /><br />avoid  so many ret s,  so the program was trying to sjmp (short jump) from disp_7seg routine to back<br /><br /> label in the begininng of the program which is obviously out of address range ( in some cases when you get "out<br /><br /> of range " error trying using LJMP command instead of SJMP)<br /><br />2) <strong class='bbcode bold'>conversion: acall conversion</strong>  - the program counter  is stuck here indefinetly <br /><br /><br />3) tip : it is a good practice  to  First relocate the stack pointer beyond the 4 Register Banks Address &amp; bit addressable ram ( from 20h) in the main routine - this avoids stack overflow/over writing   <br /><br /><br /><br />you can use  :  <strong class='bbcode bold'>MOV SP,#50H </strong>  ; put this in the first line of your Main routine to relocate SP to some safe <br /><br />address which you'll not be using for your variables <br /><br /><br /><br />try these corrections and simulate <br /><br /><br />Arun<br /><br /><br /><br /><br /><br />]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Thu, 08 May 2008 02:32:42 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[hi priya, looks like something is seriously missing in ur code.<br /><br />data_display1: mov a,#00h<br />mov b,#0ah                     <br />div ab                       -----here acc=0 and b =0ah<br />mov r7,b<br />mov b,#0ah<br />div ab<br />mov r6,b<br />mov r5,a<br />mov a,r7<br />mov p1,r7        -------here r7 will always bear a value 00h <img src='http://www.8051projects.net/e107_images/emotes/yahoo/7.gif' alt='' style='vertical-align:middle; border:0' />  <br /><br />from ur code i feel that the segments of  display  are connected to port p1.<br />now in the above code there is no mention of the register r3 nor is the adc_val u have put in accumulator. So please check the logical flow of ur routine. also mention the hardware connections of the adc and display to the uC to avoid further confusion.]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Thu, 08 May 2008 00:49:25 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[<div class='code_asm'>CODE:</div><div class='code_highlight' style='unicode-bidi: embed; direction: ltr'><div class="asm" style="font-family: monospace;"><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r6</span>,<span style="color: #46aa03; font-weight:bold;">b</span><br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">r5</span>,<span style="color: #46aa03; font-weight:bold;">a</span><br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">a</span>,<span style="color: #46aa03; font-weight:bold;">r7</span><br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r7</span><br /><span style="color: #00007f; font-weight:bold;">acall</span> disp_7segment<br /><span style="color: #00007f; font-weight:bold;">acall</span> delay<br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">a</span>,<span style="color: #46aa03; font-weight:bold;">r6</span><br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r6</span><br /><span style="color: #00007f; font-weight:bold;">acall</span> disp_7segment<br /><span style="color: #00007f; font-weight:bold;">acall</span> delay<br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">a</span>,<span style="color: #46aa03; font-weight:bold;">r5</span><br /><span style="color: #00007f; font-weight:bold;">mov</span> <span style="color: #46aa03; font-weight:bold;">p1</span>,<span style="color: #46aa03; font-weight:bold;">r5</span><br /><span style="color: #00007f; font-weight:bold;">acall</span> disp_7segment<br /><span style="color: #00007f; font-weight:bold;">acall</span> delay</div></div> <br /><br />Comment out or remove the fol. lines in the code above(as well as in all the other display routines).<br />1)mov p1,r7<br />2)mov p1,r6<br />3)mov p1,r5<br /><br />]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Thu, 08 May 2008 03:49:24 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
						<item>
						<title>Re: query regarding display</title>
<link>http://www.8051projects.net/forum-t9130.html</link>
<description><![CDATA[thanx a lot a shash sir,arun sir n  pdi33 sir,my program has now started working.its all because of ur guidance,thanx .]]></description>
<author>contact@nospam.com (Ajay Bhargav)</author>
<pubDate>Thu, 08 May 2008 18:06:30 -0700</pubDate>
<guid isPermaLink="true">http://www.8051projects.net/forum-t9130.html</guid>
</item>
				</channel>
				</rss>