[OBSOLETE] Moes 2 and 3 gang Zigbee wall switch ( cluster EF00)

Hi there, first and foremost thanks for those of you that devoted you time to make these devices work. I just got the MOES 4 Gang Scene switch, I am trying to use the handlers but I can’t even see my device in the list of devices. I see many of you get the device to show up as a thing. I don’t even get that, am I missing anything? Do you make an entry manually?
Thanks much, Martin

Ups, I guess I am referring to the Scene Switch rather than the Wall Switch. Is there any support to Scene Switch?

Hi @bairesman ,

If the device is supported by DTH it should appear as a specific device, not as a thing.
Could you please describe the pairing process you’re performing?
Do you see any messages in hub event log during pairing?
Do you have a model number and/or a link to the product page of your switch?

Hi all,

Whoever is using my DTH with Moes switches, could you please confirm the child lock actually works?
I’m working on edge driver for Tuya switches and would like to know whether ‘Child lock’ capability should be included for those devices.

The ‘Child Lock’ when enabled prevents using only a physical switch (i.e. pressing a button on the switch panel should have no effect). The automations and control from the APP should be working.


Hi @ygerlovin thanks for your reply, this is the switch I am using. I am not able to pair it as I cant figure out how to put it in pair mode.

Thanks for your help!

Hi @bairesman ,
I’m not familiar with this switch and my DTH does not support it.
However, I would suggest to try the following for pairing:

  1. Put your hub into pairing mode. From Smartthings App, go to add device, search nearby. The hub should start blinking
  2. Long press left upper button (5-7seconds)
  3. If this doesn’t help, short press the button with 0.5 sec interval for 5-10 times
  4. If this doesn’t help repeat steps 2-3

Please see the following thread, I think the DTH from it might be what you need

1 Like

@ygerlovin thanks again for your time and efforts. It looks like many people have tried it and gave up as the latest version does not seem to work well with ST. I followed the instructions in the post you provided and finally got it to pair and all but it does not respond to the actions. Too bad as I really liked the device, it is somewhat elegant and could serve multiple purposes.

Cheers! Martin

Can you please try the DTH recommended by this movie:

It is in Portuguese but you can easily translate to English

@dotan_shai I actually speak portuguese and can understand the video. I followed all of the steps and got to see the device but for some reason it does not seem to capture the button activity. Some people are saying there is a newer version (apparently the one I have) that is not very friendly with ST. I would really appreciate the help as I really like the devices and are also priced competitively.
Cheers, Martin

Read here.

seems there is a page with many handler for Zemismart. Try it:

I’ve just ordered the non-touch version of these Moes switches:

Moes Tuya ZigBee Smart Light Switch No Neutral Wire No Capacitor Needed Smart Life 2/3 Way Works with Alexa Google Home 2mqtt|Smart Home Control| - AliExpress

Does anyone know if @ygerlovin DTH will work with these? The references made on the bitbucket repo seems to just be for the touch versions, but maybe they’re all the same inside?


Add your Zbjoin… If it contains EF00 , good chance it will be supported.
Please note that No Neutral module will be consider as a SLEEPY_DEVICE and not as ROUTER.


I have adapted this DTH for a Tuya water valve (_TZE200_akjefhj5), and got it working.

However - I’m looking for help for 2 things -

  1. It looks like Alexa can’t do open / close the valve, so I tried to add Switch capabilities to it to turn it on/off. (I’m not a developer and fudging my way through this).
    I got a Switch to kind of work… In Alexa the switch can turn on (opening the valve), but turns off straight away (and leaves the valve open). The switch can’t hold it’s state.
    Similarly, using the device as a switch in Sharptools does work, so I’m close, but not working correctly. (The switch appears to stay on in Sharptools, but refreshing the page shows it goes Off shortly after being turned on)

  2. Using the Tuya gateway, the device does report battery percentage. I would like to try and bring this into the DTH if possible.

Data * application: 55

  • endpointId: 01
  • manufacturer: _TZE200_akjefhj5
  • model: TS0601
  • zigbeeNodeType: SLEEPY_END_DEVICE
    Raw Description 01 0104 0051 01 04 0000 0004 0005 EF00 02 0019 000A

