微机原理和接口技?第四?课后习题答案解析 - 百度文库 ر

ݷʱ : 2024/12/25 0:00:13һ µȫĶ

3 ݴ

ϰ3.1

1ʹö8λ޷257жӦı

2ַ'F'ֵ46HΪMOVָԴ

3Ϊʲô԰ָMOV AX, (3467H)*3еֵʽdz 4ֵ500ܹΪֽڱijֵ

5Ϊʲô˵XCHG EDX,CXһָ

6ǻȡƫƵַΪʲôָLEA EBX, [ESI]ȷָMOV EBX, OFFSET[ESI]ʹ

7INCDECNEGNOTǵָӦԴĿIJ 8Сдĸתʹʲôɣ

9˳޷зֲָͬֻһָļӼ޷з㣿

10߼ΪʲôҲΪ߼ˣ

ûСʹö8λ޷257ûжӦı롣 ַ'F'ASCIIֵ46Hû

ڻжֵʽ㣬õһȷֵʳֵʽΪ ܡֵ500һֽܱԲΪֽڱֵ ԴĿĴλͬøָݽ

ǰִָʱƫƵַȷģߵOFFSETֻڻ׶λƫƵַʱĴDz֪ģ޷ƫƵַ

INCDECNEGNOTָIJԴҲĿIJ СдĸתǵASCII20H

Ӽ޷зֱñ־ĴCFOF־CFOF

߼ƶƵij˷ԳΪ߼ˡ ϰ3.3

1ֽڱαָǷ_____________ȡеƫƵַIJ_____________

2һ01100001롣Ϊ޷10___________ΪBCD룬ʾֵ_____________ijASCII룬ַ__________

3Cá\\nʾùصһλڻҪַһǻسASCII_____________ƶǰеλһǻУASCII_____________ƵһС

4ݶ䡰H8843 DWORD 99008843HָMOV CX, WORD PTR H8843ִкCX_____________

5DWORDһXYZ_____________áTYPE XYZõֵΪ_____________ʹãӦ_____________˵

6ݶ䡰ABC BYTE 1,2,3ָMOV CL, ABC+2ִкCL_____________ 73-9TABǡ1234567890ʾ__________ 8ָXOR EAX, EAX͡SUB EAX, EAXִкEAX__________CFOF__________ָMOV EAX, 0ִкEAX__________CFOFûб仯

93-15ִнQVAR__________BCD__________

10EDXڵ޷16ʹָSHR EDX, __________кһһ

BYTEOFFSET 9761Сдĸa

5

0DH130AH10 8843H

DWORD4WORD PTR XYZ 3

78894111 000

0123456788765432H83H 4 ϰ3.4

ʮʾ޷תΪʮʽֵ FFH 0H 5EH EFH

255 0 94 239 ϰ3.7

ʮ8λƲʾ 0 127 ۣ127 57

00000000 01111111 10000001 11000111 ϰ3.8

ʮݵļӼ㣬˵Ƿнλλ 1234H7802H F034H5AB0H C051H1234H 9876HABCDH

1234H7802H8A36H޽λ F034H5AB0H4AF4Hнλ C051H1234HBE1DH޽λ 9876HABCDHECA9Hнλ ϰ3.9

09дĸAZСдĸazӦASCIIֱǶ٣ASCII0DH0AHֱӦʲôַ

09ӦASCII30H39H

дĸAZӦASCIIǣ41H5AH СдĸazӦASCIIǣ617AH ASCII0DH0AHֱӦǻسͻַ ϰ3.10

һݶΣҪų my1bΪַPersonal Computer my2bΪʮʾֽڱ20 my3bΪʮʾֽڱ20

6

my4bΪöʾֽڱ20 my5wΪ20δֱֵ my6cΪ100ij

my7cʾַPersonal Computer my1b my2b my3b my4b my5w my6c my7c

byte 'Personal Computer' byte 20 byte 14h

byte 00010100b word 20 dup(?) = 100

equ

ϰ3.16

ʹMOVָʵָֽXCHG EBX,[EDI]ܡ

push eax mov eax,ebx mov ebx,[edi] mov [edi],eax pop eax

; û

; û

ϰ3.17

赱ǰESP0012FFB0H˵ÿָESPڶ٣

push eax push dx

push dword ptr 0f79h pop eax

pop word ptr [bx] pop ebx

ESP0012FFACH ESP0012FFAAH ESP0012FFA6H ESP0012FFAAH ESP0012FFACH ESP0012FFB0H

ϰ3.19ֱһָ¹ܣ

1EBXĴEDXĴӣEDXĴ

2üĴEBXESIĻַַѰַʽѴ洢һֽALĴӣѽ͵ALС

3EBXλ0B2HļĴѰַʽѴ洢еһ˫ֺECXĴӣѽͻش洢С

432λVARD3412Hӣѽͻظô洢ԪС 50A0HEAXĴӣѽͻEAXС

add edx,ebx

add al,[ebx+esi] add [bx+0b2h],cx add varw,3412h

7

add eax,0a0h

иִָкALֵԼCFZFSFOFPF״̬

mov al,89h add al,al add al,9dh cmp al,0bch sub al,al dec al inc al

mov al,89h add al,al add al,9dh cmp al,0bch sub al,al dec al inc al

; AL89H ; AL12H ; AL0AFH ; AL0AFH ; AL00H ; AL0FFH ; AL00H

CF ZF 1 0 0 0 1 0 0 1 0 0 0 1

SF 0 1 1 0 1 0

OF 1 0 0 0 0 0

PF 1 1 1 1 1 1

ϰ3.21

ϰ3.28̽һѹBCD92HתΪӦASCII룬ȻDISPCӳӳУʾ bcd

; ݶ byte 92h ; mov al,bcd shr al,4 add al,30h call dispc mov al,bcd and al,0fh add al,30h call dispc

4 Գ

ϰ4.1

1ʲôصĿַѰַʽӦࣿ 2ʲôżУ飿

3Ϊʲôж޷СзŴСתָͬ 4˫֧ṹ֧֮JMPָʲôã 5ΪʲôرǿΪӳϱҪעͣ

6ӳöջݲΪʲôҪرעջƽ⣿ 7ݵġֵַ͡ʲô 8INCLUDEINCLUDELIBʲô 9ϱʲôƣ

10WindowsʱΪʲôʾijDLLļڣ

ͬһ򱻲ϵͳŵͬĴ洢ִʱָλûиı䣬ĿַѰַɷϵͳȡ

8