Please see all COVID-19 updates here as some shipments may be delayed due to CDC safety and staffing guidelines. If you have an order or shipping question please refer to our Customer Support page. For technical questions please check out our Forums. Thank you for your continued support.

Member #707145

Member Since: August 7, 2015

Country: United States

  • I had some drama wiring this switch, but finally managed to get it all working. In this example I have it connected to Arduino 5V An example if you want to control the LED and check switch state:

    Connect positive terminal (+) to PIN 4 (OUPUT pin to switch the LED on/off). Connect negative terminal (-) to GND. Connect common (C) to 5V rail. Connect normally open to PIN 3 (INPUT for switch).

    CODE: const int SWITCH_LED = 4; const int SWITCH = 3;

    volatile boolean switch_state = LOW;

    void setup() { pinMode(SWITCH_LED, OUTPUT); pinMode(SWITCH, INPUT); digitalWrite(SWITCH_LED, LOW); }

    void loop() { if (digitalRead(SWITCH) == LOW) { digitalWrite(SWITCH_LED, LOW); } else { digitalWrite(SWITCH_LED, HIGH); } delay(10); }

  • "These buttons are rated up to 3A and 250VAC while the LED is rated for 5V." Can I use them with 5V Arduino even though they are 250VAC? Or do I have to specifically have to use DC rated buttons?

No public wish lists :(