OpenCores
URL https://opencores.org/ocsvn/idea/idea/trunk

Subversion Repositories idea

[/] [idea/] [trunk/] [structural_c/] [key_regulator/] [fulladder34.c] - Blame information for rev 9

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 7 marta
// File Name    : fulladder34.c
2
// Description  : Full Adder 34 bit
3
// Author       : Mas Adit
4
// Date         : 29 Agustus 2001
5
 
6
#include <genlib.h>
7
 
8
main()
9
{
10
 int i;
11
 
12
 DEF_LOFIG ("fulladder34");
13
 
14
 LOCON ("a[33:0]", IN, "a[33:0]");
15
 LOCON ("b[33:0]", IN, "b[33:0]");
16
 LOCON ("sum[33:0]", OUT, "sum[33:0]");
17
 LOCON ("vdd", IN, "vdd");
18
 LOCON ("vss", IN, "vss");
19
 
20
 LOINS ("zero_x0", "zero1", "nol", "vdd", "vss", 0);
21
 LOINS ("fulladder", "fulladder1", "a[0]", "b[0]", "nol", "sum[0]", "cout0", "vdd", "vss", 0);
22
 
23
 for (i = 1; i < 33; i++)
24
   LOINS("fulladder", NAME("fulladder%d", i + 1), NAME("a[%d]", i), NAME("b[%d]", i),
25
          NAME("cout%d", i - 1), NAME("sum[%d]", i), NAME("cout%d", i), "vdd", "vss", 0);
26
 
27
 LOINS ("fulladdercout", "fulladder34", "a[33]", "b[33]", "cout32", "sum[33]", "vdd", "vss", 0);
28
 
29
 SAVE_LOFIG();
30
 exit(0);
31
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.