1.

Write A Program That Will Store The Contents Of An Accumulator And Flag Register At Locations 2000h And 2001h.?

Answer»

By making use of the Push & Pop INSTRUCTIONS the PROGRAM can be written as:

  • LXISP, 4000H - this step initiates the SP at 4000h.
  • PUSH PSW - the contents of the accumulator and flag are PUSHED into the stack.
  • POP B 
  • MOV A, B
  • STA 2000H
  • MOV A, C
  • STA 2001H
  • HLT

By making use of the Push & Pop instructions the program can be written as:



Discussion

No Comment Found