Function Definition

The function interface defines the entry points into the library, as a function or set of functions that can be called in user code to target the IP. The function definitions can contain empty function bodies since the SDSoC compilers will replace them with API calls to execute data transfers to/from the IP block. The implementation of these calls depend upon the data motion network created by the SDSoC system compilers. The function definition must #include stdlib.h and stdio.h, which are used when the function body is replaced and compiled.

For example:
// FILE: fir.c #include "fir.h" #include  #include  void fir(signed char X[N], short Y[N]) { // SDSoC replaces function body with API calls for data transfer }
Note:Application code that links to the library must also #include stdlib.h and stdio.h, which are required by the API calls in the stubs generated by the SDSoC system compilers.