How can I measure percentage of pulse signal
조회 수: 1 (최근 30일)
이전 댓글 표시
I am working on a project. I need get pwm signal on raspberry pi then find the open interval which means percentage of the signal. I design a system but it does not work properly.
I can reach the correct value without delay but when I decrease the percentage it keeps max value.
댓글 수: 0
채택된 답변
Ryan Takatsuka
2018년 7월 24일
You are probably better off filtering the PWM signal to find the interval percentage. See the attached example.
댓글 수: 2
Ryan Takatsuka
2018년 7월 25일
If you have the Signal Processing Toolbox, you can use the filterDesigner app to design a lowpass IIR filter. Otherwise, there are some online tools such as this one: Online Filter Designer
I've attached an example of a filter using a 0.020 s period with an arbitrary sampling rate.
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Digital and Analog Filters에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!