Hisense TV Control

Setup a emulated android device on your computer and install hisense remote app. then just packet capture on the interface and sniff out the username/password.

Cheers,

Hi! I try this config on H55A6100:
WOL work.
MQTT work.
But ping sensor not :confused:

Did you change any settings for open ping port?

Hello - nothing special for ping. Can you ping the TV IP from your computer/laptop? type this command in cmd prompt ‘ping ip_of_your_tv’

if that works then homeassistant should be able to ping as well.

i think the issue will be because the network seems to go offline when the tv is put in to standby, well atleast it does on mine :frowning:

Hello - Yes that’s correct. Because we dont know the state of the TV we use ping to tell Homeassistant which state its in using ping. Ping success (TV is on). Ping fail (TV is off)

We could probably get more clever somehow?

No :frowning: Can’t ping for PC.
I found WOL enable/disable in system preferences. So maybe ping also near. But maybe they lock ping in new firmware. Which version on your TV?

Hey UksusoFF,

My version is I320. Nothing fancy to allow ping. as long as its part of Wifi it works fine. Would be surprising that a device doesnt respond to ping when its on.

1 Like

Mine doesn’t seem to reply to pings either. But all the other things appear to work just fine. I don’t really mind because I could just use a Sonoff POW to monitor the energy consumption and this figuring out if it’s on or off. Not the best solution but certainly not a bad one.

Anyone had any luck at creating a component for these TVs or any additional controls?

I’m running home assistant on a Windows PC, how would I integrate the MQTT connection in my config?

Using the code @K-1 provided above I’ve been able to ping my TV and get it to wake on lan but no response from the MQTT broker.

Good stuff, thanks for the repo. This should let me control my TV with Google Assistant and maybe even auto-switch the soundbar audio mode depending on TV source

I wonder how easy/hard it would be to write a generic MQTT TV component with all the features we need

Sounds like a great idea - someone on the forum was going to attempt to make one but im sure its not that simple. I think the biggest challenge I see is state control. The way i do it is by pinging the device which is not very elegant way.

Anyone else gone beyond the above approaches to control the tv?

I ended up mixing WOL switch component (which pings the tv) with some node red automations to get active source, source names etc

.

The result is satisfactory for me though the newest tv firmware broke WOL as it seems to be crashing while off

I’ve also succeeded with my soundbar integration. I’m still looking for a better switch solution since it takes at least 30s from turning on tv for Hass to acknowledge it’s already on

Unfortunately the ping does not work for me, so I created a binary sensor with nmap, unfortunately it also takes time to reflect.

  - platform: command_line
    command: 'nmap 192.168.x.x|grep wormux | wc -l'
    name: Lounge TV
    scan_interval: 12
    payload_on: 1
    payload_off: 0

I have also set it up as a universal media player so that Kodi merges in with it.
PNG

I don’t know if it is because of my amplifier which is ARC/CEC enabled with it, but I cannot control the volume through MQTT only by the infra-red remote.

Anyone know how to increase volume ?

tryed this, but didn’t work:

mosquitto_pub -u hisenseservice -P multimqttservice -h 192.168.50.25 -p 36669 -t /remoteapp/tv/remote_service/HomeAssistant/actions/sendkey -m "VOLUME_UP"

I found it. Maybe someone is looking for the same thing:

Mosquitto pub:
mosquitto_pub -u hisenseservice -P multimqttservice -h YOUR_TV_IP -p 36669 -t /remoteapp/tv/platform_service/homeAssistant/actions/changevolume -m "YOUR_VOLUME"

Hey, I just wanted to post an update here for anyone trying to make this work with one of the newer (H8 for me) displays - It looks like they’ve moved to an encrypted session. I’ll just paste in what I wrote on github:

Hi, I spent a lot of time trying to figure out how to get this working on my H8 display, and I wanted to share with anyone else who might be trying to make it work. It looks like they’ve moved to an encrypted MQTT session (still on port 36669). I’m using MQTT Explorer for testing, and the options for encryption=on and validate=off (they’re using a self-signed cert), with the same username and password as in the main doc, are working for me. (Sure wish I’d tried just playing with those switches before setting up an android emulator and wireshark…)

I’m still working on getting control functioning, but I can’t tell if that’s just inexperience or other changes to this display yet…

1 Like

I have been playing around with this lately and have managed to get my Hisence R6 controlled by MQTT Explorer. My topics look more like this:

/remoteapp/tv/ui_service/XX:XX:XX:XX:XX:XX$normal/actions/changechannel

{“channel_param”: “1#ch39456902-c904-4939-a3af-2ed18c5b5478#sl35214240-16e7-4cc1-a66b-505956239f1e#4”}

Changing the XX to a device MAC that is paired via RemoteNOW app.
But so far I only have this working with MQTT Explorer. I have no idea how to configure this with user, pass, port and host (broker?) in HA. No way through developer tools to test?
I tried add this in config

mqtt:
broker: 192.168.1.17
port: 36669
username: hisenseservice
password: multimqttservice

But no luck. host instead of broker does not seem to work ether…

1 Like

Hi,

You need to configure your mosquito broker and setup a bridge (recommend do some research)

but this config should work for you (not in HA config but mosquitto config)

connection hisensemqtt
address 172.18.xxx.xxx:36669
username hisenseservice
password multimqttservice
cleansession true
clientid HomeAssistant
try_private false
start_type automatic
topic # both

I couldn’t get bridging working with the Mosquitto broker add-on for the life of me. I added the config to share but it just never seems to read it. I ended up bridging topics in nodered…
The only difference is with my config is the TVs address was at 192.168.xxx.xxx.
Not as clean though.
Ether way I got it going with the platform switch so far, its a shame there is no configurable TV entity type, for channels and sources ect. mediaplayer/universal just dont work well with a TV or IR set up.
This could be a big pain adding channels and other features to HA, then trying to tie them together…