Autosar MCAL Template Application for S32K142

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

Autosar MCAL Template Application for S32K142

Jump to solution
2,259 Views
talha_uyar
Contributor III

Hi,

I have previously played around with Autosar MCAL 4.3 on my S32K118 EVB. I had imported the template application (I think it was called "Platform Integration") and played around with most of the plugins. However, we are now focusing on S32K142 and I have realized that I only have template applications for S32K118 and S32K144. The same thing goes for the Peripheral Access Layers and linker files. I only have s32k118.h and s32k144.h etc.

Is there a template application for S32K142? How can I port my existing Autosar MCAL project on S32K118 to S32K142? Where can I find the linker files etc. for S32K142? Where should I look to get started with MCAL for S32K142?

Thanks for all the responses.

0 Kudos
1 Solution
2,230 Views
namnguyenviet
NXP Employee
NXP Employee

1 - Are changes in EB Tresos sufficient? >> Yes, they are

2 - Do I need a Peripheral Access Layer for s32k142 or can I just use s32k144.h for S32K142 as well? Do I need the .cmm files (runS32K142.cmm for instance)? 

It pretty much depends on whether you want to access the registers in your application. If you don't want to access registers, then you can ignore these header files. Otherwise, you can find s32k142.h in S32DS, which can be downloaded here: https://www.nxp.com/design/software/development-software/s32-design-studio-ide/s32-design-studio-for...

cmm file is used when you use Trace32 Lauterbach, however you can use whatever debugging tool for flashing into the microcontroller without the needs of Trace32 and cmm file.

3 - What changes should I make in the launch.bat, make.bat makefile etc. to use the new linker files etc?

Change the path in files.mak to from linker of 144 derivatives to the new linker files.

4 - Can you explain in detail the necessary steps of the porting process from S32K144 to S32K142?

Go to S32K144 project. In the Resouce module in EB Tresos, change the sub-derivative to s32k142

s32k142.PNGYou will see a bunch of errors in the Problems view, due to the fact that S32k142 has less peripheral/HW instances compare to S32K44. Try to remove/modify all of them until no errors. Generate the code and re-compile the application, also link the application with s32k142 linker files.

Best Regards,

Nam

View solution in original post

0 Kudos
3 Replies
2,242 Views
namnguyenviet
NXP Employee
NXP Employee

Hi @talha_uyar ,

Unfortunately, there isn't any template application for S32K142. In order to port to S32K142, I prefer you to import from S32K144 project, as s32k144 and s32k142 have the same ARM Cortex M4 core, rather than S32K118, which has ARM Cortex M0+ core. Try to change the Resource sub-derivate in EB tresos to s32k142, fix all errors regarding the different platform, then re-generate the code and compile again. 

Here I sent you the linker files for k142, which are in GHS and GCC compilers.

Best Regards,

Nam

0 Kudos
2,237 Views
talha_uyar
Contributor III

1 - Are changes in EB Tresos sufficient?

2 - Do I need a Peripheral Access Layer for s32k142 or can I just use s32k144.h for S32K142 as well? Do I need the .cmm files (runS32K142.cmm for instance)?

3 - What changes should I make in the launch.bat, make.bat makefile etc. to use the new linker files etc?

4 - Can you explain in detail the necessary steps of the porting process from S32K144 to S32K142?

 

0 Kudos
2,231 Views
namnguyenviet
NXP Employee
NXP Employee

1 - Are changes in EB Tresos sufficient? >> Yes, they are

2 - Do I need a Peripheral Access Layer for s32k142 or can I just use s32k144.h for S32K142 as well? Do I need the .cmm files (runS32K142.cmm for instance)? 

It pretty much depends on whether you want to access the registers in your application. If you don't want to access registers, then you can ignore these header files. Otherwise, you can find s32k142.h in S32DS, which can be downloaded here: https://www.nxp.com/design/software/development-software/s32-design-studio-ide/s32-design-studio-for...

cmm file is used when you use Trace32 Lauterbach, however you can use whatever debugging tool for flashing into the microcontroller without the needs of Trace32 and cmm file.

3 - What changes should I make in the launch.bat, make.bat makefile etc. to use the new linker files etc?

Change the path in files.mak to from linker of 144 derivatives to the new linker files.

4 - Can you explain in detail the necessary steps of the porting process from S32K144 to S32K142?

Go to S32K144 project. In the Resouce module in EB Tresos, change the sub-derivative to s32k142

s32k142.PNGYou will see a bunch of errors in the Problems view, due to the fact that S32k142 has less peripheral/HW instances compare to S32K44. Try to remove/modify all of them until no errors. Generate the code and re-compile the application, also link the application with s32k142 linker files.

Best Regards,

Nam

0 Kudos