Skip to content

Instantly share code, notes, and snippets.

@BrittonA
Created July 16, 2024 05:09
Show Gist options
  • Select an option

  • Save BrittonA/339d25efb934bdb4f451ba7e2f920ba3 to your computer and use it in GitHub Desktop.

Select an option

Save BrittonA/339d25efb934bdb4f451ba7e2f920ba3 to your computer and use it in GitHub Desktop.
Midea 170L heat pump modbus configuration
1. Purchase a WaveShare RS485 module. The module I used is on Amazon here - https://www.amazon.com.au/Waveshare-RS485-Ethernet-Rail-Mount-Gateway/dp/B0B4JNWF7N
2. Configure the WaveShare module. In mode, you need to set Modbus TCP <=> Modbus RTU. The default username and password is admin admin
3. Connect the WaveShare module to your Midea 170L heat pump. The cables are Yellow = GND, Gray = B, Black = A.
4. Using File Editor in Home Assistant navigator to your configuration.yaml file and add this line
modbus: !include modbus.yaml
5. Using File Editor, create a modbus.yaml file and copy the configuration above.
6. Adjust the host to match the IP address of your WaveShare module.
7. Restart Home assistant and you should now see entities with your temps.
- name: waveshare1
type: tcp
host: 192.168.0.48
port: 502
delay: 2
timeout: 5
switches:
- name: water_heatpump_on_off_toggle
unique_id: water_heatpump_on_off_toggle
slave: 1
address: 0
write_type: holding
command_on: 1
command_off: 0
verify:
input_type: holding
address: 0
state_on: 1
state_off: 0
- name: water_heatpump_offEconomy_onHybrid_toggle
unique_id: water_heatpump_offEconomy_onHybrid_toggle
slave: 1
address: 1
write_type: holding
command_on: 2
command_off: 1
verify:
input_type: holding
address: 1
state_on: 2
state_off: 1
sensors:
- name: water_heatpump_power_state
unique_id: water_heatpump_power_state
address: 0
scan_interval: 5
slave: 1
input_type: holding
- name: water_heatpump_mode
unique_id: water_heatpump_mode
address: 1
scan_interval: 5
slave: 1
input_type: holding
- name: water_heatpump_temperature_top_of_tank_T5U
unit_of_measurement: °C
state_class: measurement
unique_id: water_heatpump_temperature_top_of_tank_T5U
scan_interval: 30
address: 101
slave: 1
offset: -15
scale: 0.5
- name: water_heatpump_temperature_bottom_of_tank_T5L
unit_of_measurement: °C
state_class: measurement
unique_id: water_heatpump_temperature_bottom_of_tank_T5L
scan_interval: 30
address: 102
slave: 1
offset: -15
scale: 0.5
- name: water_heatpump_condensor_temperature_T3
unit_of_measurement: °C
state_class: measurement
unique_id: water_heatpump_condensor_temperature_T3
scan_interval: 30
address: 103
slave: 1
offset: -15
scale: 0.5
- name: water_heatpump_outdoor_temperature_T4
unit_of_measurement: °C
state_class: measurement
unique_id: water_heatpump_outdoor_temperature_T4
scan_interval: 30
address: 104
slave: 1
offset: -15
scale: 0.5
- name: water_heatpump_exhaust_gas_temperature_Tp
unit_of_measurement: °C
state_class: measurement
unique_id: water_heatpump_exhaust_gas_temperature_Tp
scan_interval: 30
address: 105
slave: 1
- name: water_heatpump_suction_temperature_Th
unit_of_measurement: °C
state_class: measurement
unique_id: water_heatpump_suction_temperature_Th
scan_interval: 30
address: 106
slave: 1
offset: -15
scale: 0.5
climates:
- name: water_heatpump_climate
unique_id: water_heatpump_climate
address: 2
slave: 1
input_type: holding
max_temp: 70
min_temp: 60
precision: 1
target_temp_register: 2
temp_step: 1
temperature_unit: C
@0xAHA
Copy link
Copy Markdown

0xAHA commented Aug 24, 2025

Hi!
Thanks for this… I was led here from a community post and this helped get my Midea unit in to home Assistant.

I’ve made some progress on it myself and noticed that the eco/hybrid switch could do with improvement as it didn’t also account for e-heater mode.

Anyhoo… see my version here: https://github.com/0xAHA/Midea-Heat-Pump-HA/blob/main/files/modbus.yaml

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment