Khi muốn sử dụng Timer 0 ở Mode 2 ta cần khởi động thanh ghi TMOD:
Trả lời:
Đáp án đúng: D
Timer 0 ở Mode 2 là chế độ tự động nạp lại (auto-reload). Trong thanh ghi TMOD, bit M1M0 (bit 1 và bit 0) xác định chế độ hoạt động của Timer 0. Với Mode 2, M1M0 = 10 (nhị phân), tương ứng với giá trị 2 (thập phân). Bit GATE và C/T không ảnh hưởng đến việc chọn mode cho timer 0 trong trường hợp này. Do đó, để chọn Mode 2 cho Timer 0, ta cần đặt TMOD=0x02 hoặc TMOD=00000010B.
This is a comprehensive multiple-choice question bank for the Microprocessor 1 course, tailored for Electrical - Electronics Engineering students. It covers core topics such as microprocessor systems, data representation in computers, the architecture and instruction set of the 8086 microprocessor, assembly language programming, and the 8051 microcontroller.
50 câu hỏi 60 phút