Altera_Forum
Honored Contributor
11 years agoTcl command execute_module doesn't seem to work
I'm using QuartusII v15 and developing for a BeMicro CV board. The board has an eeprom device that is programmable by the fpga, but you need to convert the .SOF output file into a Jtag file (.JIC format) in order to program the board. It's been tedious to do this manually on every build, so I wanted to see if I could add an automated task via a Tcl script to generate the .JIC file.
The Tcl Scripting Reference Manual claims to offer an execute_module command that allows you to execute the cdb tool from within a tcl script. I followed the recommended example (pg. 3-103) and came up with the following script line to run the quartus_cdb tool from a script:execute_module -args "-c Compression=on --sfl_device=\"5CEFA2\" --device=\"EPCS16\" output_files/simpleled.sof output_files/simpleled.jic" -tool cdb I decided to test this script inside the Tcl Console window, but it only gives me error output: Error:invalid command name "quartus_cdb" Error: while executing Error:"unknown_original quartus_cdb --tcl_eval <tcl command>" Error: ("eval" body line 1) Error: invoked from within Error:"eval unknown_original $cmd $args" Error: (procedure "::unknown" line 7) Error: invoked from within Error:"quartus_cdb --tcl_eval <tcl command>" Error: invoked from within Error:"execute_module -args "-c Compression=on --sfl_device=\"5CEFA2\" --device=\"EPCS16\" output_files/simpleled.sof output_files/simpleled.jic" -tool cdb" Can anyone at Altera tell me if I'm calling the script / procedure properly? Have I used the right escape syntax for the arguments? I'd also like to run this as a task from within the task window by putting this line into its own .tcl file and adding it to a new flow based on "Compilation". However, I need to make sure that the syntax is alright first and I find the error messages provided to be a little bit vague.