Change Channels

Rene,

Bravo on a fantastic plug in. I have it running great, and Echo now controls my AV stuff. Fantastic work!

I have looked around on these boards and not found a great answer to this. I have a wakeup event triggered by a google calendar event to slowly turn on my lights over 1/2 hour, disarm the alarm, turn up the thermostats, etc. What I’d like to also do is have the TV turn on and to a specific (news/weather) channel. I can get the TV to come on, no problem. However, getting a specific channel is more problematic. Do you have a way to do this?

-I figure I could create a child device and have it send the channel number via that.
-I thought I had read about using the plug in to call the “favorites” channel that Harmony sets? I haven’t again been able to find this or figure out how to do that …

Any help is appreciated! Thanks!

NY

The way I did it was create a child device for my satellite box and create buttons for the numbers.

Then I created a vera scene, manually triggered with an action for each number and a delay between.

So for for channel 601 immediate action 6, delay 1 second 0 etc.

Then I call the scene from pleg after turning the harmony scene for watch satellite.

Hi NY,

Thanks for the complement.

My self I have the channel set as part of the Harmony activity as the same receiver is used for radio as well. So that is an option and the other is a scene with PLEG as Chris explained.

You can also use a little LUA code as part of the scene as below. When you then use the MultiSwitch plugin for your favourite channels you can use that as scene triggers.

luup.call_action("urn:rboer-com:serviceId:Harmony1", "IssueDeviceCommand",{DeviceID="12345678",Command="6",Duration="0"},HDID)
luup.call_action("urn:rboer-com:serviceId:Harmony1", "IssueDeviceCommand",{DeviceID="12345678",Command="0",Duration="0"},HDID)
luup.call_action("urn:rboer-com:serviceId:Harmony1", "IssueDeviceCommand",{DeviceID="12345678",Command="1",Duration="0"},HDID)

You must set the correct DeviceID for how the Harmony knows your TV. You can see that as variable DeviceID of your TV device. HDID is de device number of the main Harmony device.

You may need to put in a little delay to allow the TV to be fully switched on. Best to then make a function and use a luup.call_delay to call that function.

Cheers Rene

The Vera scene with delays between numbers didn’t work for me. Will try the LUA code bit and see if that works.

Thanks for the help and for the plug-in, as far as that goes! ;D

Hi

So it is not possible to change channels using the Harmony plug-ins http request handler ?

To send a json http command to change to a certain channel number ?

Thank you.

Hi,

Yes, you can but you still have to send the separate commands for each button press. You cannot populate the channel as a single number in a single request. At least I have not see commands for any device to do that.

Cheers Rene

[quote=“reneboer, post:6, topic:191674”]Hi,

Yes, you can but you still have to send the separate commands for each button press. You cannot populate the channel as a single number in a single request. At least I have not see commands for any device to do that.

Cheers Rene[/quote]

Hi Rene

Google Home only supports one Harmony hub. I was thinking for the second hub / room of using IFTTT Webhooks to send a http request to change to a certain channel number.

But I dont think I can send more than one command url with webhooks so it probably wont work.

Thanks.

Hi,

As FYI. The latest version 3.3 does support the ChangeChannel command. See user guide.

Cheers Rene

I did manage to previously get channel changes working using PLEG Actions and some Lua code:

Channel Number 604

luup.call_action("urn:rboer-com:serviceId:Harmony1", "IssueDeviceCommand",{DeviceID="57931758",Command="6",Duration="0"},184) luup.call_action("urn:rboer-com:serviceId:Harmony1", "IssueDeviceCommand",{DeviceID="57931758",Command="0",Duration="0"},184) luup.call_action("urn:rboer-com:serviceId:Harmony1", "IssueDeviceCommand",{DeviceID="57931758",Command="4",Duration="0"},184)

I then created buttons in the Imperihome app to send a json http command to Vera to run a particular PLEG Action to change the channel etc. This worked well but was a bit of a pain to setup.

If the Harmony plugin for Vera now natively supports channel changes I will have to look in to it and see how it works now?

Hi cw,

Yes version 3.3 and up support a action to change the channel:

luup.call_action("urn:rboer-com:serviceId:Harmony1", "ChangeChannel",{newChannel="604"},184)

It uses a Harmony API call to do this.

Cheers rene

[quote=“reneboer, post:10, topic:191674”]Hi cw,

Yes version 3.3 and up support a action to change the channel:

luup.call_action("urn:rboer-com:serviceId:Harmony1", "ChangeChannel",{newChannel="604"},184)

It uses a Harmony API call to do this.

Cheers rene[/quote]

Nice one Rene I will give it a try.