We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
HI ERIK AND DHAVAL SOLANKI
PLEASE CLARIFY ME THE MISTAKE I VE DONE HERE, THIS THE PROGRAM TO INTERFACE FOUR SEVENSEGMENT LEDS (MULTIPLEXING), IN THIS PROGRAM THE DATA WHICH IS STORED IN 90H,91H,92H,93H ARE NOT DISPLAYED IN PORT P1. PLEASE GIVE ME YOUR SUGGESTION, NO ERROR DISPLAYED BUT THE ANSWER IS NOT OBTAINED
;COUNTER PROGRAM ORG 0000H LJMP MAIN ;------------------------------------- ORG 000BH LJMP T_I_CALC ;------------------------------------- MAIN: MOV R2,#0 MOV R3,#0 MOV R4,#0 MOV R5,#0 MOV TMOD,#00000001B MOV TL0,#00H MOV TH0,#0FFH MOV IE,#10000010B SETB TR0 ;------------------------------------- L1: MOV P2,#11110111B MOV R0,93H MOV P1,@R0 MOV P2,#11111011B MOV R0,92H MOV P1,@R0 MOV P2,#11111101B MOV R0,91H MOV P1,@R0 MOV P2,#11111110B MOV R0,90H MOV P1,@R0 ; MOV R6,#0FFH ;L10: MOV R7,#0FFH ;L9: DJNZ R7,L9 ; DJNZ R6,L10 SJMP L1 ;-------------------------------------- T_I_CALC: CLR TF0 CLR TR0 CLR A MOV A,R2 MOV DPTR,#DAT MOVC A,@A+DPTR MOV 90H,A INC R2 CJNE R2,#10,L4 L4: JC L5 MOV R2,#0 CLR A MOV A,R3 MOVC A,@A+DPTR MOV 91H,A INC R3 CJNE R3,#10,L6 L6: JC L5 MOV R3,#0 CLR A MOV A, R4 MOVC A,@A+DPTR INC R4 MOV 92H,A CJNE R4,#10,L7 L7: JC L5 MOV R4,#0 CLR A MOV A,R5 MOVC A,@A+DPTR INC R5 MOV 93H,A CJNE R5,#10,L8 L8: JC L5 LJMP MAIN ;--------------------------------------- L5: MOV TL0,#000H MOV TH0,#0FFH SETB TR0 RETI ;----------------------------------------- DAT: DB 0C0H,0F9H,0A4H,0B0H,99H,92H,82H,0F8H,80H,90H ;----------------------------------------- END ;-----------------------------------------
THANK YOU ERIK, I DONT NEED YOUR HELP, I DID NOT ASK YOU TO DO MY HOME WORK, JUST I CAME TO THIS FORUM FOR DISCUSSION AND CLARIFICATION, DONT BEHAVE LIKE YOU KNOW EVERYTHING,BUT ITS MY HABIT OF TYPING IN CAPITAL LETTER I CANT CHANGE THIS JUST FOR YOU.YOU NEVER THING TO CHATT TO ME LIKE THIS FURTHER, DONT YOU HAVE MANNERS?USE LIMITED WORDS.
here again is one of those posts "I want help for free, but darn it, I want it on MY conditions".
Erik, I am so sorry yaar, but one think is true that you are a wise man in micro controller.I accept that.As my apology, look at in this comment, i ve used everything in small letters except the noun.......sorry genius...dont forgive me but forget my last comment
Erik, i ve gone through the bible you ve given named:80C51_FAM_ARCH_1 page no:3 sentence is: Figure 9 gives a brief look at the Special Function Register (SFR) space. SFRs include the Port latches, timers, peripheral controls, etc. These registers can only be accessed by direct addressing. Sixteen addresses in SFR space are both byte- and bit-addressable. The bit-addressable SFRs are those whose address ends in 0H or 8H. my question: named:The 8051 Microcontroller and Embedded Systems Using Assembly and C-2nd-ed author:muhammad ali mazidi page no:30(avalable in pdf format) in this book there are only 11 bit addressable sfr's,Thy are:P0,P,02,P3,TCON,SCON,IE,IP,PSW,ACC,B which one correct.if the bible is true then which are remaining 5 bit addressable SFRs, and will it end with 0h and 8h
Erik, i ve gone through the bible you ve given named:80C51_FAM_ARCH_1 page no:3 sentence is: The next 16 bytes above the register banks form a block of bit-addressable memory space. The 80C51 instruction set includes a wide selection of single-bit instructions, and the 128 bits in this area can be directly addressed by these instructions. The bit addresses in this area are 00H through 7FH. my question: named:The 8051 Microcontroller and Embedded Systems Using Assembly and C-2nd-ed author:muhammad ali mazidi page no:24(avalable in pdf format) in this book the author has told the memory location from 20h to 2fh is alone bit addressable ... and rest of the memory is byte addressable then.. then which one is correct?
doc.nit.ac.ir/.../3-Mazidi-8051.pdf
One might hazard that 128 bits fit in 16 bytes
yes correct, what about the first question
i followed the 'bible','erik' and 'Dhaval Solanki's instruction then finally got answer for the problem,thank you both of you,once again i request you please forgive me...Erik you can fire on me however you have the way to answer the question...i got some guilty feel like i ve made mistake to you... but right now you both were the reason to bring up one step up in my programing language and solving problem..sorry lot erik...look at here i am not using any capital letters, that means i ve realized the mistake...
"what about the first question"
If that is the question about the address range 20H - 2FH, it is both bit-addressable and byte-addressable.
Sixteen addresses in SFR space are both byte- and bit-addressable. The bit-addressable SFRs are those whose address ends in 0H or 8H.
in this book there are only 11 bit addressable sfr's
There are 16 bit addressable 'slots' in the SFR space the old 'steam driven' 8051 Mazdi still babbles about only used 11 of them
Erik
hearing commends from you makes me happy from the sorrow ,but did you forgive me. please dont have any emotion in you.you can fire on me untill the emotion demolishes.