Announcement

Collapse
No announcement yet.

Need help getting started

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Need help getting started

    I finally got zigbee2mqtt working on Windows, while I failed to get it working on the RPi. In any case, I need some help with my first device. To learn how to use mcsMQTT and zigbee2mqtt, I dusted off an old Securifi peanut on/off switch, which was readily found by the zigbee sniffer. It is not a supported device, so I had to modify the zigbee2mqtt database file as instructed.

    mcsMQTT has found the devices associated with the Securifi plug (state, power, current, linkquality) and I have created HS devices. I am using the "state" device to control off and on. It rapidly updates its status, when I manually turn the plug off and on. My problem is that I can not control the device via HS. I modeled the setup after the setup instructions for Sonoff S20, which may be the problem. When I click the control on the device page, the published topic and payload show up on the plugin's Statistics page. However, the last received topic and payload are different and reflect the change I make at the plug itself. I have attached a file with some screen clippings for the device. Appreciate any help. Thanks, in advance. Elliott
    Attached Files

  • #2
    Tasmota uses "cmnd" in either the first or second position of the Topic, depending upon your setup. Zigbee2MQTT uses "set" at the end of the Topic. For example the following is what is used for one of my color bulbs.
    Code:
    Topic: zigbeeWA/0xb0ce18140001de1b/set
    Payload: {"state":"ON","brightness":128,"color":{"r":200,"g":200," b": 30}}
    Since you had to add the device the payload may not be quite as obvious. If you go the supported devices page https://www.zigbee2mqtt.io/informati...d_devices.html and click on a similar device it is likely the payload will be of the same format. For example I randomly picked AV2010 and it showed what is below. While I'm not a Home Assistant user, I think the "value_template" means {ON} or {OFF} so in the HS/mcsMQTT context of a payload template it would be {$$STATUS:} so that when you press the ON or OFF button from HS it will send the label of these two buttons.

    I think more info about the Set syntax is in the same files where you added your device. I would have to explore, but it has been a few months since I looked so I do not recall off the top of my head.

    Code:
     AV2010/25 switch:   - platform: "mqtt"     state_topic: "zigbee2mqtt/<FRIENDLY_NAME>"     availability_topic: "zigbee2mqtt/bridge/state"     payload_off: "OFF"     payload_on: "ON"     value_template: "{{ value_json.state }}"     command_topic: "zigbee2mqtt/<FRIENDLY_NAME>/set"  sensor:   - platform: "mqtt"     state_topic: "zigbee2mqtt/<FRIENDLY_NAME>"     availability_topic: "zigbee2mqtt/bridge/state"     unit_of_measurement: "W"     icon: "mdi:factory"     value_template: "{{ value_json.power }}"  sensor:   - platform: "mqtt"     state_topic: "zigbee2mqtt/<FRIENDLY_NAME>"     availability_topic: "zigbee2mqtt/bridge/state"     unit_of_measurement: "-"     value_template: "{{ value_json.linkquality }}"
    I have image based upon a Debian Lite (DietPi) that I have Zigbee2MQTT and Mosquitto running. I can upload it if you are interested. It is on an Odroid C2, but should also run on RPi.

    Comment


    • #3
      Originally posted by Michael McSharry View Post
      Tasmota uses "cmnd" in either the first or second position of the Topic, depending upon your setup. Zigbee2MQTT uses "set" at the end of the Topic. For example the following is what is used for one of my color bulbs.....
      "set" did it! Thanks!!


      Originally posted by Michael McSharry View Post
      I have image based upon a Debian Lite (DietPi) that I have Zigbee2MQTT and Mosquitto running. I can upload it if you are interested. It is on an Odroid C2, but should also run on RPi.
      Sure!

      Comment


      • #4
        Sure!
        Give me an email at mcsSolutions at CenturyTel dot net and I will give you the link and credentials.

        Comment


        • #5
          I started to upload yesterday, but with a 100 to 200 KB internet connection it would take days to upload 16GB image.

          I have a RPi that has image for Mosquitto, TuyaConvert and Zibgee Sniffer. I tried to add Zigbee2MQTT to it and ran into the same problem you have on your RPi. Reading the zigbee2mqtt threads I see that Koenkk is in the middle of a major rewrite so kind of in limbo for the RPi install. He is moving from Shepard to Herdsman.

          I ordered a few 16gb SD cards so I have some flexibility in moving images around. I will clone my Odroid image and confirm it does work on RPi. If success and you are still interested then I can provide it via USPS. I did not see a timeline for when he would have everything ready. I did see that one person did not run the audit after then install and then had success. I did run the audit so left in the same state as you and others on this specific image.

          Comment


          • #6
            Originally posted by Michael McSharry View Post
            ....
            I ordered a few 16gb SD cards so I have some flexibility in moving images around. I will clone my Odroid image and confirm it does work on RPi. If success and you are still interested then I can provide it via USPS. I did not see a timeline for when he would have everything ready. I did see that one person did not run the audit after then install and then had success. I did run the audit so left in the same state as you and others on this specific image.
            I would be interested and happy to pay costs of SD card and postage, if you can get it to work. The way I got it to work, finally, on Windows, was install and not do audit fix. Thanks. Elliott

            Comment


            • #7
              I have a functional RPi image with Zigbee2MQTT,Mosquitto and I think Tuya Convert and Zigbee sniffer. I can send it tomorrow for $10. If you also want the June version of USB Dongle firmware I can send the dongle for an additional $5. I do have your address from before so just let me know what you desire.

              Comment


              • #8
                Originally posted by Michael McSharry View Post
                I have a functional RPi image with Zigbee2MQTT,Mosquitto and I think Tuya Convert and Zigbee sniffer. I can send it tomorrow for $10. If you also want the June version of USB Dongle firmware I can send the dongle for an additional $5. I do have your address from before so just let me know what you desire.
                Sure for the 2 items! Thanks. Do I pay via Paypal and your email address? Elliott

                Comment


                • #9
                  Yes, please.

                  Comment

                  Working...
                  X