Bluetooth AT commands

I want my HC05 module to scan the Bluetooth addresses of the smartphones around, and while doing so take an action(say, blink an LED) only after some specified Bluetooth address(es) which it has paired up with connects to the Bluetooth module. how do i do that? AT commands is what I have been thinking, but I apparently do not know much that part since I have not used it. can someone guide me through this problem?