October 2010Lattice Diamond software adds new capabilities for scripting the design flow compared to previous environments. In addition to the Tcl Console tab in the Diamond environment, a separate Tcl Console application allows running scripts independently. Finally, Tcl commands can be directly run from any shell if the proper environment variables are set. Diamond-specific Tcl command dictionaries are available for the following areas.
In the Diamond GUI there is a tab labeled Tcl Console. From this tab you can view Tcl commands issued by programs in the Diamond environment and enter your own commands. Help on individual commands is available both in the online help and from using the “Help” command within the console. The help command can be used to get the top-level help, help for a particular dictionary, or help for an individual command. To use an existing Tcl script file use “source < script_file.tcl>”. To save commands in the Tcl Console to a script file use “save_script < script_file.tcl>”.

Diamond Environment Tcl Console
Diamond also includes a separate application for running Tcl commands without opening the complete GUI environment. To use this application in Windows, go to Start > All Programs > Lattice Diamond 1.0 > Accessories > Tcl Console.

Diamond TCL Console Application
Lattice Diamond Tcl scripts can also be run directly from a command line shell like DOS or Bash shells. Please review the Tcl Scripting section of the Lattice Diamond User Guide for details.
Lattice Diamond software offers the most complete and flexible scripting environment available for designing with Lattice FPGAs. In combination with the other features offered in the Lattice Diamond environment, the software brings new capabilities whether you are implementing your first FPGA or an experienced designer using a scripted design flow.
See the Lattice Diamond Tcl Scripting Video for further information on available Tcl dictionaries and how to run Tcl commands from the user interface or the Tcl Console.