MQTT Roller/Shutter activation is not stopping (toggle)

  • My Problem
    I want to use shelly2.5 with the original firmware to use my shutter/roller: I have 2 buttons, which trigger a mqtt message open/close, depending which button I press.
    I want that when I press the button the first time, that the shutter starts to close and if I press it again it stops at the current position (like the toggle function in arendst)
    => The problem is that on the 2nd push, the shutter stops like 2 seconds and then continues to go down. I see the same problem on the web interface. There I need to push stop. With MQTT it would be too complicated to check the current status, to decide if I send another "close" or "stop" message.

    Did anyone solve that problem?
    => the command I use: "shellies/shellyswitch25-4xxxxxx/roller/0/command" "close"

    Einmal editiert, zuletzt von lobocobra (26. Juni 2023 um 16:37)

  • Ich habe das Problem wie folgt mit NodeRed gelöst. Ich nehme an, dass ziemlich alle dieses Problem haben....

    Der Schalter funkt über Homematic und ich sende den Befehl über NodeRed weiter an den Shelly.
    Dieser Code unten löst das Problem:


    // toggle shutter

    if (flow.get("ZipSeiteLastCMD") == "open" ) {mqtt_msg.payload = "stop"} else {mqtt_msg.payload = "open"}

    // save state for next time

    flow.set("ZipSeiteLastCMD", mqtt_msg.payload);

  • Der Schalter funkt über Homematic und ich sende den Befehl über NodeRed weiter an den Shelly.

    Warum so kompliziert? :/

    Du kannst doch den Befehl direkt vom Homematicgerät per http an den Shelly senden.