home *** CD-ROM | disk | FTP | other *** search
CUPL PLD Program format | 1986-03-02 | 2.4 KB | 62 lines |
- Name Lookup;
- Partno CA0017;
- Revision 01;
- Date 3/10/85;
- Designer T. Kahl;
- Company Assisted Technology, Inc.;
- Location San Jose, CA.;
- Assembly Example;
- Device ra8p8;
-
- /****************************************************************/
- /* */
- /* This is an example of the TABLE format for CUPL. The lookup */
- /* table input consists of a 6 bit number for the radius of a */
- /* circle (R0-5) and the output is the value for the perimeter */
- /* (2 x Pi x Radius) of the circle (P0-7). */
- /****************************************************************/
- /* Target Devices: 256 x 8 PROM (RA8P8) */
- /****************************************************************/
-
- /** Inputs **/
-
- Pin [1..5,17] = [R0..5]; /* Radius of Circle */
-
- /** Outputs **/
-
- Pin [6..9,11..14] = [P0..7]; /* Perimeter of Circle */
-
- /** Declarations and Intermediate Variable Definitions **/
-
- Field Radius = [R5..0];
- Field Perimeter = [P7..0];
-
- /** Logic Equations **/
-
- Table Radius => Perimeter {
-
- /* Radius Perimeter Radius Perimeter */
- /* ------ --------- ------ --------- */
- 'd'00 => 'd'000; 'd'01 => 'd'006;
- 'd'02 => 'd'013; 'd'03 => 'd'006;
- 'd'04 => 'd'025; 'd'05 => 'd'019;
- 'd'06 => 'd'040; 'd'07 => 'd'031;
- 'd'08 => 'd'050; 'd'09 => 'd'044;
- 'd'10 => 'd'063; 'd'11 => 'd'069;
- 'd'12 => 'd'075; 'd'13 => 'd'082;
- 'd'14 => 'd'088; 'd'15 => 'd'094;
- 'd'16 => 'd'101; 'd'17 => 'd'107;
- 'd'18 => 'd'113; 'd'19 => 'd'119;
- 'd'20 => 'd'126; 'd'21 => 'd'132;
- 'd'22 => 'd'138; 'd'23 => 'd'145;
- 'd'24 => 'd'151; 'd'25 => 'd'157;
- 'd'26 => 'd'163; 'd'27 => 'd'170;
- 'd'28 => 'd'176; 'd'29 => 'd'182;
- 'd'30 => 'd'188; 'd'31 => 'd'195;
- 'd'32 => 'd'201; 'd'33 => 'd'207;
- 'd'34 => 'd'214; 'd'35 => 'd'220;
- 'd'36 => 'd'226; 'd'37 => 'd'232;
- 'd'38 => 'd'239; 'd'39 => 'd'245;
- 'd'40 => 'd'251;
- }