Git Product home page Git Product logo

Comments (22)

daveholst avatar daveholst commented on July 22, 2024 1

I’m not at home for the next few weeks as I am working down on the farm! I will try and remote in over the next few days with my wife on the Samsung remote to test and report back.

Thanks for all the hard work!

Dave.

from ha-samsungtv-smart.

ollo69 avatar ollo69 commented on July 22, 2024

I didn't know about this behavior, but I know that there is a way to check the art-mode status (using another web-socket connection). I suppose that when the TV is in art-mode the comunication with the TV is alive so the component suppose that is still on.
Can you provide some more details on status reported by the component when you are in art-mode and also for other states?
I will try investigate on this but I need all possible details because my TV do not have art-mode.

from ha-samsungtv-smart.

ollo69 avatar ollo69 commented on July 22, 2024

I just released a new version (v0.3.0) where I implemented the control channel for the frame TV.
This is a pre-release, so to install this version from HACS you should enable the option "Show Beta" with the 3 dots option button.
This version also log some additional info related to the message received from the "art control ws channel", so please post this log if it is not working so that I can analyze and try to fix.
I don't have a Frame TV so the code can contain errors that I wasn't able to check.

from ha-samsungtv-smart.

daveholst avatar daveholst commented on July 22, 2024

I have just installed this addon via HACS in an attempt to get my Frame TV working correctly. I thank you for looking into this for us and try to solve the problem :)

I have tried both the 0.0.3 and 0.0.3-beta 1 with the same results. When I change between on-off-artmode this is what is produced in my log file. Hope this helps. I have just included all of the intergration messages from a clean restart.

2020-05-24 12:04:44 WARNING (MainThread) [homeassistant.loader] You are using a custom integration for samsungtv_smart which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant. 2020-05-24 12:04:49 INFO (MainThread) [homeassistant.setup] Setting up samsungtv_smart 2020-05-24 12:04:49 INFO (MainThread) [homeassistant.setup] Setup of domain samsungtv_smart took 0.0 seconds. 2020-05-24 12:04:50 INFO (MainThread) [homeassistant.components.media_player] Setting up media_player.samsungtv_smart 2020-05-24 12:04:50 INFO (MainThread) [custom_components.samsungtv_smart.media_player] Samsung TV 192.168.1.165:8002 added as 'The FRAME' 2020-05-24 12:05:10 INFO (MainThread) [custom_components.samsungtv_smart.media_player] Samsung TV: loaded sources list from SmartThings: {'digitalTv': 'ST_TV', 'HDMI1': 'ST_HDMI1', 'HDMI4': 'ST_HDMI4'} 2020-05-24 12:05:21 INFO (MainThread) [homeassistant.components.discovery] Unknown service discovered: dlna_dmr {'host': '192.168.1.165', 'port': 9197, 'ssdp_description': 'http://192.168.1.165:9197/dmr', 'name': '[TV] Samsung Frame Series (65)', 'model_name': 'UA65LS03N', 'model_number': 'AllShare1.0', 'serial': '06B03NKKA00073P', 'manufacturer': 'Samsung Electronics', 'udn': 'uuid:576156ee-3ff5-42a2-99f4-47c91286f130', 'upnp_device_type': 'urn:schemas-upnp-org:device:MediaRenderer:1'} 2020-05-24 12:05:41 INFO (SamsungRemote) [custom_components.samsungtv_smart.api.samsungws] New token 81876200 2020-05-24 12:05:41 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': {'clients': [{'attributes': {'name': None}, 'connectTime': 1590066686663, 'deviceName': 'Smart Device', 'id': '7be95221-fb7e-4725-bbb-3a3a613bb90', 'isHost': True}, {'attributes': {'name': 'W0hvbWUgQXNzaXN0YW50XSBUaGUgRlJBTUU='}, 'connectTime': 1590293141673, 'deviceName': 'W0hvbWUgQXNzaXN0YW50XSBUaGUgRlJBTUU=', 'id': 'b65e5edc-225d-4e72-8628-b21e38171912', 'isHost': False}], 'id': 'b65e5edc-225d-4e72-8628-b21e38171912'}, 'event': 'ms.channel.connect'} 2020-05-24 12:05:41 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': {}, 'event': 'ms.channel.ready'} 2020-05-24 12:05:42 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"id":"","event":"error","request_data":"","error_code":"-6","target_client_id":"b65e5edc-225d-4e72-8628-b21e38171912"}', 'event': 'd2d_service_message', 'from': '7be95221-fb7e-4725-bbb-3a3a613bb90'} 2020-05-24 12:05:42 ERROR (SamsungArt) [websocket] error from callback <bound method SamsungTVWS._on_message_art of <custom_components.samsungtv_smart.api.samsungws.SamsungTVWS object at 0x7f2a4a80e890>>: 'str' object has no attribute 'get' 2020-05-24 12:06:18 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"event":"art_mode_changed","status":"on"}', 'event': 'd2d_service_message', 'from': '7be95221-fb7e-4725-bbb-3a3a613bb90'} 2020-05-24 12:06:18 ERROR (SamsungArt) [websocket] error from callback <bound method SamsungTVWS._on_message_art of <custom_components.samsungtv_smart.api.samsungws.SamsungTVWS object at 0x7f2a4a80e890>>: 'str' object has no attribute 'get' 2020-05-24 12:06:33 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"event":"art_mode_changed","status":"off"}', 'event': 'd2d_service_message', 'from': '7be95221-fb7e-4725-bbb-3a3a613bb90'} 2020-05-24 12:06:33 ERROR (SamsungArt) [websocket] error from callback <bound method SamsungTVWS._on_message_art of <custom_components.samsungtv_smart.api.samsungws.SamsungTVWS object at 0x7f2a4a80e890>>: 'str' object has no attribute 'get'

