Components Home Assistant "Room"

3 minutes of reading
Proconductor: Home Assistant Community
Availability: included in thepersonale HUB Home Assistant
Category: software
Type: components Home Assistant
Implementation difficulties: half

The "Camera" component is the founder of the platforms Home Assistant dedicated to the integration of IP Cam (surveillance cameras Wi-Fi/ LAN).

Basically it is possible, through a wide bouquet of different technical solutions, integrate the IP Cam video stream inside the profirst personal home automation based on Home Assistant, giving us an eye on our home automation environment especially when we are away from it.Xiaomi IP Cam

By now the vast majority of IP Cams on the market has a Cloud service which acts as a bridge between the camera and the camera profirst control device (smartphone, tablet, computer), allowing us a remote control - which makes technically useless an integration with Home Assistant. As explained however also in an ad hoc episode of our podcast, these Clouds can rappresentare a weakness in terms of security, because if comproput could give attackers direct access to our IP Cams.

Integration with Home Assistant circumscribes this proBlema, because the use of the Cloud of produttore (note: only if the specific integration of the IP Cam allows it) can be bypassed while maintaining remote access capabilities. It will indeed be Home Assistant our "bridge" to our private video stream.

In case the platform chosen for integration foresee necessarily use of the Cloud of produttore (eg. Logi Circle), such integration will still be useful in case you want to use ad hoc techniques for image recognition (eg. TensorFlow) or simply love to concentrate everything, including IP Cams, in the proprio HUB personnel. IP Cams can also be used from virtual sensors of movement.

This component does not explain how to integrate a specific IP Cam but rather the characteristics of the service and entity from it arising at Home Assistant.

The "daughter" platforms of this component are (complete list here, right column):

  • Abode Camera
  • Amcrest IP Camera
  • Android IP Webcam Camera
  • Arlo Camera
  • August Camera
  • Axis Camera
  • Blink Camera
  • BloomSky Room
  • Canary Room
  • Dispatcher IP Camera
  • DoorBird Camera
  • Family Hub Camera
  • FFmpeg Camera
  • Foscam IP Camera
  • Generic IP Camera
  • Generic MJPEG IP Camera
  • Logi Circle Camera
  • MQTT Camera
  • Neato Camera
  • Nest Camera
  • Netatmo Camera
  • ONVIF Camera
  • Raspberry Pi Camera
  • Ring Camera
  • Skybell Camera
  • Synology Camera
  • UniFi Video Camera
  • USPS Camera
  • Verisure Room
  • Xeoma Camera
  • Xiaomi Camera
  • Yi Home Camera
  • ZoneMinder Camera

Focus ad hoc (on specific IP Cam) on inDomus will follow.

Services

The integration of this component provides five basic services:

turn_onActivate the IP Cam. Not all integrations support it (see the reference platform)
turn_offDisable the IP Cam. Not all integrations support it (see the reference platform)
enable_motion_detectionActivate the movement recognition mode
disable_motion_detectionDisable the movement recognition mode
snapshotSave a snapshot from the video stream of the IP Cam to file.

"Turn_on" service

If summoned, activate the IP Cam. Not all integrations support it (see the reference platform).

Service data attributesOptionalDescription
entity_idYupspecific entity on which to implement the service

"Turn_off" service

If summoned, deactivate the IP Cam. Not all integrations support it (see the reference platform).

Service data attributesOptionalDescription
entity_idYupspecific entity on which to implement the service

"Enable_motion_detection" service

If summoned, it activates the movement recognition mode.

Service data attributesOptionalDescription
entity_idYupspecific entity on which to implement the service

"Disable_motion_detection" service

If evoked, it deactivates the movement recognition mode.

Service data attributesOptionalDescription
entity_idYupspecific entity on which to implement the service

"Snapshot" service

If summoned, it saves a snapshot from the video stream of the IP Cam on file.

Service data attributesOptionalDescription
entity_idNo.specific entity on which to implement the service
filletnameNo.file name template on which to save the snapshot. The variable is "entity_id"(Eg."/tmp/snapshot_{{ entity_id }}")

The route included in filletname must be an entry of whitelist_external_dirs in the sectionhomeassistant: of the file configuration.yaml.

In the following example, an automation save a snapshot from the IP Cam "Camera.miaipcam" at the path "/ Tmp”With a file name containing date and time:

action:
  service: camera.snapshot
  data:
    entity_id: camera.miaipcam
    filename: '/tmp/miaipcam_{{ now().strftime("%Y%m%d-%H%M%S") }}.jpg'


Home Assistant Official LogoATTENZIONE: remember that there is on our FORUM community an ad hoc section dedicated to Home Assistant, for any doubt, question, information on the specific merit of these components.


Please comment below