Skip to main content

Bluetooth proximity automation

Project description

Overview

BlueDo - Bluetooth proximity automation

Logo

Lock your desktop, mute music or run any other command when leaving your PC. There are dozens of apps like this. This one just aims to make it beautiful, modern and easy.

Not all bluetooth devices works for this, so some trial and error may be needed.

Maturity

Beta

Installation

From pip

sudo apt install python3-pip libbluetooth-dev playerctl libgirepository1.0-dev libcairo2-dev gir1.2-appindicator3-0.1
pip3 install --upgrade bluedo

From deb

Fetch deb file from https://github.com/ways/BlueDo/releases

Requirements

Use these system commands:

  • bluetoothctl
  • hcitool
  • loginctl
  • gsettings
  • amixer (if using mute)
  • playerctl (if using pause)

Version > 2.0 is only tested on Ubuntu 22.04 with GNOME. Version < 2.0 is only tested on Ubuntu 20.04-21.04 with GNOME.

Command line options

  • -e / --enable to start service on app start.
  • -m / --minimize to start minimized

Configuration

There are lots more options in the config file. Feel free to tune.

Screenshots

v53 v49 v49_advanced v3_2 v3

System changes

Note that this app will make these changes to your power management:

  • Enable screen lock: org.gnome.desktop.screensaver lock-enabled true
  • Set delay from screen blacking to locking to zero: org.gnome.desktop.screensaver lock-delay 0
  • Set screen saver timeout to 10 seconds when device is away, 5 minutes when device is present: org.gnome.desktop.session idle-delay 600

TODO

  • Check for dependencies on startup
  • Default lock / unlock ON.
  • Keep two instances from running at the same time.
  • Minimize to tray, instead of having both minimize and minimize to tray.
  • Stop device scanning when minimized
  • Change to dynamic widget layout instead of fixed.
  • Change preferences button to proper burger menu.
  • Move media files to some other dir?
  • Unit tests
  • When on xfce:
    • for bluetooth settings, open blueman-manager
    • to lock/unlock change xscreensaver timeout, to match functionality from gnome

Development docs

  • scan for devices: bluetoothctl devices

  • rssi for device: hcitool rssi ff:ff:ff:ff:ff:ff (unstable)

  • Version below .56 needs Python < 3.9, bluetoothctl ~5.50 or newer.

  • hard locking: lock when no signal

  • soft locking: set screensaver timeout to 10 seconds when no signal

Inspiration

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bluedo-2.0.tar.gz (302.7 kB view details)

Uploaded Source

Built Distributions

bluedo-2.0-py3.10.egg (297.7 kB view details)

Uploaded Source

bluedo-2.0-py3-none-any.whl (299.5 kB view details)

Uploaded Python 3

File details

Details for the file bluedo-2.0.tar.gz.

File metadata

  • Download URL: bluedo-2.0.tar.gz
  • Upload date:
  • Size: 302.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.6

File hashes

Hashes for bluedo-2.0.tar.gz
Algorithm Hash digest
SHA256 c88fdf30de869f61a7def746a8a96ae6c147d215f21c3657f959eb5c9cca202e
MD5 a2e02944eb71e32fee2078dbb35b60a4
BLAKE2b-256 605422bfa0f20188ec52f08df88f88f34e82c32f3169bd6e0aff989e41054fbd

See more details on using hashes here.

File details

Details for the file bluedo-2.0-py3.10.egg.

File metadata

  • Download URL: bluedo-2.0-py3.10.egg
  • Upload date:
  • Size: 297.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.6

File hashes

Hashes for bluedo-2.0-py3.10.egg
Algorithm Hash digest
SHA256 35783f3da1747243f8a1322318adc7598c0f75f7b3ae86409363b85e579b788b
MD5 f85fdca0887567d8f5a94a01b06bea91
BLAKE2b-256 5886fb00288a936bfd74fca4419047a1ed3a4073c974057a7656150f9a2f4571

See more details on using hashes here.

File details

Details for the file bluedo-2.0-py3-none-any.whl.

File metadata

  • Download URL: bluedo-2.0-py3-none-any.whl
  • Upload date:
  • Size: 299.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.6

File hashes

Hashes for bluedo-2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 3dc4dc8c99fa9a2f17e7977bfa6049fb4fe1913ba7ed53938b5dfbde69199495
MD5 cb22decc1516da55abbdfc37a14c8ca8
BLAKE2b-256 3fb96162acfa8815134c77d3156c4af91e921208b063583b622ac2b4c14c532d

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page