This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

can same memory space use two diff variables ?

Dear Sir,

I m in beginning phase of 8051 with C. i have compiled my c file and i found in .m51 file that one of the SFR and a user defined variable share the same memory space(0080H) .How it's possible.Could you pls explain me.
.M51 lists ....

------- MODULE func1

D:0080H PUBLIC PORT0
I:0080H PUBLIC variabl1

Kindly help with reference to above.

regards,
Arup

Parents
  • " no SFR 'occupies x no of bytes', they all 'occupy' ONE."

    The so-called "bible" refers to the (TH0+TL0) and (TH1+TL1) pairs as "16-bit registers"

    DPTR is also a 16-bit register (thought also accessible as DPH and DPL)

    There maybe others specific to particular derivatives?

Reply
  • " no SFR 'occupies x no of bytes', they all 'occupy' ONE."

    The so-called "bible" refers to the (TH0+TL0) and (TH1+TL1) pairs as "16-bit registers"

    DPTR is also a 16-bit register (thought also accessible as DPH and DPL)

    There maybe others specific to particular derivatives?

Children
No data