2015-04-22 02:47 AM
I am trying to use standard header files - string.h, stdint.h with SPC5Studio. When included to the project, it displays a message as 'unresolved inclusion <string.h>'. What can be done to resolve this? Whether SPC5Studio supports these type of standard header files or not? Whether need to add these files externally? If yes, which files to use for this?
Thanks in advance.Mike.2015-05-14 11:01 PM
Hello Erwan,
Please find attached installation details. The '?' is appearing for files - 'stdio.h', 'string.h', 'stdint.h' and similar. Though the files are present in the mentioned folder, '?' mark still appears. Please provide solution. Thanks. Mike. ________________ Attachments : ST_SPC_Installation_details_3_4_5.png : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006HtfP&d=%2Fa%2F0X0000000aVZ%2Fgmtn3Y0t.gJFgQ3lKH3H3nf5vo6o1RDF8MlBZZ.9Ag8&asPdf=false2015-05-18 05:13 AM
Hello Mike ,
Could you try to synchronize your project with ''F5'' ?SPC5Studio 3.5 on Luna eclipse framework will arrive in the next days.I hope that it will solve the issue Best regards Erwan2015-07-02 06:14 AM
Hello!
I have a similar issue when I tried to include math.h in one of my projects. In properties->path and symbols I added the .../hightec/ppc-ht-eabi/include path. I had to use other settings than Erwan in his screenshot. Setting the option ''Is a workspace path'' leads to an unresolved inclusion warning (question mark at line of #include <math.h>). Therefore, I unchecked this option and the inclusion seems to work. I can jump to the file or function when clicking with ctrl+left mouse button on the source code. So my next step was to use simple sine function with a=sin(b). Both values are defined as double and the project can be build successfully. But when I flashed the program to SPC56EL Discovery Board and the program counter gets to this line of code it hangs in while loop of function osalSysHalt within osal.c. Same behavior when I tried to use any other function from math.h. Defines like M_PI are no problem to use. Any suggestions what I have done wrong? I am using version 3.5 of SPC5Studio with hitec compiler. By the way, the path I included in path and symbols is also looking like that C:\SPC5Studio\... It uses ''\'' and not ''/'' as the predefined entries. Best regards, Patrik2015-07-02 08:11 AM
Hello Patrick ,
functions relative to math.h is using floatcould you use -msoft-float in your compiler options and try to link with libm ?Anyway , we have added a change request concerning the libm Best regards Erwan2015-07-03 12:00 AM
Hello Erwan,
Floating point operations like multiplications are working without additional compiler options. Nevertheless, I added -msoft-float. What I am not sure about is how to link with libm? I add libm.a in Properties->Path and Symbols->Libraries and insert -lm in compiler options which now looks like that:# Compiler options here.
ifeq ($(USE_OPT),)
USE_OPT = -O0 -lm -ggdb -fomit-frame-pointer -falign-functions=16
endif
But it is still not working.
Best regards, Patrik2015-07-07 06:45 AM
Hello Patrik ,
I ma checking the issue today Best regards Erwan2015-07-07 07:51 AM
Hello Patrik ,
it is working well from my side From an application ChibiOS-RT SPC560Dxx Test Application for Discovery Compile with these following options in Common options : -ggdb -DCHPRINTF_USE_FLOAT -lm -fomit-frame-pointer -falign-functions=16 -msoft-float Cf Application in attachment and screenshot in attachment Best regards Erwan ________________ Attachments : 2015-07-07_164341.png : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006HtcR&d=%2Fa%2F0X0000000aS7%2FJLuMHgB482kCcchoRL9VbEYa8ioam8HjYUbvlgwsRoM&asPdf=falseChibiOS-RT_SPC560Dxx_Test_Application_for_Discovery_LIBM.zip : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006HtfU&d=%2Fa%2F0X0000000aVa%2FOImDBGKi0JrtRrQcfSfGH17nm0hJPmv0xRbRNCxYR3w&asPdf=false