I’ve been trying to get my doorbell to show video in HA (or even still images would work) but can’t get it to work. I’ve followed the instructions here, managed to find the camera device ID using pytapo, set up go2rtc in HA and added the camera with the same URL as in the link.
When I try to view the stream I get the following error:
mse: streams: malformed HTTP status code “ERROR”
There’s not a lot of information about the D230 camera and HA out there, but if anyone has managed to get it working I’d love to know how.
Hi @TexxK, would you be so kind and share more details how you managed to make this work? I am struggling with the same error message. I am kinda new to HA. I managed to make another Tapo camera to work by combination of “Tapo Camera Control” and “WebRTC Camera”. But here I am really lost. No clue how to properly format the url, no clue where and how to use the url (if constructed properly)… No clue how and where to get the child id by pytapo… Any help is appreciated!
Sure, keep in mind I’m not well versed in Python and got this after some trial and error. I’m sure there are better ways but this worked for me.
Started by downloading and installing Python on my PC and saved the following script to a Tapo.py file.
from pytapo import Tapo
ip = "[IP address to tapo hub]"
user = "admin" #don't change this
password = "[Tapo cloud password]"
tapo = Tapo(ip, user, password)
result = tapo.getChildDevices()
print(result)
Open a command prompt → cd to your script location → enter “python3 Tapo.py”. The child device ID you’re looking for is the first value called device_id, provided the doorbell is the only device you have connected to the hub.
Then, in go2rtc this is my config:
streams:
doorbell: tapo://admin:[Tapo cloud password formatted as uppercase 256 hash]@[Tapo hub IP]/?deviceId=[device_id from pytapo]
When it comes to implementation I use it in 2 ways, in a WebRTC camera card and in a doorbell automation to get snapshots of the doorbell in my phone notifications. The WebRTC card defaults to the latest snapshot to save battery, however battery consumtion has increased since this started working so I’m not sure hiding the stream actually leaves the camera “asleep”.
Thanks a lot @TexxK ! This definitely helped a lot! I did some progress and now I am able to add a WebRTC camera card, that shows the stream from go2rtc. However I am not able to do a screenshot from the camera to have rich notification. May I ask you what exactly represents your “camera.doorbell” entity? And what integration you used to have such an entity? I use Tapo Camera Control, it provides me entities for the hub and for the doorbell as well, but most of them are settings. Visual editor or yaml do not show me any suitable device to take a screenshot except for other Tapo camera I have… I tried also deviceId (home assistant id) of doorbell and hub, nothing worked.
To add a camera entity go to Settings → Devices & Services → Add integration → Generic camera. My system is not in English so the actual menu items might be named differently.
In “source URL” add the go2rtc stream locally: rtsp://127.0.0.1:8554/doorbell