Short-Circuit GPIOs

Does mbed have any mechanism to Short-Circuit two GPIOs using code? i.e
ShortCircuit SC(P1,P2);
DigitalIn di(P1); //same as DigitalIn di(P2);

Hello,

what do you mean with that or what is the use case?

BR, Jan

The use case is that when I want to use part of some board pins smartly.For example, I want to make a floor-board working with some mainboard(support mbed),the floor-board has no MCU, and only use part of mainboard’s pins,like below


I think this solution can be come true quickly.

Ok, you want to solve unused pins. ST provides a Getting Started guides

Getting started with STM32F4xxxx MCU hardware development - Application note

4.3.1 Handling unused pins
All microcontrollers are designed for a variety of applications and often a particular
application does not use 100% of the MCU resources.
To increase EMC performance, unused clocks, counters or I/Os, should not be left free, e.g.
I/Os should be set to “0” or “1”(pull-up or pull-down to the unused I/O pins.) and unused
features should be “frozen” or disabled.
Note: To reduce leakage it is advisable to configure the I/O as an analog input or to push-pull and
to set it to “0”

page 25/50

I hope it helps

BR, Jan