Last week I created a script to run all Xilinx tools required for implementation from the command line. We are using the 14.4 version of Xilinx software. Before using any of the tools in this version a Xilinx script is required to be executed to set required environment variables. However the script sets variables for many Xilinx tools such as Vivado and Plan ahead that are not necessary for our process. Hence, this week I had to dig through Xilinx scripts and find out the environment variables necessary for the command line tools and then set it manually through my script.

While I’ve used bash before my knowledge wasn’t enough to understand the scripts. Thus, I read about bash if statements, special parameters and any other question found it’s answer in this rich page. It was fun to realize the difference between “source” , “.” and  “./”

The Xilinx main script is located in $source /opt/Xilinx/14.4/ISE_DS/settings64.sh

The script does a few check ups to cater for cases where the the script was run from a different location or using a certain Unix shell and expects the user to pass the location of the original Xilinx script as the first parameter if he chose to run the script from a different location. Those checkups eventually lead to a certain variable being assigned the canonical path to Xilinx Instalation folder using the $readlink command. This canonical path is used to direct the script to several other Xilinx scripts each one sets up the necessary variables for various Xilinx software.

The script that’s required for setting up environment variables for all Xilinx command line tools is located in the ISE folder under the name .settings64.sh

This script Sets 4 environment variables:

  • XILINX  and XILINX_DSP both containing the path to the ISE folder
  • PATH : Adds several locations to it and appends previous locations at the end.
  • LD_LIBRARY_PATH

I’ve made a mistake of copying every core into the SOC repository before connecting it to the system. While it gave me the freedom to mess up with those cores whatever way I liked knowing that the originals are secured in their repositories it certainly ain’t a good practice. Hence I removed all of the cores from the SOC repositories and adjusted the directory flags to be able to infer them from their original repositories.

Now that the SOC is satisfactory for our simple prototype, it’s time for me to finalize all IO devices and accelerators and make sure they are functioning well with their drivers and as part of the system. When this is done, I’ll be looking at a chance of building a new final IO core.