I want my garage door to open when I am cycling home and I am within x meters of home.
I have a garage door opener at the moment that does this and before I leave work I toggle the GPS tracking on the app. When I get near home the app opens the garage door. I am looking for something similar. A tracking app that I manually turn on before leaving.
Assuming that I have a password protected https rest service that my phone can call to open the garage door I would like to define a home zone in the app on my phone and when entering that zone send a get request to node red and then stop tracking my location.
I have done some searching and all the location tracking apps that I found seem to be always on with no easy way of turning the tracking off.
Thanks for the reply. I looked at Own Tracks and installed it on my phone but I couldn't turn it off. I seemed to have to restart my phone to stop it reporting my location.
Would it not be easier to have a manual switch that does it?! Since you will have a manual task anyway?
That could be something on your phone - an integration via a Telegram bot for example - or even using a web page if your WiFi reaches out into the street.
You could integrate that with voice command if you wear an earpiece when cycling.
Or you could build a little switch using Bluetooth (ESP32) or a simple 433MHz radio transceiver.
Phone GPS is generally too unreliable unless you want your door to open when you are still 1/2 mile away.
When I am cycling home my phone is in my saddle bag and not accessible. Also the door takes some time to open so I want it to start opening when I am say 100m away.
The really simple but reliable way is a standard door opener - very cheap from China. It uses 433MHz so has (can have) decent range. Range can be adjusted with a better aerial.
GPS is very dependent on many factors and with the phone in your bag would be unlikely to be accurate enough anyway.
Another option would be to extend your WiFi to the street. Possibly on a different SSID for security. All that is needed is for the phone to connect to it. You can use Tasker or similar to then take an action based on the connection. That action could be to send a Telegram msg to Node-RED via your bot. Or, if you don't use a Telegram bot, you could make Tasker do a web GET on a page in Node-RED (since your phone would already be connected to your network).
But you could put an NFC chip on your bike or work desk. Flash your phone against it to turn on "heading home mode" (which might include notifying node-red & switch on GPS reporting).
You could add to that a bt scanner at your gate so it detects you - coupled with the knowledge of your imminent arrival (signalled by NFC) you'd gain a bit extra security.
And/or like Julian said, you could use voice command to begin the process.
I appreciate your replies but I know that GPS will work fine. My existing solution uses Android bluetooth and it works reliably.
If I used bluetooth or wifi I would be too close to the house when the door is triggered for it to open by the time I get to the door.
A 433MHz door controller will be the cheapest and most reliable solution - but doesn't need Node-RED Though if you really wanted to, integration with 433MHz systems isn't hard at all.
Then perhaps it's time to start learning Android programming. I don't think that node-red itself can help here.
Though I am certain a tasker or ittt solution is possible (I.e. to launch and kill a tracking app). Especially coupled with one of the things we already mentioned.