MPC5777C 4.3 Sample Application on MPC5775E EVB Kit

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

MPC5777C 4.3 Sample Application on MPC5775E EVB Kit

2,140 次查看
latheef
Contributor III

All,

I started working with the MPC5777C_MCAL4_3_RTM_1_0_0_Sample_Application (Lighting app) on my MPC5775E EVB Kit but it gave IVOR6 which I fixed by correcting the flash_vec from 0x00FE0000 to BE00000 as MPC5775E supports only 4MB unlike its MPC5777C (8MB Flash) counterpart

flash_vec : ORIGIN = 0x00BE0000, LENGTH = 0x010000

Now this sample application is without OS and uses the HW interrupt vector and requires the PIT interrupt for round robin scheduling of the tasks.

The PIT interrupt is not triggered and the task are not getting executed.

Below is the PIT register and CVAL1 Value never changes 0x11940 and TFLG is not set.

latheef_0-1670151912644.png

But I could see the OCU EMIOS_1Ch0 hitting as shown below

latheef_1-1670152073490.png

latheef_2-1670152084430.png

 

latheef_3-1670152092198.png

 

Please let me know why the sample application doesn't work?

Thanks!

 

 

标记 (2)
0 项奖励
回复
11 回复数

2,118 次查看
namnguyenviet
NXP Employee
NXP Employee

Hello,

Please try to disable "GptFreezeEnable" and see whether the TIF can be set:

namnguyenviet_0-1670491305477.png

Best Regards,

Nam

 

2,112 次查看
latheef
Contributor III

@namnguyenviet  It works now.

When I try to run the code with debugger its all fine but when try to power cycle it doesnt run.

I am using S32DS to flash the elf using the OpenSDA. I tried to debug by adding an additional GPIO  and it wont even toggle this pin when without the debugger. Please help!

latheef_0-1670527846483.png

 

0 项奖励
回复

2,108 次查看
namnguyenviet
NXP Employee
NXP Employee

Hello,

Not sure how it could be the issue... Please share the application so I can double check.

Best Regards,

Nam

0 项奖励
回复

2,095 次查看
latheef
Contributor III

@namnguyenviet  Please find it attached.

0 项奖励
回复

2,063 次查看
namnguyenviet
NXP Employee
NXP Employee

Hello @latheef 

After some comparison between your app and my app, I could spot the issue: in Vector_vle_core_diab.s ( for diab compiler) and Vector_vle_core.s (if using other compiler), the reset configuration word is set as 0x005A0002, in which VLE = 0.

namnguyenviet_1-1671011295893.png

It should be set as 1, in order to be able to execute NXP VLE code. After modifying the rcw to 0x015A015A:

namnguyenviet_2-1671011388715.png

the application can be run without debugger, i.e. after performing a reset. 

Best Regards,

Nam

 

 

2,059 次查看
latheef
Contributor III

@namnguyenviet  Thanks for the reply and it works.

But the PIT interrupt wont work if running without debugger. I had to enable GptFreezeEnable to make it work but then it wont work when in debug mode. Could you please enlighten me more on this issue? How to overcome this?

Many Thanks for your help!

0 项奖励
回复

2,028 次查看
namnguyenviet
NXP Employee
NXP Employee

Hello @latheef 

That's weird... in my site the PIT interrupt works in both GptFreezeEnable enabled and disabled (although I have been working with 5777C instead of 5775E due to fact that 5775E is not available in my site, I supposed they are sharing the same behavior). The following thread might be related to your issue:

https://community.nxp.com/t5/S32-Design-Studio/S32DS-MPC5777C-and-PIT-interrupt/m-p/507216

You can try to create a demo based on MPC5777C MCAL and verify the PIT interrupt. 

Best Regards,

Nam

0 项奖励
回复

2,019 次查看
latheef
Contributor III

@namnguyenviet Thanks for the link!

So far I didn't change the ResourceSubderivative  to MPC5775E from MPC5777C, but when I change I get 6 below error in MCU module. Could you please let me know the reason for this ? I didnt expect any change here as two are similar.

latheef_0-1671717255721.png

latheef_2-1671717451672.png

 

Regards.

0 项奖励
回复

1,974 次查看
namnguyenviet
NXP Employee
NXP Employee

Hello @latheef 

It's because the following reasons:

1. SIU_LFCLKCFG seems to be not able to be configured in MPC5775E

2. PSI5 is not available in MPC5775E

Please fix those errors and re-generate the code.

Best Regards,

Nam

2,065 次查看
latheef
Contributor III

@namnguyenviet  Were you able to figure out the issue with the MCAL?

0 项奖励
回复

2,130 次查看
latheef
Contributor III

@petervlna Could you please help me with this?

0 项奖励
回复