by Marius Șucan
Wakes the phone when the proximity sensor detects activity.
It is made as much as possible to be lightweight and easy-to-use. The script uses "when" events.
The flow can be switched on / off by a simple home screen icon/shortcut.
It works with "Doze" power save mode.
Updated on 6th of March 2017. You are no longer forced to quickly unlock the device. The screen will be kept on as long as you keep interacting with the device.
Improvements upon Proximity awake flow by Arkadeep Saha.