0% found this document useful (0 votes)
29 views

Course Name: EE 3541: Introduction To Microprocessors: Academic Year 1440H/1441H - 2019G/2020G

The document contains a homework assignment on addressing modes in microprocessors. It asks the student to define various MOV instructions, list registers used for addressing, identify errors in certain MOV instructions, and determine memory addresses for different addressing modes using given register values.

Uploaded by

aa
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
29 views

Course Name: EE 3541: Introduction To Microprocessors: Academic Year 1440H/1441H - 2019G/2020G

The document contains a homework assignment on addressing modes in microprocessors. It asks the student to define various MOV instructions, list registers used for addressing, identify errors in certain MOV instructions, and determine memory addresses for different addressing modes using given register values.

Uploaded by

aa
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

'1

Prince Sattam bin Abdulaziz University ~_yJI~ j! rtk...., J'!'°~I AAA~


College of Engineering L-4,)1

Electrical Engineering Department 9 ~_A5JI L~I


j,ij.aJI >u,,.. J:!"111 w'9
,a ~<'!t:V £111' Af>d:.ilJ, n: !)i'\,~ _sµ 1..:.i~\Mll J ;i...,li.o ~3541
EE35-H Introduction to Microprocessors
P, t; t\!

Course Name:
EE 3541 : Introduction to Microprocessors

Homework No. (2) :


Addressing Modes in Microprocessor 8086/8088

Academic Year 1440H/1441H -2019G/2020G

Student Name

ID No. 4,) t O S oo 4i First Term

Teaching Notes Total


Assistant/Lecturer 10
Professor Name:
Eng.: Prof. Fayez F. M. EI -Sousy

Signature Signature

.-f

1-7
'1 J
Answer the Following Questions:
I. What do the following MOY instructions accomplish?
(a) MOY AX, BX
(b) MOY BX, AX
(c) MOY BL, CH
(b) MOY SP, BP
-·-- _(e) MOY AX, CS ······-· ......... ........ ... -····-··-

-- A)_(.o.p~.-· -B.L .ihto_J)( ........ . ·········- · ··--·· . ···-·. ·--·····- ····-···-· ·····--· ···-·-·- -
. )jfJJ ·-···- - ···- .. ··-·-····--· ·········· ······-········· ········- . · ·--··-·····-······•··· ·---·- -····-
__1)J _(.(2Vj --ih~-·-~11J Jsx. . . . . . . ··· · -· ·-·· -· ·-· . · · · -· · · ·--·-·..
__r)__cJ?.?1. -l H~.\\1.0 ..JsL··-······. ········-·-····-··· · · · -·· ·-·····-·--····· ··--·-·--·· .==:

- - ----- --- - - - - -· - --

2. List the 8-bit registers used for register addressing.


- - --- -- ---- -···- - ·-·----------- -· ·--------- ···-- ------ -- --------

- -----··- -··········-- - - - ······ ························· - - - - - - - -

••..•..... ·-·· ········-···. ······-··· .. ··········-·-·-·-······· -················---- -

··-···· ...•.. ······················-···-· ··-· · - - - -

2-7
't
3. List the 16-bit registers used for register addressing J

5. List the 16-bit segment registers used for register addressing by MOY.

·····•············----- -

························- - -- - -

···························- - - - - - - - -··- -

- ..... ---···- ------ -···· - - -.. - - · - -- --····-···············-··--····- - - - - - - -- - --

6. What is wrong with the MOY BL, CX instruction?


-----· - ··- -·--············-· ··· - - - - - -- - - ---

--1he;-_. \v~_ ±c_ 1J.e.. _. J:ht.-..-.s~~.c-.. .__£;.t ,-><-e_ _ _ _ _ __

........ ·····-··· ·- -··· ···················-·-- - - --··--····--· - - · - - - -

.. -···········-·· ··----
·····-···-··· ·-·· ··-··--····· ·· ·····-··-- - - - - - ----
7. What is wrong with the MOY DS, SS instruction?

. ··--·· ... ··-·--·····---··-- ... ········-·· -·······-···· . ----··-·····- ·-······· .... ············---

3-7
J. Select an instruction for each of the fol lowing tasks :
(a) copy BX into DX
(b) copy BL into CL
(c) copy ST into BX
(d) copy DS into AX
(e) copy AL into AH

11_)_/!J ov._. _c. L.,.Js.L. . .

~)_A. Qv::~: 13i:~_-S1.. -.:_-..


.. .. ·-................... -....... .. ... - ....-.. ............- ..-· .. - -.. -· .. _.... -·-··---.. ··---

Af-fJ.Q~___A 1._,.__D :.: ~-· ...- ................ - ....... ._....................... - .... ..... --
.... --·------ ... _ .. ___ , ......... _.._ .. ____.... . _........ ---- ..--·-..·---·.. -·-- · - --

e}_}J_Q_\l.__..f± }l_J_4 L ::-_ . ...........- ......- ........ -.......... ........ - ....... ...- ........ .............. -- .. -- ...-.• - ....--.. - --

..... -.................--.-· .. .......- .. - .... -... - ...- .. - - - ·- - - -

9. Select an instruction for each of the following tasks:


(a) move a 12H into AL
(b) move a 123AH into AX
(c) move a 0CDH into CL
(d) move a I000H into SI
(e) move a l 200A2H into BX

c0 ,~10~.. ~l~L --...·-


