This is a simple script to read battery levels from a usb wireless mouse, Attackshark X11 on linux.
git clone https://github.com/daviirodrig/attackshark.git
cd attacksharkIt’s recommended to use a virtual environment:
python3 -m venv venv
source venv/bin/activate
pip install -r requirements.txtMany scripts in this repo use hardcoded or example paths.
Update all relevant file paths in the scripts to match your environment before running.
- Check for path variables at the top of each script.
- Review any references to input/output directories or resources.
This project uses systemd for managing background services.
To enable services:
- Copy the
.servicefiles to your systemd directory, for example:sudo cp systemd/*.service /etc/systemd/system/ - Edit the
.servicefiles as needed (e.g. updateExecStartpaths). - Reload systemd and enable/start the services:
sudo systemctl daemon-reload sudo systemctl enable <service-name>.service sudo systemctl start <service-name>.service
After configuring, run scripts manually or let systemd manage them as background services.
- This repo is meant to be adapted—edit scripts and service files to fit your specific setup.
- Double-check permissions and environment variables.
- For troubleshooting, check logs in your systemd journal and Python error traces.