Cupl Tutorial

Páginas: 7 (1675 palabras) Publicado: 20 de octubre de 2011
CUPL Tutorial
We will walk through the steps in creating a circuit implementation in a 22V10 chip using the Atmel/ Logical Devices CUPL software and the ChipMaster 6000 software for programming the chip.
To see more about the 22v10, go here.
device.html
The design:
We will design and construct a simple "bouncing ball " LED circuit using only a 22v10 and a LED bar-graph circuit. The circuitwill behave like the following:
|clock | | | | | | | | |
|C |1 |1 |0 |1 |1 |1 |1 |1 |
|C |1 |0 |1 |1 |1 |1 |1 |1 |
|C |0 |1 |1 |1 |1 |1 |1 |1 |
|C |1 |0 |1 |1 |1 |1 |1 |1|
|C |1 |1 |0 |1 |1 |1 |1 |1 |
|C |1 |1 |1 |0 |1 |1 |1 |1 |
|C |1 |1 |1 |1 |0 |1 |1 |1 |
|C |1 |1 |1 |1 |1 |0 |1 |1 |
|C |1 |1 |1 |1 |1 |1 |0 |1 |
|C |1 |1|1 |1 |1 |1 |1 |0 |
|C |1 |1 |1 |1 |1 |1 |0 |1 |

Thus, the circuit is essentially a "one-hot", or in this case, an active-low "zero-hot" counter with a latch reserved for recording the current direction of the ball. We will construct the circuit using state-machines in the CUPL syntax.
To start, the CUPL softwareshould be installed correctly. Check here to make sure.
To start the CUPL software package, type MCUPL at the DOS C: prompt in the CUPL directory.you should see this pop up:

and then the menu should follow in a second or after pressing enter:

Navigation is accomplished by using the arrow keys on the keypad to select the option on the Main Menu. Alternatively, the option can be selected bypressing the keyboard letter corresponding to the option letter in brackets.
It is a good idea to take the time and explore the different menu options to get familiar with navigation. The first thign to do is select the device ( Device Selection). Press or select it using the arrow keys.At the next prompt choose the P22V10 device. It will then prompt for the package. We want the DIP (dualin-line) package.

Having picked the device, we will now create a new file for the bouncing LED device. At the main menu , choose dit design file to start work on a new file.At the prompt, type in bounce.pld as the new file name and then press Enter. You should now be in the MS-DOS EDIT program.
The first thing to do is enter the header information The header information is used to keep track of therevisions and device selection. The format is:
|Name |Bounce; |
|Partno |01; |
|Date |1/16/97; |
|Rev |01; |
|Designer |Joe Programmer;|
|Company |U. Penn; |
|Assembly |None; |
|Location |None; |
|Device |P22V10; |

This information is included at the beginning of every .pld file.
The next thing to do isasign the pins to specific input and output variables. To start with, we will asign the P22v10 the following:

Pin Declarations
/**Inputs**/
Pin 1 = CLK;
Pin 2 = reset;
/**Outputs**/
Pin 15 = out3;
Pin 16 = out2;
Pin 17 = out1;
Pin 18 = out0;
Pin 19 = dir;

The next part for the design is to declare the states using define statements that have the same usage as in programming...
Leer documento completo

Regístrate para leer el documento completo.

Estos documentos también te pueden resultar útiles

  • Tutorial
  • Tutorial
  • Tutoriales
  • TUTORIAL
  • tutoriales
  • tutorial
  • tutorial
  • Tutoriales

Conviértase en miembro formal de Buenas Tareas

INSCRÍBETE - ES GRATIS