[Release] Logitech Harmony Hub Driver v0.1.20230311

Are you using Virtual SmartThings dimmers mapped into the Harmony Hub SmartThings integration? If so, using the ST App, can you see the virtual dimmer values changing when the +/- buttons are pressed?

Yeah, I'm using virtual dimmers in ST. I can see the + / - button presses if I select either of the outlet buttons (which I'm not even using) but not for the lamp buttons (which I am using). But the webCoRE pistons I use for the lamp buttons both work perfectly.

@ogiewon

How could I go about sending a pause command for streaming?

Currently, you would need to send a ‘Pause’ “device command” to whatever device is streaming the content. Afterwards, you’d probably need to send a ‘Play’ command. I do not know the exact syntax of those commands off the top of my head, but they would be good to add to the Parent Device as well, so that they’d control whatever the currently active Activity is...:thinking:

[UPDATE] I have released a newer and simpler solution - please see next post for details.

@Bago - I have added two new custom commands to my Harmony Hub Parent Driver. You will now find a playPress("deviceID") and a pausePress("deviceID") pair of commands that you can call as a Custom Action from Rule Machine, so long as you pass in the appropriate Harmony Hub Device ID that needs to receive these commands. I tested both commands using my Apple TV and it works great. I was hoping to be able to automagically know what the correct deviceID is for each active Activity, but that will take a while longer to sort out, if possible....

For now, you can find the deviceID by looking through the State Variables section on the Harmony Hub Parent device details page, and find the following information. You will then know the correct numeric 'id' for each of your Harmony devices, which can be passed into the new pausePress() and playPress() commands as strings.

HarmonyDevices : [{id=56680216, label=Onkyo AV Receiver}, {id=70173846, label=Sony Blu-ray Player}, {id=60244164, label=Apple TV}, {id=67598832, label=Windows Computer}, {id=56680219, label=Sharp TV}, {id=56680218, label=Microsoft Xbox One}, {id=56680217, label=Microsoft Xbox 360}]

Hope this helps! New code is available in my GitHub repository already.

1 Like

@Bago - I found some additional time this evening and have updated my GitHub repo with a newer version that automagically determines the proper deviceId of the current Harmony Activity to allow the Play/Pause/Stop custom commands to now work. This eliminates the need to pass in the Harmony deviceId to these commands. Thus, it should be much simpler to use.

I have removed the playPress() and pausePress() custom commands in this latest 20200104 version. I have added play(), pause(), and stop() which do not require any arguments be passed into them. Hopefully this makes your rules easier to implement.

Please give it a try and let me know if it works for your Harmony Activities that support Play/Pause/Stop commands. If the commands are not supported, there should be a message in the live logs. After updating the driver code and saving it, please be sure to open the Harmony Parent device and click REFRESH to allow the driver to discover the necessary information to allow the new functionality to work correctly.

3 Likes

Thanks @ogiewon. Works great. A more elegant solution than I came up with (didn’t know about transportbasic).

1 Like

Thanks for the quick feedback!

Nor did I, until I spent some time researching the JSON that the Harmony Hub returned in detail. Took a little while to find a common field that appears to indicate the presence of the Play/Pause/Stop type of controls. I am not 100% certain that this will work for all users' device/activity combinations. Glad to hear it works for yours!

2 Likes

Hello! I'm having trouble getting the initial setup to the hub work. Searched the forum and found another user had a similar error, These are the steps they did to fix, but I'm having some trouble understanding what some of this means.

Here is my error: [error]java.net.NoRouteToHostException: No route to host (Host unreachable) on line 401 (initialize)

The child devices do not show up and nothing if functional. The harmony hub does not respond to ping requests. Using tp-link Deco M9 routers if that helps.

Are you sure you’re using the correct IP address for the Harmony Hub? You should be able to ping the Harmony hub. If not, it sounds like a network issue.

Yes, I set the harmony to a static IP as well. I agree that it's probably a network issue; I was just hoping someone might have gone through the same thing and have some insight on how to troubleshoot that!

Can you ping the Harmony hub?

No.

Look in the Harmony App on your phone, click the top left menu button (three horizontal lines), then click About, then Versions. This is where you will find the actual IP address being used by the hub.

Already got that part sorted out - the app shows the same IP that I configured for it in the router. In another post with a similar issue, it was fixed, but I don't understand how... He wrote: " I couldn't telnet to 8088...of course HE couldn't do anything with it."

Not sure what telnet to 8088 means and how to resolve that issue.....

Let the ping command run for a while... on Windows, use “ping yourIPaddress -t” to allow it to run until you Ctrl-C to kill it. The Harmony hub may need a few seconds to wake up and reply to a ping command.

Using Telnet to a specific port on a device is an easy troubleshooting step. It is not necessary in this case. It basically helps to know if the device is listening on a specific port or not.

What version of software is your Harmony Hub running? The Harmony hub software should be 4.15.280.

I have 3 Harmony Hubs. I was just testing PING commands to all three. Two of the three worked fine. The third Harmony Hub had to be unplugged from power, and then powered back on before it would respond to a PING command. Not sure why...but might be worth rebooting your Harmony hub to see if it makes a difference.

1 Like

Hub: 4.15.280
App: 5.7.7
Build: 212

Have unplugged twice and replugged: both times the device still does not respond to pings. (It give me either a "No route to host" or "Host is down" error.

Wish I could help more. Without any networking experience using your WiFi hardware, I have no idea where to troubleshoot from here.

I assume you can ping other devices on your home home network, including the Hubitat hub? How about other WiFi devices? Perhaps your router is configured to block traffic between your wired LAN devices and the WiFi devices? The Harmony Hubnis not connected to a special “Guest” WiFi network, is it? Those are often blocked from access the main network. Just a guess...

Also, you only have one device in your home acting as a true network Router, correct? Multiple routers daisy chained together will create a double NAT scenario that could cause the problems you’re seeing.

2 Likes

To anyone else who stumbles upon this issue, this was the fix. I keep my smart devices on a guest network segregated from everything else, but Harmony needs to be on the main network. Thanks so much!!!!

Cheers!

2 Likes