This is what I’ve got so far -

 *  Moes ZigBee Switch
 *  Copyright 2020 SmartThings
 *  Licensed under the Apache License, Version 2.0 (the "License"); you may not
 *  use this file except in compliance with the License. You may obtain a copy
 *  of the License at:
 *      http://www.apache.org/licenses/LICENSE-2.0
 *  Unless required by applicable law or agreed to in writing, software
 *  distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
 *  WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
 *  License for the specific language governing permissions and limitations
 *  under the License.
public static String version() { return "v0.0.1.20210727" }

private getMODEL_MAP() { 
        'TS0601' : 3

metadata {
    definition(name: "Moes ZigBee Switch", namespace: "Moes", author: "Kotsos", ocfDeviceType: "oic.d.watervalve", vid: "generic-valve") {
        capability "Actuator"
        capability "Configuration"
        capability "Refresh"
        capability "Health Check"
        capability "Valve"
  		capability "Battery"
  		capability "Switch"
        command "childOn", ["string"]
        command "childOff", ["string"]

		fingerprint profileId: "0104", model: "TS0601", manufacturer: "_TZE200_akjefhj5", endpointId: "01", inClusters: "0000,0004,0005,EF00", outClusters: "0019,000A", application: "55", deviceJoinName: "Tuya Valve CSF"


// Parse incoming device messages to generate events
def parse(String description) {
    Map map = [:]
    //def event = zigbee.getEvent(description)

    if (description?.startsWith('catchall:')) {
        log.debug description
        // call parseCatchAllMessage to parse the catchall message received
        map = parseCatchAllMessage(description)
        if (map != [:]) {
            log.debug "ok send event: $map.name : $map.value"
            sendEvent(name: map.name, value: map.value)
    else {
        log.warn "DID NOT PARSE MESSAGE for description : $description"

def close() {
    log.debug "called closed"
    zigbee.command(0xEF00, 0x0, "00010101000100")

def open() {
    log.debug "called open"
    zigbee.command(0xEF00, 0x0, "00010101000101")

def off() {
    log.debug "called off"
    zigbee.command(0xEF00, 0x0, "00010101000100")

def on() {
    log.debug "called on"
    zigbee.command(0xEF00, 0x0, "00010101000101")

//def setLevel(value) {
 //   log.debug "called setLevel with value $value"
 //   if (value >= 0 && value <= 100) {
  //      //String commandValue = "0001020200040000" + zigbee.convertToHexString((value * 10) as Integer, 4)
  //      Map commandParams = [:]
 //       String commandPayload = "0001020200040000" + zigbee.convertToHexString((value * 10) as Integer, 4)
 //       zigbee.command(0xEF00, 0x0, commandPayload)
//    }
// }

def refresh() {
    log.debug "called refresh"
    zigbee.command(0xEF00, 0x0, "00020100")
    //zigbee.command(0xEF00, 0x0, "0002020200")

def configure() {
    log.debug "Configuring Reporting and Bindings."
    zigbee.onOffConfig() + zigbee.levelConfig() + zigbee.onOffRefresh() + zigbee.levelRefresh()

private Map parseCatchAllMessage(String description) {
    // Create a map from the raw zigbee message to make parsing more intuitive
    def msg = zigbee.parse(description)
    Map result = [:]
    switch(msg.clusterId) {
        case 0xEF00: 
            def attribute = getAttribute(msg.data)
            def value = getAttributeValue(msg.data)
            switch (attribute) {      
                case "valve": 
                    switch(value) {
                        case 0:
                            result = [
                                name: 'valve',
                                value: 'closed',
                                data: [buttonNumber: 1],
                                descriptionText: "$device.displayName button was pressed",
                                isStateChange: true

                        case 1:
                            result = [
                                name: 'valve',
                                value: 'open',
                                data: [buttonNumber: 1],
                                descriptionText: "$device.displayName button was pressed",
                                isStateChange: true
    return result

private String getAttribute(ArrayList _data) {
    String retValue = ""
    if (_data.size() >= 5) {
        if (_data[2] == 1 && _data[3] == 1 && _data[4] == 0) {
            retValue = "valve"
        else if (_data[2] == 2 && _data[3] == 2 && _data[4] == 0) {
            retValue = "level"
    return retValue

private int getAttributeValue(ArrayList _data) {
    int retValue = 0
    if (_data.size() >= 6) {
        int dataLength = _data[5] as Integer
        int power = 1;
        for (i in dataLength..1) {
            retValue = retValue + power * _data[i+5]
            power = power * 256
    return retValue

Any help in furthering this would be appreciated.


Hi @Hendo25 ,

I would suggest to open a separate thread for this.

Regarding the switch, I think the problem is that switch state is not updated when you update the state of valve capability.
parseCatchAllMessage should update both states, i.e either the result should contain 2 entries, one for valve, another for switch or you can issue sendEvent command after or before assigning result value.
For battery, it is needed to understand how the values are reported. I would suggest to take a look at the log to see what messages are received in parse method.
Also, you are parsing only catchall calls, that means some device reporting is ignored.
As a side note, on/open and off/close have duplicated code. It is better just call open() from inside on(). Similar for off()


Hi all,
I’m wondering whether edge driver for Moes wall switches would be of interest to community.

The edge driver would have several benefits, compared to DTH

  1. It will run on the hub, so would allow local automation
  2. It will have child lock and backlight settings in the detailed view, not in the settings menu
  3. It will be possible to create automations with those capabilities
  4. It will show all gangs in detailed view
  5. It should detect the specific device model and load the device profile with the correct number of gangs. No need to set the gangs number in settings

However, it will not be able to create child devices. This could be worked around with virtual switches, but it would be needed to do it manually.

Please leave your comments/concerns below.



I’m trying to use this DTH on a 2-gang Moes switch.

Here is the zbjoin event:

zbjoin: {“dni”:“82C2”,“d”:“5C0272FFFE225827”,“capabilities”:“80”,“endpoints”:[{“simple”:“01 0104 0051 01 04 0000 0004 0005 EF00 02 0019 000A”,“application”:“42”,“manufacturer”:"_TZE200_g1ib5ldv",“model”:“TS0601”}],“parent”:0,“joinType”:0,“joinDurationMs”:1350,“joinAttempts”:1}

The device type is updated correctly to the TS0601 parent and the two child devices are created.

But the switch doesn’t work when operating in ST (just spins forever and the switch doesn’t operate).

Here is the log when clicking a switch in ST:

25d2ae45-37c6-4062-ad29-fd4b5110592a 17:18:10: debug sendCommandsToDevice(): delay=300 cmds=[st cmd 0x82C2 0x01 0xEF00 0x00 {00040101000100}, delay 2000] actions=[st cmd 0x82C2 0x01 0xEF00 0x00 {00040101000100}, delay 2000]
25d2ae45-37c6-4062-ad29-fd4b5110592a 17:18:10: debug childOnOff(): endPoint=1 turnOn=false cmds=[st cmd 0x82C2 0x01 0xEF00 0x00 {00040101000100}, delay 2000]
25d2ae45-37c6-4062-ad29-fd4b5110592a 17:18:10: debug createTuyaCommand(): dp=01 type=01 len=0001 value=00 → cmd=[st cmd 0x82C2 0x01 0xEF00 0x00 {00040101000100}, delay 2000]
25d2ae45-37c6-4062-ad29-fd4b5110592a 17:18:10: debug child off: [label:Moes 2 gang switch-SW1, deviceNetworkId:82C2-SW1] parent=[name:Moes 2 gang switch]

It also shows as a SLEEPY_END_DEVICE even though I have the neutral wire plugged in.

Can anyone help please?

The log contains only commands sent to device, no responses from the device. Is it a complete log or you truncated it?

Have you tried to remove the parent device and to add it again?

1 Like

Yes I’ve reset the switch and re-paired it a couple of times. It’s instantly recognised by your device handler but then just doesn’t work.

Should the switch be showing as a router? Is there any way I can force this?

That log is complete, clearly the commands aren’t being received by the switch, just not sure why

@venomizer Are you sure you have a version that requires a neutral wire? Usually, sleepy device is a no neutral version (or a battery powered device). Plugs/switches with neutral wire should be routers.

What do you see in IDE in “Current States”?

Definitely a version that requires neutral wire, and I have it plugged in.

Current states on the parent device shows:

sw1Name: Moes 2 gang switch-SW1
sw2Name: Moes 2 gang switch-SW2