from ha-samsungtv-smart.

ollo69 avatar ollo69 commented on July 22, 2024

That's great because something is coming, just need to handle in the right way...
I just released new version with fix for handling art-mode message, can you please install and report.

Thanks

from ha-samsungtv-smart.

pierpa68 avatar pierpa68 commented on July 22, 2024

Hi,
I'm also testing this integration with my 65" The Frame: the problem with >0.3 version is that I'm unable to switch the TV off with using remote, I have to long-press the power button and it goes completelly off (not in art mode).
ATM I disabled the connection on the TV.
Please tell me if I can help you in debugging the problem.

Regards

from ha-samsungtv-smart.

ollo69 avatar ollo69 commented on July 22, 2024

Hi,
I'm also testing this integration with my 65" The Frame: the problem with >0.3 version is that I'm unable to switch the TV off with using remote, I have to long-press the power button and it goes completelly off (not in art mode).
ATM I disabled the connection on the TV.
Please tell me if I can help you in debugging the problem.

Regards

Please install the last version that I just released (v0.3.1) and post here your HA log. Trying to manage, but not having this kind of TV I need yours log to fix what's wrong.
Suggestion on expected behavior are also welcome

Thx.

from ha-samsungtv-smart.

daveholst avatar daveholst commented on July 22, 2024

I'm getting some funny things happening with the latest version (0.3.1).

When I hit the power button (Lovelace) with the TV on it sometimes turns off and sometimes goes to art mode. If the TV turns complete off I also can't turn it back on from lovelace.

Ideally It would be great if I could monitor the TV in 3 states ON, OFF or ART MODE.

I'm more interested in monitoring the state of the TV for automation and having a way to set the tv either on,off or art-mode in nodered. I would rarely interact with it from the frontend,

If I was to use it from lovelace I guess It would make sense that the power button turns it off (from either art-mode or on) and on always turns it on (not ever going to artmode) I would rather have an additional custom button to toggle art-mode. I would be happy for the process to be Turn the TV ON, delay, then go into ART MODE.

This is my log from testing today.

