Hi all. Anyone seen a module that uses your mobile as a key ?? Like a Tesla, as long as you have your mobile with you the car will start ?? I dont want to have to open an app, then hit the “ GO” button, use BT, or NFC maybe, so a long as the phone is in range, a switch becomes active.
Thanks !
1 Like
What sort of range ?
NFC tends to only be maybe 50mm or less. How this works will likely depend on your phone and the controll it it let you have over the NFC chips.
I could see BT working with a “Paired” device. just like your phone auto connects to the car kit when within range.
While I have not yet played with BT etc, I suspect you can just use something like and ESP32 with BT enabled to paired to your phone ???
1 Like
Hi Michael, range is a metre max. There are modules available but all have either a remote or the need to open an app to control things. I imagine this would be popular if available. Mark
1 Like
Maybe, I think think there are a bit too many issues around security.
At work, some of our contracts prohibit any users involved in the project to have bluetooth enabled and any device (inc phones). BT is always recommened to be left turned off when not being used for “securty” reasons. As such I suspect there are still too many issues.
That aside, its still a cool idea for a project.
I cant really see NFC working on “any” device. From friends that work on NFC on phones, they talk a lot about what an Apple can/cant do v Android, b Jail broken. As such, you will be limited to what ever the API exposes for you to use.
Having a Play with BT on the ESP32 is on my list (just not got to it yet). But I could see if you can make a device where the phone is allowed to connect to it. Then, in theory it should auto connect each time its within range. Then that end device would see “Look: Bobs phone has connected… take some action”
This of course does not rule out using Cards/Tags for near field comms.
e.g. any 14a RFID can support a basic UID select. 15xxxx tags have longer range (but still limited to about 50-100mm)
1 Like
Thanks Michael, a lot of info for me !
1 Like
I had a play last night just using pre-made demos and Got a very based BTLE app on an esp32 and the phone could interact with it… BUT the phone did not auto connect. So we need something where the phone what’s to “talk” to it by default (as your use case is to use your phone as a proximity trigger)
Do you have any security things to consider, or can we just trigger based on if the phones BT MAC address is seen ?
EDIT: Im just learning as I go.
This morning I got a demo HID “keyboard” App running on an ESP32.
That then appeared on a BT Scan on my phone, and I could “pair” to it. (no security around the pairing, just a simple pair).
I removed the HID demo events, as it was sending commands to increase and decrease my phones volume, so I stopped those from getting sent.
If I turn off my phones BT then back on, it auto connects to the ESP32 BT HID service.
So I think that is the framework for using a phone as a proximity to make something happen.
Of Couse, this is just me playing and real world tests would need to happen on actual devices intended to be used.
Hi Michael, missed your questions !
The intention here is to do like a keyless entry for a vehicle. Not too worried about security, using the BT MAC would be good !
1 Like
As per my last post, I can see how using something like a very simple ESP32 (or something else that supports BT) as a HID device.
I just used the HID demo for the ESP32.
I paired that with my phone, so now my phone will auto connect when ever it sees it.
there is a “phone” ID/Mac that is reported when the phone connects, so you can use that as a filter (with some better code you could have a “learn” mode and “run” mode only allowing new pairing during learn mode and then only allowing learnt addresses during run mode.
My phone and ESP work over a fairly long distance, so maybe using the RSSI to see how close the phone is and use that to reduce the distance could work.
Since you said you are not too concerned with security, the above should be enough.
So as a proof of concept it seems to do what you want.
ESP32 BT/BTLE as HID device. Manage “pairing” and maybe use RSSI for closer proximity.
1 Like
Hey Mark,
Welcome Back!
It is an interesting idea and I am sure it would have some great use cases. As mentioned, RFID/NFC does not have a great range, though is already in use in most Tesla’s. I did manage to track down a great breakdown of the protocol on this Github Repo.
As far as Bluetooth pairing and using a HID action to accomplish this, I have found a bunch of talk on HID in Tesla Vehicles and it seems the HID input was patched out in a software update a little while ago. I keep seeing the mention of HW 4.5 specifically as being the patch there.
You could look at using both Ideas, though. An ESP32 looking for that Bluetooth signal to connect and get close, where it activates a Dynamic Tag on the sensor nearby, could just be a great solution. It wouldn’t affect any entry mechanics outside of a while-in-use basis.
Cheers,
Blayden
1 Like
Thanks so much Blayden. !
1 Like
Thanks again Michael.Looks like a solution. I get the idea that this sort of mechanism as a “Key” would have many uses. 
1 Like