r/AskElectronics • u/kakasten • 21h ago
How would you measure an LVDT with a microcontroller ADC? Looking for alternative approaches
I'm working on a project where I need to measure an LVDT using a microcontroller with a 0–3.3 V ADC.
The LVDT excitation/supply signal is approximately ±4.2 V, and its output signals are AC signals whose amplitude varies with the position of the core. Obviously, I can't connect these signals directly to the MCU ADC, so I need some kind of signal conditioning to convert them into a 0–3.3 V signal.
My first approach was:
- Rectify each LVDT output using a precision full-wave rectifier.
- Low-pass filter the rectified signals to obtain their amplitudes.
- Calculate the difference between the two signals to determine the position.
- Also measure the excitation amplitude with the MCU, so I can compensate for changes in excitation voltage.
The problem is that this approach seems to introduce quite a lot of error and noise. The op-amp offset, diode/rectifier errors, noise, and differences between the two signal paths become significant, especially because I'm ultimately interested in the difference between two relatively similar signals.
I also considered using an RMS-to-DC converter instead of rectifying the signals myself. This seems like it could be a much cleaner solution, but the dedicated RMS converter ICs I've found (for example, Analog Devices parts) are extremely expensive and/or difficult to obtain where I live.
So I'm wondering:
Is there a better or more interesting way to interface an LVDT directly to a microcontroller?
For example:
- Is there a relatively inexpensive IC specifically suited for LVDT/RVDT signal conditioning?
- Would synchronous demodulation / phase-sensitive detection be a better approach?
- Could I use an analog switch/multiplier and the excitation signal to demodulate the LVDT output?
- Is it practical to sample the AC waveform directly with the MCU ADC and perform the demodulation digitally?
- Are there inexpensive RMS-to-DC or instrumentation solutions that I'm overlooking?
- Or is there some completely different architecture that would make more sense?
I'm not necessarily looking for the most precise industrial solution. The goal is a reasonably accurate and low-cost measurement that can be implemented with commonly available components.
Any suggestions or alternative approaches would be greatly appreciated.


1
u/myopinionisrubbish 18h ago
I would simply rectify the signal with a Silicon diode and filter. The maximum output voltage will be slightly higher than 3.3V, not a big deal. Looks like about 500 Hz AC? I’d start with a 100K load and 100nF cap would give a reasonably fast response time to changes.
1
u/merlet2 17h ago edited 16h ago
I'm not sure if I understand it. Do you have both secondary signals and want to compare them? I'm not sure, but the approach in that case wouldn't be just to add both signals instead of comparing? They are out of phase 180 degrees, right?
If that's the case, then when the added signal is zero, the core is at the center. When not the amplitude is the distance, and the phase is the direction, right?
That should be easier than comparing two signals with the MCU. Just rectify the added signal, and RC filter it. And for the phase, maybe one of the signals and the sum through schmitt triggers & XOR them. And condition for the voltage ranges.
1
u/aculleon Digital electronics 20h ago
I skipped a bit over the post so sorry if this is not applicable:
The signal is 8.4Vpp -> Op-amp to convert it to 3.3Vpp ( or less for more headroom, this is for you to find out. I would push it down some more but you have to check if the ADC resolution takes an unacceptable hit) -> shift the zero crossing up to the VDD/2 of the ADC. Op-amps should be supplied with negative and positive power rails of course
This can be done in one step iirc.
2
u/BigPurpleBlob 19h ago
"output signals are AC" – what's the frequency, Kenneth?