2020-05-25 12:03:58 WARNING (MainThread) [homeassistant.loader] You are using a custom integration for samsungtv_smart which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant. 2020-05-25 12:04:04 INFO (MainThread) [homeassistant.setup] Setting up samsungtv_smart 2020-05-25 12:04:04 INFO (MainThread) [homeassistant.setup] Setup of domain samsungtv_smart took 0.0 seconds. 2020-05-25 12:04:05 INFO (MainThread) [homeassistant.components.media_player] Setting up media_player.samsungtv_smart 2020-05-25 12:04:05 INFO (MainThread) [custom_components.samsungtv_smart.media_player] Samsung TV 192.168.1.165:8002 added as 'Lounge TV' 2020-05-25 12:04:08 INFO (MainThread) [custom_components.samsungtv_smart.media_player] Samsung TV: loaded sources list from SmartThings: {'digitalTv': 'ST_TV', 'HDMI1': 'ST_HDMI1', 'HDMI4': 'ST_HDMI4'} 2020-05-25 12:04:08 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': {'clients': [{'attributes': {'name': None}, 'connectTime': 1590379425473, 'deviceName': 'Smart Device', 'id': '2126fa5e-4abf-44c-9c95-b3724a8d15d', 'isHost': True}, {'attributes': {'name': 'W0hvbWUgQXNzaXN0YW50XSBMb3VuZ2UgVFY='}, 'connectTime': 1590379448954, 'deviceName': 'W0hvbWUgQXNzaXN0YW50XSBMb3VuZ2UgVFY=', 'id': 'c7fbaf9b-46e2-459e-9299-4993bcb0ff17', 'isHost': False}], 'id': 'c7fbaf9b-46e2-459e-9299-4993bcb0ff17'}, 'event': 'ms.channel.connect'} 2020-05-25 12:04:08 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': {}, 'event': 'ms.channel.ready'} 2020-05-25 12:04:08 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"id":"","event":"error","request_data":"{\'request\': \'get_artmode_status\', \'id\': \'aacd23c4-64c2-4f12-bbcb-6a485db72d3b\'}","error_code":"-6","target_client_id":"c7fbaf9b-46e2-459e-9299-4993bcb0ff17"}', 'event': 'd2d_service_message', 'from': '2126fa5e-4abf-44c-9c95-b3724a8d15d'} 2020-05-25 12:04:08 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'id': '', 'event': 'error', 'request_data': "{'request': 'get_artmode_status', 'id': 'aacd23c4-64c2-4f12-bbcb-6a485db72d3b'}", 'error_code': '-6', 'target_client_id': 'c7fbaf9b-46e2-459e-9299-4993bcb0ff17'} 2020-05-25 12:04:35 INFO (MainThread) [homeassistant.components.discovery] Unknown service discovered: dlna_dmr {'host': '192.168.1.165', 'port': 9197, 'ssdp_description': 'http://192.168.1.165:9197/dmr', 'name': '[TV] Samsung Frame Series (65)', 'model_name': 'UA65LS03N', 'model_number': 'AllShare1.0', 'serial': '06B03NKKA00073P', 'manufacturer': 'Samsung Electronics', 'udn': 'uuid:576156ee-3ff5-42a2-99f4-47c91286f130', 'upnp_device_type': 'urn:schemas-upnp-org:device:MediaRenderer:1'} 2020-05-25 12:11:38 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"event":"art_mode_changed","status":"on"}', 'event': 'd2d_service_message', 'from': '2126fa5e-4abf-44c-9c95-b3724a8d15d'} 2020-05-25 12:11:38 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'event': 'art_mode_changed', 'status': 'on'} 2020-05-25 12:11:45 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"event":"art_mode_changed","status":"off"}', 'event': 'd2d_service_message', 'from': '2126fa5e-4abf-44c-9c95-b3724a8d15d'} 2020-05-25 12:11:45 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'event': 'art_mode_changed', 'status': 'off'} 2020-05-25 12:12:02 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"event":"go_to_standby"}', 'event': 'd2d_service_message', 'from': '2126fa5e-4abf-44c-9c95-b3724a8d15d'} 2020-05-25 12:12:02 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'event': 'go_to_standby'} 2020-05-25 12:12:53 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': {'clients': [{'attributes': {'name': 'W0hvbWUgQXNzaXN0YW50XSBMb3VuZ2UgVFY='}, 'connectTime': 1590379973154, 'deviceName': 'W0hvbWUgQXNzaXN0YW50XSBMb3VuZ2UgVFY=', 'id': '5b68fb6f-5f7-4b5e-b931-7081823ae8a1', 'isHost': False}], 'id': '5b68fb6f-5f7-4b5e-b931-7081823ae8a1'}, 'event': 'ms.channel.connect'} 2020-05-25 12:12:57 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': {'attributes': {'name': None}, 'connectTime': 1590379976303, 'deviceName': 'Smart Device', 'id': '362ad2a-cee5-40fc-9a73-58711377e3e7', 'isHost': True}, 'event': 'ms.channel.clientConnect'} 2020-05-25 12:12:57 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': {}, 'event': 'ms.channel.ready'} 2020-05-25 12:12:57 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"id":"","event":"error","request_data":"{\'request\': \'get_artmode_status\', \'id\': \'d094e886-9f3d-4e03-b564-2b9e77c834e9\'}","error_code":"-6","target_client_id":"5b68fb6f-5f7-4b5e-b931-7081823ae8a1"}', 'event': 'd2d_service_message', 'from': '362ad2a-cee5-40fc-9a73-58711377e3e7'} 2020-05-25 12:12:57 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'id': '', 'event': 'error', 'request_data': "{'request': 'get_artmode_status', 'id': 'd094e886-9f3d-4e03-b564-2b9e77c834e9'}", 'error_code': '-6', 'target_client_id': '5b68fb6f-5f7-4b5e-b931-7081823ae8a1'} 2020-05-25 12:13:36 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"event":"wakeup"}', 'event': 'd2d_service_message', 'from': '362ad2a-cee5-40fc-9a73-58711377e3e7'} 2020-05-25 12:13:36 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'event': 'wakeup'} 2020-05-25 12:13:36 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"id":"","event":"error","request_data":"{\'request\': \'get_artmode_status\', \'id\': \'9ed37694-c065-4be2-aa7e-b118159714e6\'}","error_code":"-6","target_client_id":"5b68fb6f-5f7-4b5e-b931-7081823ae8a1"}', 'event': 'd2d_service_message', 'from': '362ad2a-cee5-40fc-9a73-58711377e3e7'} 2020-05-25 12:13:36 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'id': '', 'event': 'error', 'request_data': "{'request': 'get_artmode_status', 'id': '9ed37694-c065-4be2-aa7e-b118159714e6'}", 'error_code': '-6', 'target_client_id': '5b68fb6f-5f7-4b5e-b931-7081823ae8a1'}
I hope this helps! I did try and make a hardware solution for this with an ESP and IR blaster. I managed to simulate a PWR Button SHORT and LONG, but I was unable to ever know the state of the TV (Power Monitoring could distuiguish between ART MODE and normal ON)

