The previous compilation was not very good. By this microcomputer interface to the assembly language is to fill up.
The following is a note of this time relative to the assembly language used in the microcomputer interface.
PTR
In the case where there is no register name, the length of the memory unit is indicated by the operator "x ptr", and X can be word or byte in the assembly instruction. For example:mov word ptr ds:[0],1inc Word PTR [BX]move byte ptr ds:[0],1Inc byte PTR [BX]In memory unit access directives that do not have register participation, you must explicitly tell the CPU whether the unit to be accessed is a word cell or a byte cell.
XLAT
Xlat for the Table command, which operates as [Bx]+[al]---->al
MOV
Assignment statement: MOV dx,key; key is Variable
out
typically used for write ports
MOV Dx,pa; PA is PortOut Dx,al; Al for specific commands such as 8255 initialization
inch
typically used to write CPU
In AL,DX, the value of the port can not be directly written in AL, need to first mov into DX and then in into the Al
OFFSET
Get offset Address
MOV dx,offset tab, tab array, Get tab offset address, this is the first address
SEG
Get segment Address
MOV dx,seg INSTR; here INSTR to interrupt the program, get the segment address of the interrupt program
Lea
Writes a near-address pointer to the specified register. Format: LEA REG16,MEM16 where reg16 must be a 16-bit general-purpose register, MEM16 must be a memory, and after executing this instruction, the 16-bit offset address referred to by MEM16 is transmitted reg16. For example, the LEA ax,buf is the transfer of the address referred to by BUF in memory to Microsoft Dynamics AX.
Difference mov transmission instructions:mov transmits the content that the address refers to, and the LEA is only the address.
about several common DOS calls:
dos call first mov into Ah, that is, the first deposit to execute the command, and then int 21H to execute the command
mov ah,4ch exit program
eg; mov ah,4chint 21h
mov ah,25hWrite Interrupt
mov ah,35hRead Interrupt
mov ah,02hwrite DL; commonly used in CRT
assembly language in the microcomputer interface