Behavioral modules are user-generated symbols functionally defined by some logic description other than a schematic, typically Boolean equations or HDL. Some reasons why you may want to use behavioral modules in your schematic are:
The Xilinx CPLD fitter also accepts entirely behavioral designs which use no schematics. Similar to behavioral modules for schematic designs, behavioral designs are expressed using Boolean equations or HDL and compiled using a PLD compiler (like XABEL) or a logic synthesis tool. Unlike behavioral modules, behavioral designs contain all the device I/O port information in its behavioral description.
This manual describes only schematic-based designs and the behavioral modules which may be contained in them. The procedures for creating behavioral modules in CPLD schematics is essentially the same as for all other Xilinx device families.
The equation or HDL files defining behavioral modules must be compiled before they can be used by the fitter. There are a variety of PLD compilers and synthesis tools that support design entry for CPLD devices.
Behavioral compilers which are compatible with the CPLD fitter translate their logic descriptions into EDIF or XNF formatted netlists.
Previous versions of the CPLD fitter used the Plusasm equation language as an interchange language in place of XNF or EDIF for some behavioral compilers, such as XABEL. Plusasm is still recognized and processed by this version of the fitter for the sake of existing behavioral modules based on that interface. However, future versions of the software will not support Plusasm and it should not be used when creating any new behavioral modules.
If the behavioral compiler tool supports the development of completely behavioral designs, make sure you select the appropriate mode of operation or compilation flow for producing logic modules, not stand-alone designs. The netlist produced by the compiler must not contain device I/O pin information. If any of the terminal nodes (inputs or outputs) of your behavioral module are to be connected to CPLD device pins, you must use IBUF and OBUF symbols in your schematic.
If you are using a synthesis tool to prepare a behavioral module, make sure you target the appropriate CPLD technology library.
Your compiled behavioral module file is normally stored in your project directory. You can also copy it to a user library directory if you want to use it for more than one project.
Using a behavioral module in a schematic design involves creating a symbol to represent your logic, placing the symbol into your schematic and applying necessary attributes to identify the logic-defining file.
This simple example shows you how to develop a behavioral module defined by an ABEL-language equation file and represented by a custom symbol in a Viewlogic schematic.
MODULE regxor
TITLE `Registered XOR gate'
IO pin;
I1 pin;
CLK pin;
Q pin istype `reg';
EQUATIONS
Q := IO $ I1;
Q.C = CLK;
end
Figure 2.7 The REGXOR Symbol |