Bug: camera.snapshot not working after HA restart
See original GitHub issueDescribe the bug
I have a TP-Link Tapo C110 in use. Every time I restart Home Assistant (manually or due to initiating core updates) the camera seems to lose its ability to make snapshots. A resulting JPG image produced by camera.snapshot
(manual + automatic) always has a size of 0 (zero) bytes.
A reboot of the camera (either via Tapo app or via tapo_control.reboot
) does not resolve the issue. The only “solution” is to power off and power on the camera again. As a known issue, the camera temporarily loses its motion sensor but it gets it back once it detects a motion. After that, camera.snapshot
produces a valid image file again.
To Reproduce Steps to reproduce the behavior:
- Make sure
camera.snapshot
does produce a valid image file. - Restart HA.
- Trigger
camera.snapshot
(manually or via automation) - Check resulting image file.
Expected behavior
camera.snapshot
produces a valid image file once a working stream is available from the camera. It makes no difference whether
- HA has been restarted or
- the camera has been rebooted (e.g. via
tapo_control.reboot
) or - the camera has been powered off and on again.
Log n/a
Camera (please complete the following information):
- Device Model: C110
- FW: 1.1.12 Build 211028 Rel.22161n(4555)
Using stream component no (Tapo-Control only)
Camera works through onvif component OR different cameras work in general yes
Camera has all attributes filled out properly in developer tools yes
HASS Environment
- Home Assistant 2022.2.5
- Raspberry Pi 4 (4 GB) directly connected to router
- Sandisk microSDHC UHS-I 64GB Class10
- Pi-Hole, blocking 2 TP-Link URLs
Additional context n/a
Issue Analytics
- State:
- Created 2 years ago
- Comments:6 (3 by maintainers)
It persists and gets even worse.
Already done, In fact it was one of my first actions with the camera.
I have also thought of this. Before, I have played with MotionEye. I was able to see a stream with it. But I have completely removed the integration when I was unable to solve this issue. I also added and later removed manual camera definitions via YAML. Unfortunately, this did not help either.
I am afraid I have to live with it so far. At least, I know how to deal with it.
Thank you very much for your support, Juraj! That was very nice of you.
In that case I think it might be a camera limitation. Try turning off stream (or turning it on if off) via settings and see if the issue persists. Also try updating camera firmware if you are not on the latest one. Also turn off any additional streams you might be running off the camera.