Control Jarolift with wemos d1mini + CC1101 & mqtt

Hello, I used Jarolift_MQTT to control the RF Jarolift roller shutters with a wemos d1 mini + CC1101 and successfully tested on 2 for the moment! Where I’m stuck is for the integration into home assistant with mqtt. As the repository is no longer up to date, the proposed configuration does not seem to work.

I can see that my wemos communicates with mqtt but I don’t understand how I can control it.
i have already try with stat/jarolift/…

The instruction:

MQTT topics send back with the updated status of a shutter:
The status of a shutter is:

0 - open
90 - shade position
100 - close

stat/jarolift/shutter/0 100

Integration into Home Assistant
Here is a configuration example for Home Assistant:

cover:
  - platform: mqtt
    name: "Wohnzimmer links"
    command_topic: "cmd/jarolift/shutter/1"
    availability_topic: "tele/jarolift/LWT"
    payload_open: "UP"
    payload_close: "DOWN"
    payload_stop: "STOP"
    payload_available: "Online"
    payload_not_available: "Offline"

I have Try too in my configuration.yaml:

mqtt:
  sensor:
    - name: 'jarolift'
      unique_id: 'jarolift_bureau'
      command_topic: "stat/jarolift/shutter/0"
      state_topic: "tele/jarolift/LWT"
      payload_open: "UP"
      payload_close: "DOWN"
      payload_stop: "STOP"
      payload_available: "Online"
      payload_not_available: "Offline"```

If it helps I used MQTT explorer to retrieve information:
![img1|690x55](upload://ccm2A0FGT8Nt6jXuIy6QULkNpvp.png)

You only need to configure the cover properly in configuration.yaml and restart HA. Then you should find cover.jarolift in your entity list and add it to the UI.

My config looks like this:

mqtt:
  cover:
    - name: "Jarolift"
      command_topic: "cmd/jarolift/shutter/0"
      availability_topic: "tele/jarolift/LWT"
      state_topic: "stat/jarolift/shutter/0"
      value_template: >
        {% if value == "100" %}
          closed
        {% else %}
          open
        {% endif %}    
      payload_open: "UP"
      payload_close: "DOWN"
      payload_stop: "STOP"
      payload_available: "Online"
      payload_not_available: "Offline"
      retain: false
      optimistic: false

Ok ty,
can you explain to me what “cover” means?

I tried to do like you, but nothing comes up in the mqtt devices and nothing on the entity side either

HA MQTT Cover https://www.home-assistant.io/integrations/cover.mqtt/

Is Jarolift_MQTT connecting to your MQTT Broker?
Can you see the messages in MQTT Explorer?

Your screenshot is not visible. Most likely the format is not supported or you did not use the insert picture button.

Yes he is connecting,
Ho sorry !

If for example i turn off power supply and after 5 min i turn on
mqtt_ofline

mqtt_online

Please post your configuration.yaml

Here The configuration in configuration.yaml, same as you

#####JAROLIFT CONTROL#####
mqtt:
  cover:
    - name: "Jarolift"
      unique_id: JAROLIFT
      command_topic: "cmd/jarolift/shutter/0"
      availability_topic: "tele/jarolift/LWT"
      state_topic: "stat/jarolift/shutter/0"
      value_template: >
        {% if value == "100" %}
          closed
        {% else %}
          open
        {% endif %}    
      payload_open: "UP"
      payload_close: "DOWN"
      payload_stop: "STOP"
      payload_available: "Online"
      payload_not_available: "Offline"
      retain: false
      optimistic: false

Looks good. And you do not see cover.jarolift in your entities like this?

No :frowning_face:
This is where I don’t understand, because declaring it in the .yaml should at least make it appear, even if it doesn’t work

i 'm on HAOS:

  • Core 2024.4.4
  • Supervisor 2024.04.0
  • Operating System 12.2
  • Interface utilisateur 20240404.2

This is correct unless there are errors. Did you check your log for related errors?

That means errors? Where should I look?

Settings → System → Logs

I have no error with MQTT

Any other errors? You can Post your error log. Did you also check Mosquitto error log? That is selectable on the top right in setting - > system - > logs

I found the problem! It’s a bit curious. In my yaml I had a duplicate key “MQTT” I have one of my mqtt devices which had an excess offset.
By deleting the duplicated key, it detected a block error, I put the correct format back on the “climate” and “sensor” concerned and the cover appeared! What is curious is that my different mqtt entities worked perfectly, but obviously the cover type one put upstream in my config file was not taken into account.

I don’t know if I’m clear.
I take this opportunity to ask this question, I have planned to remove all the mqtt configuration from my configuration file to separate them in another file, Can I make 1 file per entity or should I still not have 1 single “include” with all my mqtt entities declared manually?

https://www.home-assistant.io/docs/configuration/splitting_configuration/

Thank you, you don’t use the SHADE position on your shutters?

No but it should be easy to add.