原创 【博客大赛】简易cpu的设计2-汇编指令波形仿真

2015-5-23 17:05 859 9 9 分类: FPGA/CPLD

Simulated waveforms &Machine instructions:

Just  AND

Machine instructions:

20150523170253325001.png

The ram.mif

20150523170300930002.png

The waveforms and results

20150523170309660003.png

Explanation: If s1=0036s2=0064 Then s1 and s2? From the waveform we can

find s1 and s2=0024.

Just  not

Machine instructions:

20150523170315730004.png

The ram.mif

20150523170323772005.png

The waveforms and results

20150523170329454006.png

Explanation: If s1=1234,then not s1=? From the waveform we find s1=EDCB

Just  shiftr

Machine instructions:

20150523170336972007.png

The ram.mif

20150523170343336008.png

The waveforms and results

20150523170356915009.png

Explanation: If s1=1234,then shiftr s1=? From the waveform we find s1=091A.

ADD,SUB,MPY

Machine instructions:

20150523170403865010.png

The ram.mif

20150523170412261011.png

 

The waveforms and results

20150523170420355012.png

Explanation: s1=3,s2=4,s3=2,s4=7, From the waveform we find 3*4+2-7=7.

ADD,LOOP,MPY,DIV(1+2+…+49+50)*3/8

Machine instructions:

20150523170428375013.png

The ram.mif

20150523170436311014.png

The waveforms and results

20150523170443160015.png

Explanation: From the waveform we find 1+2+…+49+50=1275, 1275*3=3825,

3285/8=478.

The contents of location 21 is 478

20150523170450920016.png

Conclusions:

1From the experiment we learn what is cpu, how the cpu works.

2Through using quartus2 ,I learn to program by myself, in the experiment I found two errors ,then I try to solve the problem. Errors 1: ACTION: Successfully run the Timing Analyzer or Fitter before running timing simulation. Solutionsstart classic timing analyzer first; Errors 2: Error: Cannot run Timing Analyzer (quartus_tan) -- Fitter (quartus_fit) failed or was not run  solutions: start fitter first.

3Of course, in the meantime I meet multiple difficulties, I ask my classmates, we help each other.

4Programming needs to be patient, we should remember it.

文章评论0条评论)

登录后参与讨论
相关推荐阅读
sunyzz 2017-08-19 10:38
【博客大赛】AVALON总线介绍
1、AVALON总线简介Avalon总线是一种协议较为简单的片内总线,是ALTERA公司定义的片上互联总线,该总线可以将诸如NIOS II的CPU与其他外设连接起来,进而进行数据交换。AVALON总线...
sunyzz 2017-08-17 21:36
【博客大赛】不要轻易做职场滥好人
小A毕业于国内普通高校,但是他聪明,勤奋,能干,动手能力强,可是即便有这些优点也不能让小A轻轻松松找到一份好工作。这不,去年9月份小A好不容易找到一份工作,然后立马就入职了C公司,生怕C公司过两天不要...
sunyzz 2017-08-16 21:15
【博客大赛】IC设计低功耗技术四
五:工艺层面的降低功耗前面几节都是在讨论设计人员如何在前期阶段,中期阶段降低功耗,涉及到软件层面的,硬件层面的,这些技巧基本都是前辈总结出来的,或者根据理论推论出来的。但是到了后期,想降低功耗基本就要...
sunyzz 2017-08-14 22:35
【博客大赛】IC设计之低功耗技术三
四:RTL(寄存器传输)级的低功耗设计4.1 状态机的设计状态机编码中一般有两种方式,普通的二进制编码,特殊的格雷码,格雷码的特点是两个数据之间的跳变时只会有一个bit在toggle,显然比起多bit...
sunyzz 2017-08-12 16:51
【博客大赛】IC设计之低功耗技术二
三、架构层面的降低功耗系统的实现有很多的方式,每种方式对功耗的影响都不相同,本节主要介绍架构对功耗的影响。3.1 高级门口电路 在同步电路系统中,时钟占据了大部分的动态功耗,因而在一些情况下,如果有些...
sunyzz 2017-08-12 10:37
【博客大赛】IC 设计之低功耗技术一
一、前言随着计算机技术和微电子技术的迅速发展,嵌入式系统应用领域越来越广泛。节能是全球化的热潮,如计算机里的许多芯片过去用5V供电,现在用3.3V,1.8V,甚至更低的电压。目前的低功耗设计主要从芯片...
我要评论
0
9
1
2
3
4
5
6
7
8
9
0
关闭 热点推荐上一条 /4 下一条