1 / 42

Memory and Programmable Logic

Memory and Programmable Logic. Mano & Ciletti Chapter 7 By Suleyman TOSUN Ankara University. Outline. RAM Memory decoding Error detection and correction ROM Programmable Logic Array (PLA) Programmable Array Logic (PAL). Memories.

blandm
Download Presentation

Memory and Programmable Logic

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Memory and Programmable Logic Mano & Ciletti Chapter 7 By Suleyman TOSUN Ankara University

  2. Outline • RAM • Memory decoding • Error detection and correction • ROM • Programmable Logic Array (PLA) • Programmable Array Logic (PAL)

  3. Memories • Memory unit is a collection of cells capable of storing a large quantity of binary information. • Information from input device is stored in memory • Information to output is taken from memory • Two types of memories • Random-access memory (RAM) • Stores binary info for later use • Write operation: Storing data into memory • Read operation: Transferring data out of memory • Read-only memory (ROM) • Can perform only read operation

  4. RAM vs ROM • ROM is a programmable logic device (PLD). • The binary information is embedded within the hardware. • Other programmable devices • Programmable logic array (PLA) • Programmable array logic (PAL) • Field programmable gate array (FPGA) • Since PLDs have a lot of gates and paths, gates in array logic is shown in different way.

  5. Random-Access Memory (RAM) • The time it takes to transfer to or from any random location always the same • That’s why the name random access memory. • In magnetic tapes, the time depends on the location of the data.

  6. Word size • 4 bits - nibble • 8 bits - byte • 16 bits – 2 bytes • 32 bits – 4 bytes • Most computer uses multiples of 8 bits • The capacity of a memory is stated as the total number of bytes.

  7. A memory unit • Communication between memory and its environment is achieved by • Data input and output lines • Address selection lines • Control lines

  8. Address • Each word is assigned to an address • Ranges from 0 to 2k-1, where k is the number of address lines • Internal decoder decodes the address for specific word. • Memory size vs address lines • 10 bits (k=10) can address 210 words • 32 bits, 232 words

  9. Memory addressing • A memory with 1K words of 16 bits each

  10. Read and Write Operations • To read data • Put the binary address on the address lines • Activate read input • To write data • Put binary address on the address lines • Put data on data input lines • Activate write input

  11. Write cycle

  12. Read cycle

  13. Types of memories • Static RAM (SRAM) • Consists of latches to store binary data • Stored data is valid as long as power is applied • Easier to use • Shorter write and read cycles • Dynamic RAM (DRAM) • Stores data in the form of electric charges on capacitors (MOS transistors). • It must be refreshed periodically. • Has less power consumption • Larger storage capacity.

  14. Volatile vs Nonvolatile • SRAMs and DRAMs are volatile memories • Since they loose data when power is turned off • Magnetic disks are nonvolatile • They store data using magnetization.

  15. Memory Decoding • Decoders are used to select word locations. • A memory with m words and n bits per word requires mxn storage cells. • A basic cell is behaves like D latch (4 to 6 transistors) • When read/write=1, read operation • When read/write=0, write operation

  16. 4x4 RAM • 4 words needs 2 address lines to be decoded • 2k words needs k address lines

  17. Coincident decoding • A decoder with k inputs and 2k output requires 2k AND gates with k inputs per gate. • Use two decoders to reduce this (two dimensional decoding) • Two decoders with k/2 inputs 2x32=64 AND gates instead of 1024 AND gates (for 10 bits) 32x32 memory cell array

  18. Error Detection and Correction • Error detection • Use parity bits • Error correction • Use multiple parity bits • Each parity is generated for a group of bits • If check parity bits are correct • No error • If check bit/bits are not correct • They give a pattern (called syndrome) that gives which bit is incorrect.

  19. Hamming Code • K parity bits are added to n bit data • Bit positions are numbered from 1 to n+k (no 0) • Parity bits are positioned as powers of 2. • Remaining bits are data bits. • Example: data word is 11000100 (8 bit)

  20. Parity generation

  21. Parity check • C=C8C4C2C1 • If C=0, no error • If C!=0, error (C gives the erroneous bit position)

  22. Single error correction, Double error detection • Add additional parity bit (P13)

  23. ROM • Only read occurs • K inputs and n outputs • Nonvolatile

  24. 32x8 bit ROM • 32 words of 8 bits each. • 2kxn ROM has kx2k decoder and n OR gates

  25. Combinational Circuit Implementation • Similar to design procedure of circuits with decoders and OR gates as we have seen in Chapter 4. • We have decoders and OR gates inside of the ROM.

  26. Design example • B1=0 • B0=A0

  27. Types of ROMs • ROM-mask programming • Fill out the truth table, manufacturer makes the mask to produce 0’s and 1’s. • PROM (programmable ROM) • Can be programmed in a lab by blowing the fuses (all fuses initially intact) • EPROM (Erasable PROM) • Program it then erase under ultraviolet light. • EEPROM or E2PROM(Electrically erasable PROM) • Can be programmed and erased electrically.

  28. Combinational PLDs

  29. Programmable Logic Array • Similar to PROMS except that decoder is replaced with AND gates. • AND gates are connected to OR gates to produce sum-of-product terms.

  30. An example PLA circuit • F1=AB’+AC+A’BC’ • F2=(AC+BC)’

  31. Fuse Map • - means not connected, 1 means connected, 0 means complement is connected. • T means true (for XOR) • C means complement (for XOR)

  32. Example

  33. Programmable Array Logic (PAL) • Fixed OR array and programmable AND array. • Figure shows 4 input 4 output PAL

  34. Design example • PALs may need simplifications as z includes w in this example.

  35. Sequential Programmable Devices • Needs flip-flops • Types

  36. SPLD

  37. Basic Macrocell Logic

More Related