Skip to content
Home Assistant custom component for Beward security Cameras and Doorbells
Python Shell Dockerfile
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.devcontainer
.github
.vscode
custom_components/beward
.gitattributes
.gitignore
CONTRIBUTING.md
LICENSE
README.md
beward.png
hacs.json
info.md
requirements.txt
tracker.json
update_tracker.py

README.md

Please ⭐️ this repo if you find it useful

ha-beward

GitHub Release GitHub Activity License Requires.io

hacs Project Maintenance

GitHub pull requests Bugs

Community Forum

The beward implementation allows you to integrate your Beward devices to Home Assistant.

Beward Logo

There is currently support for the following device types within Home Assistant:

Currently only doorbells are supported by this integration.

I also suggest you visit the support topic on the community forum.

Installation

  1. Using the tool of choice open the directory (folder) for your HA configuration (where you find configuration.yaml).
  2. If you do not have a custom_components directory (folder) there, you need to create it.
  3. In the custom_components directory (folder) create a new folder called beward.
  4. Download all the files from the custom_components/beward/ directory (folder) in this repository.
  5. Place the files you downloaded in the new directory (folder) you created.
  6. Restart Home Assistant
  7. Add beward: to your HA configuration.

Using your HA configuration directory (folder) as a starting point you should now also have this:

custom_components/beward/__init__.py
custom_components/beward/binary_sensor.py
custom_components/beward/camera.py
custom_components/beward/const.py
custom_components/beward/helpers.py
custom_components/beward/manifest.json
custom_components/beward/sensor.py

* * *

I put a lot of work into making this repo and component available and updated to inspire and help others! I will be glad to receive thanks from you — it will give me new strength and add enthusiasm:


Patreon PayPal
or support via Bitcoin or Etherium:
Bitcoin
16yfCfz9dZ8y8yuSwBFVfiAa3CNYdMh7Ts

Configuration

To enable Beward device, add the following to your configuration.yaml file:

# Example configuration.yaml entry
beward:
  - host: HOST_ADDRESS_CAMERA
    username: YOUR_USERNAME
    password: YOUR_PASSWORD

Configuration variables

host:
(string) (Required)
The IP address or hostname of your Beward device. If using a hostname, make sure the DNS works as expected.

username:
(string) (Required)
The username for accessing your Beward device.

password:
(string) (Required)
The password for accessing your Beward device.

name:
(string) (Optional)
This parameter allows you to override the name of your Beward device in the frontend.
Default value: "Beward <device_id>"

port:
(integer) (Optional)
The port that the Beward device is running on.
Default value: 80

rtsp_port:
(integer) (Optional)
The RTSP port that the Beward camera is running on.
Default value: Autodetect from the device

stream:
(integer) (Optional)
Number of video stream from Beward device.
Default value: 0

ffmpeg_arguments:
(string) (Optional)
Extra options to pass to ffmpeg, e.g., image quality or video filter options.
Default value: "-pred 1"

Note: To be able to playback the live stream, it is required to install the ffmpeg component. Make sure to follow the steps mentioned at FFMPEG documentation.

cameras:
(list) (Optional)
Camera types to display in the frontend. The following cameras can be added:
Default value: all cameras below

live:
Live view camera.

last_motion:
Camera which store photo of last motion.

last_ding:
Camera which store photo of last visitor.

binary_sensors:
(list) (Optional)
Conditions to display in the frontend. The following conditions can be monitored:
Default value: None

online:
Return on when camera is available (i.e., responding to commands), off when not.

motion:
Return on when a motion is detected, off when not.

ding:
Return on when a doorbell button is pressed, off when not.

sensors:
(list) (Optional)
Conditions to display in the frontend. The following conditions can be monitored:
Default value: None

last_activity:
Return the timestamp from the last event captured (ding/motion/on demand) by the Beward device camera.

last_motion:
Return the timestamp from the last motion event captured by the Beward device camera.

last_ding:
Return the timestamp from the last time the Beward doorbell button was pressed.

* * *

I put a lot of work into making this repo and component available and updated to inspire and help others! I will be glad to receive thanks from you — it will give me new strength and add enthusiasm:


Patreon PayPal
or support via Bitcoin or Etherium:
Bitcoin
16yfCfz9dZ8y8yuSwBFVfiAa3CNYdMh7Ts

Advanced Configuration

You can also use this more advanced configuration example:

# Example configuration.yaml entry
beward:
  - host: HOST_ADDRESS_CAMERA_1
    username: YOUR_USERNAME
    password: YOUR_PASSWORD
    binary_sensors:
      - motion
      - online
    sensors:
      - last_ding

  # Add second camera
  - host: HOST_ADDRESS_CAMERA_2
    username: YOUR_USERNAME
    password: YOUR_PASSWORD
    name: "Back door"
    rtsp_port: 1554
    camera:
      - last_motion

Usage tips

Send history image via Telegram

You can use photos of the last motion and the last ding outside this integration. For example, send it via Telegram.

History images are stored in /config/.storage/beward/. For example, for a camera named "Front door" there will be files front_door_last_motion.jpg and front_door_last_ding.jpg.

Automation example (see the Telegram documentation for more details how to send images):

# Example configuration.yaml entry
homeassistant:
  whitelist_external_dirs:
    - /config/.storage/beward  # Required for Home Assistant version 0.48+

automation:
  - alias: "Front door Ding"
    trigger:
      platform: state
      entity_id: binary_sensor.front_door_ding
      to: 'on'
    action:
      - service: notify.NOTIFIER_NAME
        data:
          message: "The doorbell is ringing!"
          data:
            photo:
              file: /config/.storage/beward/front_door_last_ding.jpg
              caption: "The doorbell is ringing!"

Contributions are welcome!

If you want to contribute to this please read the Contribution guidelines

Track updates

You can automatically track new versions of this component and update it by custom-updater (deprecated) or HACS.

For custom-updater to initiate tracking add this lines to you configuration.yaml file:

# Example configuration.yaml entry
custom_updater:
  track:
    - components
  component_urls:
    - https://raw.githubusercontent.com/Limych/ha-beward/master/tracker.json
You can’t perform that action at this time.