stuck in OSIF_TimeDelay()

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

stuck in OSIF_TimeDelay()

跳至解决方案
3,391 次查看
thomasbao
Contributor II

Hello, I am using MPC5748G. I have a problem about OSIF_TimeDelay(), it will stuck in it, and the debug window looks like this:

thomasbao_0-1632903827565.png

 

After osif component is added, what else needs to be done to use OSIF_TimeDelay()?

Thanks.

0 项奖励
1 解答
3,273 次查看
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi,

After further investigation, I found out that it is known issue in S32DS debugger. I tested your project using Lauterbach debugger and it was working in this case.

It's not fixed yet but the workaround is to not use freeze mode - FRZ bit in PIT_MCR should be 0.

It works as expected in standalone mode without a debugger.

Sorry for inconvenience.

Regards,

Lukas

在原帖中查看解决方案

0 项奖励
9 回复数
2,103 次查看
Francescovgg1
Contributor I

Hi, 

Is there an update on this topic?

I'm using MCP5748G with SDK RTM 3.0.3 and the problem is still present. When I'm in debug, I have to manually reset the FRZ bit via the embsys registers and the FRZ bit gets set back to 1, next time round.

Thank you for your help

0 项奖励
2,604 次查看
davidanderle
Contributor II

I have the same issue and I use PIT as my system timer. Therefore, when the OSIF reconfigures the PIT peripheral, the FRZ bit is set and while my debugger is attached, my 1ms task is not triggered.

OSIF-PIT dependency is not listed in the referenced components. there are 2 ways to stop this from happening: Use the STM module for the system timer or patch the osif driver manually (comment out FRZ bit set)

2,539 次查看
Bobkat
Contributor II

Hi David,

Apologies for the late reply.

Ended up debugging over CAN. Not ideal, but seemed to get the job done.

Will change over to the STM module for timing when I next work on the core code.

Many thanks

Rob

0 项奖励
3,295 次查看
thomasbao
Contributor II

Hi,

    I used MPC5748G-GW-RDB, the pin I measured is shown in the red box below, and there are no other originals attached to J11.

thomasbao_0-1634115895983.png

 

0 项奖励
3,274 次查看
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi,

After further investigation, I found out that it is known issue in S32DS debugger. I tested your project using Lauterbach debugger and it was working in this case.

It's not fixed yet but the workaround is to not use freeze mode - FRZ bit in PIT_MCR should be 0.

It works as expected in standalone mode without a debugger.

Sorry for inconvenience.

Regards,

Lukas

0 项奖励
3,118 次查看
Bobkat
Contributor II

Hi Lukas,

Encountering this problem with S32ds, MPC5748G and OSIF.

With regard to the workaround, we're using the SDK and can only reset the bit via the embsys registers and the FRZ bit gets set back to 1, next time round.

The application doesn't recognise PIT.MCR.B.FRZ = 0; it looks like 'PIT' is redefined by the SDK.

Any ideas as to how to set the FRZ bit to 0 permanently?

Additionally, is there a schedule for releasing an update to S32ds that will fix this problem?

Best regards

 

Rob

 

0 项奖励
3,383 次查看
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi,

it works as expected on my side without additional configuration. Do you have some simple project to reproduce the behavior?

Regards,

Lukas

0 项奖励
3,322 次查看
thomasbao
Contributor II

Hi,

    Here is a simple project to flip the level of PA0 every 100ms, but the level of PA0 remains 0V after entering the while loop, even when observed with an oscilloscope.

    Could you give me some advice? Thank you.

0 项奖励
3,307 次查看
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi,

it works as expected on my side. I used DEVKIT-MPC5748G and I can see that USR_LED2 connected to PA0 is toggled. Do you measure correct pin?

Regards,

Lukas

0 项奖励