SmartThings Community

[RELEASE] Kodi for SmartThings BETA



When you are editing a piston at the top right of your screen select options and enable “show restrictions”


(Phil Pugh) #264

Thanks, I don’t see the “with” under my “only when” section - i see

2018-01-10 18_15_45-webCoRE Dashboard

Also I am unable to get this to work when a movie is played, if I remove the tracktype line and only use execute when playing this dims the lights. but if i add tracktype back nothing seems to happen and the piston remains at false

Sorry for all this :slight_smile:


It looks like maybe you have an extra if/then/else statement nested in your else statement? I whipped up a piston with the code used in the screen shot earlier so you can just import it using the import code below and modify as needed.

In regards to your tracktype condition not working in the ST app look at your recently tab for the kodi device and when you play a movie look for something that says “[your kodi device] track type is object.item.videoitem.???”. What you find in place of the question marks is what you will want to use as your condition in webcore.

(Phil Pugh) #266

Thanks again, got that imported. In the smartapp I see object.item.videoItem for all video types and nothing after it so looks like this where the problem lies. I am running Kodi 17.4 on Windows 10 and don’t leave the PC on 24/7, not sure if that will make a difference?


Ah yeah sounds like an issue with kodi, wish I could help there but I dont know much about Kodi. Not leaving it on 24/7 shouldnt be an issue, if your using a custom skin in kodi maybe that could mess with the metadata maybe?

(Phil Pugh) #268

Thanks for help anyway with this, I am using a custom skin but when switching back to the default I still see the same.
I will continue playing around with this but for now I think I have got as far as I can on this one.

(Gene Clark) #269

Does this do notifications? I’m looking for a way to display SmartThings notifications while in Kodi.

(Joshua Lyon ( Dashboard)) #270

Yes, it has the capability to send notifications to Kodi. You can use something like WebCoRE to translate ST events into Kodi notifications.

(Gene Clark) #271

Ahh there you are - just posted in Facebook asking for your help. Followed all these instructions and smartapp doesn’t find Kodi on my Fire tv. Any advice?

(Gene Clark) #272

Never mind I guess patience truly is a virtue. My only question is whether entering Kodi user name and password is necessary and what additional benefit it adds to enter that information if it’s not necessary.

(Gene Clark) #273

Also is it the shownotification() command in webCoRE? I can’t seem to get it working.

(Joshua Lyon ( Dashboard)) #274

The Kodi username and password is required if you have a username and password set in the Kodi HTTP server. Without it, you’ll get status updated via UPnP but won’t be able to control anything over HTTP.

(Joshua Lyon ( Dashboard)) #275

You need both a title and a message:

showNotification("Title", "Message")

Take a look starting at the second post I linked above. Or starting somewhere around here: [RELEASE] Kodi for SmartThings BETA

(Gene Clark) #276

Mr. Lyon you are a genius! That did the trick! Thanks so much!!!

(Gene Clark) #277

Do you know where I can find a list of Kodi activities? I’m trying to use kodi to trigger events in webCoRE such as playing movie would turn off all lights.

(Joshua Lyon ( Dashboard)) #278

Did you see the post just a few posts earlier where @David_Van had an example for when movies play? [RELEASE] Kodi for SmartThings BETA

(Gene Clark) #279

Ahh that makes sense! I see where you can find out status information. There’s no track type info and freaky not sure when you’d see that anyway. Also don’t see activity type information either. But maybe both of those two require playing my own files instead of streaming…? I’m new to Kodi and not sure, but at least now I’ve got a starting point. Thanks again - your helpfulness is really appreciated!

(Steve ) #280

Yeah I think that depends on the person who’s hosting the file or even the add-on to correctly list what type or genre etc it is.
I think possibly turn on the debug log on Kodi and that would display what’s being played.
I have got a piston for adjusting my lamp but it got on my nerves as i realised I didn’t want it every time so it’s paused now lol

(Gene Clark) #281

How did you turn on debugging in Kodi? Here’s the device settings in SmartThings app and don’t see anything.

I’d wondered too if pistons may get annoying and be nothing more than novelty just the same as when first connecting speakers to SmartThings with verbal notifications everywhere - gets irritating after a while.

(Steve ) #282

The Kodi debug is on Kodi itself nothing to do with SmartThings.
You need to go into the settings on Kodi and turn on debugging.
Are you the same guy I’ve been talking to on Facebook with the freeboard setup lol