0
\$\begingroup\$

I am trying to get two microcontrollers to communicate. One is a Tiva-C TM4C123GH6PM (3.3 V.) The other is an Arduino (5 V.) I will use UART.

Should the grounds of the two microcontrollers be connected to each other? Why is a common ground needed?

\$\endgroup\$
8
  • \$\begingroup\$ How are these boards powered? \$\endgroup\$
    – Mitu Raj
    Commented Jul 23, 2021 at 21:25
  • \$\begingroup\$ Yes, common ground is needed. Usually there is a ground line pilled along the TX/RX lines. It has is not always safe though, as if both devices are floating, hot-plugging this line might result in a current surge to equalize the two grounds to the same potential, which might very well burn things. \$\endgroup\$
    – Eugene Sh.
    Commented Jul 23, 2021 at 21:29
  • 1
    \$\begingroup\$ @MituRaj Both of them connected to computer with their cable. I mean they get power with their connection cable. \$\endgroup\$ Commented Jul 23, 2021 at 21:42
  • \$\begingroup\$ Does this answer your question? How to share ground connection between to microcontrollers connected to a PC \$\endgroup\$
    – Mitu Raj
    Commented Jul 23, 2021 at 21:49
  • 1
    \$\begingroup\$ @KerimTurak You need to connect them so both have the same reference point for the signal voltages. If they haven't, the 3.3v one device is sending might be "felt" as 200v by the other device. \$\endgroup\$
    – Eugene Sh.
    Commented Jul 23, 2021 at 21:57

2 Answers 2

0
\$\begingroup\$

Why is a common ground needed?

'Ground' is the reference point in a circuit which is assumed as 0V. Voltages at different nodes are quantified with respect to this ground point.

So if two microcontrollers are 'talking' to each other serially in terms of signals, then both micro-controllers should have a common reference point to 'understand' or 'agree upon' what's the voltage level of the signal coming from the other micro-controller. If one sends 3.3V, the other one needs to read it as 3.3V itself.

So yea, they should have a common ground.

\$\endgroup\$
0
\$\begingroup\$

Yes you certainly need to have a common ground connection for any physical layer that isn't designed to be galvanically isolated, such as Ethernet.

\$\endgroup\$

Your Answer

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

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