FPGA Intellectual Property
PCI Express*, Networking and Connectivity, Memory Interfaces, DSP IP, and Video IP
Announcements
The Intel sign-in experience is changing in February to support enhanced security controls. If you sign in, click here for more information.
6064 Discussions

generic Serial Flash Interface tested on Arria10 dev board

dsun01
New Contributor III
427 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
401 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

6 Replies
Ash_R_Intel
Employee
409 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


dsun01
New Contributor III
402 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

Ash_R_Intel
Employee
360 Views

Hi,

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


Regards


dsun01
New Contributor III
313 Views

Hi Ash_R

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

 

Thank you very much

David 

meenalkb
Novice
159 Views

Hi,

What was the solution?

Thanks

Ash_R_Intel
Employee
283 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


Reply