Change icons in new app

bar code is just for high security devices (S2) which most new devices are now. it might take a while for the correct icon to appear.

Can someone help me figure out how to find this line of code, i did a keyword search for “ofcDeviceType” on my DTH code and got 0 results

You would need to add it to the metadata

Sorry, not catching on, can you clarify a bit more. My device is a qubino shutter switch and the icon is a window blind, looking at the code i don’t see “ocfDeviceType” in the actual code anywhere. I guess i don’t understand what you mean by metadata, i assumed that meant the actual code of the device handler

The ocfDeviceType (ocf not ofc) needs to be added to the arguments of definition() in your DTH if you don’t already have it. So if you have:

definition( name: 'My Device', author: 'Joe Bloggs', namespace: 'fragrantegg' )

… you would change it to …

definition( name: 'My Device', author: 'Joe Bloggs', namespace: 'fragrantegg', ocfDeviceType: 'oic.d.blind' )

There is a limited range of possible values, some of which you will see an earlier post in this thread. If you look at the icons that are displayed when you add a device by type in the mobile app, that might give you clues what some of them look like.

After adding to your DTH you will need to save and publish it again, and you will probably benefit from going to the device pages for your devices using that handler in the IDE, Editing the page, making a change to something significant like the Device Name or Device Label, and hitting Update. You can do it again to revert the changes. That usually gives things enough of a kick to make your app update the presentation it uses.


Thank you for that great explanation

I’m not trying to make self-published DTH, so is there a solution for my case:
I have two zigbee smart outlets. One shows up with an outlet icon (the brand Innr, sold on Amazon). The other (Securifi Peanut) shows as a switch. Both have the same DTH: Zigbee Switch.

I seem to be able to select another builtin device handler like Zigbee Metering Plug and this will cause the Peanut to show an outlet icon, yet it then also attempts to report power consumption, which the Peanut does not do. I can ignore this, of course. Is there a better way though? Change the icon for the Peanut? Or another published official device handler that reflect Zigbee Outlet (I see none as I scanned the list twice).


PS: If I must edit some metadata, I’m tracking I need “oic.d.smartplug”

PPS: The Zigbee Metering Plug device executes in the cloud, while the Zigbee Switch (preferred) executes locally.

If you don’t have a custom DTH you cannot change the DTH metadata to change the icon.

That’s not the answer I was looking for :frowning:

Most of the icons discussed here have an on and an off state, coloured for on, grey for off. How is this controlled? It seems to happen automatically for many classes of device, but not all. I have, for example, a thermostat, I would like the icon to go to the off state, when the mode is set to off.

It only happens for certain devices. Thermostat does not have an off icon.

OK! However, I notice that, if I leave my mobile with the Smartthings App open and return to it 10 minutes later, that all the dashboard icons, including the thermostat, are grey for a short time before acquiring colour. This appears to be connected to the App checking the status of each device.

There is no way to use the thermostat off icon. Only shows when checking status.

hey, thanks…it works for chaging the MyQ Garage Door Opener DTH…it was shown in the app as a simple “contact sensor” but now i used the ocfDeviceType parameter “oic.d.garagedoor” and it seems to be a garage door :sunglasses:

1 Like

How do edit the DH? Is this something you can do in the app or something external?

If this is a custom handler you will be able to edit it on IDE.
login to your account here:

Hi there,

Thanks. Where do I get the ID info reqested on form on products. Is that listed in Smartthings app?.
Couldn’t find anything in info




Sorry, don’t know the difference or how or where to edit the IDE.

Is there a document that shows this?