RAM

  The RAM is a 16 X 8 static TTL RAM. We can program the RAM by means of the address and data switch registers. This allows us to store a program and data in the memory before a computer run.

  During a computer run, the RAM receive 4-bit addresses from MAR and a read operation is performed. In this way, the instuction or data word stored in the RAM is placed on the W bus for use in some other part of the computer.

 library IEEE;
use ieee.std_logic_1164.all;
use ieee.numeric_std.all; entity ROM_16_8 is
port
(
READ : in std_logic; --! Active low enable ROM signal, (tri-state)
ADDRESS : in std_logic_vector ( downto ); --! -bit ROM address bits from MAR
DATA_OUT : out std_logic_vector ( downto ) --! -bit ROM output word to W-bus
);
end ROM_16_8 ; architecture beh of ROM_16_8 is type mem is array ( to ) of std_logic_vector( downto ) ;
signal rom : mem; begin
20 --! This program works as follow:
21 --!
22 --! Load 5 to AC (memory content of 9)
23 --! Output 5 (content of AC)
24 --! Add 7 (memory content of 10) to 5 (AC content)
25 --! Output 12 (content of AC)
26 --! Add 3 (memory content of 11) to 12 (AC content)
27 --! Subtract 4 (memory content of 12) from 15 (AC content)
28 --! Output 11 (content of AC)
rom <= (
=> "" , -- LDA 9h ... Load AC with the content of memory location 9
=> "" , -- OUT
=> "" , -- ADD Ah ... Add the contents of memory location A to the AC content and replace the AC
=> "" , -- OUT
=> "" , -- ADD Bh ... Add the contents of memory location B to the AC content and replace the AC
=> "" , -- SUB Ch ... Sub the contents of memory location C from the AC content and replace the AC
=> "" , -- OUT
=> "" , -- HLT
=> "" ,
=> "" , --5
=> "" , --7
=> "" , --3
=> "" , --4
=> "" ,
=> "" ,
=> "" ); process (READ,ADDRESS)
begin
if READ = '' then
DATA_OUT <= rom(to_integer(unsigned(ADDRESS))) ;
else
DATA_OUT <= (DATA_OUT'range => 'Z');
end if;
end process ; end beh;

SAP computer之RAM的更多相关文章

  1. SAP computer之input and MAR

    Input and MAR Below the program counter is the input and MAR block. It includes the address and data ...

  2. SAP computer之program counter

    Program counter The program is stored in memory with the first instruction at binary address 0000, t ...

  3. SAP computer之architecture

    Simple-As-Possible computer introduces all the cruicial ideas behind computer operation without bury ...

  4. VMware12 安装 CentOS 6.5 64位

    前言:本人在配置Hadoop的过程中,需要搭建Cent OS 64 环境,借此,顺便将Cent OS 64 的安装在此记录,方便自己,也方便大家学习.本次是在VM12虚拟机中实现Cent OS 64 ...

  5. 堆栈 & Stack and Heap

    What's the difference between a stack and a heap? The differences between the stack and the heap can ...

  6. PostgreSQL Hardware Performance Tuning

    Bruce Momjian POSTGRESQL is an object-relational database developed on the Internet by a group of de ...

  7. MongoDB十二种最有效的模式设计【转】

    持续关注MongoDB博客(https://www.mongodb.com/blog)的同学一定会留意到,技术大牛Daniel Coupal 和 Ken W. Alger ,从 今年 2月17 号开始 ...

  8. Client Dataset Basics

    文章出处:  http://www.informit.com/articles/article.aspx?p=24094 In the preceding two chapters, I discus ...

  9. What’s the difference between a stack and a heap?

    http://www.programmerinterview.com/index.php/data-structures/difference-between-stack-and-heap/ The ...

随机推荐

  1. IE7浏览器下去除flash动画边框问题

    <object width="100%" height="100%" data="/templates/default/swf/guide.sw ...

  2. 重庆OI2017 老 C 的任务

    老 C 的任务 时间限制: 2 Sec  内存限制: 512 MB 题目描述 老 C 是个程序员. 最近老 C 从老板那里接到了一个任务——给城市中的手机基站写个管理系统.作为经验丰富的程序员,老 C ...

  3. [BZOJ1031][JSOI2007]字符加密Cipher(后缀数组)

    传送门 算是个模板. 题目说循环,那就再复制一串拼接上. 然后求后缀数组,再搞就可以. 虽然是求后缀,会在后面多一些字符串,然而题目中说的是循环一圈,但是没有影响. ——代码 #include < ...

  4. CentOS6.5下卸载MySql(yum安装)

    因为我是用yum安装的mysql,所以卸载相对简单 yum -y remove mysql* 再把相关的文件删掉, rm -f /etc/my.cnf.rpmsave  rm -rf /var/lib ...

  5. V - 吉哥系列故事――完美队形I Manacher

    吉哥又想出了一个新的完美队形游戏!  假设有n个人按顺序站在他的面前,他们的身高分别是h[1], h[2] ... h[n],吉哥希望从中挑出一些人,让这些人形成一个新的队形,新的队形若满足以下三点要 ...

  6. ZooKeeper教程资源收集(简介/原理/示例/解决方案)

    菩提树下的杨过: ZooKeeper 笔记(1) 安装部署及hello world ZooKeeper 笔记(2) 监听数据变化 ZooKeeper 笔记(3) 实战应用之[统一配置管理] ZooKe ...

  7. Unity图片变灰的方式

    http://www.tuicool.com/articles/Vruuqme NGUI中的Button差点儿是最经常使用到的控件之中的一个,而且能够组合各种组件(比方UIButtonColor,UI ...

  8. ZZUOJ-1195-OS Job Scheduling(郑州大学第七届ACM大学生程序设计竞赛E题)

    1195: OS Job Scheduling Time Limit: 2 Sec  Memory Limit: 128 MB Submit: 106  Solved: 35 [id=1195&quo ...

  9. hdu3371 Connect the Cities (MST)

    Connect the Cities Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Other ...

  10. [RK3288][Android6.0] U-boot 启动流程小结【转】

    本文转载自:http://blog.csdn.net/kris_fei/article/details/52536093 Platform: RK3288OS: Android 6.0Version: ...