---
title: "MiniHPC Heat Pump Controller"
description: "MiniHPC air-to-water heat pump controller over MQTT: mode, water and DHW setpoints, defrost, power limit, temperatures, energy. Needs a local MQTT broker."
url: "https://taphome.com/en/compatibility/minihpc/"
language: en
lastmod: 2026-11-12
generator: hugo
ai:
  topics: ["mqtt","heat-pump","air-to-water","hvac","domestic-hot-water","wifi","energy-monitoring"]
  questions: ["How to integrate a MiniHPC heat pump controller with TapHome?","What does the MiniHPC TapHome template control and measure?","How to connect MiniHPC to TapHome via an MQTT broker?","Why does MiniHPC ignore setting changes sent from TapHome over MQTT?","Why do some MiniHPC values stay empty in TapHome after a restart?","How often must an external T1 or outdoor temperature be sent to MiniHPC?"]
---

# MiniHPC Heat Pump Controller

Communication: Packet Parser → MQTT

> Network address
> 
> With the MQTT broker built into TapHome, enter `127.0.0.1` as the broker address in TapHome. In the device, enter the IP address of the TapHome Core and give the Core an IP reservation in the router.
> 
> [Network Preparation](https://taphome.com/en/docs/setup/network-preparation/)

## Integration guide

MiniHPC is a DIY heat pump controller from the Slovak manufacturer MiniHPC. Installed between the outdoor unit of an ordinary split air conditioner and a water circuit, it turns the outdoor unit into an air-to-water heat pump for space heating, cooling and domestic hot water (DHW). The controller drives the circulation pump, the three-way valves and the electric backup heaters through its own relays and measures the water, refrigerant and room temperatures with NTC sensors.

TapHome talks to MiniHPC over MQTT. Both connect to the same MQTT broker in the local network (for example Mosquitto): MiniHPC publishes its measurements and configuration to the broker and accepts setting changes and commands from it. This community template reads the operating data and lets TapHome switch the operating mode, change the water and DHW setpoints, start DHW heating and defrosting, limit the power and send external sensor values to the controller.

## Hardware connection

> [!WARNING]
> MiniHPC works with mains voltage and is connected to the refrigerant circuit of the outdoor unit. Wiring must be done by a qualified electrician and, for the refrigerant side, a qualified refrigeration technician.

### Mounting

- MiniHPC is mounted on a DIN rail in a distribution board at least **9 modules** wide, ideally as close as possible to the heat exchanger — the supplied NTC sensors and the flow sensor have 3 m cables.
- If the board holds other devices (circuit breakers, relays, energy meters), place MiniHPC at the **far right**, with nothing to its right. The Wi-Fi antenna sits in its upper right corner and nearby devices could interfere with it.
- Route the power cables separately from the low-voltage cables of the NTC sensors and the flow sensor.
- The controller has no mains switch of its own. The installer must add an easily accessible all-pole disconnecting device (for example a two-pole circuit breaker or switch disconnecting L and N) to the fixed installation in the board.

### Wiring diagram

![MiniHPC electrical connection diagram: controller terminals R1-R5, S1-S2, outdoor unit and NTC sensors T1-T6.](https://taphome.com/images/compatibility/minihpc/wiring-electrical_hu_eb6b9080a4489af1.jpg)

The **Outdoor** terminal block of MiniHPC (N, communication, L, PE) is wired to terminals 1, 2, 3 and PE of the outdoor unit (N + communication + L + PE) with a cable of at least 4 × 0.75 mm². The controller is powered through this terminal, and so are the loads on R3, R4 and R5, which share a common 3 A fuse.

| Terminal | Type | Primary function | Alternative function |
|----------|------|------------------|----------------------|
| T1 | NTC 10 kΩ input | Indoor air temperature | Can be replaced by a Bluetooth sensor |
| T2 | NTC 10 kΩ input | Heating water entering the heat exchanger | — |
| T3 | NTC 10 kΩ input | Heated water leaving the heat exchanger | — |
| T4 | NTC 10 kΩ input | Heating water after the electric backup heater | — |
| T5 | NTC 10 kΩ input | Water in the DHW tank | — |
| T6 | NTC 10 kΩ input | Liquid refrigerant pipe (1/4" pipe, bottom left of the heat exchanger) | — |
| I1 | 5 V pulse input | Heating water flow sensor | — |
| R1 | 230 V relay, 10 A | Electric heater in the DHW tank | Outdoor unit base heater |
| R2 | 230 V relay, 10 A | Electric backup heater of the heating water | Outdoor unit base heater |
| R3 | 230 V, switched phase + N + PE | Circulation pump of the heating circuit | — |
| R4 | 230 V, switched phase + L + N + PE | Three-way valve DHW / heating | Outdoor unit base heater |
| R5 | 230 V, switched phase + L + N + PE | Three-way valve ceiling cooling / heating | Outdoor unit base heater |
| S1 | Potential-free input | Flow switch of the heating circuit | External energy meter with S0 output |
| S2 | Potential-free input | External on/off wired thermostat | External energy meter with S0 output |

- **T6 is mandatory.** T2 or T3 is mandatory when that sensor is used for temperature control, and T5 is mandatory when DHW heating is on. Tape T2, T3, T4 and T6 to the pipe with aluminium tape and insulate them.
- **T1** belongs indoors, away from heat sources such as a fireplace, direct sunlight or a stove. It can be replaced by a Xiaomi Mijia LYWSD03MMC Bluetooth temperature and humidity sensor running the alternative ATC firmware.
- **I1** is set by default to 476 pulses per litre (YF-B10 sensor); the value is changed in the flow meter calibration menu (7.3) for another sensor type.
- **R1 and R2** carry 10 A. A heater drawing more current must be switched through an external auxiliary relay or contactor. The R2 backup heater is off by default.
- **R4 and R5** have four terminals: N, L4/L5, L and PE. L is permanently live and L4/L5 is switched. Valves with a single-phase SPST actuator connect directly; valves with an SPDT actuator (two phase inputs) need an auxiliary changeover relay between the output and the valve.
- **S1 and S2** are for potential-free contacts or transistor (S0) outputs of energy meters only.

> [!WARNING]
> Never connect any voltage source to the S1 and S2 inputs.

### Hydraulic diagram

![MiniHPC hydraulic connection diagram of the heating circuit with plate heat exchanger, pump and three-way valves.](https://taphome.com/images/compatibility/minihpc/hydraulic-heating_hu_deb3a69f7625566c.jpg)

The diagram shows where the sensors and outputs sit in the water circuit: T2 and T3 at the inlet and outlet of the plate heat exchanger, T6 on the refrigerant pipe, the flow sensor (S1/I1) and the R3 pump in the return, R5 switching to the ceiling cooling, R2 as the electric backup heater with T4 behind it, R4 switching to the DHW tank with the R1 heater and T5 inside.

## Configuration

### Connecting MiniHPC to the local network

1. Connect MiniHPC to the home Wi-Fi network following menu **9.2 WiFi AP** in the manufacturer's manual. Once connected, a white Wi-Fi icon appears next to the clock in the upper right corner of the display.
2. Read the controller's IP address in menu **9.1 WiFi station**. The address is assigned by the DHCP server of the network; only IPv4 is supported. The same menu shows the Wi-Fi signal strength (RSSI) and the MQTT connection state.

### Preparing the MQTT broker

TapHome and MiniHPC need a working MQTT broker in the same local network, for example Mosquitto. Note its IP address and TCP port (usually 1883); they are the only two values the template asks for when it is imported.

### Enabling MQTT on MiniHPC

1. Open the IP address of MiniHPC in a web browser and choose the **MQTT** menu. The page asks for the name and password shown in menu **9.2 WiFi AP** on the controller.
2. Fill in the MQTT settings:

| Setting | Value |
|---------|-------|
| Enable MQTT | On |
| MQTT broker IP | IP address of the broker in the local network |
| MQTT port | TCP port of the broker |
| MQTT user name / MQTT password | Credentials for the broker, if it requires them |
| MQTT Root topic | `miniHPC` — the template listens only on `miniHPC/#` |
| MQTT Birth topic | Optional — any message on this topic makes MiniHPC publish its complete configuration and all data |
| MQTT update interval | How often MiniHPC sends measured data to the broker |

3. On the controller, open menu **9.4 Permissions** and allow **MQTT** under remote control permissions. Without it, MiniHPC ignores everything sent to the `set`, `setns`, `setsensor` and `cmd` topics, so TapHome can read values but cannot change anything.
4. Check menu **9.1 WiFi station**: the MQTT state must show **Connected**.

> [!NOTE]
> The template has the root topic `miniHPC` fixed in its scripts. If several MiniHPC controllers share one broker, the manufacturer requires a unique root topic for each of them — this template then only works with the controller that keeps `miniHPC`.

### MQTT topics used

| Topic | Direction | Use in the template |
|-------|-----------|---------------------|
| `miniHPC/data/#` | MiniHPC publishes | Measured data. A value is sent only when it changes; all values are sent at start-up and after any settings change. |
| `miniHPC/config/#` | MiniHPC publishes | Current configuration (mode, setpoints, power limit) |
| `miniHPC/set/PARAMETER` | TapHome writes | Setting changes, stored permanently in the controller's memory |
| `miniHPC/setsensor/SENSOR` | TapHome writes | External sensor values T1, Tout and RH |
| `miniHPC/cmd/COMMAND` | TapHome writes | Commands: DHW heating and outdoor unit defrost |

> [!WARNING]
> The template writes all settings to `miniHPC/set/`, which saves them to the controller's memory. That memory has a limited number of write cycles. Normal use does not wear it out, but a smart rule that changes setpoints or modes several times a minute should not drive these devices. For such automation the manufacturer provides `miniHPC/setns/`, which applies a change without storing it; this template does not use it.

In TapHome, import the template on the control unit and enter the IP address and port of the MQTT broker (defaults 192.168.0.1 and 1883).

## Device capabilities

The device names in the template are in Slovak; the table lists them as they appear in the TapHome app.

| Device | Name in the template | What it does |
|--------|----------------------|--------------|
| Operating mode | Prevádzkový stav | Switches MiniHPC between Off, Heating and Cooling (Vypnuté / Kúrenie / Chladenie) |
| Heating water setpoint | Vykurovacia teplota vody | Fixed target of the T2/T3 outlet water for heating, 15–55 °C (menu 1.2) |
| Cooling water setpoint | Chladiaca teplota vody | Fixed target of the T2/T3 outlet water for cooling, 10–25 °C (menu 2.2) |
| Room temperature | Izbová teplota | Room temperature from sensor T1 |
| DHW heating on/off | TÚV – zapnutie | Enables or disables DHW heating (menu 3.1) |
| DHW target temperature | TÚV – cieľová teplota | DHW target temperature, 20–80 °C |
| Outdoor unit | Vonkajšia jednotka | Compressor power input in W |
| Heating energy | Energia – kúrenie | Electricity used for heating in kWh |
| Cooling energy | Energia – chladenie | Electricity used for cooling in kWh |
| DHW energy | Energia – TÚV | Electricity used for DHW heating in kWh |
| System temperatures | Teploty systému | Outdoor temperature (Tout) |
| Relays and inputs | Diagnostika – relé a vstupy | State of relay R1 (DHW electric heater) |
| Bluetooth sensor | Bluetooth senzor | Temperature and humidity from the paired Bluetooth sensor |
| System settings | Nastavenia systému | Outdoor unit power limit: no limit, 70 % or 50 % (menu 13.2) |

MiniHPC reports energy in mWh; the template converts it to kWh.

### DHW heating

The **DHW heating on/off** device has four service actions that send commands to `miniHPC/cmd/dhw`:

- **Start DHW heating** (Spustiť TÚV ohrev) and **Stop DHW heating** (Zastaviť TÚV ohrev) — starts heating or stops heating in progress.
- **Anti-legionella heating** (Protilégionelový ohrev) — forces DHW heating to the temperature set in menu 3.3 Anti-legionella.
- **Turbo DHW heating** (Turbo TÚV ohrev) — heats with the compressor and the electric DHW heater at the same time.

### Outdoor unit and energy

Service attributes of the **Outdoor unit** device: compressor state, outdoor unit mode (Cool, Dry, Fan, Heat), compressor frequency (Hz), fan speed (RPM), expansion valve (EEV) position, inverter DC voltage (V), compressor current (A), defrost active and the current heat output of the heat pump (W). The service action **Manual defrost** (Manuálne odmrazovanie) starts defrosting of the outdoor unit.

**Heating energy** also shows the heat produced for heating, and **DHW energy** the heat produced for DHW together with the total compressor running time (h) and total number of compressor starts — these two counters cover the compressor in all modes, not DHW only.

### Temperatures and diagnostics

Service attributes of **System temperatures**: T2 (water entering the heat exchanger), T3 (water leaving it), T4 (after the electric backup heater), T5 (DHW tank), T6 (liquid refrigerant pipe), evaporator temperature (Tsuc), compressor discharge temperature (Texh), the temperature set by the controller and the heating water flow in l/min.

**Relays and inputs** shows R1 as its main state and R2 (electric backup heater of the heating water), R3 (circulation pump), R4 (DHW three-way valve), R5 (cooling three-way valve) and inputs S1 and S2 as service attributes.

The **Bluetooth sensor** adds battery level (%) and signal strength (RSSI, dBm) as service attributes. Reading of the Bluetooth sensor is switched on in the controller in menu 2.6.

### System settings and sensor injection

Service actions of the **System settings** device:

- **Night mode** (Nočný režim) — Off, Always on or Time-based (menu 13.3).
- **System power limit** (Limit výkonu systému) — 0–5000 W (menu 7.4).
- **R2 electric heating mode** (Režim elektrického vykurovania R2) — heat pump only, heat pump + electric backup, heat pump or electric backup, electric backup only (menu 1.5).
- **T1 sensor injection**, **Tout sensor injection**, **RH sensor injection** (Injekcia senzora T1 / Tout / RH) — send a room temperature, outdoor temperature or indoor relative humidity to `miniHPC/setsensor/`. MiniHPC then uses the value instead of the physical sensor (T1 replaces the indoor sensor, Tout the outdoor temperature measured by the outdoor unit).

> [!WARNING]
> An injected sensor value is valid for **60 minutes**, then MiniHPC discards it. Send it repeatedly, more often than once an hour — the manufacturer recommends once a minute, for example from a TapHome smart rule.

## Troubleshooting

**TapHome shows no values**
- Check that menu 9.1 WiFi station shows the MQTT state as Connected.
- Check that the broker IP address and port entered in TapHome match the broker MiniHPC uses.
- Check that the MQTT Root topic on MiniHPC is `miniHPC`.
- MQTT Explorer, recommended by the manufacturer, shows everything MiniHPC publishes on the broker.

**Values are shown, but MiniHPC ignores changes from TapHome**
- Allow MQTT in menu 9.4 Permissions. Without this permission MiniHPC ignores the `set`, `setns`, `setsensor` and `cmd` topics.

**Some values stay empty after TapHome or the broker restarts**
- MiniHPC sends a value only when it changes, and sends everything at start-up or after a settings change. Set the **MQTT Birth topic** on MiniHPC — any message published to it makes MiniHPC send the complete configuration and all data again.

**An injected sensor value stopped working**
- Injected values T1, Tout and RH expire after 60 minutes. Repeat the injection regularly, ideally once a minute.

## Available devices 14

These devices appear in TapHome after import.

MiniHPC MQTT modul Module

Prevádzkový stav Multi-value Switch

Values / States: Vypnuté · Kúrenie · Chladenie

Read switch state

```taphome
RETURN(Mu);
```

Write switch state

```taphome
MQTTPUBLISH("miniHPC/set/mode", TOSTRING(Mu));
```

Listener

```taphome
IF(INDEXOF(RECEIVEDMSG.TOPIC, "miniHPC/") != 0)
    RETURN(0);
END
IF(RECEIVEDMSG.TOPIC = "miniHPC/config/mode")
    Mu := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
END
```

Vykurovacia teplota vody Variable

Read

```taphome
RETURN(Va);
```

Write

```taphome
MQTTPUBLISH("miniHPC/set/temperature_T3", TOSTRING(Va));
```

Listener

```taphome
IF(RECEIVEDMSG.TOPIC = "miniHPC/config/temperature_T3")
    Va := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
END
```

Chladiaca teplota vody Variable

Read

```taphome
RETURN(Va);
```

Write

```taphome
MQTTPUBLISH("miniHPC/set/temperature_T3_cool", TOSTRING(Va));
```

Listener

```taphome
IF(RECEIVEDMSG.TOPIC = "miniHPC/config/temperature_T3_cool")
    Va := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
END
```

Izbová teplota Temperature Sensor

Read temperature

```taphome
RETURN(Te);
```

Listener

```taphome
IF(RECEIVEDMSG.TOPIC = "miniHPC/data/t1")
    Te := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
END
```

TÚV – zapnutie Switch

Values / States: Zapnuté · Vypnuté

Service Actions

|                        |
|------------------------|
| Spustiť TÚV ohrev      |
| Zastaviť TÚV ohrev     |
| Protilégionelový ohrev |
| Turbo TÚV ohrev        |

Read switch state

```taphome
RETURN(St);
```

Write switch state

```taphome
MQTTPUBLISH("miniHPC/set/dhw_onoff", IF(St = 1, "1", "0"));
```

Listener

```taphome
IF(RECEIVEDMSG.TOPIC = "miniHPC/config/dhw_onoff")
    St := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
END
```

Service Actions

Spustiť TÚV ohrev

```taphome
MQTTPUBLISH("miniHPC/cmd/dhw", "on");
```

Zastaviť TÚV ohrev

```taphome
MQTTPUBLISH("miniHPC/cmd/dhw", "off");
```

Protilégionelový ohrev

```taphome
MQTTPUBLISH("miniHPC/cmd/dhw", "al");
```

Turbo TÚV ohrev

```taphome
MQTTPUBLISH("miniHPC/cmd/dhw", "turbo");
```

TÚV – cieľová teplota Variable

Read

```taphome
RETURN(Va);
```

Write

```taphome
MQTTPUBLISH("miniHPC/set/dhw_temp_target", TOSTRING(Va));
```

Listener

```taphome
IF(RECEIVEDMSG.TOPIC = "miniHPC/config/dhw_temp_target")
    Va := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
END
```

Vonkajšia jednotka Variable

Service Attributes

|                                 |
|---------------------------------|
| Stav kompresora                 |
| Režim vonkajšej jednotky        |
| Frekvencia kompresora           |
| Otáčky ventilátora              |
| Poloha expanzného ventilu (EEV) |
| Napätie DC zbernice             |
| Prúd kompresora                 |
| Odmrazovanie aktívne            |
| Výstupný výkon TČ               |

Service Actions

|                       |
|-----------------------|
| Manuálne odmrazovanie |

Variable: `ouPwr`, Variable: `ouFreq`, Variable: `ouFan`, Variable: `ouEEV`, Variable: `ouDCbus`, Variable: `ouDCcurr`, Variable: `ouDefrost`, Variable: `ouMode`, Variable: `ouState`, Variable: `ouPwrOut`

Read

```taphome
RETURN(Va);
```

Listener

```taphome
IF(INDEXOF(RECEIVEDMSG.TOPIC, "miniHPC/data/out") != 0 AND INDEXOF(RECEIVEDMSG.TOPIC, "miniHPC/data/pwrOutHP") != 0)
    RETURN(0);
END
IF(RECEIVEDMSG.TOPIC = "miniHPC/data/outPower")
    ouPwr := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
    Va := ouPwr;
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/outFrequency")
    ouFreq := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/outFan")
    ouFan := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/outEEV")
    ouEEV := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/outDCbus")
    ouDCbus := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/outDCcurrent")
    ouDCcurr := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/outDefrost")
    ouDefrost := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/outMode")
    ouMode := TOSTRING(RECEIVEDMSG.PAYLOAD);
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/outState")
    ouState := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/pwrOutHP")
    ouPwrOut := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
END
```

Service Attributes

Stav kompresora

```taphome
IF(ouState = 1, "Zapnutý", "Vypnutý");
```

Režim vonkajšej jednotky

```taphome
IF(LENGTH(ouMode) = 0, "Neznámy", ouMode);
```

Frekvencia kompresora

```taphome
TOSTRING(ouFreq, "F0") + " Hz";
```

Otáčky ventilátora

```taphome
TOSTRING(ouFan, "F0") + " RPM";
```

Poloha expanzného ventilu (EEV)

```taphome
TOSTRING(ouEEV, "F0");
```

Napätie DC zbernice

```taphome
TOSTRING(ouDCbus, "F1") + " V";
```

Prúd kompresora

```taphome
TOSTRING(ouDCcurr, "F1") + " A";
```

Odmrazovanie aktívne

```taphome
IF(ouDefrost = 1, "Áno", "Nie");
```

Výstupný výkon TČ

```taphome
TOSTRING(ouPwrOut, "F0") + " W";
```

Service Actions

Manuálne odmrazovanie

```taphome
MQTTPUBLISH("miniHPC/cmd/odu", "defrost");
```

Energia – kúrenie Electricity Meter

Service Attributes

|                                         |
|-----------------------------------------|
| Vyprodukovaná tepelná energia – kúrenie |

Variable: `hPwrIn`, Variable: `hPwrOut`

Read total consumption

```taphome
RETURN(To);
```

Read demand

```taphome
RETURN(NaN);
```

Listener

```taphome
IF(RECEIVEDMSG.TOPIC = "miniHPC/data/heatPwrIn")
    hPwrIn := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD)) / 1000000.0;
    To := hPwrIn;
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/heatPwrOutHP")
    hPwrOut := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD)) / 1000000.0;
END
```

Service Attributes

Vyprodukovaná tepelná energia – kúrenie

```taphome
TOSTRING(hPwrOut, "F3") + " kWh";
```

Energia – chladenie Variable

Read

```taphome
RETURN(Va);
```

Listener

```taphome
IF(RECEIVEDMSG.TOPIC = "miniHPC/data/coolPwrIn")
    Va := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD)) / 1000000.0;
END
```

Energia – TÚV Electricity Meter

Service Attributes

|                                     |
|-------------------------------------|
| Vyprodukovaná tepelná energia – TÚV |
| Celkový čas behu kompresora         |
| Celkový počet spustení kompresora   |

Variable: `dhwPwrIn`, Variable: `dhwPwrOut`, Variable: `comprT`, Variable: `comprC`

Read total consumption

```taphome
RETURN(To);
```

Read demand

```taphome
RETURN(NaN);
```

Listener

```taphome
IF(RECEIVEDMSG.TOPIC = "miniHPC/data/dhwPwrIn")
    dhwPwrIn := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD)) / 1000000.0;
    To := dhwPwrIn;
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/dhwPwrOut")
    dhwPwrOut := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD)) / 1000000.0;
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/comprTime")
    comprT := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/comprCount")
    comprC := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
END
```

Service Attributes

Vyprodukovaná tepelná energia – TÚV

```taphome
TOSTRING(dhwPwrOut, "F3") + " kWh";
```

Celkový čas behu kompresora

```taphome
TOSTRING(ROUND(comprT / 3600.0), "F0") + " h";
```

Celkový počet spustení kompresora

```taphome
TOSTRING(comprC, "F0") + " x";
```

Teploty systému Temperature Sensor

Service Attributes

|                                  |
|----------------------------------|
| Teplota T2                       |
| Teplota T3 (výstup vody)         |
| Teplota T4                       |
| Teplota T5 (TÚV)                 |
| Teplota T6                       |
| Teplota výparníka (Tsuc)         |
| Teplota výfuku kompresora (Texh) |
| Nastavená teplota regulátora     |
| Prietok vody                     |

Variable: `sT2`, Variable: `sT3`, Variable: `sT4`, Variable: `sT5`, Variable: `sT6`, Variable: `sTsuc`, Variable: `sTex`, Variable: `sTout`, Variable: `sTset`, Variable: `sFlow`

Read temperature

```taphome
RETURN(Te);
```

Listener

```taphome
IF(INDEXOF(RECEIVEDMSG.TOPIC, "miniHPC/data/t") != 0 AND INDEXOF(RECEIVEDMSG.TOPIC, "miniHPC/data/tout") != 0 AND INDEXOF(RECEIVEDMSG.TOPIC, "miniHPC/data/tsuc") != 0 AND INDEXOF(RECEIVEDMSG.TOPIC, "miniHPC/data/texh") != 0 AND INDEXOF(RECEIVEDMSG.TOPIC, "miniHPC/data/tset") != 0 AND INDEXOF(RECEIVEDMSG.TOPIC, "miniHPC/data/flow") != 0)
    RETURN(0);
END
IF(RECEIVEDMSG.TOPIC = "miniHPC/data/tout")
    sTout := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
    Te := sTout;
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/t2")
    sT2 := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/t3")
    sT3 := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/t4")
    sT4 := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/t5")
    sT5 := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/t6")
    sT6 := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/tsuc")
    sTsuc := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/texh")
    sTex := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/tset")
    sTset := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/flow")
    sFlow := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
END
```

Service Attributes

Teplota T2

```taphome
TOSTRING(sT2, "F1") + " °C";
```

Teplota T3 (výstup vody)

```taphome
TOSTRING(sT3, "F1") + " °C";
```

Teplota T4

```taphome
TOSTRING(sT4, "F1") + " °C";
```

Teplota T5 (TÚV)

```taphome
TOSTRING(sT5, "F1") + " °C";
```

Teplota T6

```taphome
TOSTRING(sT6, "F1") + " °C";
```

Teplota výparníka (Tsuc)

```taphome
TOSTRING(sTsuc, "F1") + " °C";
```

Teplota výfuku kompresora (Texh)

```taphome
TOSTRING(sTex, "F1") + " °C";
```

Nastavená teplota regulátora

```taphome
TOSTRING(sTset, "F1") + " °C";
```

Prietok vody

```taphome
TOSTRING(sFlow, "F1") + " l/min";
```

Diagnostika – relé a vstupy Reed Contact

Service Attributes

|          |
|----------|
| Relé R2  |
| Relé R3  |
| Relé R4  |
| Relé R5  |
| Vstup S1 |
| Vstup S2 |

Variable: `dR1`, Variable: `dR2`, Variable: `dR3`, Variable: `dR4`, Variable: `dR5`, Variable: `dS1`, Variable: `dS2`

Read

```taphome
RETURN(St);
```

Listener

```taphome
IF(INDEXOF(RECEIVEDMSG.TOPIC, "miniHPC/data/R") != 0 AND INDEXOF(RECEIVEDMSG.TOPIC, "miniHPC/data/S") != 0)
    RETURN(0);
END
IF(RECEIVEDMSG.TOPIC = "miniHPC/data/R1")
    dR1 := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
    St := dR1;
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/R2")
    dR2 := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/R3")
    dR3 := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/R4")
    dR4 := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/R5")
    dR5 := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/S1")
    dS1 := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/S2")
    dS2 := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
END
```

Service Attributes

Relé R2

```taphome
IF(dR2 = 1, "Aktívne", "Neaktívne");
```

Relé R3

```taphome
IF(dR3 = 1, "Aktívne", "Neaktívne");
```

Relé R4

```taphome
IF(dR4 = 1, "Aktívne", "Neaktívne");
```

Relé R5

```taphome
IF(dR5 = 1, "Aktívne", "Neaktívne");
```

Vstup S1

```taphome
IF(dS1 = 1, "Aktívne", "Neaktívne");
```

Vstup S2

```taphome
IF(dS2 = 1, "Aktívne", "Neaktívne");
```

Bluetooth senzor Temperature Sensor

Service Attributes

|                                 |
|---------------------------------|
| BT senzor – úroveň batérie      |
| BT senzor – sila signálu (RSSI) |

Variable: `btHum`, Variable: `btBat`, Variable: `btRssi`

Read humidity

```taphome
RETURN(btHum);
```

Read temperature

```taphome
RETURN(Te);
```

Listener

```taphome
IF(INDEXOF(RECEIVEDMSG.TOPIC, "miniHPC/data/BT") != 0)
    RETURN(0);
END
IF(RECEIVEDMSG.TOPIC = "miniHPC/data/BTtemp")
    Te := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/BThum")
    btHum := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/BTbat_lev")
    btBat := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
ELSEIF(RECEIVEDMSG.TOPIC = "miniHPC/data/BTrssi")
    btRssi := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
END
```

Service Attributes

BT senzor – úroveň batérie

```taphome
TOSTRING(btBat, "F0") + " %";
```

BT senzor – sila signálu (RSSI)

```taphome
TOSTRING(btRssi, "F0") + " dBm";
```

Nastavenia systému Multi-value Switch

Values / States: Bez obmedzenia · Obmedzenie na 70 % · Obmedzenie na 50 %

Service Actions

|                                   |
|-----------------------------------|
| Nočný režim                       |
| Limit výkonu systému              |
| Režim elektrického vykurovania R2 |
| Injekcia senzora T1               |
| Injekcia senzora Tout             |
| Injekcia senzora RH               |

Read switch state

```taphome
RETURN(Mu);
```

Write switch state

```taphome
MQTTPUBLISH("miniHPC/set/odu_power_limit", TOSTRING(Mu));
```

Listener

```taphome
IF(RECEIVEDMSG.TOPIC = "miniHPC/config/odu_power_limit")
    Mu := TODOUBLE(TOSTRING(RECEIVEDMSG.PAYLOAD));
END
```

Service Actions

Nočný režim

Parameters: Režim

```taphome
MQTTPUBLISH("miniHPC/set/odu_night_mode", TOSTRING(nm));
```

Limit výkonu systému

Parameters: Výkon (W) (0–5000 pw)

```taphome
MQTTPUBLISH("miniHPC/set/power_limit", TOSTRING(pw));
```

Režim elektrického vykurovania R2

Parameters: Režim

```taphome
MQTTPUBLISH("miniHPC/set/heating_elh_mode", TOSTRING(em));
```

Injekcia senzora T1

Parameters: Teplota T1 (°C) (-30–60 t1v)

```taphome
MQTTPUBLISH("miniHPC/setsensor/T1", TOSTRING(t1v));
```

Injekcia senzora Tout

Parameters: Vonkajšia teplota (°C) (-40–60 tov)

```taphome
MQTTPUBLISH("miniHPC/setsensor/Tout", TOSTRING(tov));
```

Injekcia senzora RH

Parameters: Relatívna vlhkosť (%) (0–100 rhv)

```taphome
MQTTPUBLISH("miniHPC/setsensor/RH", TOSTRING(rhv));
```

**Connection:** Packet Parser → MQTT

## Import parameters

Enter these values when you import the XML.

| Asked in the app       | Default       |
|------------------------|---------------|
| IP adresa MQTT brokera | `192.168.0.1` |
| Port MQTT brokera      | `1883`        |

## Related Documentation

- [MQTT Integration](https://taphome.com/en/compatibility/mqtt-guide/)
- [Packet Parser (HTTP, TCP, UDP, FTP, MQTT)](https://taphome.com/en/docs/integration/packet-parser/)
- [Packet parser functions](https://taphome.com/en/docs/script/packet-parser/)
- [Parsing functions](https://taphome.com/en/docs/script/parsing-functions/)
- [MQTT Broker](https://taphome.com/en/docs/integration/packet-parser/mqtt-broker/)
- [Listener scripts](https://taphome.com/en/docs/script/listener-scripts/)

