Xilinx ISE WebPACK

提供: ArchWiki
2015年4月7日 (火) 00:50時点におけるKusakata (トーク | 投稿記録)による版 (ページの作成:「Category:開発 Category:計算と科学 en:Xilinx ISE WebPACK Xilinx ISE WebPACK は完全な FPGA/CPLD プログラマブルロジックデザインスイ...」)
(差分) ← 古い版 | 最新版 (差分) | 新しい版 → (差分)
ナビゲーションに移動 検索に移動

Xilinx ISE WebPACK は完全な FPGA/CPLD プログラマブルロジックデザインスイートです:

  • 回路図キャプチャまたは Verilog/VHDL によるプログラマブルロジックの設計
  • 特定のロジックの合成と配置配線による様々な Xilinx FPGA と CPLD
  • ファンクショナル (振る舞い) シミュレーションと (配置配線後の) タイミングシミュレーション
  • 通信ケーブルによる対象機器への設定データのダウンロード

Arch Linux は公式サポートされているディストリビューションではありませんが、多くの機能は Arch Linux で動作します。

必須要件

依存パッケージ

組み込み ARM コア (Xilinx Zynq SoC デバイスなど) 用にソフトウェアを開発する場合、Xilinx Embedded Development Kit (EDK) にバンドルされている GCC クロスコンパイラをインストールすることになります。このコンパイラは glibcncurses パッケージを必要とします。i686 環境の場合、大抵これらのパッケージは既にインストールされています。

64ビットの Arch 環境の場合、multilib リポジトリからパッケージをインストールする必要があります (lib32-glibclib32-ncurses)。

デフォルトシェル

インストール時に、埋め込みプロセッサの Mentor CodeSourcery ツールチェインを Xilinx ツールと一緒にインストールすることができます。デフォルトのシェルが "dash" に設定されている場合、このインストールは何も出力をしないで失敗します。/usr/bin/sh/usr/bin/bash になっていることを確認してください。

次のコマンドを実行することで確認できます:

$ ls -l /usr/bin/sh

以下のように出力された場合:

lrwxrwxrwx 1 root root 15 13 Mar 06:47 /usr/bin/sh -> bash

/usr/bin/sh/usr/bin/bash になっています (Arch Linux でのデフォルト)。

出力が異なる場合、root で以下のコマンドを実行してください:

$ rm /usr/bin/sh
$ ln -s bash /usr/bin/sh

インストール

ノート: The installation is last known to work with Xilinx ISE 14.7, requiring the dynamic library fix described below.

ISE デザインツールは 公式のダウンロードページ からダウンロードできます。登録とライセンス契約が必要ですが、料金はかかりません。つまり、"言論の自由"のフリーではなく、"無料のビール"と同じ意味のフリーです。

tarball のダウンロードが完了したら、解凍してください:

$ tar -xvf Xilinx_ISE_DS_Lin_14.7_1015_1.tar

ISE デザインツールインストーラは Qt アプリケーションです。KDE デスクトップ環境を使っている場合、インストーラは "Oxygen" ウィジェットテーマをロードしようとしますが、Xilinx ISE デザインツールに付属している Qt フレームワークが古いために失敗します。インストーラを実行する前に QT_PLUGIN_PATH 環境変数を削除する必要があります:

$ unset QT_PLUGIN_PATH

それから、ISE デザインツールをインストールしてください:

$ cd Xilinx_ISE_DS_Lin_14.7_1015_1
$ ./xsetup

指示に従って ISE をインストールしてください。デフォルトで、アプリケーションは /opt/Xilinx/ にインストールされるため、このディレクトリに書き込みを行う権限がインストーラを実行するユーザーにあることを確認してください。

インストール中、"Install Cable Drivers" のオプションのチェックを外して下さい。チェックしたままにするとインストール中にエラーが発生します。

ISE デザインツールの起動

ISE デザインツールには環境変数 (主に PATH と LD_LIBRARY_PATH) を変更するシェルスクリプトが含まれています。ISE ツールを起動する前にこのスクリプトを source する必要があります:

$ source /opt/Xilinx/14.7/ISE_DS/settings64.sh

また、32ビット環境の場合:

$ source /opt/Xilinx/14.7/ISE_DS/settings32.sh

スクリプトを読み込むことで、ISE デザインツールに PATH が通るのでツールの名前をターミナルに入力することで起動できます (例: ise, planAhead, xsdk, ...)。

デスクトップアイコンによる起動

/usr/share/applications/ にファイルを作成することもできます。

ise.desktop:

#!/usr/bin/env xdg-open
[Desktop Entry]
Version=1.0
Type=Application
Name=Xilinx ISE
Exec=sh -c "unset LANG && unset QT_PLUGIN_PATH && source /opt/Xilinx/14.7/ISE_DS/settings64.sh && ise"
Icon=/opt/Xilinx/14.7/ISE_DS/ISE/data/images/pn-ise.png
Categories=Development;
Comment=Xilinx ISE
StartupWMClass=_pn

ファイルを作成したら、ホームのデスクトップフォルダにこのファイルをコピーしてデスクトップから ISE ツールを起動できます。

ライセンスのインストール

Xilinx の Licensing Site から WebPACK のライセンスをリクエストすると、ライセンスファイルがメールで届きます。このファイルは Xilinx License Manager でインポートすることができます (ターミナルから xlcm -manage を実行)。

また、~/.Xilinx/opt/Xilinx/14.7/ISE_DS/ISE/coregen/core_licenses ディレクトリにファイルをコピーするだけでもライセンスをインポートできます。

ノードロックライセンス

Arch Linux はデフォルトで systemd の Predictable Network Interface Names を使っています。そのためシステム上のネットワークインターフェイスの名前は "eth0" や "eth1" などにはなりません。

しかし、Xilinx License Manager はそのような名前を検索してシステムの MAC アドレスを確認します。そして、ノードロックライセンスにその MAC アドレスが使われます。ノードロックライセンスが必要な場合、この機能を無効にしてネットワークインターフェイスの命名規則をカーネルによる名前に戻して、ライセンスを取得した NIC の名前を固定する必要があります。以下のコードが役に立ちます:

# echo 'SUBSYSTEM=="net", ACTION=="add", ATTR{address}=="xx:xx:xx:xx:xx:xx", NAME="eth1"' > /etc/udev/rules.d/10-net-naming.rules

For more specific, refer to the page systemd wiki describes how to work and what you have other(formal) ways.

インストール後の設定

After installation, a few manual fixes are required to work around problems caused by running the Xilinx tools on a Linux distribution that is not officially supported by Xilinx. Some of these fixes are taken from this forum post.

動的ライブラリの修正 (libstdc++.so)

The ISE tools supply an outdated version of the libstdc++.so library, which may cause segfaults when using the Xilinx Microprocessor Debugger and prevents the usage of the oxygen-gtk theme. This outdated version is located in two directories within the installation tree: /opt/Xilinx/14.7/ISE_DS/ISE/lib/lin64/ and /opt/Xilinx/14.7/ISE_DS/common/lib/lin64. To use Arch's newer version of libstdc++, rename or delete the original files and replace them with symlinks:

cd /opt/Xilinx/14.7/ISE_DS/ISE/lib/lin64/
mv libstdc++.so libstdc++.so-orig
mv libstdc++.so.6 libstdc++.so.6-orig
mv libstdc++.so.6.0.8 libstdc++.so.6.0.8-orig
ln -s /usr/lib/libstdc++.so
ln -s libstdc++.so libstdc++.so.6
ln -s libstdc++.so libstdc++.so.6.0.8

Then, repeat this process in the /opt/Xilinx/14.7/ISE_DS/common/lib/lin64 directory.

Digilent USB-JTAG ドライバー

To use Digilent Adept USB-JTAG adapters (e.g. the onboard JTAG adapter on the ZedBoard) from within the Xilinx design tools, you need to install the Digilent Adept Runtime and Plugin.

