[ST Edge] Lidl Bulb Zigbee Driver

It can be done with a custom device presentation using the “values” and “range” properties. Eg.

"component": "main",
"capability": "colorTemperature",
"version": 1,
"values": [
    {
        "key": "colorTemperature.value",
        "enabledValues": [],
        "range": [
            2200,
            6500
        ],
        "step": 1
    }
]

This way, those buttons act according to the specified range, for example in the range of 2200K - 6500K, the value for the first one is 2630K.

This is the VID as a reference: 1491a1e5-b77e-3e8b-8fad-49ed566a5ca8, remember you can get the original device-config using the command:

smartthings presentation:device-config vid -j -o=devConfigPres.json

Link just as a reference:

1 Like

Here are the to types I have.

I will test them using your driver and report what I find.


Also I will need the link to your driver channel

Ecosmart was already included in the initial version

I have added Sengled as profile switch and level.

The link is here

it will take about 12 hours to update

@Mariano_Colmenarejo with 1.1 driver change Ecosmart bulb’s details page now does not show level and temperature update. I have tried clearing cache restarting hub, but no change.


Bulb is On, but shows 0% for level and temperature.
I can turn bulb on and off, but there is no update even on that status, icon is just spinning, and eventually throws an error message.

Before this update everything was working

@milandjurovic71,

The operating code has not changed, I have only added the version information preferences and added the fingerprint of the sengled bulb.

I have tried it on mine before publishing it and well.
It will not have been updated yet, according to say they are 12 hours, 7 hours have passed, although the preferences seem to be seen before.

Let him see if he updates himself, so they can see if the procedure works or what problems he has.

If it is not fixed, delete the driver from the app and reinstall it. You will have to remove the device, remove the driver and reinstall driver and device

1 Like

My EcoSmart bulb linked to your driver is working fine.

1 Like

Will the version appear in settings, preferences?

Yes the version appears under settings. Version 1.1 (Sep 2021) “Added in Preferences: Version info & Sengled E11-G13”

1 Like

I added a Sengled E11-G13 bulb with your driver. It is a dimmable warm white bulb, with no adjustment for color temperature.
So far it works good with your driver. Since it is not color temperature adjustable NO adjustment slider appears in the app.

1 Like

Yes, the fingerprint is with the profile switch-level

I too can confirm the Sengled build is working as expected.

1 Like

Hello @nayelyz,

I have created the custom capacity and the presentation for colorTemperarue with limits 2700k to 5500k, according to the tutorial, except that the configuration file that creates the VID I have created it with the ID of the profile instead of the DTH.
I already have the presentation VID placed in the profile file as it is in the custom-capability example which is in the sampleDrivers folder.

metadata:
  mnmn: SmartThingsCommunity
  vid: "bdd33c60-0c36-3ffb-a5f3-0c277fa85230"
  deviceType: Light
  ocfDeviceType: oic.d.light
  deviceTypeId: Light

The presentation does not change in the app.

Do I also have to put the custom capacity created in the profile file and manage it in lua.ini or is it valid with the custom VID presentation only?

I have also created the configuration file of the presentation in .yaml instead of .json, as in your example, but it doesn’t work either

I have rewritten the values 2700, 5500 in the configuration file of the presentation once created and it does not work either

What am I doing wrong?

Thanks

I put the log process of creating the cuatom-capability and the presentation files, in case you see something wrong

**Custom capability colorTemperature creation:**

PS C:\Users\Mariano\smartthings> .\smartthings capabilities:create            
? Capability Name: Color Temperature  
? Select an action... Add an attribute
? Attribute Name:  colorTemperature
? Select an attribute type: integer     
? Minimum value (default: no minimum):  2700
? Maximum value (default: no maximum):  5500
? Unit of measure (default: none):
? If you want to add a basic command, enter a command name now (or hit enter for none):
(Basic commands are simple commands that set the attribute to a specific value.)
? Select an action... Finish & Create

Capability: legendabsolute60149.colorTemperature

