0
\$\begingroup\$

schematic

simulate this circuit – Schematic created using CircuitLab

MCU1 is factory and I can't modify its firmware. I need to add a second MCU2 (ESP32) to control existing 4-20 sensor. Which ADC can I use here?

Are there any variants to use the ESP32's internal ADC? Isolated DC-DC does not solve the problem because I also need to sniff the UART port of MCU1.

Ground is car body here.

\$\endgroup\$
8
  • \$\begingroup\$ Why do you need another 120Rsense resistor? You can simply sense the voltage at the input of mcu1. Share the same 0V rail and the problem is solved for the uart as well. Also, do you want to control the sensor or simply measure it? \$\endgroup\$
    – Kartman
    Feb 20 at 11:27
  • \$\begingroup\$ if I connect MCU2 paralel it can get some current and make unexpected things on reboot. And not shure that I can make short wire from MCU2 to R1. \$\endgroup\$
    – eri
    Feb 20 at 12:10
  • \$\begingroup\$ Are you sure? Have you measured it? \$\endgroup\$
    – Kartman
    Feb 20 at 12:32
  • \$\begingroup\$ Can't you just use two ADC inputs of MCU2 and subtract the value in software ? If you reduce R2, you can even omit the DC/DC converter, and use the same supply as MCU1. Then again, whenever I see very simple solutions, I usually misunderstood something :) \$\endgroup\$
    – tobalt
    Feb 20 at 13:10
  • \$\begingroup\$ @tobalt iteresting, but then i will get +5 and +2.5 on two inputs adc. Need 2.5. So i can measure 50% and its good if no current from R2 to MCU2. \$\endgroup\$
    – eri
    Feb 20 at 14:52

1 Answer 1

2
\$\begingroup\$

I would suggest your instinct is right when you suggest an isolated DC-DC converter. To solve the problem of UART access, you just need an opto-isolated serial interface. These are generally available, but also easy to construct with a logic level opto-coupler.

This also fits with the essentially floating nature of the 4-20mA measurement system.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.