Add Linux support with application mute handling and startup script

This commit is contained in:
Robert Chery
2026-07-08 21:28:21 -04:00
parent 4b45c031e0
commit 5ff2e15571
3 changed files with 99 additions and 7 deletions

View File

@@ -27,10 +27,40 @@ The architecture consists of three main components:
## Starting the Server
There are a couple of ways to launch the software depending on your needs:
There are a few ways to launch the software depending on your needs:
- **Interactive Mode (`Start-Macropad.bat`)**: Starts the Node.js server, displays the console output, and automatically opens your default web browser to the `http://localhost:3001` configuration page.
- **Background Mode (`Run-Hidden.vbs`)**: Silently launches the Node server in the background without opening a visible command prompt window. This is ideal for adding to your Windows Startup folder for seamless background operation.
- **Interactive Mode (Windows) (`Start-Macropad.bat`)**: Starts the Node.js server, displays the console output, and automatically opens your default web browser to the `http://localhost:3001` configuration page.
- **Background Mode (Windows) (`Run-Hidden.vbs`)**: Silently launches the Node server in the background without opening a visible command prompt window. This is ideal for adding to your Windows Startup folder for seamless background operation.
- **Linux Mode (`start-macropad.sh`)**: Starts the Node.js server and automatically opens the configuration page in your default browser.
---
## Linux Installation & Prerequisites
To run the application on Linux (e.g., Ubuntu/Debian), perform the following configuration steps:
### 1. Serial Port Permissions
By default, Linux limits access to serial devices (like `/dev/ttyACM0`). Give your user account permission to access the Pico serial port by running:
```bash
sudo usermod -a -G dialout $USER
```
*Note: You must log out and log back in (or reboot) for this change to take effect.*
### 2. Keyboard Simulation Dependencies (`nut-js`)
The keyboard simulation library requires the development header for `libXtst` and requires an **X11 / XWayland** environment (native Wayland will block synthetic input):
```bash
sudo apt-get update
sudo apt-get install libxtst-dev
```
### 3. Launching
Make the script executable and run it:
```bash
chmod +x start-macropad.sh
./start-macropad.sh
```
---
## Configuration