Attributes:
┌──────────────────┬─────────┬─────────────────────┐
├──────────────────┼─────────┼─────────────────────┤
│ colorTemperature │ integer │ setColorTemperature │
└──────────────────┴─────────┴─────────────────────┘
Commands:
┌─────────────────────┬────────────────┐
│ Name                │ Arguments      │
│ setColorTemperature │ value: integer │
└─────────────────────┴────────────────┘

PS C:\Users\Mariano\smartthings> .\smartthings capabilities:presentation:create legendabsolute60149.colorTemperature 1 -j -i=C:\Users\Mariano\Documents\Mariano\VSC\SampleDrivers\my-capabilities\colorTemperature.json 
{
    "dashboard": {
        "states": [
            {
                "label": "{{colorTemperature.value}} {{colorTemperature.unit}}",
                "alternatives": null
            }
        ],
        "actions": [],
        "basicPlus": []
    },
    "detailView": [
        {
            "label": "Color Temperature",
            "displayType": "slider",
            "slider": {
                "range": [
                    2700,
                    5500
                ],
                "step": 1,
                "unit": "colorTemperature.unit",
                "command": "setColorTemperature",
                "argumentType": "integer",
                "value": "colorTemperature.value",
                "valueType": "integer"
            },
            "state": null
        }
    ],
    "automation": {
        "conditions": [
            {
                "label": "Color Temperature",
                "displayType": "slider",
                "slider": {
                    "range": [
                        2700,
                        5500
                    ],
                    "step": 1,
                    "unit": "colorTemperature.unit",
                    "value": "colorTemperature.value",
                    "valueType": "integer"
                }
            }
        ],
        "actions": [
            {
                "label": "Color Temperature",
                "displayType": "slider",
                "slider": {
                    "range": [
                        2700,
                        5500
                    ],
                    "unit": "colorTemperature.unit",
                    "command": "setColorTemperature",
                    "argumentType": "integer"
                }
        ]
    },
    "id": "legendabsolute60149.colorTemperature",
    "version": 1


PS C:\Users\Mariano\smartthings>.\smartthings presentation:device-config:generate 115c0572-4d8e-3315-9d06-6d5a80513ba0 -o=deviceConfig.json -j

{
    "dashboard": {
        "states": [
            {
                "component": "main",
                "capability": "switch",
                "version": 1,
                "idx": 0,
                "group": "main",
                "values": []
            }
        ],
        "actions": [
            {
                "component": "main",
                "capability": "switch",
                "version": 1,
                "idx": 0,
                "group": "main"
            }
        ]
    },
    "detailView": [
        {
            "component": "main",
            "capability": "switch",
            "version": 1,
            "values": [],
            "patch": []
        },
        {
            "component": "main",
            "capability": "switchLevel",
            "version": 1,
            "values": [],
            "patch": []
        },
        {
            "component": "main",
            "capability": "colorTemperature",
            "version": 1,
            "values": [],
            "patch": []
        },
        {
            "component": "main",
            "capability": "refresh",
            "version": 1,
            "values": [],
            "patch": []
        }
    ],
    "automation": {
        "conditions": [
            {
                "component": "main",
                "capability": "switch",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            },
            {
                "component": "main",
                "capability": "switchLevel",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            },
            {
                "component": "main",
                "capability": "colorTemperature",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            }
        ],
        "actions": [
            {
                "component": "main",
                "capability": "switch",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            },
            {
                "component": "main",
                "capability": "switchLevel",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            },
            {
                "component": "main",
                "capability": "colorTemperature",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            },
            {
                "component": "main",
                "capability": "refresh",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            }
        ]
    },
    "type": "profile"
}

PS C:\Users\Mariano\smartthings>.\smartthings presentation:device-config:create -j -i deviceConfig.json

{
    "mnmn": "SmartThingsCommunity",
    "vid": "bdd33c60-0c36-3ffb-a5f3-0c277fa85230",
    "version": "0.0.1",
    "type": "profile",
    "dashboard": {
        "states": [
            {
                "component": "main",
                "capability": "switch",
                "version": 1,
                "idx": 0,
                "group": "main",
                "values": []
            }
        ],
        "actions": [
            {
                "component": "main",
                "capability": "switch",
                "version": 1,
                "idx": 0,
                "group": "main"
            }
        ]
    },
    "detailView": [
        {
            "component": "main",
            "capability": "switch",
            "version": 1,
            "values": [],
            "patch": []
        },
        {
            "component": "main",
            "capability": "switchLevel",
            "version": 1,
            "values": [],
            "patch": []
        },
        {
            "component": "main",
            "capability": "colorTemperature",
            "version": 1,
            "values": [],
            "patch": []
        },
        {
            "component": "main",
            "capability": "refresh",
            "version": 1,
            "values": [],
            "patch": []
        }
    ],
    "automation": {
        "conditions": [
            {
                "component": "main",
                "capability": "switch",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            },
            {
                "component": "main",
                "capability": "switchLevel",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            },
            {
                "component": "main",
                "capability": "colorTemperature",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            }
        ],
        "actions": [
            {
                "component": "main",
                "capability": "switch",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            },
            {
                "component": "main",
                "capability": "switchLevel",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            },
            {
                "component": "main",
                "capability": "colorTemperature",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            },
            {
                "component": "main",
                "capability": "refresh",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            }
        ]
    },
    "presentationId": "bdd33c60-0c36-3ffb-a5f3-0c277fa85230",
    "manufacturerName": "SmartThingsCommunity"
}

@Mariano_Colmenarejo please add one for 2700-6500K too :grinning:

1 Like

Sorry for the confusion, you don’t have to create a custom capability. Using the standard colorTemperature, you can override its value range from the device presentation.
For this, you have to follow these steps:

  1. Create a device-config. I used the VID you shared to get the original device-config and changed it accordingly. This is how it should look like:
Open to see device-config
{
    "type": "profile",
    "dashboard": {
        "states": [
            {
                "component": "main",
                "capability": "switch",
                "version": 1,
                "group": "main",
                "values": []
            }
        ],
        "actions": [
            {
                "component": "main",
                "capability": "switch",
                "version": 1,
                "values": []
            }
        ]
    },
    "detailView": [
        {
            "component": "main",
            "capability": "switch",
            "version": 1,
            "values": [],
            "patch": []
        },
        {
            "component": "main",
            "capability": "switchLevel",
            "version": 1,
            "values": [],
            "patch": []
        },
        {
            "component": "main",
            "capability": "colorTemperature",
            "version": 1,
            "values": [
                {
                    "key": "colorTemperature.value",
                    "range": [
                        2700,
                        5500
                    ],
                    "step": 1
                }
            ],
            "patch": []
        },
        {
            "component": "main",
            "capability": "refresh",
            "version": 1,
            "values": [],
            "patch": []
        }
    ],
    "automation": {
        "conditions": [
            {
                "component": "main",
                "capability": "switch",
                "version": 1,
                "values": [],
                "patch": []
            },
            {
                "component": "main",
                "capability": "switchLevel",
                "version": 1,
                "values": [],
                "patch": []
            },
            {
                "component": "main",
                "capability": "colorTemperature",
                "version": 1,
                "values": [
                    {
                        "key": "colorTemperature.value",
                        "range": [
                            2700,
                            5500
                        ],
                        "step": 1
                    }
                ],
                "patch": []
            }
        ],
        "actions": [
            {
                "component": "main",
                "capability": "switch",
                "version": 1,
                "values": [],
                "patch": []
            },
            {
                "component": "main",
                "capability": "switchLevel",
                "version": 1,
                "values": [],
                "patch": []
            },
            {
                "component": "main",
                "capability": "colorTemperature",
                "version": 1,
                "values": [
                    {
                        "key": "colorTemperature.value",
                        "range": [
                            2700,
                            5500
                        ],
                        "step": 1
                    }
                ],
                "patch": []
            },
            {
                "component": "main",
                "capability": "refresh",
                "version": 1,
                "values": [],
                "patch": []
            }
        ]
    }
}

Run the command smartthings presentation:device-config:create using the input above.

  1. Put the resulting VID in your driver’s profile metadata without ", eg:
metadata:
  vid: 1491a1e5-b77e-3e8b-8fad-49ed566a5ca8
  mnmn: SmartThingsCommunity

You might have to uninstall and install the device again to refresh the presentation. If you’re using an Android device, you can delete the app’s cache, just go to your mobile’s settings > apps > look for the ST app > storage > delete cache

I have created with @nayelyz help a presentation for colorTemperature between 2700k and 6000k, so that it can be used for most lights. Works in detail view and automations view.

@milandjurovic71, I am going to test it before publish it in the channel.
It seems a little slow in updating the color of the ends 2700 & 6000.
If you click on the default temperature icons, which are 3030k and 5681k, it goes fast.

It is necessary clear the app cache for the changes take effect or reinstall device. I don’t know if the automatic version is updated what will happen

Thanks @nayelyz

2 Likes

@nayelyz,
The custom presentation does not show values in the range from 2700k to 6000k in “automations” ,“actions” view.
It shows it correctly in “automations”, “conditions”

In vid created two view are equal.

I don’t know if anyone else noticed this

Can you share the VID, please?

{
    "mnmn": "SmartThingsCommunity",
    "vid": "caf5c1b2-3110-3a85-bd2b-a7437d361bae",
    "version": "0.0.1",
    "type": "profile",
    "dashboard": {
        "states": [
            {
                "component": "main",
                "capability": "switch",
                "version": 1,
                "idx": 0,
                "group": "main",
                "values": []
            }
        ],
        "actions": [
            {
                "component": "main",
                "capability": "switch",
                "version": 1,
                "idx": 0,
                "group": "main"
            }
        ]
    },
    "detailView": [
        {
            "component": "main",
            "capability": "switch",
            "version": 1,
            "values": [],
            "patch": []
        },
        {
            "component": "main",
            "capability": "switchLevel",
            "version": 1,
            "values": [],
            "patch": []
        },
        {
            "component": "main",
            "capability": "colorTemperature",
            "version": 1,
            "values": [
                {
                    "key": "colorTemperature.value",
                    "enabledValues": [],
                    "range": [
                        2700,
                        6000
                    ],
                    "step": 1
                }
            ],
            "patch": []
        },
        {
            "component": "main",
            "capability": "refresh",
            "version": 1,
            "values": [],
            "patch": []
        }
    ],
    "automation": {
        "conditions": [
            {
                "component": "main",
                "capability": "switch",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            },
            {
                "component": "main",
                "capability": "switchLevel",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            },
            {
                "component": "main",
                "capability": "colorTemperature",
                "version": 1,
                "values": [
                    {
                        "key": "colorTemperature.value",
                        "enabledValues": [],
                        "range": [
                            2700,
                            6000
                        ],
                        "step": 1
                    }
                ],
                "patch": [],
                "exclusion": []
            }
        ],
        "actions": [
            {
                "component": "main",
                "capability": "switch",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            },
            {
                "component": "main",
                "capability": "switchLevel",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            },
            {
                "component": "main",
                "capability": "colorTemperature",
                "version": 1,
                "values": [
                    {
                        "key": "colorTemperature.value",
                        "enabledValues": [],
                        "range": [
                            2700,
                            6000
                        ],
                        "step": 1
                    }
                ],
                "patch": [],
                "exclusion": []
            },
            {
                "component": "main",
                "capability": "refresh",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            }
        ]
    },
    "presentationId": "caf5c1b2-3110-3a85-bd2b-a7437d361bae",
    "manufacturerName": "SmartThingsCommunity"
}

Yes, I have notified author of this driver, couple days ago. It goes from 1 to 30000K. I think that @Mariano_Colmenarejo is working on it.
@nayelyz is it possible to create one Edge driver with settings that can be changed by user to show correct Temperature range, as different manufacturers have different ranges