MPMC M4 Ktunotes - in
MPMC M4 Ktunotes - in
• It is a programmable device.
• CS: This is Active Low signal. It stands for Chip Select. A LOW on
this input selects the chip and enables the communication between the
8255 and the CPU.
A1 A0 Select
0 0 PA
0 1 PB
1 0 PC
Control word
1 1
reg.
● PB0-PB7:Similar to PA
• In this mode, Port A and B is used as two 8-bit ports and Port C as two
4-bit ports.
• Each port can be programmed in either input mode or output mode
where outputs are latched and inputs are not latched.
• Ports do not have interrupt capability.
• Ports in mode 0 is used to interfaces LEDs, Hexa keypad and 7
segment LEDS to the processor.
• Each counter has 2 input pins, i.e. Clock & Gate, and 1 pin for “OUT”
output.
● It has four channels that can be used over four I/O devices. Each channel has
16-bit address and 14-bit counter.
● Each channel can transfer data up to 64kb.
● Each channel can be programmed independently. Each channel can perform
read transfer, write transfer and verify transfer operations.
● It operates in 2 modes, i.e., Master mode and Slave mode.
The pin configuration of DMA Controller (8257) is shown in Figure and the descriptions
are as follows:
CLK It is a clock frequency signal which is required for the internal operation of 8257.
RESET This signal is used to RESET the DMA controller by disabling all the DMA channels.
Ao - A3 These are the four least significant address lines. In the slave mode, they act as an input, which
selects one of the registers to be read or written. In the master mode, they are the four least significant
memory address output lines generated by 8257.
READY It is an active-high asynchronous input signal, which makes DMA ready by inserting wait states.
HRQ This signal is used to receive the hold request signal from the output device. In the slave mode, it is
connected with a DRQ input line 8257. In Master mode, it is connected with HOLD input of the CPU.
b) Control logic
c) Read/write logic
d) Priority Resolver
e) DMA channels
1. DMA Address Register Each DMA channel has one DMA address register. The
function of this register is to store the address of the starting memory location, which
will be accessed by the DMA channel.
2. Terminal Count Registers Each of the four DMA channels of 8257 has one terminal
count register (TC). This 16-bit register is used for ascertaining that the data transfer
through a DMA channel ceases or stops after the required number of DMA cycles.
3. Mode Set Register The mode set register is used for programming the 8257 as per
the requirements of the system. The function of the mode set register is to enable the
DMA channels individually and also to set the various modes of operation as shown
in Figure.