S32K3 PWM measure

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

S32K3 PWM measure

1,743 次查看
kjy106906
Contributor IV

Hello. I have a question.

I want to measure odd number of data waveforms.

I hope to measure the waveform through the EMIOS ICU.
The values I set are as follows.
Measurement mode: ICU Mode Signal Measurement
Measurement property: ICU Duty Cycle

When the measurement is carried out, the duty and period in the red square box are measured.

(400 ticks, 600 ticks) (active time, period)
However, the last data is not measurable.

kjy106906_1-1653878854508.png

Is there any way to measure that data?
For example:

kjy106906_2-1653878925307.png

(400,400),(0,200), (300,300) 

Thank you

标记 (3)
0 项奖励
回复
5 回复数

1,726 次查看
PetrS
NXP TechSupport
NXP TechSupport

Hi,

as far as I understand driver code, in this mode it does not return 3rd and 4th edge, active time duration (first 2 edgess) in tics is returned and a period is calculated from 2nd and 4th edge. You will probably need to select edge detect mode and read value for each edge.

BR, Petr

0 项奖励
回复

1,711 次查看
kjy106906
Contributor IV

Thanks for the reply @PetrS 
Is it possible to measure duty and period even in edge detect mode?
(I think duty and period can only be measured in ICU_MODE_SIGNAL_MEASUREMENT.)
Is there a way to measure the duty and period of odd number of data as in the question above?

kjy106906_0-1654134491873.png

 

标记 (3)
0 项奖励
回复

1,669 次查看
PetrS
NXP TechSupport
NXP TechSupport

Hi,

if having captured values for each edge you can calculate duty cycle/period yourself. 
ICU_MODE_SIGNAL_MEASUREMENT does not return values for bunch of 2 edges you outlined.

BR, Petr 

0 项奖励
回复

1,666 次查看
kjy106906
Contributor IV

Thanks for the reply @PetrS 

sorry. I didn't understand
Please explain in more detail about "if having captured values for each edge you can calculate duty cycle/period yourself"

Best Regards

0 项奖励
回复

1,650 次查看
PetrS
NXP TechSupport
NXP TechSupport

Hi,

in edge mode, you should get a notification for each edge and you can read captured value of the timer and save it for later. Collecting all four edges you can calculate signal parameters.

BR, Petr

0 项奖励
回复