[OBSOLETE] KuKuHarmony - DTH and SmartApp that support to control devices in Logitech Harmony(using Harmony-API)

You’ll have to search the forum for Webcore, then install it into Smartthings. Then you’ll need to make your AV unit KuKu buttons available to Webcore in it’s settings. Then you’ll have to create a piston to do the actual commands. I’ll see if I can find Webcore for you and post a link here.

I’d be willing to share my piston for my AC unit with you and you can modify it to use your services and commands. We can do that through PM and such as not to distract from this thread.

You can do short pauses in Webcore in-between your commands. Or possibly even something more elaborate as it’s VERY powerful.

1 Like

I am using Kuku Harmony for controlling my Aircondition device.
nodejs part runs on my PI3 server.
when I reboot PI3 it works for a few attempts. But then it starts not working.

For example , to turn off the device following endpoint is called:
http://192.168.254.199:8282/hubs/harmony-hub/devices/arcelik-climate-control/commands/power-off

sometimes it returns:
Cannot GET /hubs/harmony-hub/devices/arcelik-climate-control/commands/power-off

and when this happens, it does not work anymore.
Until I restart PI3.

Maybe I am using an old version.
How can I check if I have the most recent and stable version ?

and how can I trobleshoot “can not get” problem further ?

when I get “can not get” for “power-off” command, I can get command list as:

http://192.168.254.199:8282/hubs/harmony-hub/devices/arcelik-climate-control/commands/
{“commands”:[{“name”:“18”,“slug”:“18”,“label”:“18”},{“name”:“19”,“slug”:“19”,“label”:“19”},{“name”:“20”,“slug”:“20”,“label”:“20”},{“name”:“21”,“slug”:“21”,“label”:“21”},{“name”:“22”,“slug”:“22”,“label”:“22”},{“name”:“23”,“slug”:“23”,“label”:“23”},{“name”:“24”,“slug”:“24”,“label”:“24”},{“name”:“25”,“slug”:“25”,“label”:“25”},{“name”:“26”,“slug”:“26”,“label”:“26”},{“name”:“27”,“slug”:“27”,“label”:“27”},{“name”:“28”,“slug”:“28”,“label”:“28”},{“name”:“29”,“slug”:“29”,“label”:“29”},{“name”:“30”,“slug”:“30”,“label”:“30”},{“name”:“PowerOff”,“slug”:“power-off”,“label”:“Power Off”},{“name”:“Fan Speed”,“slug”:“fan-speed”,“label”:“Fan Speed”},{“name”:“Horizontal swipe on/”,“slug”:“horizontal-swipe-on”,“label”:“Horizontal swipe on/”},{“name”:“jet cool”,“slug”:“jet-cool”,“label”:“jet cool”},{“name”:“Mode”,“slug”:“mode”,“label”:“Mode”},{“name”:“Plasma”,“slug”:“plasma”,“label”:“Plasma”},{“name”:“Power”,“slug”:“power”,“label”:“Power”},{“name”:“Swipe on/off”,“slug”:“swipe-onoff”,“label”:“Swipe on/off”},{“name”:“Temp Down”,“slug”:“temp-down”,“label”:“Temp Down”},{“name”:“Temp Up”,“slug”:“temp-up”,“label”:“Temp Up”}]}

@KuKu , any ideas about this problem ?

thanks

Hm…Well…

When there is a remote control problem, I found a log that hub disconnection event and there was a problem recovery of connection at that time.

But there is no solution in harmony-api library for that problem without hub reboot or daemon reboot.

I am so sorry that I can not give you a solution right now.

@KuKu , that’s fair. What about a workaround ?
Would you suggest restarting the daemon frequently ? (maybe with 5 minute intervals)
if yes, what is the best way of doing that ? (just kill the app process so “forever” will run it again ?)

or any more intelligent way of doing this ?
in fact, if I could find the piece of code that results “can not get” output, I would just make the daemon restart there but I couldn’t find where this error is thrown.

