Include folder not created

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Include folder not created

2,355 Views
juliana_rojas30
Contributor III

I am trying to compile a project with SDK. I get a bunch of "not resolved symbols" and undeclared variables. 

I read in another thread that it migh be due the "include" folder is grayed out. The thing is that I checked in my project folder and that "include" folder does not exist. How can I create it? 

Kind regards.

0 Kudos
9 Replies

2,303 Views
jiri_kral
NXP Employee
NXP Employee

Hi Juliana, 

 

just for reference - can you please share screenshot which Include folders are grayed-out? Are there some SDK ones? For folders which can't be found (are grey) - you can add path into project properties -> Settings -> Include:

 
 

 

 

 

 

0 Kudos

2,285 Views
juliana_rojas30
Contributor III

Hi @jiri_kral ,

Sure, I'll attach the screenshots. In fact I'll attach 3: 1 showing the missing path, 1 showing the folders created when it is first imported from the model, and 1 showing the folders created after the SDK is added.

There are SDK folders created, yes. 

But I don't think that's the problem anymore. What I think is, since I am importing the model from Simulink, it imports a bunch of .h and .c files that then, when the SDK is added, are added again with different parameters and in different locations but with the same names. There are a lot of variables that are "undefined" because the tool doesn't find the right document to look into, and manually change it would be super messy.

So, for example for the "system_s32k144.c" file, it is imported at the beggining from the simulink model into the Design Studio. But then, when the sdk is added, another "system_s32k144.c" file is created but in SDK>platform>devices>S32k144>startup.

In conclusion, I think the problem is that the creation of these additional files is creating conflict and that's why for all the undeclared and unresolved variables. I don't know how to solve that. Manually would be messy and doing manual changes for every project is not an option. The final objective was to implement RTOS but without the SDK working I don't see how this could be done. 

 Thanks for the reply. Kind regards.

0 Kudos

2,278 Views
jiri_kral
NXP Employee
NXP Employee

Hi Juliana, 

try to copy your include folder from your .zip into project folder. If there are duplicated SDK files, you can exclude it from build: 

 

image.png

 

 

0 Kudos

2,251 Views
juliana_rojas30
Contributor III

Hello Jiri,

It mostly worked! I don't have any more errors in the SDK folder. I have errors of "undefined variables" from files that used to work before the SDK were added. (I attached a screenshot).

I found here a solution, that didn't quite worked.

I also noticed here that you sugested something related to the AMMCLIB, which I don't think I have in my includes.

includes_Ihave.PNG

But I have the file .a added at the root. 

juliana_rojas30_0-1602071554493.png

Is that enough? Should it be among my includes?

Kind regards.

 

0 Kudos

2,351 Views
jiri_kral
NXP Employee
NXP Employee

Hi, 

what is your S32DS Version? Did you generated Processor expert code before build? 

 

Jiri 

0 Kudos

2,342 Views
juliana_rojas30
Contributor III

Edit @jiri_kral : I found here how to use the add the Expert Code, but I keep getting the errors. 

Regarding the SDKs, I have this data, I don't know if it's useful:

juliana_rojas30_0-1601898616927.png

0 Kudos

2,348 Views
juliana_rojas30
Contributor III

Hi @jiri_kral ,

Thanks very much for your fast reply.

I am using the S32DS.ARM.2018.R1 version. I don't think I used expert generator since I don't know what that is. I only imported a .xml from a project created in Simulink.

When I first build it, it goes well. There's only these warnings:

juliana_rojas30_0-1601895820166.png

When I attach the SDK, and then press build again, it's when all the errors appear.

juliana_rojas30_1-1601897835183.png

Kind regards, Juliana.

 

0 Kudos

2,335 Views
jiri_kral
NXP Employee
NXP Employee

Hi Juliana, 

 

what kind of project do you have? Default way how to import an existing project is through File -> Import -> General -> Existing project into workspace: 

jiri_kral_0-1601900308898.png

 

Other possibility (actually I never use it) is import ProjectInfo.xml: 

jiri_kral_1-1601900504203.png

If I'm correct - the second method create project based on info inside.xml file, but doesn't copy source files into project itself and you need to copy it manually.

 

Jiri

 

 

0 Kudos

2,332 Views
juliana_rojas30
Contributor III

I imported it using the second method you mentioned. When I tried the first one, it couldn't find the project in the folder I specified.

The process I followed when I tried the first method you mentioned (that I couln't make it work) was:

1. In matlab, I select the project folder example_mbd_rtw

2. I create a .zip with this folder.

3. I unzip it and put it in my desktop.

4. I open the DS and select Import>Existing Project into Workspace>

juliana_rojas30_0-1601901499461.png

So I just tried the other way, in which I could find the file directly into the folder. 

As you can see in the picture below, It seems that it can't find the definition of the variables, I am just assuming it is due the lack of the include folder but I might be mistaken. Maybe it's because something else is missing?

juliana_rojas30_1-1601902108418.png

And it comes from here

juliana_rojas30_2-1601902140196.png

Which I don't understand, is that the error is given only for 3 variables that are the same as the first one in the declaration, but the first one doesn't give any errors.

juliana_rojas30_0-1601902480217.png

 

The error is only for 1, 2 and 3. 0 is OK.

Kind regards.

0 Kudos