Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
12 years ago

Setting up Nallatech pci385 d5 board

Following the instructions on how to install the board I have run (after setting up the required environment variables):

$ aocl install

yielding:

aocl install: Running install from /opt/AOCL//board/pcie385n//linux64/bin

Using kernel source files from /usr/src/kernels/2.6.32-358.11.1.el6.x86_64

make: Entering directory `/usr/src/kernels/2.6.32-358.11.1.el6.x86_64'

Building modules, stage 2.

MODPOST 1 modules

WARNING: modpost: missing MODULE_LICENSE() in /opt/AOCL/board/pcie385n/host/linux64/driver/aclpci_drv.o

see include/linux/module.h for more information

make: Leaving directory `/usr/src/kernels/2.6.32-358.11.1.el6.x86_64'

Can't find the device!

Make sure:

1. Altera OpenCL Accelerator board is plugged into PCIe slot.

2a. The board either has a default OpenCL image in its flash, or

2b. If it's the first time using the board after power up, load

SOF using quartus_pgm and reboot the machine.

See documentation for the details.

Remeber that you can use 'reprogram' command to change SOFs once the

board is recognized as a PCIe device and this driver is loaded.

To see if the Altera Accelerator board is recognized as a PCIe device

run '/sbin/lspci | grep Altera'.

aocl install: failed.

Thus, I'm turning to suggestion 2b. This is the first time using the board after power up (first time ever in fact). However, what .SOF should I load to the FPGA? I presume this means using the Usb Blaster cable and the JTAG adapter.

What .sof should I use, and how should I call the quartus_pgm command?

quartus_pgm -c USB-Blaster -m JTAG whatSOF.sof ?

Thank you

