-
-
Notifications
You must be signed in to change notification settings - Fork 28.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Panasonic GX800 series with Panasonic Viera TV integration doesn't works #29088
Comments
Looks similar to #21185. I would advise you to create another issue in the panasonic_viera repo so this can be implemented in the python package that is used in this integration. |
It has already been implemented in the package. |
Thanks for the tip @ramondunker, in which version has this device been implemented? |
Oh I'm sorry @springstan, I was looking at the wrong issue. Issue I'm having is this one: It has been addressed in the latest init.py (https://github.com/florianholzapfel/panasonic-viera/blob/master/panasonic_viera/__init__.py), but hasn't been implemented in Home Assistant. |
No worries. @ramondunker could you test the newest version of panasonic_viera in Home Assistant and report back so that it can be implemented? |
I would if you could explain how to implement it in my own Home Assistant setup :-). @springstan |
Well you could easily update your version of panasonic_viera by adjusting the following lines |
Okay thanks but where can I find those files? Looked at /config/deps but nothing in there. @springstan |
I'm using a Raspberry Pi Zero W with Hassio. |
Oh I am sorry but I believe this does not work under Hassio. However, you could set up a new development environment and test it there. |
Okay thankyou. I will look into that after my tests! If it works on my dev environment, can I implement it into Hassio? @springstan |
Sorry I am not too familiar with Hassio, therefore I cannot give you a concrete answer to that question. Still thank you very much for testing this out 👍 |
Okay I've installed a dev environment and installed 0.3.4. I edited configuration.yaml to include the mediaplayer. I'm getting the error: Failed to call service media_player/media_play_pause. Please refer to the docs for using encryption. Could you help me find out how to get the encryption? @springstan |
I think that this error message comes from the used library, therefore it looks like encryption needs to be implemented into the Home Assistant Panasonic viera component. The docs referring to the documentation of the library, which probably includes an example of how to use encryption. |
Okay I worked it out! I placed this code inside media_player.py:
And I changed the volume_up function to:
And it works. I guess every function has to be changed to use the key to make it all working. |
Got it working. Now when I turn the tv off and I want to turn it back on it gives an Error 500: Internal server error. Any ideas? @springstan |
Not really sure what is causing this server error, unfortunately I do not own a panasonic viera device myself so I cannot test it myself. |
@ramondunker do you think you could put your code changes together in a pull-request? I'd also like to use this integration with my TV but can't because of the missing encryption. Hopefully your code can get merged into the master branch. |
I'm not sure if that's going to work because there is no UI for entering the PIN inside Home Assistant. It has to be done with CLI. @SeanHub |
Hmm @springstan my hassbian install of home assistant is missing that manifest file in the Panasonic integration folder? Or am I looking at this in the wrong place? |
@ramondunker fair point, maybe a one time script could run the pin code functionality and the
|
@Depechie No, you are looking in the right place. Not sure why it is missing but I would recommend to create it (manifest.json) manually just to be safe. |
Does it have to be a development environment? Or would a manual install of Home Assistant suffice? |
I made a pull request that updates the component to support encryption (with persistent data and all). I just need to figure out how to make the tests pass (it's the first time I ever contribute to HA). |
Wow good job! I noticed my integration with my tv isn’t working anymore. I’m getting CancelledError error. |
The |
Woow awesome work @joogps !! Can’t wait to get this up and running. |
You’re welcome! Once you update your installation, you will be able to configure the integration either via YAML or the UI 😊 |
It seems that my TV isn't syncing. It shows that it's off in HA, but it is turned on. |
Well, it takes some seconds... Did you check if the entity is set as 'unavailable'? Also check the logs to see if there are any connection errors happening! |
I noticed that this occurs when I use the TV remote. Home Assistant doesn't sync the changed state when turned on or off with the TV remote. Have you had this issue aswel? |
Nope, mine just syncs perfectly. Maybe it's not updating itself, I need to investigate on that. |
hey @joogps I have a GZ950 and the new integration asked the pin connect and the new entity does show on / off status fine of the TV. Logger: custom_components.panasonic_viera.media_player Could not establish remote connection: |
That's probably because your TV disconnects when it turns off. You could try to define a turn_on_action (which will override the default turn on method) to something that would be able to turn the TV on. In this case, wake-on-lan would be a good option. wake_on_lan:
panasonic_viera:
host: 192.168.0.1 # This is the IP address of your TV
turn_on_action:
- service: wake_on_lan.send_magic_packet
data:
mac: "AA:BB:CC:DD:99:1A" # This is the MAC address of your TV However, not all TVs and connection methods support it. Mine doesn't while connected via Wi-Fi, but maybe it would if I had connected it through the Ethernet port. Good luck! |
Any idea @joogps why the official Panasonic app ( on my iPhone ) can start the TV than? Is it using another method you think? |
It's probably using wake-on-lan too. :) |
Also, @Depechie quick question: are you using Wi-Fi or ethernet? I'm curious because my TV doesn't support wake-on-lan while on Wi-Fi and I can't use Ethernet. |
By the way, the documentation page will be updated when Home Assistant gets updated. There you can find more info about customization. :) |
Well it is indeed connected through WiFi and the turn action has no effect with WOL. Still weird the Panasonic app has no issues. |
For reference it now gives another error: An unknown error occurred: local variable 'res' referenced before assignment |
That's a problem with the panasonic_viera library when the connection is not successful. My latest pull request fixes it.
That's strange... I will download the app and see if I can figure out how it works. |
Still, already thx for all the work!! I think with this new version I can already do all the automations I was thinking about. Turning ON the TV is not a high prio for me at the moment ;) |
That makes me very happy! :D If you need to send remote key commands for your automations, I'm working on it too: #34444 |
Home Assistant release with the issue:
channel: stable
hassos: "2.11"
homeassistant: 0.102.1
hostname: hassio
logging: info
machine: raspberrypi3
supervisor: "192"
supported_arch:
timezone: Europe/Rome
Last working Home Assistant release (if known):
homeassistant: 0.102.1
Operating environment (Hass.io/Docker/Windows/etc.):
Hass.io
Integration:
https://www.home-assistant.io/integrations/panasonic_viera/
Description of problem:
Internal server error 500 when press all buttons except the mute button that works.
Problem-relevant
configuration.yaml
entries and (fill out even if it seems unimportant):host: 192.168.102.61
mac: XX:XX:XX:XX:XX:XX
app_power: true
Traceback (if applicable):
Additional information:
The text was updated successfully, but these errors were encountered: