Why does a multimeter see a PWM signal when measuring a sensor using the voltage range?

Publisher:温柔阳光Latest update time:2021-03-04 Source: elecfansKeywords:Multimeter Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

There is a position sensor that measures position changes. When the output signal of the sensor is measured with the voltage range of a multimeter, the result shows an analog signal, that is, the position and the signal output are linearly related. However, when the output signal of the sensor is measured with an oscilloscope (Picoscope 4227), it shows a PWM signal (pulse width modulation), that is, the duty cycle of the output PWM signal is different for different positions.


The parameters of the PWM signal are: 200 Hz, low level is 0V, high level is 18V.


Now it is confirmed that the output signal of my sensor is a PWM signal. The PWM signal needs to be input into the controller I/O, but the controller I/O port does not have the function of directly collecting PWM signals.


solution

Design a circuit to convert the PWM signal into an analog signal, and then input the converted analog signal into the controller analog I/O port.


Conversion circuit

1. Second-order voltage-controlled active low-pass filter circuit.

Design a deep filtering circuit. The filtering circuit diagram is:

Why does a multimeter see a PWM signal when measuring a sensor using the voltage range?

The formula for low-pass filter frequency is: f=1/(2π*RC). I finally chose R=1K, C=10uf, and the calculated low-pass cutoff frequency f=15.9HZ.


The back end of the filter circuit is an operational amplifier, and the amplification formula is: A=1+Rf/R1. I don't want the voltage to be amplified, so I choose A=1.1. And because R1//Rf=2R (the value of R1 and Rf in parallel is equal to the value of R in series), the final result is: Rf=220 ohms, R1=2.2k, R=1k.


2. Integral circuit (passive filter circuit)

There is a two-stage integration circuit in front of the low-pass filter circuit (both capacitors are grounded), R=1K, C=10uf. The figure below is a first-stage integration circuit. The designed integration circuit is to connect the two circuits in series to form a second-stage integration circuit:

Why does a multimeter see a PWM signal when measuring a sensor using the voltage range?

To test the circuit effect, I used a PicoScope4227. Since the device can only generate a voltage signal of positive or negative 1V at most, I generated a PWM signal with an amplitude of 1V (low level 0V, high level 1V) and a frequency of 200HZ as the input signal of the integration circuit. The various effect diagrams are as follows:

The oscilloscope directly samples the PWM signal generated by the generator, and the waveform is as follows:

Why does a multimeter see a PWM signal when measuring a sensor using the voltage range?

The oscilloscope collects signals from the input end of the second-order filter circuit, and the waveform is as follows. It is found that this waveform has changed compared with the waveform in the figure above.

Why does a multimeter see a PWM signal when measuring a sensor using the voltage range?

The signal waveform collected by the oscilloscope from the output end of the first-order filter circuit, that is, the output waveform of the intersection of the first resistor and the first capacitor from left to right in the filter circuit:

Why does a multimeter see a PWM signal when measuring a sensor using the voltage range?

The signal waveform collected by the filter from the output end of the second-order filter circuit, that is, the final output signal waveform

Why does a multimeter see a PWM signal when measuring a sensor using the voltage range?

Parameters of the final output waveform.


question

1: Why is it that when I use the voltage range of a multimeter to measure the output signal of a sensor, the result is an analog signal, while when I use an oscilloscope, the result is a PWM signal? Which result should I believe?

A: This question involves the resolution of the measurement input port. The resolution of the multimeter input port is low (in this example, it is less than 200HZ), while the resolution of the oscilloscope input port is high, reaching several thousand or even several megahertz, so the output results are different. We have to believe the results displayed by the oscilloscope. I understand that the essence of PWM signals is to achieve the effect of analog quantity, but the expression form is different.

2: About the calculation formula

Answer: In the low-pass filter circuit, there is a frequency formula f=1/(2π*RC), which calculates the low-pass cutoff frequency (-3dB). In the integration circuit, there is a formula T=RC. This T refers to the time required for the capacitor to charge and discharge. When selecting T, according to the general empirical formula, T>10 * T' (T' represents the signal period).

In the integration circuit of this example, RC=10ms, which is only twice the signal period, but through testing, the signal effect is still relatively ideal. If more integration circuits are connected in series, the effect will be better.

3: Are there any other solutions for the PWM signal to be collected by the controller?

Answer: Solution 1: Multiply the PWM signal, that is, increase the frequency of the PWM signal, but the duty cycle does not change. If the frequency after PWM multiplication is greater than the resolution of the controller I/O, it can be regarded as analog by the controller by default, and can be input into the analog I/O.

Solution 2: Calculate the PWM duty cycle by software. Write a program in the controller to first set the timing and measure the high level time of the PWM signal during this period of time, so as to calculate the duty cycle.

Keywords:Multimeter Reference address:Why does a multimeter see a PWM signal when measuring a sensor using the voltage range?

Previous article:DMM7510 Graphical Sampling Multimeter for Measuring Power-On and Power-Off Transient Events
Next article:Steps and methods for testing junction field effect transistors using a multimeter

Latest Test Measurement Articles
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号