Use Bluetooth module to detect presence of unpaired device?

As an additional safety feature, I want to be able to shut down a 30mW laser diode if anyone gets close to it. One thought I had was that technicians approaching the device could set their cell phone to pairing mode If a Bluetooth module could detect the presence of a pairing request and signal the Arduino, that should work. However, I can find only information on using Arduino with an already-paired Bluetooth Serial device. Anyone know if a Bluetooth module that can be used this way exists? Thanks.

(I will probably also implement remote shutdown using a keyfob type RC device like the 315MHz transmitter/receiver sold by Adafruit, but it would be nice to have something less likely to be lost as a backup, even though Bluetooth's range is so much less.)

You can use HC-05 bluetooth module to pair device

Thank you. My hope is to be able to detect any unpaired device so that anyone with a BT-enabled phone could deactivate this project just by getting within range, even if their phone had never been near it before.

@ davidhbrown:

I personally had many many project requiring the use of bluetooth module such as HC-05 and HC-06. In my opinion the pairing isn't your problem, because the Bluetooth module will only connect with one bluetooth device at a time. Let say if a device get unpair, the module will automatically set itself discoverable and another phone could pair with the module, thus allowing for control access.

What you really need to be concentrating on is how does a device communicate with the arduino in such a way that the arduino will understand what is ask of it.

so maybe you could limit yourself to using only Android phone for now, and later on maybe IOS devices and later on write a GUI that work in a cross platform PC.

I personally had gone through the step and its a nice experience which a allow a user to control a device using a simple guy.

Thank you also.

What I was hoping for was something like how when I look at the BT control panel on my notebook while waiting at an airport, I might see a dozen BT devices around me, none of which have actually paired with my computer. If I were instead in the middle of a corn field, I wouldn't see any. With this device literally in the middle of a corn field, seeing any BT devices would be a signal to shut down for safety.

Indeed, though I haven't see anything even looking at the command mode options that would allow the current BT modules to do this.

I may set things up to use a BT serial module for configuration instead of requiring a USB connection. The way the BT module works -- when trying to use it as designed -- is indeed pretty slick.

@ davidhbrown:

Maybe you could use the HC-05/06 AT command to get those information. A quick glance of the data sheet suggest to me that it is possible.

I think it would be something along the line as

Arduino talk to HC-05/06 asking for list of available BT device in the surrounding area,

HC-05/06 give Arduino the list

compare the list with known paired device

if there is any BT device that is not in the list, Arduino shut the device off ( the laser device ).

so yes I do think you could get the functionality that you wanted.


A quick google of HC-05 data sheet had lead me to the link below:

< HC-05/06 AT command Data Sheet >

if you scroll down and you will find ( 30. Inquire Bluetooth device ),

this is what you want… a list of available BT device in the area.

well hopes that answer your question