assmeblers and disassemblers

Roger Heflin rah at horizon.hit.net
Thu Sep 24 18:37:09 GMT 1998



On Thu, 24 Sep 1998, Bruce Plecan wrote:

> 
> -----Original Message-----
> From: Frederic Breitwieser <frederic.breitwieser at xephic.dynip.com>
> To: diy_efi at efi332.eng.ohio-state.edu <diy_efi at efi332.eng.ohio-state.edu>
> Date: Thursday, September 24, 1998 12:53 PM
> Subject: Re: assmeblers and disassemblers
> 
> 
> Big Snip
> >
> >For example.
> >LDA $FF
> >The above means "load the A register with value $FF (which is 255 to you
> and me).  The assember converts this to:
> >08FF
> >The microprocessor likes the latter, people prefer the former.  Hope that
> answered your question without making it more confusing.
> >Frederic Breitwieser
> 
> 
> 08 would be an address, right?
> How do you know A=address 08?.
> Bruce
> 
> 

No.  Generally for small chips (ones with few registers that aren't numbered)
the 08 actaully means loada with a value, in the case of a 68hc11 the first
byte would be 86 and then the value to load.  For a load B the value
would be C6 and then a value.  Generally in the micros with a few unnumberd
registers the instruction is actually defined as load A, in machines with
more registers the instruction is defined as load and then several bits
for the part identifing the register.  In the case of the 68hc11 there does
not seem to be a consistant way (among different instructions) to determine
if it is working on a or b.  The use of a or b is built into the instrution
itself.   So to answer your question 08 or (86 on hc11) is in a assembly
decoding/encoding table that defines it as LDA, and that is really howit
is decoded.  You must have the table to be able to encode/decode things, and
every chip from a different manufacturer is different, and even alot of chips
from within the same manufacturer.

				Roger




More information about the Diy_efi mailing list