The implementation on the Samsung remote is pretty Janky and quite confusing for people not familar with the tv. This is why I tend to just use the apple tv remote to wake TV and it will also turn both the apple tv and the tv off.

Samsung Remote Logic

If TV is ON:
SHORT PWR = ART MODE
LONG PWR = OFF

if TV is OFF (and last state was ON)
SHORT PWR = ON
LONG PWR = ON

if TV is OFF (and last state was ART MODE)
SHORT PWR = ART MODE
LONG PWR = ART MODE

if TV is ART MODE
SHORT PWR = ON
LONG PWR = OFF

I hope this wasn't too confusing! Thanks again for looking into this!

Please let me know if you want any more info and I'm happy to test and report back on anything!

Cheers. Dave.

from ha-samsungtv-smart.

ollo69 avatar ollo69 commented on July 22, 2024

Thanks for your time in testing.

Problem is that message "get_artmode_status" still not working.
Can you try again with version v0.3.1-beta1 (is prerelease). If I found the correct format for this message than will be possible to implement different logic, maybe implementing a dedicated service to manage the "art-mode" status.

from ha-samsungtv-smart.

daveholst avatar daveholst commented on July 22, 2024

It turned my TV on from OFF, but then stopped working when I tried to turn it off to the point where using power button in Lovelace had no effect on the TV and stopped the Samsung remote from working. The only way I could power it off was with the aTV remote.

