I have an old, custom pair of connectors in use by what will be a large number of systems. The connectors are mother/father and symmetrical, as in they don't have a mechanical guide to have the user plug it in in the "right" position.
I cannot alter the father device and connector in any way.
The 4 pins are: VCC GND Rx Tx. I have a high voltage on the power pin and Rx/Tx logic is at 5V. Rx/Tx clock is pre-set at a particular value.
Therefore, the father connector can be plugged in in 4 possible ways.
Mother supplies father with VCC under 1000V and under 100A if and when the pins are "aligned". Until then, the devices can talk through Rx and Tx @ 5V (there is a small rechargeable battery on the father connector end device).
Connectors' and devices' case(s) are non-conductive.
I need to be able to detect the orientation / how the father connector is inserted so I can relay current and signals properly, so that the devices will connect and talk regardless how the connectors are plugged in.
What is the best way to accomplish this? By "best way" I mean least number of components/FETs/relays/diodes. I can use any type of MCU on my end, was looking at a L0-class from STM.
NB: an electro-mechanical device behind the mother connector, in the form of a disk is rotated by a motor in steps of 90' clockwise (basically up to 4 "tries" are made until the signals are properly aligned) has been proposed through another channel, I am not looking for this kind of solution, need something solid state, without moving parts.