19 Replies

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    just reboot. Now i'm flashing again the board and i will do a full shutdown as you say. I comment you when finish.

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    not work:

    aocl install -> the same output as my first post

    aocl diagnostic -> the same output, also Error Window: diagnostic.exe has stopped working

    I have seen that in the windows device manager after installing appears:

    Accelerators: "Altera FPGA Accelerator 13.0". Should'n be "ACL Pcie385 Test System Rev. 1?

    Jungo: "WinDriver"

    :(
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Is AOCL_BOARD_PACKAGE defined as a user variable or system variable? Since aocl install needs to be run with admin privaleges if you have it only declared as a user variable then the admin user will not have that variable declared. If your Windows user account is already setup to be admin then this will not matter.

    I just checked on my Windows machine and the accelerator is showing up as "Altera FPGA Accelerator 13.0" so that should be the correct device description.

    I don't know if this is still needed anymore but one other thing I used to do when installing the driver is go into the device manager and uninstall the Accelerator and Jungo drivers before running aocl install. This makes sure the board driver is not already loaded up when the aocl install attempts to install the new driver.
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    AOCL_BOARD_PACKAGE_ROOT was defined as user variable. Defined as system variable not works anyway... but "aocl install" get the correct path "C:\altera\13.1\hld\board\pcie385n. I think that the issue could be in the physical installation of the board, in the motherboard. The guide for the installation i not found in the Nallatech website. I have the JTAG adapter and the Usb Blaster cable connected. The board is in the pcie 16x because i have not 8x... and my RAM is just 4GB, not the 24GB minimum. What can i do?

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Hi rotty,

    If the board shows up in the Hardware Manager as "Altera FPGA Accelerator 13.0", this proves that the OpenCL driver is correctly installed on your machine and that the board is functional, e.g. no issues with only 4GB of RAM (that is to run host application, building design is a different issue - the compilation process requires a larger amount of RAM) or using a x16 slot (for maximum bandwidth make sure that 8 lanes of the 16 lanes slots are connected to the motherboard).

    Assuming Windows 7 64-bit & admin rights, can you please double check your environment variables? Here is what my ** System Variables ** are set to:

    ** System Variables **

    ALTERAOCLSDKROOT

    C:\altera\13.1\hld

    PATH

    %ALTERAOCLSDKROOT%\windows64\bin;

    %ALTERAOCLSDKROOT%\bin;

    %QUARTUS_ROOTDIR%\bin;

    QUARTUS_ROOT

    C:\altera\13.1\quartus

    AOCL_BOARD_PACKAGE (not set)

    ** - **

    [1] - Can you now run "aoc --list-boards" OK? What is the output?

    [2] - When you reprogrammed your flash, what design did you use? You should use a precompiled design from this page: http://www.altera.com/support/examples/opencl/opencl.html (I would advise the vectorAdd example but it really doesn't matter). When you build your own designs make sure you're using 13.1.

    [3] - Can you still see the board listed in the Hardware Manager as "Altera FPGA Accelerator 13.0"?

    [4] - If you are still having issues, can you run the "SET" command in a Windows Command Prompt and post the output here?

    Thanks,

    Gildas
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Hi gigi,

    I've fixed the "aocl --list-boards" issue. One user said in another thread that solved it by installing windows 7 in English because it was in Spanish (Argentina). I am Spanish (Spain) and now, when i install it in English (same environment variables), everything works, including "aoc --board pcie385n_a7 -v hello_world.cl" (if I have windows in Spanish I get the error: can't change into dir) and then i flash the card with the .aocx generated: "aocl flash hello_world.aocx". I shutdown the computer (not restart), I wake up it but "aocl diagnostic" crashes again. I think it's a bug. A question: Whenever I modify my .cl file i need compile with "aocl --board....." and then flash the board with "aoc flash xxxxx.aocx"? Compiling hello_world has taken me an hour ...
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Hi rotty,

    Did you actually use "aoc --board pcie385n_a7 -v hello_world.cl" command? The d5 board uses a different FPGA then the a7 board so I think they are most likely not compatible. Try use "aoc --board pcie385n_d5 -v hello_world.cl" instead. And yes, the .cl file have to be recompiled after change, but I think the next time you compile, it may take less time.
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    The first user of this thread has the d5 board but i really have the a7 board. The titles of my post are wrong, sorry... On the other hand, i've run the hello_world kernel on the board as the getting_started_guide says and works perfectly but some reason "aocl diagnostic" crashes.

    Thanks!!!
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    --- Quote Start ---

    The first user of this thread has the d5 board but i really have the a7 board. The titles of my post are wrong, sorry... On the other hand, i've run the hello_world kernel on the board as the getting_started_guide says and works perfectly but some reason "aocl diagnostic" crashes.

    Thanks!!!

    --- Quote End ---

    Hello,

    I am using pci385n_a7 too and having trouble in running hello world.aocx. There's no problem in compling the opencl and burning it into flash. But when I run ./hello_world in bin after compiling it by make -f makefiel. It crashed :

    fpga is in user mode. enabling bridges

    querying platform for info:

    ==========================

    cl_platform_name = altera sdk for opencl

    cl_platform_vendor = altera corporation

    cl_platform_version = opencl 1.0 altera sdk for opencl, version 13.1

    error: cl_device_not_found

    location: ../common/src/aocl_utils.cpp:355

    query for number of devices failed

    At this time, I ran $aocl diagnostic and it failed also. But that one used to be successful when I there was default hardware image in flash.

    aocl diagnostic: running diagnostic from /home/jisuansuogcb/altera/13.1/hld/board/pcie385n/linux64/bin

    running diagnostic for : acl0

    fpga is in user mode. enabling bridges

    using platform: altera sdk for opencl

    failed clgetdeviceids.

    error code: -1

    aocl diagnostic: failed.

    When I ran $aocl install. It's saying,

    aocl install: running install from /home/jisuansuogcb/altera/13.1/hld/board/pcie385n/linux64/bin

    using kernel source files from /usr/src/kernels/2.6.18-274.el5xen-x86_64

    make: entering directory `/usr/src/kernels/2.6.18-274.el5-xen-x86_64'

    building modules, stage 2.

    modpost

    make: leaving directory `/usr/src/kernels/2.6.18-274.el5-xen-x86_64'

    Based on this, there should be no problem, right?

    But when I tried this one,lspci | grep altera there was no reply, meaning pcie drivers installation failure right? :(

    I have been frustrated with that for two days!

    What should I do next? Can you help me with that?

    Thank you in advance.

    $ld_library_path: /home/jisuansuogcb/altera/13.1/hld/host/linux64/lib

    $alteraoclskdroot: /home/jisuansuogcb/altera/13.1/hld

    $aocl_board_package_root: /home/jisuansuogcb/altera/13.1/hld/board/pcie385n

    Yuxuan