Skip to main content

Timing diagram of STA 8050H

Short answer

A bus timing diagram depicts address, data, and control signals per T-state. STA 8050H uses four cycles: opcode fetch, two memory reads to get 50H and 80H forming address, and a memory write to store A at 8050H; total 13 T-states.

Explain bus timing diagram. Draw and explain the timing diagram of the 8085 instruction STA 8050H.

Bus timing diagram

A bus timing diagram shows the state of the address lines, data lines and control signals (ALE, RD, WR, IO/M, S1, S0) against the clock, T-state by T-state, during one machine cycle. It tells exactly when the address is valid, when data is read or written and which device is selected. It is used to design memory/I/O interfaces and to check timing requirements.

Basic pattern of an opcode fetch cycle (4T):

        |  T1  |  T2  |  T3  |  T4  |
 CLK    | _|-|_| _|-|_| _|-|_| _|-|_ |
 ALE    |  HIGH|  low |  low |  low |
 A15-A8 |  PCH (address valid ........|
 AD7-0  |  PCL |  --  |opcode|  --  |
 RD     |  high|  LOW |  LOW | high |
 IO/M   |  low (memory operation)     |

STA 8050H

STA 8050H (opcode 32H) stores the accumulator into memory location 8050H. It is a 3-byte instruction with 4 machine cycles: opcode fetch (4T), memory read (3T), memory read (3T), memory write (3T), total 13 T-states. Assume it is stored at 2000H: bytes 32H, 50H, 80H.

M-cycleTA15-A8AD7-AD0ALEControlIO/M S1 S0
M1 (opcode fetch, 4T)T120H00H (PCL)1-0 1 1
T220HHi-Z (bus floats)0RD low0 1 1
T320H32H (opcode in)0RD low, rises at end0 1 1
T4--0none (decode)0 1 1
M2 (memory read, 3T)T120H01H1-0 1 0
T220HHi-Z (bus floats)0RD low0 1 0
T320H50H (data in)0RD low, rises at end0 1 0
M3 (memory read, 3T)T120H02H1-0 1 0
T220HHi-Z (bus floats)0RD low0 1 0
T320H80H (data in)0RD low, rises at end0 1 0
M4 (memory write, 3T)T180H50H1-0 0 1
T280HA (data out)0WR low0 0 1
T380HA0WR low, rises at end0 0 1

Explanation

  • M1 (opcode fetch): PC = 2000H on the bus, ALE high in T1; RD low in T2-T3; opcode 32H is read into IR and decoded in T4.
  • M2 (memory read): address 2001H; RD low; low-order address byte 50H goes to register Z.
  • M3 (memory read): address 2002H; RD low; high-order address byte 80H goes to register W.
  • M4 (memory write): WZ = 8050H is put on the bus (80H on A15-A8, 50H on AD7-AD0 with ALE high in T1). In T2 the CPU places the content of A on AD7-AD0 and WR goes low; the memory stores the data when WR rises at the end of T3. IO/M = 0, S1 = 0, S0 = 1.

✓ Answer checked by Claude Opus 5.5 (high effort)

All Microprocessor chapter 2 questions →