This is a custom integration for Home Assistant that allows you to control and monitor your cryptocurrency miners running Braiins OS+. It connects directly to your miner's local API, providing advanced tuning controls and detailed telemetry.
- Local Control: Connects directly to your miner via its local IP address. No cloud services are required.
- Detailed Monitoring: Provides sensor entities for key metrics with a rapid 5-second update interval.
- Total hashrate (TH/s).
- Real-time power consumption (W) and energy efficiency (J/TH).
- Highest chip and board temperatures.
- Per-hashboard hashrate, chip temperature, and board temperature.
- Per-hashboard enabled state and per-pool enabled/alive/active state.
- Monitor RPM and Target Speed (%) for every fan detected.
- Simple Controls: Provides button entities to perform key actions:
- Pause and Resume mining operations.
- Increment and Decrement the power target.
- Start, Stop, and Restart BOSminer, plus reboot the device.
- Fine-tune how much the increment/decrement buttons change your targets via dedicated configuration entities.
- Direct Braiins Diagnostics:
- API heartbeat status (whether the last refresh succeeded).
- Public API version, current miner errors, tuner state, efficiency profile diagnostics, pool diagnostics, and locate LED state.
- Tuner Management:
- Set specific Power Targets (Watts) or Hashrate Targets (TH/s).
- Dynamic slider limits: Sliders automatically adjust their min/max range based on your specific miner's hardware constraints.
- Robust Authentication: Automatically handles the renewal of authentication tokens to ensure the connection is always active.
- A miner running a recent version of Braiins OS+.
- Home Assistant (Version 2023.11.0 or newer).
- HACS (Home Assistant Community Store) installed and running.
This integration is best installed via HACS.
- Navigate to the HACS section in your Home Assistant.
- Go to "Integrations", then click the three-dots menu in the top right and select "Custom repositories".
- Paste the following URL into the "Repository" field:
https://github.com/aleixps/Braiins-OS-HA - Select "Integration" as the category.
- Click "Add".
- The "Braiins OS+" integration will now be available in HACS. Find it and click "Install".
- Restart Home Assistant after the installation is complete.
- Go to the latest release page of this repository.
- Download the
braiins_os_plus.zipfile. - Unzip the file.
- Copy the
braiins_os_plusdirectory into your Home Assistantconfig/custom_components/directory. - Restart Home Assistant.
Once installed, you can add and configure the integration through the Home Assistant UI.
- Go to Settings > Devices & Services.
- Click the "+ Add Integration" button in the bottom right.
- Search for "Braiins OS+".
- In the configuration dialog, enter the following details:
- Miner IP: The local IP address of your miner.
- Username: The username for your miner's web interface.
- Password: The password for your miner.
- Click "Submit".
The integration will log in and create a new device with all associated entities.
| Entity ID | Description |
|---|---|
number.power_target |
Set specific power draw in Watts. Limits are dynamic per model. |
number.hashrate_target |
Set specific hashrate target in TH/s. |
number.power_adjustment_step |
Config: Set how many Watts buttons change (e.g., 100W, 250W). |
number.hashrate_adjustment_step |
Config: Set how many TH/s buttons change (e.g., 1.0, 5.0). |
button.increment_power_target |
Increases Power Target by the configured step. |
button.decrement_power_target |
Decreases Power Target by the configured step. |
button.increment_hashrate_target |
Increases Hashrate Target by the configured step. |
button.decrement_hashrate_target |
Decreases Hashrate Target by the configured step. |
button.pause_miner |
Pauses mining operations. |
button.resume_miner |
Resumes mining operations. |
button.start_bosminer |
Starts the BOSminer process. |
button.stop_bosminer |
Stops the BOSminer process. |
button.restart_bosminer |
Restarts the BOSminer process. |
button.reboot_device |
Reboots the miner device. |
switch.device_locate_led_blinking |
Turns the miner locate LED blinking state on or off. |
| Sensor | Description | Unit |
|---|---|---|
| Total Hashrate | Combined real-time hashrate of all boards. | TH/s |
| Miner Consumption | Real-time power draw from the wall. | W |
| Miner Efficiency | Real-time efficiency (reports 0.0 when paused). | J/TH |
| Chip Temperature | The highest chip temperature reported by cooling system. | °C |
| Board Temperature | Calculated highest surface temperature among all boards. | °C |
| Fan Speed | Actual RPM for each individual fan. | RPM |
| Fan Target Speed | The duty cycle percentage for each fan. | % |
| API Version | Braiins OS Public API version reported by the miner. | - |
| Miner Error Count | Number of current miner errors; raw error list is exposed as attributes. | count |
| Tuner State | Overall Braiins tuner state as a readable label such as stable or tuning. |
- |
| Efficiency Profile Points | Number of efficiency profile points exposed by Braiins. | count |
| Efficiency Profile Min/Max Power Target | Lowest and highest power targets present in the efficiency profile. | W |
| Efficiency Profile Min/Max Hashrate | Lowest and highest hashrates present in the efficiency profile. | TH/s |
| Pool Groups | Number of configured pool groups. | count |
| Pool Count | Number of configured pools. | count |
| Pool Active | URL of the currently active pool. | - |
| Binary Sensor | Description |
|---|---|
| API Heartbeat | On when the last coordinator/API refresh succeeded; off when the integration cannot currently poll the miner. |
| Hashboard N Enabled | One binary sensor per hashboard, using the direct Braiins enabled flag for that board. |
| Pool N Enabled | One binary sensor per configured pool, showing whether Braiins marks that pool as enabled. |
| Pool N Alive | One binary sensor per configured pool, showing whether Braiins reports that pool as reachable/alive. |
| Pool N Active | One binary sensor per configured pool, showing whether Braiins currently uses that pool. |
Notes:
- Per-hashboard means the integration creates one entity for each hashboard reported by the miner.
- Per-pool means the integration creates one set of pool state entities for each pool configured in Braiins.
Per-hashboard sensors for hashrate and temperature are also created automatically, alongside hashboard enabled binary sensors.
To track total energy consumption for the Home Assistant Energy Dashboard:
- Go to Settings > Devices & Services > Helpers.
- Create a "Riemann sum integral sensor".
- Input sensor:
sensor.miner_consumption. - Metric prefix:
k(kilo). - Unit of time:
Hours. - Use the resulting entity in your Energy Dashboard.
This integration was developed with the assistance of Artificial Intelligence tools.
Contributions and bug reports are welcome! Check the issues page to get involved.
This project is licensed under the MIT License. See the LICENSE file for details.