登录 免费注册 首页 | 行业黑名单 | 帮助
维库电子市场网
技术交流 | 电路欣赏 | 工控天地 | 数字广电 | 通信技术 | 电源技术 | 测控之家 | EMC技术 | ARM技术 | EDA技术 | PCB技术 | 嵌入式系统
驱动编程 | 集成电路 | 器件替换 | 模拟技术 | 新手园地 | 单 片 机 | DSP技术 | MCU技术 | IC 设计 | IC 产业 | CAN-bus/DeviceNe

帮我看看这个程序是什么语言写的?

作者:ivorguo 栏目:EDA技术
帮我看看这个程序是什么语言写的?
NAME      Adder;
PARTNO    CA0016;
Date      10/08/85;
Rev       01;
Designer  Woolhiser;
Company   Assisted TECHNOLOGY;
Assembly  None;
Location  None;
DEVICE    G16V8;

/****************************************************************/
/*                                                              */
/* Four bit adder using the CUPL function statement.            */
/*                                                              */
/* 4-bit asynchronous adder implemented as a ripple-carry       */
/* through four adder-slice CIRCUITs.  Each adder-slice         */
/* takes a pair of 1-bit NUMBERs (Xi, Yi) and the carry from    */
/* a previous slice (Cin) and produces their 1-bit sum (Zi)     */
/* and carry (Cout).  Each adder-slice CIRCUIT is defined       */
/* using the CUPL function adder_slice(), which returns         */
/* the PRODUCT directly and the carry as Cout.                  */
/****************************************************************/

/** Inputs **/

Pin [1..4] = [X1..4];           /* First 4-bit NUMBER   */
Pin [5..8] = [Y1..4];           /* Second 4-bit NUMBER  */

/** Outputs **/

Pin [12..15] = [Z1..4];         /* 4-bit sum                    */
Pin [16..18] = [C1..3];         /* Intermediate carry vaules    */
Pin 19 = Carry;                 /* Carry for 4-bit sum          */

/* Adder-slice CIRCUIT - add 2, 1-bit, NUMBERs with carry */

function adder_slice(X, Y, Cin, Cout) {
        Cout    = Cin & X               /* Compute carry */
                # Cin & Y
                # X & Y;
        adder_slice = Cin $ (X $ Y);    /* Compute sum */
}

/* Perform 4, 1-bit, additions and KEEP the final carry */

Z1 = adder_slice(X1, Y1, 'h'0, C1);     /* Initial carry = 'h'0         */
Z2 = adder_slice(X2, Y2,   C1, C2);
Z3 = adder_slice(X3, Y3,   C2, C3);
Z4 = adder_slice(X4, Y4,   C3, Carry);  /* Get final carry VALUE        */


2楼: >>参与讨论
whjwhjwhj
细心点
白痴:
一有问题就问人,看下面这句话,在你程序的前面。
Four bit adder using the CUPL function statement. 

3楼: >>参与讨论
whjwhjwhj
你就不知道从网上找找,就知道发帖子,不劳而或
赌东道

4楼: >>参与讨论
wsjc1999
Protel 99SE 自带的
 
参与讨论
昵称:
讨论内容:
 
 
相关帖子
请大人推荐一个50万门左右的FPGA
这是不是QuartusII5.0的BUG?的图片2
这是不是QuartusII5.0的BUG?
两个always之中分别对同一个变量赋值
用Verilog在QuartusII上的仿真问题。
免费注册为维库电子开发网会员,参与电子工程师社区讨论,点此进入


Copyright © 1998-2006 www.dzsc.com 浙ICP证030469号