Forum Discussion

bsp_user's avatar
bsp_user
Icon for Occasional Contributor rankOccasional Contributor
3 years ago
Solved

arria V compiler and hwlibs

Hi,

My goal is to successfully build and run a bare-metal app which measure time by reading one of the the Arria V Soc HPS timers using hwlib. Afterwards I wish to use the same app on a custom board which contains the same HPS as the Arria V SoC.

I'm using Windows with Arm DS-5 v5.29.1 and IntelFPGA suite 18.1 (these the packages I have license for)

I tried to follow several examples like here:

https://www.intel.com/content/www/us/en/docs/programmable/683211/current/bare-metal-user-guide.html

but got some conflicts when using different compilers.

I have two questions please:

1. I don't know which compiler is best for me. I got lost between the following three options:

1.1. In the Bare Metal user guide (link above) they suggest using the ARM Compiler 5 C.

1.2. In the HWlib section, they refer to git repository which recommend using the Linaro suite.

1.3. In the Altera-SoCFPGA-HardwareLib-Timer-AV-ARMCC example (intelFPGA 18.1 version) they use , by defualt , the GCC 4.x [arm-linux-gnueabihf](DS-5 built in) and if I switch to the ARM CC 5 as the Bare Metal user guide suggests I get "program -E" error.

So I got a little confused regarding which one to use and why.

2. The official Intel HWLib source is here:

https://github.com/altera-opensource/intel-socfpga-hwlib

they have a category for av/cv but inside all the examples are for cyclone V only (no av examples)

is there any guide regarding how to configure a new "hello" app to use the hwlib?

- do I need to compile the hwlib first?

- if do, does it generates libraries for inclusion in my "hello" app?

Thanks

  • Hi,


    Since the case have been open for too long, we recommend that we close the thread as per our support procedure.


    However, I highly recommend that you open issues that you'd face separately, for e.g your help needed for Quartus compilation on another then the Baremetal build on next.


    Once you open the new case/s, we will support your issue then. Hopes this helps.


27 Replies

  • Hi,


    For the SoC EDS you can install the Standard free version on the Ubuntu machine, from my experience, it was all fresh install from Ubuntu 20.04 to the SoC EDS, but with already compiled Quartus project and bring over the "handoff" files needed then proceed OK:


    After installing the virtual machine I had ran the following commands to make sure I have all the packages I need:

    $ sudo apt-get update

    $ sudo apt-get install openssh-server mc libgmp3-dev libmpc-dev gawk wget git diffstat unzip texinfo gcc build-essential chrpath socat cpio python3 python3-pip python3-pexpect xz-utils debianutils iputils-ping python3-git python3-jinja2 libegl1-mesa libsdl1.2-dev pylint3 xterm python3-subunit mesa-common-dev zstd liblz4-tool git fakeroot build-essential ncurses-dev xz-utils libssl-dev bc flex libelf-dev bison xinetd tftpd tftp nfs-kernel-server libncurses5 libc6-i386 libstdc++6:i386 libgcc++1:i386 lib32z1 device-tree-compiler curl mtd-utils u-boot-tools net-tools swig doxygen -y


    I guess I'll keep the case open for few days for you to have your tests.


    • bsp_user's avatar
      bsp_user
      Icon for Occasional Contributor rankOccasional Contributor

      Hi,

      I've download the following tools for Ubuntu 18.04 (I use it for other projects and its easier for me instead of installing 20.04):

      - ARM DS: DS000-BN-00001-r22p2-00rel0.tgz

      - Quartus Prime: Quartus-22.1std.1.917-linux-complete.tar

      - SoCEDS: SoCEDSSetup-20.1.0.711-linux.run

      - HWlibs

      I started to follow your guides and now I'm stuck at:

      https://www.rocketboards.org/foswiki/Documentation/BuildingBootloaderCycloneVAndArria10?elq_cid=3780821_ts1679915029555&erpm_id=6664898_ts1679915029555#Cyclone_V_SoC_45_Boot_from_QSPI

      instruction:

      ~/intelFPGA/22.1std/nios2eds/nios2_command_shell.sh \
      make generate_from_tcl

      bsp@bsplinux1:~/Desktop/cv_example.qspi/cv_soc_devkit_ghrd$ ~/intelFPGA/22.1std/nios2eds/nios2_command_shell.sh \
      > make generate_from_tcl
      make -s scrub_clean
      You're already as clean as it gets!
      make quartus_generate_qsf_qpf quartus_generate_top qsys_generate_qsys
      make[1]: Entering directory '/home/bsp/Desktop/cv_example.qspi/cv_soc_devkit_ghrd'
      rm -rf soc_system.qsf soc_system.qpf
      quartus_sh --script=create_ghrd_quartus.tcl
      quartus_sh: error while loading shared libraries: libprotobuf.so.14: cannot open shared object file: No such file or directory
      Makefile:347: recipe for target 'quartus_generate_qsf_qpf' failed
      make[1]: *** [quartus_generate_qsf_qpf] Error 127
      make[1]: Leaving directory '/home/bsp/Desktop/cv_example.qspi/cv_soc_devkit_ghrd'
      Makefile:386: recipe for target 'generate_from_tcl' failed
      make: *** [generate_from_tcl] Error 2

      so it looks for a missing shared library

    • bsp_user's avatar
      bsp_user
      Icon for Occasional Contributor rankOccasional Contributor

      I can try but I apologize I don't know how to do that.

      Which file to load and how to compile?

      Thanks

  • Hi,


    If you're new, please check the following video for reference on the flow of Quartus build in part 1 and part 2:

    https://www.youtube.com/watch?v=8BehnPg8IvM&ab_channel=IntelFPGA

    https://www.youtube.com/watch?v=L8FMSy7Uxjc&ab_channel=IntelFPGA


    The video is just for your reference, it is using old flow but they are almost similar.


    For your step, in Quartus GUI, locate and open the GHRD's Project file ".qpf" in then compile to get the handoff folder to proceed.


  • bsp_user's avatar
    bsp_user
    Icon for Occasional Contributor rankOccasional Contributor

    Hi,

    Thank you very much for your replies and patience.

    I apologies I didn't answered earlier.

    Currently I don't have access to my EVB right now so I kinda stuck until 04/17

    Is it ok to post my progress on this date?

  • Hi,


    Since the case have been open for too long, we recommend that we close the thread as per our support procedure.


    However, I highly recommend that you open issues that you'd face separately, for e.g your help needed for Quartus compilation on another then the Baremetal build on next.


    Once you open the new case/s, we will support your issue then. Hopes this helps.


  • bsp_user's avatar
    bsp_user
    Icon for Occasional Contributor rankOccasional Contributor

    I'll do it, based on your previous replies.

    Thank you very much

  • Hi,


    We look forward to support you on any new thread/issue from you, I now transition this thread to community support. If you have a new question, Please login to ‘https://supporttickets.intel.com’, view details of the desire request, and post a feed/response within the next 15 days to allow me to continue to support you. After 15 days, this thread will be transitioned to community support. The community users will be able to help you on your follow-up questions.



    p/s: If any answer from the community or Intel Support are helpful, please feel free to give best answer or rate 4/5 survey.