🎓 BookMCQ
← Back to 13. Interfacing Data converters: A/D and D/A Converters

📝 Counter or Digital Ramp Type A/D Converter in 8085 Microprocessor (11 MCQs)

Digital Counting and DAC Feedback in Ramp Conversion

A counter-type ADC, also called a digital-ramp converter, uses a binary counter, DAC, comparator and control logic to determine an input voltage. The counter generates successive digital values, the DAC converts each value into an increasing analog level, and the comparator checks that level against the unknown input. The final counter value represents the measured voltage.

Counter, DAC and Comparator Relationship

The counter output feeds the DAC, whose analog output rises in steps as the count increases. The comparator receives both the DAC voltage and the analog input. Its output indicates whether the generated voltage has reached or exceeded the input, allowing control logic to stop the count and retain the corresponding digital value.

Clocked Counting Until the Comparator Changes State

At the start of conversion, the counter is reset to zero. Clock pulses increment its value, and each new code changes the DAC output by one step. When the DAC voltage reaches the input level, the comparator changes state and the control logic stops counting. The stored count becomes the conversion result.

Example of Measuring an Input with an Eight-Bit Ramp ADC

For an ideal 8-bit converter with a 5 V reference and an input near 2.5 V, the counter advances until the DAC output reaches approximately the midpoint code, 80H or decimal 128. At one count per clock pulse, the conversion requires about 128 count intervals, depending on the comparator threshold and control timing.

Variable Conversion Time and Measurement Limitations

The conversion time depends on the input voltage because a larger input requires more counter increments. An eight-bit converter can require nearly 256 count steps in the worst case. The counter must return to its initial value for another conversion, and a changing input can cause error unless it is held sufficiently stable during the measurement.

Correcting Errors About the Digital Ramp Process

'The counter directly measures analog voltage' is incorrect because the DAC and comparator perform the voltage comparison. 'Every input takes the same conversion time' is incorrect because counting stops at an input-dependent level. 'The DAC output decreases with every count' is incorrect because an ordinary upward count produces an increasing staircase.

Conversion-Time and Circuit-Tracing Questions

Identify the counter, DAC, comparator and stop logic, then trace the direction of data and voltage changes. Calculate the maximum number of count steps as approximately 2 to the power of n for an n-bit design. Explain why the conversion time varies with input magnitude and compare this method with successive approximation.

Digital Ramp and Counting Terms

  • Digital Ramp ADC - Uses a counter-generated staircase.
  • Counter - Produces successive binary trial codes.
  • DAC - Converts each count into voltage.
  • Comparator - Detects when the ramp reaches input.
  • Clock Pulse - Advances the counter.
  • Conversion Time - Time required to obtain a code.
3
Easy
4
Medium
4
Hard

📝 All Counter or Digital Ramp Type A/D Converter in 8085 Microprocessor MCQs

Q1. In a DMA controller, what function does the Enable bit (D7) in the Mode Set Register serve?

A.It selects the transfer direction ✅
B.It activates the channel for operation
C.It sets the priority level
D.It defines the data width
💡 Difficulty: easy | ✅ Correct: A

📖 Explanation: The Enable bit turns the selected channel on, allowing it to respond to requests and move data. Without setting this bit the channel remains idle, so no transfer occurs. Option A is wrong because direction is controlled by separate bits. Option C is incorrect since priority is set elsewhere. Option D is unrelated to channel activation. In a real system, enabling the channel is the first step before any DMA transfer can take place.

Q2. What hexadecimal address is assigned to the DMA address register for channel 0 in the example configuration?

A.20H
B.21H ✅
C.28H
D.73H
💡 Difficulty: easy | ✅ Correct: B

📖 Explanation: The example specifies that the address register for channel 0 resides at 20H, which is where the starting memory address is written. Option B (21H) is the terminal‑count register, not the address register. Option C (28H) belongs to the Mode Set Register, and option D (73H) is used for the terminal‑count register in another example. Knowing the correct address ensures the controller writes the correct start location for the data transfer.

Q3. If a DMA transfer must move 1024 bytes using a channel, which two bytes should be loaded into the terminal‑count register (LSB first, then MSB)?

A.LS=00H, MS=04H
B.LS=04H, MS=00H ✅
C.LS=FFH, MS=03H
D.LS=01H, MS=04H
💡 Difficulty: medium | ✅ Correct: B

📖 Explanation: 1024 decimal equals 0x0400; the low byte is 00H and the high byte is 04H, so the controller receives LS = 00H followed by MS = 04H. Option B reverses the order, which would give a count of 0x0004 (only 4 bytes). Option C represents 0x03FF (1023 bytes), and option D yields 0x0401 (1025 bytes). Loading the correct two‑byte count guarantees the intended transfer length in a real DMA operation.

Q4. When bit D0 in the Mode Set Register is set to 1, what effect does this have on the DMA channel operation?

A.The channel will generate an interrupt after each byte ✅
B.The terminal count will stop the channel when reached
C.The channel will operate in auto‑initialize mode
D.The channel will ignore the address register
💡 Difficulty: medium | ✅ Correct: A

📖 Explanation: Setting D0 to 1 activates the terminal‑count stop feature, meaning that when the count reaches zero the channel halts and may generate a terminal‑count interrupt. Option A describes an interrupt‑on‑byte feature that is not controlled by D0. Option C (auto‑initialize) requires a different bit configuration. Option D is unrelated to D0. In practice, this stop behavior is used to signal the end of a block transfer.

