I am struggling to make a cockpit for my home-made flight simulation.
How can I connect this toggle switch to an Arduino Uno:
I connected one end to "Ground" another to "VCC" and middle one to any analog pin. But it turns off the Arduino.
Please help me to connect this switch correctly.