09-26-2013, 10:52 AM
This note has particular applicability to control of at least my particular TV (Sharp Aquos LC-80LE632U)
But this note highlights the usefulness of "Generic TCP/IP Passthrough", a very general, useful, perhaps-not-generally-known device driver.
My goals were four-fold:
1. Have a way to display image/signal/source on the TV with zero interaction from the user
2. Minimize power consumed in standby mode.
3. preferably avoid using IR doo-dads stuck to front of TV that kids will knock off.
4. Strong preference for a tcp/ip approach (vs rs232) since I already have cat6 to the TV for internet, but don't have r232. (Could be possible to pull but my undersized conduit is pretty full).
Background:
* This 80 inch TV is wall mounted in a dedicated home theater. It has its own, non-switchable, non-controllable, outlet in the wall behind the TV.
* In the rack in a cabinet near the TV, I have
* Onkyo AV receiver TX-NR1009, which outputs to TV via HDMI
* Dune HD connected as source to Onkyo (3 gig HDD for ripped movies)
* LG BluRay (with NetFlix, etc) connected as source to Onkyo.
I discovered the Onkyo draws over 80watts in standby mode! so I have a lutron wireless appliance module that can switch the Onkyo on/off based on different Lutron button presses and/or motion detection in the theater. I now also have the LG bluray attached to that as well since I never need the LG bluray without the Onkyo
(I don't have the Dune on switched power since it only draws 10 w in standby and I use it for other media serving, such as mp3s to sonos, family pics to touch screens, etc. I am happy spending 10w on an always-on media server/HDD. But I digress)
So I could walk in the room (or press a button from a Lutron or CQC interface which connects to Lutron) and have lights, LG, Onkyo all come on. All that remained is for the TV to come on automatically.
Since all I wanted was on/off control. I thought that there might be a way via CQC (without dealing with TV drivers). There is. Sort of.
There is also a way to get the TV to turn on automatically when it detects HDMI signal from a HDMI/CEC compliant source. Sorta.
I set up the Onkyo to enable RIHD (its name for CEC) and I set up the Sharp to enable AquosLink (its name for CEC) and auto Power On. Didn't work.
So I tried the CQC route. It turns out that there is a driver called "Generic TCP/IP Passthrough" documented here.
You have to follow the directions in the Sharp manual to enable control over IP. I won't repeat them here. That bit of their documentation is clear.
Then when you add the (Generic TCP/IP Passthrough) driver to CQC, CQC will prompt you for the IP address of TV and the port (TV defaulted to port 10002 so I left that alone and entered that for CQC). When naming this driver instance, since it is specific to a device, use the name of the device (e.g., "Sharp80", not GenPassThru). Leave the default format as "ascii" but add a "CR" as a decoration to be appended to each command.
Then create an action with a few lines.
//To initiate session, first send user name and password (defined when you setup TV)
Devices::FieldWrite(Sharp80.SendTextMsg, username, True)
Devices::FieldWrite(Sharp80.SendTextMsg, password, True)
//Now send the command, in this case "Power On" which is "POWR1XXX" where the "X"s are really required spaces.
Devices::FieldWrite(Sharp80.SendTextMsg, POWR1 , True)
But this won't work either.
If your TV is on and you send "POWR0 " that will work. So communication and all other details are ok.
The problem with turning the TV on is that this TV's "standby mode" is really practically an off mode. In this TV's standby mode it can respond to IR via remote, but not to TCP. The good news is that this standby mode (I'll call it standby/deaf mode) consumes negligible power (I measure < 0.1w). The bad news is that that is not enough power to listen for TCP sessions.
This, I think, is also the reason that the HDMI auto-on doesn't work (that seems like a bug to me).
It turns out there is a different standby mode. I'll call is standby/listening mode. But the only way I could find to activate this mode is by:
* first power TV on (so it can listen)
* initiate session via CQC action with username and password as above
* then send Devices.FieldWrite(SendTextMsg, RSPW2xxx, True) [xxx=3 spaces]
This command is documented as "Power On command accepted". What it does is changes a "standby" command to standby/listen (from the default standby/deaf).
The good news is that in this standby mode, the TV can accept tcp command to power on ("POWR1 " shown above). Other good news is that the TV can now accept auto-on via HDMI (this fact, in my instance, makes using CQC to power on unneccesary).
The bad news is that standby/listening consumes about 25watts of power (vs <0.1w in standby/deaf mode) (That is $45/year for me).
The other good news is that if you physically unplug the TV and turn and then plug it in again, it seems to remember that it is set to standby/listening. (I have not tested for longer periods of unplugged time...perhaps it reverts to standby/deaf after some amount of time).
I will leave it in this 25watt standby/listening mode for now to achieve goal #1 of auto-on. I will add some controllable power-switch overlay later.
I wrote this to:
* share what I learned about "standby" modes on the Sharp
* share what I learned about "General TCP/IP passthrough" a very general, useful, perhaps-not-generally-known device driver
It turns out you can think of this tcp passthrough driver as similar to a terminal program (with no feedback), where you can connect to a host (ip+port) and send text commands (including userid and password if necessary).
But this note highlights the usefulness of "Generic TCP/IP Passthrough", a very general, useful, perhaps-not-generally-known device driver.
My goals were four-fold:
1. Have a way to display image/signal/source on the TV with zero interaction from the user
2. Minimize power consumed in standby mode.
3. preferably avoid using IR doo-dads stuck to front of TV that kids will knock off.
4. Strong preference for a tcp/ip approach (vs rs232) since I already have cat6 to the TV for internet, but don't have r232. (Could be possible to pull but my undersized conduit is pretty full).
Background:
* This 80 inch TV is wall mounted in a dedicated home theater. It has its own, non-switchable, non-controllable, outlet in the wall behind the TV.
* In the rack in a cabinet near the TV, I have
* Onkyo AV receiver TX-NR1009, which outputs to TV via HDMI
* Dune HD connected as source to Onkyo (3 gig HDD for ripped movies)
* LG BluRay (with NetFlix, etc) connected as source to Onkyo.
I discovered the Onkyo draws over 80watts in standby mode! so I have a lutron wireless appliance module that can switch the Onkyo on/off based on different Lutron button presses and/or motion detection in the theater. I now also have the LG bluray attached to that as well since I never need the LG bluray without the Onkyo
(I don't have the Dune on switched power since it only draws 10 w in standby and I use it for other media serving, such as mp3s to sonos, family pics to touch screens, etc. I am happy spending 10w on an always-on media server/HDD. But I digress)
So I could walk in the room (or press a button from a Lutron or CQC interface which connects to Lutron) and have lights, LG, Onkyo all come on. All that remained is for the TV to come on automatically.
Since all I wanted was on/off control. I thought that there might be a way via CQC (without dealing with TV drivers). There is. Sort of.
There is also a way to get the TV to turn on automatically when it detects HDMI signal from a HDMI/CEC compliant source. Sorta.
I set up the Onkyo to enable RIHD (its name for CEC) and I set up the Sharp to enable AquosLink (its name for CEC) and auto Power On. Didn't work.
So I tried the CQC route. It turns out that there is a driver called "Generic TCP/IP Passthrough" documented here.
You have to follow the directions in the Sharp manual to enable control over IP. I won't repeat them here. That bit of their documentation is clear.
Then when you add the (Generic TCP/IP Passthrough) driver to CQC, CQC will prompt you for the IP address of TV and the port (TV defaulted to port 10002 so I left that alone and entered that for CQC). When naming this driver instance, since it is specific to a device, use the name of the device (e.g., "Sharp80", not GenPassThru). Leave the default format as "ascii" but add a "CR" as a decoration to be appended to each command.
Then create an action with a few lines.
//To initiate session, first send user name and password (defined when you setup TV)
Devices::FieldWrite(Sharp80.SendTextMsg, username, True)
Devices::FieldWrite(Sharp80.SendTextMsg, password, True)
//Now send the command, in this case "Power On" which is "POWR1XXX" where the "X"s are really required spaces.
Devices::FieldWrite(Sharp80.SendTextMsg, POWR1 , True)
But this won't work either.
If your TV is on and you send "POWR0 " that will work. So communication and all other details are ok.
The problem with turning the TV on is that this TV's "standby mode" is really practically an off mode. In this TV's standby mode it can respond to IR via remote, but not to TCP. The good news is that this standby mode (I'll call it standby/deaf mode) consumes negligible power (I measure < 0.1w). The bad news is that that is not enough power to listen for TCP sessions.
This, I think, is also the reason that the HDMI auto-on doesn't work (that seems like a bug to me).
It turns out there is a different standby mode. I'll call is standby/listening mode. But the only way I could find to activate this mode is by:
* first power TV on (so it can listen)
* initiate session via CQC action with username and password as above
* then send Devices.FieldWrite(SendTextMsg, RSPW2xxx, True) [xxx=3 spaces]
This command is documented as "Power On command accepted". What it does is changes a "standby" command to standby/listen (from the default standby/deaf).
The good news is that in this standby mode, the TV can accept tcp command to power on ("POWR1 " shown above). Other good news is that the TV can now accept auto-on via HDMI (this fact, in my instance, makes using CQC to power on unneccesary).
The bad news is that standby/listening consumes about 25watts of power (vs <0.1w in standby/deaf mode) (That is $45/year for me).
The other good news is that if you physically unplug the TV and turn and then plug it in again, it seems to remember that it is set to standby/listening. (I have not tested for longer periods of unplugged time...perhaps it reverts to standby/deaf after some amount of time).
I will leave it in this 25watt standby/listening mode for now to achieve goal #1 of auto-on. I will add some controllable power-switch overlay later.
I wrote this to:
* share what I learned about "standby" modes on the Sharp
* share what I learned about "General TCP/IP passthrough" a very general, useful, perhaps-not-generally-known device driver
It turns out you can think of this tcp passthrough driver as similar to a terminal program (with no feedback), where you can connect to a host (ip+port) and send text commands (including userid and password if necessary).