-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Welcome All Makers, Inventors, Hobbyist and Electronic Enthusiast !!!

Talk to us @ 0933-124-7932   ;   email us support@bitstoc.com   ;   chat on BitStoc Facebook Chat
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Contact Us

Open: 1:00pm - 6:30pm

 0933.124.7932 (Sun)
 support@bitstoc.com
 Store Address :
2nd Floor, Unit 2D, TanKim
Bldg, 80-Tres Borces St.,
Mabolo, Cebu City      Map...

Connect with us

Magnetic Contact Switch (Door Sensor)

Magnetic Contact Switch (Door Sensor)
Magnetic Contact Switch (Door Sensor) Magnetic Contact Switch (Door Sensor)
Product Code: Magnetic Contact Switch (Door Sensor)
Availability: In Stock
Price: ₱179



Magnetic Contact Switch (Door Sensor)

This is a very easy and straight forward to use Magnetic Contact sensor. This basically is compose of a Reed Switch inside. You can use this to detect an Open or Closed door. The 2 wires are connected (Closed) when the 2 white plastic contact switches are stick together and the 2 wires are not Connected (Open) when the 2 contact swithces are not in contact.
 


SPECIFICATION

- Easy to use application
- Wire Connected (Closed) when the contact switches are in contact AND Wire NOT connected (Open) when contact switches are not in contact.
- Sticker included to attach the contact switches

 



TUTORIALS - MANUALS - DOCUMENTS

(Upload the Code directly)

/*
  Connect one end of the wire to the GND and one end on Arduino Digital PIN 3.
  Touch the contact switches and the LED (Arduino PIN 13) on the Arduino board will turn ON
  and OFF when the contacts are not in contact
*/

// digital pin 3 is where the contact switch attached to read.
int contactPin = 3;

void setup() {
  // make the contact switch (contactPin) pin an input.
  pinMode(contactPin, INPUT);
  pinMode(13, OUTPUT);
}

void loop() {
  if (contactPin == LOW) {
    digitalWrite(13, HIGH);
  }
  else {
    digitalWrite(13, LOW);
  }
}

 

Tags:

               Payment Channel                                           Shipping and Delivery Channel
                    


                HOME   |   CUSTOMER SERVICE   |   ABOUT US   |   ORDERS  &  SHIPPING   
 BitStoc Electronics
          2nd Floor, Unit 2H, TanKim 
Bldg, 80-Tres Borces St., Mabolo, Cebu City
              ...             (Tel. No.)  --  +63 
933.124.7932 (Sun)  --  ...                       (Globe)
    |  
  www.bitstoc.com