I would like to pass, from the TCL file that is commanding the Diamond tool of Lattice, some options to the Synplify synthesis tool.

E.g.: It is possible to set a value of the VHDL generic at toplevel in the GUI. https://www.doulos.com/knowhow/fpga/Setting_Generics_Parameters_for_Synthesis/

But when saving this project in TCL (save_script test.tcl), this option is not exported to TCL.

Adding the Synplify TCL code in the Lattice TCL file isn't helping.

set_option -hdl_param -set BUILD_VERSION {x"01"}

pnmainc diamond.tcl
invalid command name "set_option"
    while executing
"set_option -hdl_param -set BUILD_VERSION x"01""
    (file "diamond.tcl" line 3)

And the manual not the help in Lattice/TCL isn't revealing anything.

I would like to avoid having another TCL file just for Synplify in my repo.

  • 1
    \$\begingroup\$ Are you using LSE or Synplify? I'm avoiding a direct call to pnmainc. So I'm calling synthesis -f <optionfile> directly. \$\endgroup\$
    – Paebbels
    Commented Jul 19, 2016 at 8:27
  • \$\begingroup\$ @paebbels I'm using Synplify. But I should check with the owner of the code why :-). 'synthesis.exe' is LSE, I assume. \$\endgroup\$
    – vermaete
    Commented Jul 19, 2016 at 12:00

1 Answer 1


(I still think it's stupid I can't post that as a comment before 50rep)

Try with the following syntax:

hdl_param -set BUILD_VERSION x"01"

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.