De Dietrich/Diematic (Modbus) to MQTT Interface

Hello Kromagnsss,

I thank you for your feedback. Yes automatic discovery need birth message to be retained to allow proper behavior if the Diematic interface is launched after HA.

I have updated wiki to remind that.
Benoit

Hi all,
Thanks for all this great work !
@BenoitS and @mtrofimm , based on your discussion here above, does that mean that the GitHub project from BenoitS is compatible with Diametic Isystem (one year before, it seems to not to be the case)?
I have a De Dietrich Modulens AGC 35.
Thanks

Hello,

I donā€™t think itā€™s compatible because I heard that Diematic Isystem is only a modBus slave. But I never try as I do not have access to any Boiler with Diematic Isystem.

What I saw on the internet that modBus register seems to be equivalent, so the main task should be update the loop function inside Diematic3Panel class. For that you need a Boiler, the hardware stuff and few python knowledeges.

Regards,
Benoit

Hi,
I try to use docker compose and I got this message :
[+] Running 0/1
ā ¦ diematic Pulling 1.6s
manifest unknown
I search on dockerhub : diematic and i didnā€™t find any image
docker image diematic, is it still in dockerhub ?
maybe you change name ?
Thanks

I forgot to give my docker-compose.yml
version: ā€˜3ā€™
services:
diematic:
container_name: diematic
restart: unless-stopped
image: Package diematic_to_mqtt Ā· GitHub
volumes:
- ~docker/diematic/conf:/app/conf
- ~docker/diematic/log:/app/log

hello,

docker image are still there :

But I think there is an access right issue:
docker pull Package diematic_to_mqtt Ā· GitHub
Error response from daemon: Head ā€œhttps://ghcr.io/v2/benoit3/diematic_to_mqtt/manifests/dev-latestā€: denied: denied

As I renew github repository secret token for workflow actions 3 days ago, it could be linked. But I donā€™t at all to solve that. I will look for, but as Iā€™m newbe for this kind of subject it could take days.

Benoit

Hi Benoit,
Thanks for your answer.
Iā€™m going to wait for your search.
Iā€™m newbe too and iā€™m trying to use docker for parts of my sofwares to avoid too much confusion :wink:
Itā€™s working, thanks.
But I have an other trouble. Everything is working, except i donā€™t see any published message in my MQTT server (Mosquitto). What can be wrong ?
see below some logs:
024-01-24 10:01:40,676 - main - CRITICAL - Modbus interface address: 192.168.1.62 : 20108
2024-01-24 10:01:40,677 - main - CRITICAL - Modbus regulator address: 0xa
2024-01-24 10:01:40,679 - main - CRITICAL - Broker: 192.168.1.87 #warning: using server name or localhost or 127.0.0.1 may not work with docker : 1883
2024-01-24 10:01:40,680 - main - CRITICAL - Topic Root: home/heater/boiler
2024-01-24 10:01:40,681 - main - CRITICAL - Hassio Discovery Enable: True
2024-01-24 10:01:40,682 - main - CRITICAL - Hassio Discovery Prefix: homeassistant
2024-01-24 10:01:40,683 - main - CRITICAL - Regulator type is Diematic3
2024-01-24 10:01:40,865 - Diematic - INFO - Using tzinfo (ā€˜Europe/Parisā€™) for Boiler time sync
2024-01-24 10:01:40,869 - Diematic - WARNING - Init Link with Regulator
2024-01-24 10:01:46,193 - Diematic - INFO - ModBus Master Slave Synchro OK
2024-01-24 10:01:47,222 - main - INFO - Publish :home/heater/boiler/status Online
2024-01-24 10:01:47,224 - main - INFO - Publish :home/heater/boiler/date 2024-01-24T11:01:00+01:00
2024-01-24 10:01:47,226 - main - INFO - Publish :home/heater/boiler/lastTimeSync
2024-01-24 10:01:47,229 - main - INFO - Publish :home/heater/boiler/type 1
2024-01-24 10:01:47,231 - main - INFO - Publish :home/heater/boiler/ctrl 402
2024-01-24 10:01:47,233 - main - INFO - Publish :home/heater/boiler/ext/temp 10.1
2024-01-24 10:01:47,235 - main - INFO - Publish :home/heater/boiler/temp 48.8
2024-01-24 10:01:47,237 - main - INFO - Publish :home/heater/boiler/targetTemp 0.0
2024-01-24 10:01:47,239 - main - INFO - Publish :home/heater/boiler/returnTemp
2024-01-24 10:01:47,241 - main - INFO - Publish :home/heater/boiler/waterPressure 1.0
When i check with MQTT explorer no trace on any message home/ā€¦
I published a message from SBC where diematic_to_MQTT is implemented
eric@pine64:~$ mosquitto_pub -h 192.168.1.87 -t home/heater/boiler/zoneB/dayTemp/set -m 17.5
and then i can see a message in an other SBC where i have MQTTT server home/heater/boiler/zoneB/dayTemp
So it seems something is wrong in my config see above
Modbus]
ip: 192.168.1.62
port: 20108
#regulator address is used for Diematic3
regulatorAddress:0x0A
#interfaceAddress is used for DiematicDelta
interfaceAddress:0x32

[MQTT]
brokerHost: 192.168.1.87 #warning: using server name or localhost or 127.0.0.1 may not work with docker
brokerPort: 1883
brokerLogin:
brokerPassword:
#topic prefix without any / at the beginning and the end of it
topicPrefix: home/heater
#clientId is append to the topicPrefix
clientId: boiler

[Boiler]
#regulator type ( Diematic3 (Default) or DiematicDelta, for dev purpose only)
regulatorType:Diematic3
#timezone in pytz list
timezone:Europe/Paris
#automatic boiler time synchronization
timeSync:False
#period for parameter polling in seconds
period: 10
#force circuit A to be enabled. False means it is automatic if a temperature sensor is detected
enable_circuit_A: False
#force circuit B to be enabled. False means it is automatic if a temperature sensor is detected
enable_circuit_B: True

[Home Assistant]
#enable MQTT Discovery
MQTT_DiscoveryEnable:1
#topic prefix without any / at the beginning and the end of it
discovery_prefix: homeassistant

thanks
Eric

Hello,
seems to be corrected now.
I unfortunately clear some parts of docker images.
They should be regenerated
Benoit

Hi Benoit,
After upgrading Paho-MQTT to version 2.0 I had a ā€œcallback_api_versionā€ issue without possibility to launch the diematic service. So to make it compatible with paho-mqtt 2.0, it is very simple and we just have to change in Diematic32MQTT.py Line 322

client = mqtt.Client()

by

client = mqtt.Client(mqtt.CallbackAPIVersion.VERSION1)

Then again it works like a charm :wink:
Rofiq

Hello,
Trank you for the issue and the correction. Can you raise an issue on github to track them?
Regards,
Benoit

Hi Benoit,
Done, thanks

Corrected in main / v1.2.5