Why is ClrValue() not working?

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

Why is ClrValue() not working?

542 次查看
cmcc
Contributor I

I am having trouble with the PPG1_ClrValue().  First I use PPG1_Disable().  That works fine.  However, when I use PPG1_ClrValue(), nothings happens.  It is the same with PPG1_SetValue().  Why are these not working?

标签 (1)
0 项奖励
回复
2 回复数

488 次查看
adriancano
NXP Employee
NXP Employee

Hi,

This PPG component works with the FTM module as the counter module or another timer and the methods SetValue and ClearValue are only valid when the module is disabled, the necessary sequence to use them is:

Disable();

ClearValue();
Enable();

Or

Disable();

SetValue();
Enable();

These methods do not write to the duty register, this means that the value of the counter for each channel remains the same after calling these methods. The methods only write to the register that changes the initial value of the channel.

I hope this information can help you.

Regards,

Adrian

-----------------------------------------------------------------------------------------------------------------------

Note: If this post answers your question, please click the Correct Answer button. It would be nice!

-----------------------------------------------------------------------------------------------------------------------

0 项奖励
回复

488 次查看
cmcc
Contributor I

Adrian,

I am aware of this.  However, my PPG signal is high even when I try to clear it.  I cannot make it low.

Sincerely,

Chris

0 项奖励
回复