2020-05-25 19:37:12 WARNING (MainThread) [homeassistant.loader] You are using a custom integration for samsungtv_smart which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant. 2020-05-25 19:37:18 INFO (MainThread) [homeassistant.setup] Setting up samsungtv_smart 2020-05-25 19:37:18 INFO (MainThread) [homeassistant.setup] Setup of domain samsungtv_smart took 0.0 seconds. 2020-05-25 19:37:19 INFO (MainThread) [homeassistant.components.media_player] Setting up media_player.samsungtv_smart 2020-05-25 19:37:19 INFO (MainThread) [custom_components.samsungtv_smart.media_player] Samsung TV 192.168.1.165:8002 added as 'Lounge TV' 2020-05-25 19:37:22 INFO (MainThread) [custom_components.samsungtv_smart.media_player] Samsung TV: loaded sources list from SmartThings: {'digitalTv': 'ST_TV', 'HDMI1': 'ST_HDMI1', 'HDMI4': 'ST_HDMI4'} 2020-05-25 19:37:23 INFO (SamsungRemote) [custom_components.samsungtv_smart.api.samsungws] New token 18420133 2020-05-25 19:37:23 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': {'clients': [{'attributes': {'name': None}, 'connectTime': 1590381856047, 'deviceName': 'Smart Device', 'id': '28f9a62-65a9-4329-bff2-6c183588b35', 'isHost': True}, {'attributes': {'name': 'W0hvbWUgQXNzaXN0YW50XSBMb3VuZ2UgVFY='}, 'connectTime': 1590406642504, 'deviceName': 'W0hvbWUgQXNzaXN0YW50XSBMb3VuZ2UgVFY=', 'id': '82a1befd-1f48-4f6-b66c-3055b36ff9d', 'isHost': False}], 'id': '82a1befd-1f48-4f6-b66c-3055b36ff9d'}, 'event': 'ms.channel.connect'} 2020-05-25 19:37:23 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': {}, 'event': 'ms.channel.ready'} 2020-05-25 19:37:23 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"id":"6988c163-86be-485c-b9b2-b243ddf669a7","event":"artmode_status","value":"on","target_client_id":"82a1befd-1f48-4f6-b66c-3055b36ff9d"}', 'event': 'd2d_service_message', 'from': '28f9a62-65a9-4329-bff2-6c183588b35'} 2020-05-25 19:37:23 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'id': '6988c163-86be-485c-b9b2-b243ddf669a7', 'event': 'artmode_status', 'value': 'on', 'target_client_id': '82a1befd-1f48-4f6-b66c-3055b36ff9d'} 2020-05-25 19:37:38 INFO (SyncWorker_7) [homeassistant.loader] Loaded samsungtv from homeassistant.components.samsungtv 2020-05-25 19:37:49 INFO (MainThread) [homeassistant.components.discovery] Unknown service discovered: dlna_dmr {'host': '192.168.1.165', 'port': 9197, 'ssdp_description': 'http://192.168.1.165:9197/dmr', 'name': '[TV] Samsung Frame Series (65)', 'model_name': 'UA65LS03N', 'model_number': 'AllShare1.0', 'serial': '06B03NKKA00073P', 'manufacturer': 'Samsung Electronics', 'udn': 'uuid:576156ee-3ff5-42a2-99f4-47c91286f130', 'upnp_device_type': 'urn:schemas-upnp-org:device:MediaRenderer:1'} 2020-05-25 19:51:11 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"event":"art_mode_changed","status":"off"}', 'event': 'd2d_service_message', 'from': '28f9a62-65a9-4329-bff2-6c183588b35'} 2020-05-25 19:51:11 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'event': 'art_mode_changed', 'status': 'off'} 2020-05-25 19:52:11 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"event":"go_to_standby"}', 'event': 'd2d_service_message', 'from': '28f9a62-65a9-4329-bff2-6c183588b35'} 2020-05-25 19:52:11 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'event': 'go_to_standby'} 2020-05-25 19:53:10 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': {'clients': [{'attributes': {'name': None}, 'connectTime': 1590407585605, 'deviceName': 'Smart Device', 'id': 'e76e655a-9050-444d-a33b-4ea59263783d', 'isHost': True}, {'attributes': {'name': 'W0hvbWUgQXNzaXN0YW50XSBMb3VuZ2UgVFY='}, 'connectTime': 1590407589957, 'deviceName': 'W0hvbWUgQXNzaXN0YW50XSBMb3VuZ2UgVFY=', 'id': '64bdbc1b-1cd-4575-9a18-84bb9f894be', 'isHost': False}], 'id': '64bdbc1b-1cd-4575-9a18-84bb9f894be'}, 'event': 'ms.channel.connect'} 2020-05-25 19:53:10 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': {}, 'event': 'ms.channel.ready'} 2020-05-25 19:53:10 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"id":"aaad007f-3231-4968-8b1a-ee030f254bea","event":"artmode_status","value":"off","target_client_id":"64bdbc1b-1cd-4575-9a18-84bb9f894be"}', 'event': 'd2d_service_message', 'from': 'e76e655a-9050-444d-a33b-4ea59263783d'} 2020-05-25 19:53:10 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'id': 'aaad007f-3231-4968-8b1a-ee030f254bea', 'event': 'artmode_status', 'value': 'off', 'target_client_id': '64bdbc1b-1cd-4575-9a18-84bb9f894be'} 2020-05-25 19:53:53 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"event":"wakeup"}', 'event': 'd2d_service_message', 'from': 'e76e655a-9050-444d-a33b-4ea59263783d'} 2020-05-25 19:53:53 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'event': 'wakeup'} 2020-05-25 19:53:53 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"id":"0f5e7584-6b24-4eaf-8c16-4b0ecdcc22a3","event":"artmode_status","value":"off","target_client_id":"64bdbc1b-1cd-4575-9a18-84bb9f894be"}', 'event': 'd2d_service_message', 'from': 'e76e655a-9050-444d-a33b-4ea59263783d'} 2020-05-25 19:53:53 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'id': '0f5e7584-6b24-4eaf-8c16-4b0ecdcc22a3', 'event': 'artmode_status', 'value': 'off', 'target_client_id': '64bdbc1b-1cd-4575-9a18-84bb9f894be'} 2020-05-25 20:01:41 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"event":"go_to_standby"}', 'event': 'd2d_service_message', 'from': 'e76e655a-9050-444d-a33b-4ea59263783d'} 2020-05-25 20:01:41 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'event': 'go_to_standby'} 2020-05-25 20:02:33 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': {'clients': [{'attributes': {'name': None}, 'connectTime': 1590408150711, 'deviceName': 'Smart Device', 'id': '7ab99675-2b71-400-861a-af4c54c9240', 'isHost': True}, {'attributes': {'name': 'W0hvbWUgQXNzaXN0YW50XSBMb3VuZ2UgVFY='}, 'connectTime': 1590408153581, 'deviceName': 'W0hvbWUgQXNzaXN0YW50XSBMb3VuZ2UgVFY=', 'id': 'b7843f48-e7a2-45cb-b9f4-9b3593f47d9', 'isHost': False}], 'id': 'b7843f48-e7a2-45cb-b9f4-9b3593f47d9'}, 'event': 'ms.channel.connect'} 2020-05-25 20:02:33 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': {}, 'event': 'ms.channel.ready'} 2020-05-25 20:02:33 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'data': '{"id":"1c8edaf3-e8ef-4c70-af17-454dba52eb97","event":"artmode_status","value":"off","target_client_id":"b7843f48-e7a2-45cb-b9f4-9b3593f47d9"}', 'event': 'd2d_service_message', 'from': '7ab99675-2b71-400-861a-af4c54c9240'} 2020-05-25 20:02:33 INFO (SamsungArt) [custom_components.samsungtv_smart.api.samsungws] {'id': '1c8edaf3-e8ef-4c70-af17-454dba52eb97', 'event': 'artmode_status', 'value': 'off', 'target_client_id': 'b7843f48-e7a2-45cb-b9f4-9b3593f47d9'}

