IoT Cat Door using a Raspberry Pi 3, Node-Red and BLE tracking tags!
The goal of this project is to build an IoT style motorized pet door so we can control which animals can come into the house. For this we are using BLE tags attached to the animals (cats) and the built-in Bluetooth module on the Raspberry Pi 3 which scans for the tags. We also have some indicator LEDs on the Raspberry Pi 3 for troubleshooting what state the door is supposed to be in.
The Node-RED BLE Scan node continuously scans for BLE advertisements. If it sees one that matches the device name and minimum RSSI it will open the pet door, and after a timeout period it will close the door. In order to prevent the door from closing prematurely on a slow-moving animal, the system will reset the timer whenever it gets a BLE match.
This project has a couple different areas to it: the hardware, which is all the wiring and components necessary for manipulating the door, and the software which is all the logic for deciding which direction the door should move.”

Link