Build a device that when it loses SSID access for 5 minutes, it triggers a relay

Is this possible with Arduino? I would like to make something that when it loses sight of a particular SSID for 5 minutes, (it does not need to be joined to it, just sees it), that it would trigger a relay.
Or if it would have better battery life I can do BLE.

Would this be able to be made battery-operated?

Thank you

EDIT: I added more details farther down. TY

What hardware would be needed for it? Thank you

I think the idea is YOU have to make the decision how you want to proceed with the project before you can know the hardware required.

An ESP8266 or ESP32 comes to mind. And a relay or relay module.

Depends on how long the battery should last and how big the battery can be. WiFi stuff tends to consume quite a bit of power. It helps that it doesn't have to be active all the time, but an ESP-type controller that reaches out to a WiFi AP once every minute or so will wear down a battery pretty quickly. You'd have to do the math based on typical power consumption of the controller, the time it takes on average to contact the AP and the capacity of the battery and then see if it fits with your requirements. There's a couple of variables you can play with, such as battery size, but also how often you have the controller reach out to the AP.

Keep in mind that if the relay is activated, this also draws a fair amount of current and keeps doing so until it switches off. This will drain the battery quicker than the network activity.

Thank you to everyone who replied.
My goal is that if this device exits the coverage area, it will trigger a relay which will trigger a siren.
The siren itself will be independently powered so I don't need that from the Arduino, just the relay.

I was thinking of using either bluetooth or wifi as beacons, so the device knows whether it is still in the area. The benefit of using wifi is that there is currently a wifi infrastructure there, but from my understanding the issue is that wifi uses a lot of power. Eventually I would want the device to be able to run a few months on battery, but for right now I am just trying to do a proof of concept, so I don't need that long of a battery.

THank you

So either:

  • Use a big battery
  • Be content with a very low polling frequency; i.e. is it OK if the device takes a couple of minutes to realize it's gone out of range?
  • Explore other options except WiFi or BLE

For a proof of concept, you could easily kludge something with a couple of AA's, an ESP8266/32 and a relay. A solid-state relay will consume less power than one with a coil. If the siren is DC-powered, you could even use a MOSFET (module). If so, make sure it is a logic-level MOSFET that can switch on a 3.3V input.

I do not need it in real-time. Polling every five - to ten minutes is more than enough.

What other options besides Wifi and BLE would there be that can reduce power? I looked into UWB but aren't those anchors very expensive?

The siren is a DC one, so then the MOSFET would work.

Thank you

I think for all intents and purposes a BLE beacon is probably the best compromise between cost, complexity, ease of implementation, reliability etc. If it offers the kind of range you're looking for, I'd look no further.

It really helps if you can keep the sampling rate down. Also have a look at any other power wasters on the boards/modules you'll be using and strip off anything that wastes power (power LEDs etc.) - or not design them in there in the first place if you're doing your own PCB.

Great, that saves you some, too. Be careful in selecting the right kind of MOSFET (module). There are still plenty around that work marginally at best on 3.3V logic ports.

Thank you. So I am very new to this, besides the ESP32 what components would I need to add to the PCB?

Thank you

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.