When I spammed the Lovelace button a bit nothing was changing in the log. It only wrote that last line when I turned the tv off with the aTV remote. After this had happened I could then turn it on with Lovelace. It seems to be working now, I think I might have broken it by turning it on and off to quick from Lovelace. It does seem like the get_artmode_status error message have gone!

Cheers.
Dave.

from ha-samsungtv-smart.

ollo69 avatar ollo69 commented on July 22, 2024

Seems good, I just changed in last release the behavior of power off command that could be the cause of remote stop working described by you.
In any case is better to not stress too much the HA power button, keep in mind that the component can take until 15-20 sec. to correctly detect status change from on to off and viceversa.
Can you make some test to verify that is working properly? Here same test case example:

  1. TV on -> put in art-mode from TV remote -> HA should detect as off
  2. TV in art-mode -> turn off from TV remote -> HA should continue detect as off
  3. TV off (from art-mode) -> turn on from HA -> TV must switch to on (and not art-mode)
  4. TV on -> turn off from HA -> TV must go off

Please leave 30 seconds between each test to really check that status update properly and to not change unexpectly.
Any additional scenario / test case that you want to test are welcome.

Thx

from ha-samsungtv-smart.

mlbs-dev avatar mlbs-dev commented on July 22, 2024

First, thanks for working on this, works great so far.

I also have a "The Frame" TV and it seems that the status is correctly reported now. That is, TV off and TV in art-mode is reported as off in HA and TV on as on in HA.

However, would it be possible to report that the TV is in Artmode somehow? Maybe as an attribute in HA? The reason is that I have a need for detecting if the TV is on or in art-mode so that I can turn it off under specific conditions (like leaving home).

