MC6 Thermostat

The file has expired again (" The files in this link are deleted") – would you mind reuploading it somewhere? Thanks so much!

That would be great, thank you! I still need the bootloader, it is dead since that.

Here you are the files for the firmware v327 and the bootloader inside. Make sure the bootloader points to address 0x8000000.

I have updated to this version and the circles around the temperature and humidity dissapeared. You can charge them again using the USB port. I haven’t tested because I do not have USB connector. I will solder one and will try.

Here the link: firmware v_327 + bootloader + gif images.

Has any of you integrated the thermostate into HA?

I tried using ModBus Climate: https://www.home-assistant.io/integrations/climate.modbus

This is my code:

modbus:
  name: hub1
  type: tcp
  host: 192.168.1.150
  port: 502
  
climate:
  - platform: modbus
    name: termostato_salon
    hub: hub1
    slave: 1
    data_type: int
    data_count: 1
    scale: 0.1
    offset: 0
    precision: 1
    max_temp: 30
    min_temp: 15
    temp_step: 1
    target_temp_register: 64
    current_temp_register: 0

It is displayed in lovelace but others it doesn’t:

Did you get it to work?

I am now trying with Node-red, but at this moment I am not able to get the temperature data properly (I think I have to parser the payload received. Im on it).

Hi, could you send me a frontal image of that usb connector? I have to buy one. Thanks

Many thaks for your picture!

Well, I have finally integrated in HA. I did it working using Node-Red, MQTT and HVAC MQTT:

I am preparing a tutorial on my blog but it will takes me time. If you are interested on it, let me know and I will export the node-red project to send you.

This is how it looks:

ok

1 Like

Hello Domarray,
I am currently trying this after i saw your modbus thread.
The basic modbus climate configuration you posted works and i get the same reactions on lovelace as you. (the value comes back after some seconds after setting something and the gauge is blanked)
I am looking forward to check your node-red export.

Great work
Chris

Here you can find the Node-red flow and a guide to integrate it into HomeAssistant: It is in Spanish but you can select English at the top right:

http://domaray.com/2020/10/07/termostato-mc6-integracion-en-home-assistant/

Hope it helps. Any doubts comment me.

1 Like

Thanks so much for all of your work!

You had mentioned some diagrams in a .zip file an earlier post, do you happen to have those available? I also saw some schematics above, including the pinout of JP1, do we have these anywhere?

Did you manage to get the GIF files uploaded through the USB port?

Also, any idea why the HA Modbus integration didn’t work for you and you had to use NodeRED?

After having some connection troubles with the node-red flow of @domarray i decided to do my own which is compatible. Currently I am still struggling in getting the lovelace display right, but all the necessary mobus info is written to mqtt.

Temperature Setpoint, Current Temperature, Humidity, Heating status, Thermostat status, Away Temperature, Away Status.

I used the “local getter flex” node to get all values (as suggested in the documentation of the modbus nodes)

Node-red Flow

working configuration.yaml entry (as the MC6 has several states and modes, i used the simplest implementation now and will show other states on different cards/buttons)

#thermostat
climate:
 - platform: mqtt
   name: Wohnzimmer
   modes:
   - 'off'
   - heat

   temperature_command_topic: "/home/thermostat/temperature_setpoint/set"
   temperature_state_topic: "/home/thermostat/temperature_setpoint/state"
   temperature_state_template: "{{ value_json[0]|float / 10  }}"
   current_temperature_topic: "/home/thermostat/current_temperature/state"
   current_temperature_template: "{{ value_json[0]|float / 10  }}"
   
   mode_state_topic: "/home/thermostat/mode/state"
   mode_state_template: "{{ value_json[0] }}"
   
   temperature_unit: c
   max_temp: 30
   min_temp: 15
   temp_step: 0.5
   retain: 1

Hi all. Any idea how to unlock the thermostat when the lock pin is unknown/lost?
Nobody changed the code but yesterday when I tried to enter before the winter season the good known lock code no longer works… Can it be cleared/factory-def from the usb port maybe ??
Thanks
Luca

After several days, I was having troubles after integrating more Modbus signals. I followed the recommendation of @captFuture and now it seems to work better. Here is the result:

