Lock/unlock your elementary computer based on proximity of bluetooth device (e.g. your phone or tablet).
This works for me under elementary OS 0.3 Freya.
- First step is to pair your device with your computer.
- Then get the devices address from System Settings > Bluetooth, or by running
bluez-test-device list
in the terminal. - Then configure the script to run in the background at system startup (TODO)
Here's how it works:
- The script pings the bluetooth device.
- When the device moves out of range of the computer, the pings fail and the screen will lock.
- Once the device is out of range, the script pings every second attempting to find the device again.
- As soon as it pings successfully (you're back in range) the screen will automatically unlock again (WIP).
- Fix slow locking on Freya.
- Fix unlocking not switching to mainscreen.
- Ignore locking attempts for separate duration after unlock.
- FOR RELEASE: Rewrite in Vala.
- FOR RELEASE: Implement plug patch for bluetooth locking in
Security & Privacy
>Locking