Edit: Or maybe states "On" "Off" "Art" or similar if that is possible.

from ha-samsungtv-smart.

ollo69 avatar ollo69 commented on July 22, 2024

Good to know that it works.
I will try to add the attribute with next release, but anyway you can probably solve your need simply calling the service "media_player.turn_off" (not switch) because it should always turn totally off the TV also if it is in art-mode. Can you try if this work?

from ha-samsungtv-smart.

mlbs-dev avatar mlbs-dev commented on July 22, 2024

Ah, of course. It works with "media_player.turn_off".

from ha-samsungtv-smart.

mlbs-dev avatar mlbs-dev commented on July 22, 2024

The art_mode_status attribute seems to work as it should.

from ha-samsungtv-smart.

daveholst avatar daveholst commented on July 22, 2024

I haven't had a chance to test anything sorry. I'm still down the farm for another week.

Thanks for all the advancements you guys have made!

from ha-samsungtv-smart.

p1ll0wf0rtress avatar p1ll0wf0rtress commented on July 22, 2024

What's the interval/method for setting the state of the TV? I've got a 55" Frame and the state seems to lag behind the actual power status of the TV a lot.

from ha-samsungtv-smart.

ollo69 avatar ollo69 commented on July 22, 2024

What's the interval/method for setting the state of the TV? I've got a 55" Frame and the state seems to lag behind the actual power status of the TV a lot.

A lot of what? If you want help please provide more detail about environment, component and HA version, adding log and screenshot. Also check closed ticket if someone apply to your issue, eventually open a new one with all necessary details

Thanks.

from ha-samsungtv-smart.

skynet01 avatar skynet01 commented on July 22, 2024

is there a way to turn it on into the Art mode somehow? Maybe passing in art_mode_status: 'on' as a data attribute? That would be sick. Since then we can have automation control art mode :) Btw thank you for this great addon, its the only one that works and i use it on all of my TVs :)

from ha-samsungtv-smart.

Letrab avatar Letrab commented on July 22, 2024

is there a way to turn it on into the Art mode somehow? Maybe passing in art_mode_status: 'on' as a data attribute? That would be sick. Since then we can have automation control art mode :) Btw thank you for this great addon, its the only one that works and i use it on all of my TVs :)

As mentioned here #45 (comment) : You can check your art_mode_status and power status. If it's not in art_mode, you could us the service media_player.play_media to send a POWER_KEY (like pressing the power key on the remote) which puts the TV in art mode!

  "entity_id": "media_player.<your entity>",
  "media_content_type": "send_key",
  "media_content_id": "KEY_POWER"

And use the services media_player.turn_off and media_player.turn_on for changing the power state ofc ;-)

from ha-samsungtv-smart.

Letrab avatar Letrab commented on July 22, 2024

What's the interval/method for setting the state of the TV? I've got a 55" Frame and the state seems to lag behind the actual power status of the TV a lot.

A lot of what? If you want help please provide more detail about environment, component and HA version, adding log and screenshot. Also check closed ticket if someone apply to your issue, eventually open a new one with all necessary details

Thanks.

I can relate to this with my 50" 2020 The Frame.

Transitions:

Art Mode -> On : Instantly shown in HA (+-4s)
On -> Art Mode: Instantly shown in HA (+-4s)
Art mode -> Off: Instantly shown in HA (+-4s)
Off -> Art Mode: To be confirmed, but I thought it was instant as well (+-4s)
Off -> On: Very slow (+-40s)

The sequence Off -> On, I validated many times, each time this big delay.
I polled manually the /api/states/media_player.<your entity> and also there no change. Even last_changed and last_updated timestamps are not updated until the correct "on-state" is reflected (after that +- 40s)

Other problem: sending media_player.turn_on does not always succeed somehow... Sometimes the (API) call takes only +-200ms (instant return) and the TV does not power on. Sometimes the call takes like +-7s, after which mostly the TV powers back on (but neither always, tb confirmed). Is there a wait-time between a turn_off and turn_on? I tried increasing WOL packets to 2. But maybe even higher?

General question: Which type of connection should one choose, and why? (Standard, Remote, REST API)?

Happy to help/debug if you could give me some pointers!

from ha-samsungtv-smart.

ollo69 avatar ollo69 commented on July 22, 2024

This issue is the same of issue #82 and should now be fixed.
I close this, open a new one if you still have issue with Frame TV

from ha-samsungtv-smart.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.