---
title: "Instruction and data format, addressing modes"
subject: "Microprocessor"
chapter: 2
key: "semester_4/microprocessor:8085-instruction-data-format-addressing"
source: https://www.bctengineer.com/q/semester_4/microprocessor/8085-instruction-data-format-addressing
site: BCT Engineering
---

# Instruction and data format, addressing modes

Microprocessor · Chapter 2: Programming with 8085 Microprocessor

- Asked in: 2072 Asoj, 3+5 marks; 2068 Magh, 3+5 marks (asked 2 times)
- Video: [Addressing Modes of 8085 Microprocessor](https://www.youtube.com/watch?v=RyMT7GznQUo) — Neso Academy
- Answer checked by Claude Opus 5.5 (high effort) on 2026-10-14
- Page: https://www.bctengineer.com/q/semester_4/microprocessor/8085-instruction-data-format-addressing
- Whole chapter: https://www.bctengineer.com/md/semester_4/microprocessor/chapter-2

## Question

Explain the instruction format and data format of 8085 microprocessor. Explain different addressing modes.

## Short answer

8085 instructions are one-byte (opcode only), two-byte (opcode + 8-bit data), or three-byte (opcode + 16-bit address low/high). Data can be unsigned, signed 2's complement, BCD, ASCII, or 16-bit. Addressing modes are immediate, register, direct, register indirect, and implied.

## Answer

#### Instruction format
Every 8085 instruction has an opcode (operation code) and, optionally, an operand. Depending on length, there are three formats.

| Type | Bytes | Layout | Example |
|---|---|---|---|
| One-byte | 1 | Opcode (operand implied or in opcode) | `MOV A,B` (78H), `ADD C`, `HLT` |
| Two-byte | 2 | Opcode, 8-bit data/port | `MVI A,32H` (3E 32), `OUT 80H` |
| Three-byte | 3 | Opcode, low-order byte, high-order byte | `LDA 2050H` (3A 50 20), `JMP 3000H` |

In 3-byte instructions the low-order byte of the address/data is stored first, then the high-order byte.

#### Data format
The 8085 is an 8-bit machine; a word is 8 bits (D7 ... D0). Data can be:
- **Unsigned binary**: 00H to FFH (0 to 255).
- **Signed binary**: 2's complement; D7 is the sign bit (-128 to +127).
- **BCD**: packed BCD has two digits per byte (e.g. 47H = 47); DAA corrects BCD addition.
- **ASCII**: 7-bit code stored in a byte, e.g. 'A' = 41H.
- **16-bit data/address**: stored in two memory locations, low byte at the lower address.

#### Addressing modes
The way the operand is specified in an instruction.

1. **Immediate**: the data is part of the instruction. `MVI B,45H`, `LXI H,2050H`, `ADI 0FH`.
2. **Register (register direct)**: the operand is in a register. `MOV A,B`, `ADD C`.
3. **Direct**: the address of the operand is given in the instruction (a 16-bit memory address, or an 8-bit port address for IN/OUT). `LDA 2050H`, `STA 3000H`, `IN 80H`, `OUT 81H`.
4. **Register indirect**: a register pair holds the memory address of the operand. `MOV A,M` (address in HL), `LDAX B`, `STAX D`.
5. **Implied (implicit)**: the operand is implied by the opcode itself, usually the accumulator. `CMA`, `RAL`, `DAA`, `STC`.

## Check yourself

The answer's key points as multiple-choice questions, with the correct option and why.

1. LDA 2050H is stored in memory as 3A 50 20. Which statement about it is correct?
   A. It is a two-byte instruction; the address is stored high byte first
   B. It is a three-byte instruction; the low-order address byte (50H) is stored before the high-order byte (20H)
   C. It is a three-byte instruction; the high-order address byte is stored right after the opcode
   D. It is a one-byte instruction because the address is implied by the opcode
   Answer: B. LDA carries a 16-bit address, so it is opcode + low byte + high byte = 3 bytes. In 3-byte instructions the low-order byte comes first, so 2050H is stored as 50 20. (Key point: Three instruction formats: 1-, 2- and 3-byte)

2. In the 8085 signed binary data format, what is the range of an 8-bit number and which bit gives the sign?
   A. 0 to 255; D0 is the sign bit
   B. -127 to +127; D7 is the sign bit (sign-magnitude)
   C. -128 to +127 in 2's complement; D7 is the sign bit
   D. -128 to +128 in 2's complement; D0 is the sign bit
   Answer: C. Signed data in the 8085 uses 2's complement with D7 as the sign bit, giving -128 to +127. 0 to 255 (00H to FFH) is the unsigned range. (Key point: Signed data uses 2's complement with D7 as sign bit)

3. Which instruction uses register indirect addressing?
   A. MOV A,B
   B. LDA 2050H
   C. MVI B,45H
   D. MOV A,M
   Answer: D. In MOV A,M the operand's memory address is held in the HL pair, which is register indirect. MOV A,B is register, LDA is direct and MVI is immediate. (Key point: Register indirect: a register pair holds the operand's address)

4. What is the difference between MVI A,32H and LDA 0032H?
   A. MVI is immediate: 32H itself is the data; LDA is direct: 0032H is the address where the data is
   B. Both are immediate; they load 32H into A
   C. MVI is direct and LDA is immediate
   D. MVI is implied addressing because A is named in the opcode
   Answer: A. In immediate addressing the data is part of the instruction (MVI A,32H puts 32H in A). In direct addressing the instruction gives the 16-bit address of the operand (LDA reads the byte stored at 0032H). (Key point: Immediate (data in instruction) vs direct (address in instruction))

## Related in Microprocessor

- [Features and addressing modes of 8085](https://www.bctengineer.com/question.md?key=semester_4%2Fmicroprocessor%3A8085-features-addressing-modes) — Microprocessor, chapter 2
- [Addressing modes of 8086](https://www.bctengineer.com/question.md?key=semester_4%2Fmicroprocessor%3A8086-addressing-modes) — Microprocessor, chapter 3, asked 2×
- [RIM instruction in 8085](https://www.bctengineer.com/question.md?key=semester_4%2Fmicroprocessor%3A8085-rim) — Microprocessor, chapter 5
- [Modes of parallel data transfer](https://www.bctengineer.com/question.md?key=semester_4%2Fmicroprocessor%3Aparallel-data-transfer-modes) — Microprocessor, chapter 4
- [8085 ALP: transfer data with more than 3 ones](https://www.bctengineer.com/question.md?key=semester_4%2Fmicroprocessor%3Aalp-8085-ones-greater-than-3) — Microprocessor, chapter 2
- [8085 ALP: copy data within a range](https://www.bctengineer.com/question.md?key=semester_4%2Fmicroprocessor%3Aalp-8085-copy-range) — Microprocessor, chapter 2

## Related in other subjects

- [LD instruction under addressing modes](https://www.bctengineer.com/question.md?key=semester_5%2Fcomputer_organization_and_architecture%3Ald-addressing-modes) — Computer Organization and Architecture, chapter 2
- [Microprocessor vs microcontroller; 8051 addressing](https://www.bctengineer.com/question.md?key=semester_6%2Fembedded_system%3A8051-addressing-modes-micro-vs-processor) — Embedded System, chapter 9
- [Addressing modes with examples](https://www.bctengineer.com/question.md?key=semester_5%2Fcomputer_organization_and_architecture%3Aaddressing-modes) — Computer Organization and Architecture, chapter 2, asked 10×
- [Addressing modes of 8051](https://www.bctengineer.com/question.md?key=semester_6%2Fembedded_system%3A8051-addressing-modes) — Embedded System, chapter 9, asked 4×