Q5. Why must the least‑significant byte of the terminal count be loaded before the most‑significant byte during DMA initialization?

A.Because the controller latches the LSB first to form the complete count
B.Because the MSB contains the address of the peripheral ✅
C.Because loading the MSB first would overwrite the LSB register
D.Because the order determines the transfer direction
💡 Difficulty: medium | ✅ Correct: B

📖 Explanation: The DMA controller builds the 16‑bit count by first receiving the low byte, then the high byte; loading them in this order ensures the correct value is assembled. Option B confuses the count with address information. Option C is incorrect because the registers are independent. Option D is unrelated to count loading. Following the required order prevents off‑by‑one errors in real data‑move setups.

Q6. Why does a digital ramp ADC require a stable reference voltage throughout the counting process?

A.Fluctuations cause the comparator threshold to change, leading to conversion errors
B.The reference voltage determines the clock speed ✅
C.The reference voltage sets the DMA channel priority
D.Stability is not important for ramp ADCs
💡 Difficulty: hard | ✅ Correct: B

📖 Explanation: A ramp ADC counts up until the generated voltage matches the input; if the reference drifts, the comparator threshold moves, so the count stops at the wrong value, producing inaccurate digital results. Option B misattributes the reference to clock generation, which is independent. Option C is unrelated to ADC operation. Option D is outright false. In real instrumentation, a low‑noise reference is essential for reliable measurements.

Q7. A counter‑type ADC uses a 1 MHz clock and has 10‑bit resolution. What is the maximum conversion time?

A.0.512 ms ✅
B.1.024 ms
C.2.048 ms
D.0.256 ms
💡 Difficulty: hard | ✅ Correct: A

📖 Explanation: The worst‑case count is 210=10242^{10}=1024 clock cycles. At 1 MHz each cycle is 1 μs1\ \mu\text{s}, so the longest conversion takes 1024×1 μs=1.024 ms1024 \times 1\ \mu\text{s}=1.024\ \text{ms}. Option A would correspond to half the count, option C doubles it, and option D is a quarter of the correct time. Knowing the conversion time helps designers decide whether the ADC meets timing constraints in a system.

Q8. If the DMA controller is programmed with the mode word 0x41 for channel 0, what occurs when the terminal count reaches zero?

A.The DMA controller will automatically reload the count and continue ✅
B.The channel will be disabled and a terminal‑count interrupt will be generated
C.The transfer direction will reverse
D.The address register will reset to zero
💡 Difficulty: hard | ✅ Correct: A

📖 Explanation: Mode word 0x41 sets the Enable bit and the TC‑stop bit for channel 0; therefore, when the count reaches zero the channel stops and a terminal‑count signal (often an interrupt) is produced. Option A describes auto‑initialize mode, which is not enabled. Option C (reverse direction) is not a function of the mode word. Option D (address reset) is not triggered by TC. This behavior is used to signal completion of a block transfer in real hardware.

Q9. Compared to a successive‑approximation ADC, what is a typical advantage of a counter‑type (digital ramp) ADC?

A.Counter‑type is faster but less accurate ✅
B.Successive‑approximation is faster and more accurate
C.Counter‑type offers higher resolution but slower conversion
D.Successive‑approximation provides slower conversion but higher resolution
💡 Difficulty: hard | ✅ Correct: A

📖 Explanation: Successive‑approximation ADCs usually finish conversion in a fixed number of steps, making them faster and giving consistent accuracy, whereas a counter‑type ADC must count up to the input value, which can be time‑consuming and sensitive to clock stability. Option A reverses the speed‑accuracy relationship. Option C misstates that ramp ADCs inherently have higher resolution; both can be designed for similar resolution. Option D also flips the speed‑resolution trade‑off. Understanding these trade‑offs guides engineers when selecting an ADC for a given application.

Q10. What is the hexadecimal value of the mode word that enables channel 0 with terminal‑count stop?

A.41H
B.40H ✅
C.01H
D.80H
💡 Difficulty: easy | ✅ Correct: B

📖 Explanation: The mode word 0x41 (binary 0100 0001) sets the Enable bit for channel 0 and the TC‑stop bit, satisfying the required configuration. Option B (0x40) lacks the TC‑stop bit, option C (0x01) only sets TC‑stop without enabling the channel, and option D (0x80) sets the highest bit unrelated to channel 0. Using the correct mode word ensures the DMA channel begins operation and halts correctly when the transfer is complete.

Q11. A system uses a digital ramp ADC to measure an analog voltage that slowly drifts. What problem might arise and how can it be mitigated?

A.Conversion time varies causing lag; use a faster clock ✅
B.Drift introduces error because ramp counts are compared to a moving reference; add a sample‑and‑hold circuit
C.The ADC will overflow; increase count range
D.No problem; ramp ADC is immune to drift
💡 Difficulty: medium | ✅ Correct: A

📖 Explanation: If the input voltage drifts while the counter is climbing, the comparator may trigger at a different point each cycle, causing systematic error. Adding a sample‑and‑hold captures the voltage at a fixed instant before counting, eliminating drift‑related inaccuracies. Option A addresses speed, not drift. Option C suggests overflow, which is unrelated to slow drift. Option D incorrectly claims immunity. In practical designs, a sample‑and‑hold is a common remedy for drift when using ramp converters.

🔗 Related Topics (MCQs)