Friday, May 25, 2012

8086 Memory Banks

The 8086 has 20-bit address bus, so it can address 2^20 or 1,048,576 addresses. Each address represents a stored byte. To make it possible to read or write a word with one machine cycle, the memory for an 8086 is set up in to 2 banks of up to 524,288 bytes each. See figure.
8086 Memory Banks


One memory bank contains all the bytes which have even addresses such as 00000h, 00002h, and 00004h etc. the data lines of this bank is connected to the lower 8 bit data lines i.e. from D0 to D7 of 8086.

The other memory bank contains all bytes which have odd addresses such as 00001h, 00003h and 00005h etc. the data lines of this bank is connected to the upper 8 bit data lines i.e. from D8 to D15 of 8086.

Address line A0 is used for enabling the memory device in the lower bank. An addressed memory device in this bank will be enabled when A0 is low, as it will be for any even address.
Like address 00222h = 0000 0000 0010 0010 0010.
Address lines A1 to A19 are used to select the desired memory device in the bank and hence the desired byte in the device.

Address line A1 to A19 are also used to select the desired memory device in the upper bank and hence the desired byte. An additional part of enabling the upper bank memory device is handled by the BHE i.e. the bus high enable signal. This is multiplexed out from the 8086 at the same time as an address is sent out.  An external latch, strobbeed by the ALE signal, grabs the BHE signal and holds it stable for the rest of the machine cycle like it does for the address.

So now if we read a byte from or write a byte to an even address the A0 will be low BHE will be high enabling the lower bank and disabling the upper bank.

The main reason that the A0 and BHE signal work as they do is to prevent the writing of an unwanted signal.

15 comments:

  1. the note was very helpful,but i would like to rectify just one small mistake..there is no "machine cycle" present in the 8086mp.The 8086 mp performs bus cycles for executing instructions and fetching new operands asynchronously(pipelining)

    Good work!
    thank you!

    ReplyDelete
  2. Thank you. Now I understand better.... :)

    ReplyDelete
  3. What is the abbreviation of BHE

    ReplyDelete
  4. BUS HIGH ENABLE. It is multiplexed with status pin S7.
    BHE is a LOW ON signal.
    BHE/S7 - (type) Output, tristate

    ReplyDelete
  5. Mam can u tell me about advantage of this type of segmentation.

    ReplyDelete
  6. Why we need to make two different banks why not only one in it?

    ReplyDelete
    Replies
    1. because our output/input data from the processeur is written on 16 bits so we need two bytes to store

      Delete
  7. What are the Advantages of memory banking systems

    ReplyDelete