Our IOT project has the goal of detecting when a door opens and alerts someone. Two particle argons were involved in successfully monitoring, communicating, and powering an LED to alert someone. This IOT project is used for monitoring the status of components that move, for example these particle devices could be used to monitor: open windows, open doors, open gates, or receiving mail.
This is our first particle, it is equipped with a MC-38B NC&NO Embedded Magnetic Gap Switch ordered from Amazon. This particle monitors feedback from the magnetic switch and then communicates with the second particle. The first particle sends the status of the switch to the cloud. When the switch is open, the display will read "open" and when the switch is closed, nothing is uploaded. When closed, no signal is sent from particle one. When the magnetic switch is disrupted (door opening) the particle will send a signal to the second particle.
The purpose of the second particle is to receive a signal from the first particle and power a red LED light to signal that a door has been opened. When the first particle detects that the door is closed, a signal will be sent to the second particle and it will turn off the red LED. The second particle is subscribed to the first particles events and reacts to the signal received.
Shown above are the events recorded by particle 1. This is a visual to see that communication is having between the particles and that the switch is work
The graph above shows the position of the door with respect to time. Each reading is taken every 10 seconds and door was open/closed in random intervals.