Skip to content

Simple tool that runs in the background to warn you about your wireless Razer products battery level

License

Notifications You must be signed in to change notification settings

Elehiggle/SimpleRazerBatteryNotification

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GitHub Repo stars GitHub Actions Workflow StatusGitHub last commit Codacy Badge GitHub License

Simple Razer Battery Notification

This is a very simple tool that runs in the background and notifies you via a tray notification and beeps when your Razer mouse/keyboard battery is low (and possibly other devices that are listed via Razer Synapse 3).

Features

  • Checks battery level of the Razer device and notifies you when it is low
  • If you lock your PC, it will notify you at a higher battery percentage so you can prepare earlier

Prerequisites

  • Python >=3.9 or just download the precompiled Windows executable file
  • It uses the Razer Synapse 3 tool which always runs in the background and writes log files. This simple tool watches the log files for battery status changes.

Installation

SIMPLE USAGE: Skip to the Usage via Windows binary section if you want to use the precompiled Windows executable file

  1. Clone the repository:

    git clone https://github.com/Elehiggle/SimpleRazerBatteryNotification.git
    cd SimpleRazerBatteryNotification
  2. Install the required dependencies:

    pip3 install -r requirements.txt

    or alternatively:

    python3 -m pip install Windows-Toasts file-read-backwards
  3. Set the following environment variables with your own values:

Parameter Description
BATTERY_LEVEL_ALERT_THRESHOLD Battery % where you would like to get notified. Default: "5"
BATTERY_LEVEL_ALERT_THRESHOLD_LOCKED Battery % where you would like to get notified when you lock your PC. Default: "30"

Usage via script

Run the script:

python3 main.py

Usage via Windows binary

Simply run the executable file which you can download here (attention: Windows SmartScreen defender may raise an alert, this is normal since this is an unknown tool). It will silently run in the background and notify you when your Razer device battery is low via notifications and beeps at certain thresholds. Copy the file into your startup folder at %APPDATA%\Microsoft\Windows\Start Menu\Programs\Startup to run it automatically on startup. It will use the default variables (5% and 30% for when the PC is locked)

Known Issues

This tool was only meant for private use for my Razer Viper V2 Pro wireless mouse. It may not work if you have multiple wireless Razer devices. In this case, let me know, and I may fix it

Contributing

Contributions are welcome! If you find any issues or have suggestions for improvements, please open an issue or submit a pull request.

License

This project is licensed under the MIT License.

About

Simple tool that runs in the background to warn you about your wireless Razer products battery level

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages