Add amcrest binary_sensors (#22703)
* Add amcrest binary_sensors Add binary_sensors with option motion_detected. Deprecate motion_detector sensor. * Update per review * Update per review Add custom validators to make sure camera names are unique, and to issue warning if deprecated sensors option motion_detector is used. async_setup_platform should not return a value. * Another review update Since there is only one type of binary_sensor, remove type test in update method.
This commit is contained in:
parent
a48c0f2991
commit
34bb31f4ec
4 changed files with 147 additions and 46 deletions
|
@ -28,8 +28,6 @@ async def async_setup_platform(hass, config, async_add_entities,
|
|||
|
||||
async_add_entities([AmcrestCam(hass, amcrest)], True)
|
||||
|
||||
return True
|
||||
|
||||
|
||||
class AmcrestCam(Camera):
|
||||
"""An implementation of an Amcrest IP camera."""
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue