How to identity connected pins

say if we randomly connect pin A1 with pin 3 with a jumper wire, is it possible to display that on the serial monitor that pin A1 is connected to pin 3?

Make pin three (3) an input pin, turn on internal pull-up on 3.

Make pin A1 (14) an output pin.
Make A1 (14) go to a LOW.

Use digital read on pin 3, if it is LOW it is detecting pin A0 (14).

Serial.print(digitalReadln(3) ); // LOW (0) means 3 is connected to A1 (14).

Thankyou so much, but can you explain me a bit further. I want to write into registers without using Arduino functions

Please explain more ?

2 posts were split to a new topic: Too much spammy

Wants you do do their homework.

Yes. Read both and compare them!

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.