Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Space Heater Thermostat Control - Exergy HA Blueprint

Control your bitcoin miner like a traditional space heater with thermostatic temperature control.

Before You Start

How It Works

This automation turns your miner on and off based on room temperature:

  1. Temperature drops below target → Miner turns ON
  2. Temperature rises above target → Miner turns OFF
  3. Repeat to maintain desired temperature

Just like a space heater with a thermostat, but earning bitcoin while heating.

Automation Installation

To use the YAML automation examples in this guide:

  1. Copy the desired YAML code from the examples below
  2. In Home Assistant, navigate to Settings → Automations & Scenes
  3. Click the three-dot menu (⋮) in the top right corner
  4. Select Edit in YAML
  5. Paste the copied YAML code at the bottom of your automations file
  6. Adjust the entity_id values to match your specific miner entities
  7. Click Save
  8. The new automation(s) will appear in your automations list

Alternatively, you can create each automation through the UI and manually configure the triggers, conditions, and actions based on the examples.

Configuration

Required Inputs

InputDescription
Miner EntityYour miner’s power switch (e.g., switch.avalon_mini_3_power)
Temperature SensorRoom temperature sensor (e.g., sensor.living_room_temperature)
Target TemperatureDesired room temperature

Note: This example uses the Avalon Mini 3 onboard input or ambient temperature sensors for reporting to the thermostat. You could instead use a different temperature sensor in the room such as a Zigbee Temperature sensor.

Optional Inputs

InputDefaultDescription
Hysteresis1.0°FTemperature band to prevent rapid cycling
Minimum On Time5 minPrevent short cycles
Minimum Off Time5 minAllow miner to cool down

Understanding Hysteresis

Hysteresis prevents the miner from rapidly turning on and off:

Example with 70°F target temperature and 1°F hysteresis:

  • Miner turns ON when temp drops to 69°F
    • This is the Cold Tolerance reference below
  • Miner turns OFF when temp rises to 71°F
    • This is the Hot Tolerance reference below
  • 2°F total swing (target ± hysteresis)

Increase hysteresis for longer, less frequent cycles. Decrease for tighter temperature control.

Creating a Climate Helper

The recommended approach is to create a Generic Thermostat climate entity that controls your miner. This gives you a native thermostat interface in Home Assistant.

Method 1: GUI Configuration

  1. Navigate to Settings → Devices & Services → Helpers
  2. Click + Create Helper
  3. Select Generic Thermostat
  4. Configure the following:
SettingValueDescription
NameExergy OfficeName for your thermostat
Heaterswitch.exergy_office_mini_3_powerYour miner’s power switch
Target Sensorsensor.exergy_office_sensor_temperatureRoom temperature sensor
Min Temp60Minimum temperature setting
Max Temp80Maximum temperature setting
Target Temp70Default target temperature (this is editable from the dashboard after being deployed)
Cold Tolerance1How far below target before turning on
Hot Tolerance1How far above target before turning off
Min Cycle Duration10 secondsMinimum time heater stays in one state
  1. Click Create

Method 2: YAML Configuration

Add this to your configuration.yaml file:

climate:
  - platform: generic_thermostat
    name: Exergy Office
    heater: switch.exergy_office_mini_3_power #Your Miner Power Switch
    target_sensor: sensor.exergy_office_mini_3_ambient_temperature #Or use an external sensor like: sensor.exergy_office_sensor_temperature
    min_temp: 60 #Set the lowest temp you'll allow this thermostat to be set
    max_temp: 80 #Set the highest temp you'll allow this thermostat to be set 
    ac_mode: false
    target_temp: 70 #Default starting temp
    cold_tolerance: 1
    hot_tolerance: 1
    min_cycle_duration:
      seconds: 10
    keep_alive:
      minutes: 3
    initial_hvac_mode: "heat" #Thermostat defaults to heating mode, can also be set to off
    precision: 0.5 #Amout you want to be able to set the thermostat. 0.5 = 70,70.5,80, etc.

After adding the YAML configuration:

  1. Go to Developer Tools → YAML
  2. Click Check Configuration
  3. If valid, click Restart under Server Controls

Understanding the Parameters

ParameterDescription
heaterThe switch entity that controls your miner
target_sensorTemperature sensor that measures room temperature
cold_toleranceTemperature drops this much below target before turning ON
hot_toleranceTemperature rises this much above target before turning OFF
min_cycle_durationPrevents rapid on/off cycling
keep_aliveSends periodic updates to the heater switch
initial_hvac_modeMode when Home Assistant starts (“heat” or “off”)
precisionTemperature adjustment increment (0.5 or 1.0)

Example: 70°F Target with 1° Tolerance

  • Miner turns ON when temperature drops to 69°F (70 - 1)
  • Miner turns OFF when temperature rises to 71°F (70 + 1)
  • Total swing: 2°F

Tips

External Sensor Placement

  • Place temperature sensor at “living height” (3-5 feet)
  • Keep away from direct miner exhaust
  • Avoid windows, exterior walls, or direct sunlight

Multiple Rooms

  • Create separate automations for each room/miner pair
  • Each automation tracks its own temperature sensor

Work Mode Considerations

  • Heating Mode: Full power, maximum heat output
  • Eco Mode: Reduced power, may not reach target temperature
  • Night Mode: Quieter but less heat

Consider automations that adjust work mode based on time of day.

Troubleshooting

Miner cycling too frequently

  • Increase hysteresis value
  • Increase minimum on/off times
  • Check sensor placement (may be too close to miner)

Room never reaches target temperature

  • Miner may not have enough heat output for space
  • Check for drafts or heat loss
  • Consider running in higher power mode

Temperature overshoots

  • Miner continues heating during shutdown
  • Increase hysteresis slightly
  • Normal behavior - mining hardware retains heat

Dashboard Integration

See Space Heater Digital Thermostat for a matching dashboard to control this automation visually.

Resources