cancel
Showing results for 
Search instead for 
Did you mean: 

Is the possible to internally connect two GPIO pins together?

dchen
Associate II

Hi,

I am wondering if it is possible to internally connect two GPIO pins by software, not using wires.

Thank you

1 ACCEPTED SOLUTION

Accepted Solutions
Jean-Marc S
ST Employee

Hi @Community member​ 

no it is not possible

View solution in original post

5 REPLIES 5
Jean-Marc S
ST Employee

GPIO's are connected either to internal registers (independant of each others) or to internal IP blocks (UART, I2C,etc..) through an internal multiplexer ("AF" Alternate Function Mux) or to some analog IP blocks (ADC, ..) through "Addtional Function" muxing.

It is not possible to connect physically two GPIO on the device.

So toggling 2 GPIO in the samew way you may have to write on 1st GPIO output register then write same data on the 2nd GPIO.

However if your intention is to output the same "Alternate function" signal (ex: UART) to 2 GPIOs at the same time, this is possible:

you can find this on the web:

https://electronics.stackexchange.com/questions/86616/what-happens-on-the-stm32-when-two-pins-are-configured-to-have-the-same-alternat

JM

dchen
Associate II

Thank you @Jean-Marc S​ 

To clarify my question, is it possible to set one pin as UART TX and the other as UART RX. Then able to connect them internally without a wire? I guess the answer is no though

Did you find such a pin that supports both on your chip, and which one?

hth

KnarfB

Jean-Marc S
ST Employee

Hi @Community member​ 

no it is not possible

No I didn't find such register that can handle loopback, which is a register in my previous MPU. That' why I want to confirm in the community.