You can make pin assignments and use the PROHIBIT attribute in the graphical interface. When you have finished making the pin assignments, you can automatically create a .ucf file that will implement the pin assignments when the fitter is run.
To assign inputs and outputs to a specific device:
Open the .ngd file for the design. See Opening a Design, if necessary. You may be prompted to select a device. Select one from the list and click OK.
The chip package view will appear showing pin numbers and pin types (I/0 or I/O/Foe0, etc.). The left column will list signals. If no signals are apparent, click once on the plus sign (+) adjacent to the Signals folder icon. To display subfolders, such as Inputs and Outputs, click on the plus signs adjacent to them.
Highlight the signal you want to assign by clicking once on it. Then move the mouse pointer to the pin you want to assign the signal to, and click once on it. The signal name should assign to the pin and appear next to it on the graphic. The signal name will also disappear from the list of inputs or outputs.
Note: If you make a mistake and just want to change an assignment, see Removing Pin Assignments.
PROHIBIT allows you to reserve device pins for later use, or simply to prevent them from being used at all. For instance, if you anticipate design changes in the future and want to set traces on your printed circuit board now, you can use PROHIBIT to prevent the fitter from using pins associated with those traces. Then, when you decide to use the traces, you can use the ChipViewer to assign those pins to new input/output buffers you place in your design. To reserve or prohibit:
Open the .ngd file for the design. See Opening a Design, if necessary. You may be prompted to select a device. Select one from the list and click OK.
The chip package view will appear showing pin numbers and pin types (I/0 or I/O/Foe0, etc.). From the Menu bar, select Edit -> Add Prohibit. This will enable the selection of reserved pins.
Move the mouse pointer to the pin you want to reserve and click once. The designator PROHIBIT should appear adjacent to the pin. If you try to reserve a pin that has already been assigned, the pin will stay assigned. If you want to reserve an assigned pin, remove the pin assignment first.
Continue reserving other pins if needed.
The UCF file is generated automatically when you save the file:
File -> Save
This will save the .ngd file and create a .ucf file with the same file name as your design.
Note: If you already have a .ucf file you will need to use Save As instead of Save, and give the new .ucf a different name. This will prevent you from losing your original .ucf file. You can then use a text editor to add the pin-locking and reserved pin information to the end of your .ucf file. This concatenation will give you a .ucf with your design attributes plus the pin assignment and reserved pin information you just created.
If you wish to remove an assignment to a pin move the mouse pointer to the pin and click once to highlight the pin. Then select from the menu bar Edit -> Remove Selected Assignment. The pin should become colorless and the signal name assigned and displayed next to the pin should vanish. The signal can then be found in the Input or Output folder where it can be reassigned or left alone for automatic assignment.
Note: You can also remove a PROHIBIT attribute from a pin using this method.
Alternatively, a pin assignment can removed by positioning mouse pointer over the pin and clicking once on the right mouse button. This will display a small menu that includes Remove Assignment.