Make sure you have installed fxloadAUR from the Arch User Repository .

To install the Digilent Adept Runtime, it is recommended to build and install adept-runtime-xilinxAUR and its dependencies libftd2xx-digilentAUR and usbdrvAUR from the Arch User Repository.

To install the Digilent plugin, you have to copy two files to the ISE plugin directory. Run the following commands as root:

$ mkdir -p /opt/Xilinx/14.7/ISE_DS/ISE/lib/lin64/plugins/Digilent/libCseDigilent
$ cd /opt/Xilinx/14.7/ISE_DS/ISE/bin/lin64/digilent/libCseDigilent_2.4.4-x86_64/lin64/14.1/libCseDigilent
$ cp libCseDigilent.{so,xml} /opt/Xilinx/14.7/ISE_DS/ISE/lib/lin64/plugins/Digilent/libCseDigilent
$ chmod -x /opt/Xilinx/14.7/ISE_DS/ISE/lib/lin64/plugins/Digilent/libCseDigilent/libCseDigilent.xml

Finally, add every user that should have access to the Digilent USB-JTAG adapter to the "uucp" group.

You may have to add the USB Vendor/Product IDs of your JTAG adapter which can be found with

$ lsusb | grep Xilinx

to the udev rules in /etc/udev/rules.d/20-digilent.rules.

If it still doesn't work, you can make further reading in Xilinx_JTAG_Linux. The magic git repo there may be help.

Xilinx Platform Cable USB-JTAG ドライバー

Make sure you have installed fxloadAUR from the Arch User Repository . We need to build driver from source (git and some make stuff need to be installed, make will say what programs or libraries are missed):

$ cd /opt/Xilinx
$ sudo git clone git://git.zerfleddert.de/usb-driver
$ cd usb-driver/
$ sudo make

If you using 32-bit version of ISE on 64-bit system, pass "lib32" to make:

$ sudo make lib32

And install driver (replace 14.7 to your version):

$ ./setup_pcusb /opt/Xilinx/14.7/ISE_DS/ISE/

When performing this command, the udev rules file will be created. You can reload udev rules to apply changes immidiately:

$ sudo udevadm control --reload-rules

If driver installed correctly and udev rule works, STATUS led should turn on (green or red depending on voltage presence on VREF PIN)

ロケールの問題

PlanAhead doesn't like locales using other literals than '.' as the decimal point (e.g. German, which uses ','). Run the following command before launching PlanAhead:

$ unset LANG

PlanAhead でセグメンテーションフォルト

When launching PlanAhead to generate a .ucf file, a segmentation fault may occur. The issue seems unrelated to the previous topic. The ISE console will show

"/opt/Xilinx/14.7/ISE_DS/PlanAhead/bin/rdiArgs.sh: line 64: 14275 Segmentation fault      $RDI_PROG $*"

The problem seems to come from the bundled JRE as described here. To fix the issue, symlink the OpenJDK libjvm.so into the Xilinx's installation directory.

# cd /opt/Xilinx/14.7/ISE_DS/PlanAhead/tps/lnx64/jre/lib/amd64/server
# mv libjvm.so{,-orig}
# ln -s /usr/lib/jvm/java-7-openjdk/jre/lib/amd64/server/libjvm.so

GNU make

XSDK looks for the gmake executable, which is not present in Arch Linux by default. Create a symlink somewhere in your path, e.g.

$ ln -s /usr/bin/make /home/<user>/bin/gmake

Make sure this directory is in your PATH variable.

KDE の中から Xilinx ツールを実行

KDE by default defines the QT_PLUGIN_PATH shell variable. Some of the Xilinx ISE tools (ISE, Impact, XPS) are Qt applications, which means that they will search for Qt plugins in the locations defined by this shell variable.

Because the Xilinx tools are compiled against and ship with an older version of the Qt framework which cannot use these plugins, they will crash when launched with this environment variable present.

To fix this issue, run the following command before launching the tools:

$ unset QT_PLUGIN_PATH