~l-l1~.'-J. ._. _A'i-r-~ 2J A..H _... -...-·---·-·...... . -....
.. .. ........._. ___ ........ - ·---·---· ..........- ..... - --

.... - ..............· - - - · · - - -- - - - - --

...... -.. -·--··- .... -··-· .. - - - -- · ·-·- - ..--- -- - · - -

0) .. /VlO\' Sl, \ooo\-\

.. _ . -------..- ........ ·-...........----·-· -·-.. ·----- _____... .. .... - --

----·-- ---

4-7
1o. Suppose that DS==0200H, BX==0300H, and D1==4001-1. Determine the memory
address accessed by each of the foll owing instructions, assuming real mode operation:
(a) MOY AL, [ 1234H]
(b) MOY AX, [BX]
(c) MOY [DI ], AL

_(:,>_Q S_x__\o - 7 o oo \-\


_ ; - OSc,Uo q 1 H \:-1 1ooo\:\ "1 l 4 \-i_ {s,3 4_;J} -=--
-ti) _QS'<,_\ 0 - 1 o
i. ·-__ ____
0 \-\ _ _ .. ... ____ __. - - -- ·--•------ _ _____ ....___ __ __

_ . ..0 >.Xl b -r o 3 c-o \\ - _'b oc.\A _1- o J.P ..9 \-\.: \ '2 3 o \-\

- --- - - - - - ----- - - - - - -·----··--···--·-·· · - - - - - - - - - -

11 . What is wrong wi th a MOY [BX], [DI] instruction?

12. Suppose that OS== IOOOH, SS=2000H, BP= IOOOH, and DI= IOOH. Determine the
memory address accessed by each of the following, assuming real mode operation:
(a) MOY AL, [BP+DJJ
(b) MOY ex, [DI]
(c) MOY DX, [BP]

o)C:S~\t, _loooq\ -

Ojx\ c.;. +- \00 \.\ - \ot>oo \-\ i--\ t)D H ;;~\o\vo uJ


_CJ ~)_j \~Z- 1o_oou __ ::~~ --·--- _- - --·- ...........
- - - _......... . ··- -
.. -·------- ----------·-- _ -·-
~S) \t,,., \t.ic•ci\-\ 1 0001; \\"' \ oc.Jo \-\ ::\ 2 \ t100 \ \\

5-7
-

13. Suppose that DS= 12OOH BX=OIOOH and ') .


accessed by each of the D0 Il .' . . ' ' S_l- O~SOH Determ111e the address
. OY [
(a) M owmg 111struct1ons assuming real mode operation·
IOOOH], DL ·
(b) MOY [Sl+lOOOH], AX
(c) MOY DL, [BX+ IOOH]

__c~) Q.S \ -~-- \{hoov~\


__Q.S\_\.o \·.lDOo \\

_\Jlu~i_\o L) 1 ":__\ 0. 10
\-t .- \1~co \.\..1- 0 1 ?.o \\.±.\oco.J \ :;[ 13.2.5QJAJ
e,) 0 \oD ~-- -\?~o~-~-+~-\·~·~~-~·\-~~~-~\\ '2?60 ~)

- - - - · ······-···-···-·-···- .... ··-·-····----- -----·-··- ---··--·- -

14. Suppose that DS= 11 OOH, BX=O2OOH, LIST=O25OH, and SI=OSOOH. Determine the
address accessed by each of the following instructions assuming real mode operation:
(a) MOY LIST[SI], EDX
(b) MOY CL, LIST[BX+SI]
(c) MOY CH, [BX+SI]
·-· · ---·--······--·-------·---- --·········-··-·- - - - -
C") QSx\o \\Duu _ _
v~x \u -r JtVJC,\\ -'".JSu ·\-\ \\u__;c1\\10'2~0 1\1 o~oo \--1{\\.;,?S o~1

6-7
'1 J
I 5. Suppose that OS=1300H, SS== 1400H, BP=IS0OH, and SI=OIOOH. Determine the
address accessed by each of the following instructions, assuming real mode operation:
(a) MOY AX, [BP+200H]
(b) MOY AL, [BP+Sl-200H]
(c) MOY AL, [Sl-01 OOH]

. _£~_s_s~··'-~. : :_\4Qo..~\\ -...... ··········· ·-·- .


--· .. _S,S.x_\.o.. J·_..iJ?. .:.\...29.Q~ .. \~'..boc \i..±.\5.D>-..l-\ \-Loo r\ ....:=.. \ 5 l oo H _.

c) DSx\o n°00 \\
-·- ~ l o.r SJ .- ~\. ..- \ lo.D
..o. \Lt .0\0.1...})... o ..Lo.P \:1. ...:-:.. \}?.Q.Q... \-\ ······ ··

... ............. .... - --

- - - -- - - - - -- - - · · · · · · · - ·········· ···· · ······•·•• - ·· - ··············-·· ·· ··· - - · - - -

16. Which base register addresses data in the stack segment?

················· · · · - --

- - - - -· -·-······-•··-·-··· ------- - - - - · · · · · · · · ········-·· --··- · -

- - · - · · - ··- ·················· · · · · · · · - - -

- - -•·-············-·· - - - · · ···-·- - -- - -· . ···-·· .. ······-·- - - -···· . ..•. ··········-·--··· · -···

- - -- - - - - - -·················· ·····- - - -

·-·······-···-··- - -- -·----

- - - - - · · · · · - · ····- · · · · · · - -- -
rl l
7.7

You might also like