FPGA Intellectual Property
PCI Express*, Networking and Connectivity, Memory Interfaces, DSP IP, and Video IP
6343 Discussions

generic Serial Flash Interface tested on Arria10 dev board

dsun01
New Contributor III
763 Views

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

 

0 Kudos
1 Solution
dsun01
New Contributor III
737 Views

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

View solution in original post

0 Kudos
6 Replies
Ash_R_Intel
Employee
745 Views

Hi,

Please refer to the information available on following page:

1.9. Nios II HAL Driver (intel.com)


Note:

  1. Enable altera_safeclib in BSP Software Package from BSP Editor to use the HAL API.


Regards


0 Kudos
dsun01
New Contributor III
738 Views

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

0 Kudos
Ash_R_Intel
Employee
696 Views

Hi,

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


Regards


0 Kudos
dsun01
New Contributor III
649 Views

Hi Ash_R

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

 

Thank you very much

David 

0 Kudos
meenalkb
Novice
495 Views

Hi,

What was the solution?

Thanks

0 Kudos
Ash_R_Intel
Employee
619 Views

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


0 Kudos
Reply