Forum Discussion

dsun01's avatar
dsun01
Icon for Contributor rankContributor
4 years ago
Solved

generic Serial Flash Interface tested on Arria10 dev board

Dear Support/Expert,

I am following ug_gen_sfi_683419-666881 step by step to create a Quad_SPI on Arria10 dev board.

I need learn how this SPI works and going to custom it to a none flash operation. so I confir the parameters as

disable dedicated active serial interface( checked)

enable SPI pins interface (checed)

use byteenable for CSR( checked)

platform designer can generate HDL no problem, Quartus pro 21.3 compiles OK

but will I generate the Nios2 project, hello from nios2. I got the following errorw.

Description Resource Path Location Type
#error Missing altera safeclib. Please enable it in BSP Software Package. intel_generic_serial_flash_interface_top.c /helloworld_bsp/drivers/src line 282 C/C++ Problem
#error Missing altera safeclib. Please enable it in BSP Software Package. intel_generic_serial_flash_interface_top.c /helloworld_bsp/drivers/src line 672 C/C++ Problem
make: *** [obj/drivers/src/intel_generic_serial_flash_interface_top.o] Error 1 helloworld_bsp C/C++ Problem
recipe for target 'obj/drivers/src/intel_generic_serial_flash_interface_top.o' failed Makefile /helloworld_bsp line 573 C/C++ Problem

---------------------------------

if I double click the error, it will point to this code. ( intel_generic_serical_flash_interface_top.c)

I attached the archive. hope someone who familiar with the quad spi give me some suggestion.

Best Regards,

#ifdef SAFECLIB
ret_code = memcpy_s(((void*)&word_to_write) + padding, bytes_to_copy,
((void*)data) + buffer_offset, bytes_to_copy);

if(0 != ret_code)
{
return ret_code;
}

#else
#error Missing altera safeclib. Please enable it in BSP Software Package.
#endif

  • dsun01's avatar
    dsun01
    4 years ago

    Hi Ash_R_Intel,

    I will give it a try, it will take sometime because I am still learning how to use it. thank you very much.

    David

6 Replies

    • dsun01's avatar
      dsun01
      Icon for Contributor rankContributor

      Hi Ash_R_Intel,

      I will give it a try, it will take sometime because I am still learning how to use it. thank you very much.

      David

  • Ash_R_Intel's avatar
    Ash_R_Intel
    Icon for Regular Contributor rankRegular Contributor

    Hi,

    Do you have any update on this case? Were you able to resolve the issue with provided suggestion?


    Regards


    • dsun01's avatar
      dsun01
      Icon for Contributor rankContributor

      Hi Ash_R

      I accidently clicked myself post as a solution. sorry. it solved, please close this topic.

      Thank you very much

      David

  • Ash_R_Intel's avatar
    Ash_R_Intel
    Icon for Regular Contributor rankRegular Contributor

    Glad to know that the issue was resolved, so closing the case. However, for other community user's knowledge, request you to add your observations here and how did you resolve it.


    Thanks and regards