How to remotely turn off the TV?

Here for general support for D series TVs, request and problem solve area.

oga83
Posts: 268
Joined: Sun Mar 18, 2012 10:11 pm
Location: France

Re: How to remotely turn off the TV?

Post by oga83 »

Tcpdumping the official app gave me "." while someone else had ".."
At this point, I don't know which one is better to use
Anyway, it works in both cases.
rol
Posts: 62
Joined: Sat Jul 28, 2012 11:44 am

Re: How to remotely turn off the TV?

Post by rol »

Thanks for the precision.

I have already a nice remote, that emulates all functions of the hardware remote, plus some other ones. It is sometimes difficult to find the right key for a particular button, and your program was invaluable to check the codes. Great and useful job!

BTW, I've noticed that the keys of the macros of your program are sent either one at a time (with the "," separator), or immediately, all keys after each other (with "+"). What's the reason to treat the keys as separate "packs" or as a group (other than the slight speed penalty of the first method)?
oga83
Posts: 268
Joined: Sun Mar 18, 2012 10:11 pm
Location: France

Re: How to remotely turn off the TV?

Post by oga83 »

...because some special functions require separate sessions for each key.
The most famous is KEY_INFO,KEY_FACTORY

Of course, for other functions, it's faster to use the same session (for example, KEY_1+KEY_5 to set channel "15" )
rol
Posts: 62
Joined: Sat Jul 28, 2012 11:44 am

Re: How to remotely turn off the TV?

Post by rol »

OK, understood.

BTW, is it always safe to send several keys (in the same session or not), or is it sometimes necessary to insert pauses? I guess that the TV executes the key function before getting the other commands from its TCP port. Right? (I would like to make a macro to go to the Smart Hub, then send cursor keys to navigate to the PVR manager app, and open it automatically. But going to the Smart Hub takes sometimes a very long time, and I wonder if the TV will loose the keys.)
[EDIT] Oops, sorry! I can check that easily with your program!
oga83
Posts: 268
Joined: Sun Mar 18, 2012 10:11 pm
Location: France

Re: How to remotely turn off the TV?

Post by oga83 »

In fact you should check the answer of your unit when you connect or send a key
rol
Posts: 62
Joined: Sat Jul 28, 2012 11:44 am

Re: How to remotely turn off the TV?

Post by rol »

Not sure how to do it. I just need to read the socket?
oga83
Posts: 268
Joined: Sun Mar 18, 2012 10:11 pm
Location: France

Re: How to remotely turn off the TV?

Post by oga83 »

You should at least wait for the answer
I didn't work on the meaning of the returned data...
rol
Posts: 62
Joined: Sat Jul 28, 2012 11:44 am

Re: How to remotely turn off the TV?

Post by rol »

Well, I open the socket in blocking mode, so I guess the write function returns only when the answer has been received. But I'm not sure. It's the first time I use sockets in a program, and the Tcl doc is not clear on how to check for errors. Anyway, don't worry. I'll find the solution myself. I don't want to abuse of your patience.
rol
Posts: 62
Joined: Sat Jul 28, 2012 11:44 am

Re: How to remotely turn off the TV?

Post by rol »

With your help, I've finally finished to write and test my remote controller. I've started a new thread here.
Thanks again!
oga83
Posts: 268
Joined: Sun Mar 18, 2012 10:11 pm
Location: France

Re: How to remotely turn off the TV?

Post by oga83 »

It sounds great !

Post Reply

Return to “[D] Support”