Compilation problem after Green Hill project is migrated to S32

cancel
Showing results for 
Search instead for 
Did you mean: 

Compilation problem after Green Hill project is migrated to S32

269 Views
Contributor III

Hi,

After I transplanted the Green Hill project to S32, I encountered some problems with the compilation. Please help us to answer this question.

pastedImage_1.png

pastedImage_2.png

Wenhui Wang

5 Replies

3 Views
NXP Employee
NXP Employee

Hello,

instead of nop instruction, use e_nop. S32DS does not support register alias. So, you must use mtspr and mfspr with appropriate spr register number instead of DEAR, IVPR and so on.

Another issues I am not able to describe without the project. So, please share the project if it is possible.

Regards,

Martin

3 Views
Contributor III

Hi,

I've also created a new empty project for S32, added my source files, and compiled it, but I got an error when I ran Green Hills Probe emulation. After I click "Run" for a few seconds, an error message box appears.

捕获.PNG

Wenhui Wang

0 Kudos

3 Views
NXP Employee
NXP Employee

Hello,

Run button is not implemented, so, please use Debug button instead of Run button.

But from my point of view, Green Hiils Probe debugger is not directly supported by S32 Design Studio. In release notes, there are following debuggers listed P&E Multilink/Cyclone/OpenSDA  (with P&E GDB Server), Lauterbach, iSystem, and PLS debuggers support by new project wizard.

Regards,

Martin

3 Views
Contributor III

Hi,

Thank you for your help, I use the Green Hills Probe simulation is wrong. I am now using PE simulation is possible, but I encountered a problem, I hope you can help me to answer it.

pastedImage_1.png

pastedImage_4.png

pastedImage_2.png

pastedImage_3.png

Regards,

Vern

0 Kudos

3 Views
NXP Employee
NXP Employee

Vern,

There is an issue with preprocessing the code.

I don't think token concatenation is what is is expected here:

Could you try to replace you macro(s):

#define WR_BIT(reg,bit,val) do {ptr->##reg##.##bit##=(val); _NOP();}while(0)
‍

with 

#define WR_BIT(reg,bit,val) do {ptr->reg.bit=(val); _NOP();}while(0)‍

NOTE:

I'd recommend you to use "Preprocess Selected File(s)" feature for debugging preprocessor related issues:

pastedImage_1.png

pastedImage_1.png

Hope it helps.

Stan

0 Kudos