OSA_TimeDelay() returns immediately in i2c_rtos_mqx_frdmk64f demo but works fine in i2c_comm_mstr_frdmk64f demo

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

OSA_TimeDelay() returns immediately in i2c_rtos_mqx_frdmk64f demo but works fine in i2c_comm_mstr_frdmk64f demo

跳至解决方案
1,284 次查看
yorknh
Contributor IV

Pretty much as the title describes, OSA_TimeDelay doesn't appear to work in the i2c rtos demo. It doesn't hang like someone else had noticed in one of the k64 tower demos, instead it returns immediately. When I run the i2c comm demo instead, OSA_TimeDelay works fine.

Can anyone give me some guidance as to where I should look?

 

This is using KSDK 1.1.0 with KDS2.0

标签 (1)
0 项奖励
回复
1 解答
953 次查看
yorknh
Contributor IV

Iva,

I just reinstalled KSDK because I had inadvertently modified some of the demo src files prior to making a copy of the originals. With a fresh reinstall it seems to be working fine.

If I happen to run into the problem again, I will make note of what change triggers it. That said the debugger error messages should give a clue about what is not right, if they don't,

then what's the point in displaying them?

Thanks,

Larry

在原帖中查看解决方案

0 项奖励
回复
7 回复数
953 次查看
ivadorazinova
NXP Employee
NXP Employee

Hi Larry,

I test both demos and they work without some problems.

I have focused on i2c_rtos_mqx_frdmk64f and make some modifications with OSA_TimeDelay() and made screenshot for you.

When I set OSA_TimeDelay(200) in task_master(task_param_t param)

salea2.png

I got the correct output

salea.png

When I set OSA_TimeDelay(300) I also get correct output

salea3.png

Best Regards,

Iva

0 项奖励
回复
953 次查看
yorknh
Contributor IV

Ok I will attempt what you did. In the meantime, can you explain the errors the debugger was displaying?

Thanks

0 项奖励
回复
953 次查看
ivadorazinova
NXP Employee
NXP Employee

Larry,

I try to solve it, but what do you exactly do for the modifications in your project?

Best Regards,

Iva

0 项奖励
回复
954 次查看
yorknh
Contributor IV

Iva,

I just reinstalled KSDK because I had inadvertently modified some of the demo src files prior to making a copy of the originals. With a fresh reinstall it seems to be working fine.

If I happen to run into the problem again, I will make note of what change triggers it. That said the debugger error messages should give a clue about what is not right, if they don't,

then what's the point in displaying them?

Thanks,

Larry

0 项奖励
回复
953 次查看
ivadorazinova
NXP Employee
NXP Employee

Hi Larry,

Ok. If the problems still persists, can you upload the project ?

The errors could related with that GDB debugger is not able to read the value for that variable.

Best Regards,

Iva

0 项奖励
回复
953 次查看
ivadorazinova
NXP Employee
NXP Employee

Hello Larry,

I will check it on my side and tell you.

Best Regards,

Iva

0 项奖励
回复
953 次查看
yorknh
Contributor IV

Iva,

I've narrowed it down some, though I don't really know what to make of it. There appears to be something wrong with the td_ptr. I've stepped through the _mqx function and the debugger display errors associated with the TIMEOUT structure within td_ptr. I've attached a screenshot.td_ptr.JPG.jpg

When _time_delay gets called, the TIMEOUT displays the same errors so it is hard to know what is happening.

0 项奖励
回复