@Kuku,
any ideas on my previous post ?

I don’t have the code written, but I have a PI3 that sometime offlines the KuKu Docker under IP/Wifi changes. My thought is to write a bash script and curl the endpoint you show above. If you don’t get the results you want just restart the KuKu docker container.

This is the command I use (cheap and dirty): “docker restart $(docker ps -q)”

1 Like

@Bloodtick_Jones
that is a good idea but this endpoint either power off or power on my air condition. I don’t want my check script to trigger it for each check.
is there a generic endpoint which I can use to test ?

@KuKu
actually I really understand a little javascript. if you can point me to the code where this “no hubs available” issue occur, I may put a check there and then maybe restart the node app…

If I have my hub behind a VLAN, where would I enter the direct IP for it? Because, it won’t find it otherwise.

Guys, are you facing an issue with other devices integrations with the harmony hub (such as google home / alexa or smartthings) when we enable the sev option in the harmony app that causes the integration to stop working (no longer detects the hub)? Or is it only me?

Trying to get KuKuHarmony API working and I’m so close.

  • I edited the Harmony Hub settings (via the App) to Enable XMPP and saved the change.
  • I have harmony-api up and running on raspberrypi 4b in docker.
  • I execute 192.168.xx.xx:8282/hubs and get the following result: {“hubs”:[“great-room”]}
  • I add the KuKu Harmony SmartApp in SmartThings and enter the above IP address. It connects, but when I select Add a device… it has “Discovering Harmony Hub. Please wait…” on the Add Device page by it never completes.

I have all the Device Type Handles in the IDE and they are Published.
I’ve tried deleting and re-adding the SmartApp and reconnecting. Still the same behavior.
I thought the name of the hub might be an issue (it had a space in the name that was showing up as a dash in the API) so I:

  • Renamed the hub via the Harmony App to remove the space.
  • Rebooted the Harmony Hub
  • Restarted the API
  • Confirmed the new name was now returned via the /hubs as {“hubs”:[“greatroom”]}
  • Installed the KuKu Harmony SmartApp.
  • Entered the IP and it connects, but it still stops at Discovering Harmony Hub. Please wait… under Add Device.

I did some more digging and this led me to try the following command:

I execute 192.168.xx.xx:8282/devices and I receive: Cannot GET /devices

So connection to the hub is successful, but device retrieval is not working.

KuKu Harmony Version: V1.6.501
Harmony Hub Software Version: 4.15.280

What am I missing @KuKu?

Thanks,

Tom

Did you also add in all of the Device Type Handlers in the IDE?

Yes, same issue, it will never work if xmpp is turned on, and to get the hub back discoverable needs xmpp turned off and have the hub reset (from scratch), sometimes (very randomly) it would work when its on but eventually it doesn’t work, i also emailed logitech about it and no response.

This is what I have in Device Handlers for KuKu Harmony

1 Like

Hi @fearz, xmpp is set as needed. The API is showing it is discovering the hub just fine.

Does anyone have any other ideas???

From a web browser (Chrome, Safari, etc) with just

http://192.168.xx.xx:8282

do you see something like this showing the showing the hub and its devices?

I do, here’s the result from http://192.168.xx.xx:8282:

So it appears the API is working just fine.

This points to the SmartApp as the source of the issue. I did try removing and re-pulling the Git repository and publishing the Device Handlers, but I didn’t see any change in behavior.

And here is what I get when I select the Devices:

Yes, the API is working fine and finding your hub(s) correctly. It is the SmartApp.

I no longer have the SmartApp and went a different direction with Hubitat+webCoRE, but do remember you need include the full address “192.168.x.x:8282” in the SmartApp to make it work. The SmartApp is curious the way it works, and has a hitch to ensure it picks up that address. Try adding the address and return to the add device, then go back to the address again and hit save.