Node-Red flow:

MC6_Thermostate

And here the “configuration.yaml” code:

  - platform: mqtt
    name: Salón
    modes:
      - "off"
      - "heat"
      - "auto"
    temperature_command_topic: "home/termostato/temperature_setpoint/set"
    temperature_state_topic: "home/termostato/temperature_setpoint/state"
    temperature_state_template: "{{ value_json|float / 10  }}"
    current_temperature_topic: "home/termostato/current_temperature/state"
    current_temperature_template: "{{ value_json|float / 10  }}"
    mode_state_topic: "home/termostato/mode/state"
    temperature_unit: c
    max_temp: 30
    min_temp: 15
    temp_step: 0.5
    retain: 1

For the Away, you have to add a Helper “input_number” type and called “away_temperature”. Then add this code to the Automations:

- id: '1597530567890'
  alias: Set Away Temperature
  description: ''
  trigger:
  - entity_id: input_number.away_temperature
    platform: state
  action:
  - data_template:
      payload: '{{ [(states(''input_number.away_temperature'') | float)*10] }}'
      retain: true
      topic: home/termostato/away_temperature/set
    service: mqtt.publish
  mode: single
  
- id: '1602464759287'
  alias: Get Away temperature
  description: Set the slide to the away temperature read
  trigger:
  - platform: mqtt
    topic: home/termostato/away_temperature/state
  condition: []
  action:
  - service: input_number.set_value
    data:
      entity_id: input_number.away_temperature
      value: "{{ (trigger.payload|float)/10 }}"
  mode: single

This is the code for the UI:

cards:
  - entity: climate.salon
    type: thermostat
  - cards:
      - entity: switch.termostato_on_off
        hold_action:
          action: more-info
        show_icon: true
        show_name: true
        show_state: false
        tap_action:
          action: toggle
        type: button
      - entity: switch.termostato_away
        hold_action:
          action: more-info
        show_icon: true
        show_name: true
        show_state: false
        tap_action:
          action: toggle
        type: button
        name: Ausente
    type: horizontal-stack
  - type: entities
    entities:
      - entity: input_number.away_temperature
        icon: 'mdi:thermometer'
        name: Temp. Ausente
    state_color: true
type: vertical-stack

Additionally, I added some History stats that could be interesting to control the time elapsed of the “heat” mode (When the heat water is running):

History_stats

Here the code for “configuration.yaml”:

  - platform: history_stats
    name: Termostato_history_today
    entity_id: sensor.termostato_mode
    state: 'heat'
    type: time
    start: '{{ now().replace(hour=0, minute=0, second=0) }}'
    end: '{{ now() }}'

  - platform: history_stats
    name: Termostato_history_24h
    entity_id: sensor.termostato_mode
    state: 'heat'
    type: time
    end: '{{ now() }}'
    duration:
      hours: 24
    
  - platform: history_stats
    name: Termostato_history_week
    entity_id: sensor.termostato_mode
    state: 'heat'
    type: time
    start: '{{ as_timestamp( now().replace(hour=0, minute=0, second=0) ) - now().weekday() * 86400 }}'
    end: '{{ now() }}'

  - platform: history_stats
    name: Termostato_history_total
    entity_id: sensor.termostato_mode
    state: 'heat'
    type: time
    start: '{{ 0 }}'
    end: '{{ now() }}'

Hope you like it.

2 Likes

Did you experience the same “issue” as me that the MC6 is not accepting commands when the display is on “screensaver mode” ?

I can only send commands when the display shows the whole screen
:frowning:

I’m using this config and works properly:

which firmware are you using?

Hi Avitaler. You cannoit flash using the usb. USB only gives you access to theinternal bmp storage where you can fing all bm related to icons being used by the firmware

Hi tiziano. I failed to connect my ST jtag to the arm connector ( Can not connect to target!)
. Do you have the cabling print out from the jlink 20pin connector to the MC6 2x5 connector ?
thanks

@ringhio80

Have you connected the power supply?

Be attention is very dangerous, i have disassembled the case , and use

only the pcb power supply on the mc6