百科.dev
全部条目在线工具AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
N

node-red-contrib-homebridge-automation

> 编程语言
开源

Homebridge 和 Node-RED 集成

100 stars0 点赞1 次浏览
访问官网GitHub

工具介绍

Homebridge 和 Node-RED 集成

Homebridge Automation powered by Node-RED

The above Node-RED Flow, turns on my 'Outside Office' light when the powder room is turned on, and turns them both off after 10 seconds. Not practical but a good sample of the power behind Node-RED. Link to exported flow for above.

Table of Contents

  • Homebridge Automation powered by Node-RED
  • Table of Contents
  • Introduction
    • Caveats
    • Changes
      • Mar 18, 2019 - Version 0.0.39
      • Mar 19, 2019 - Version 0.0.42
      • Mar 31, 2019 - Version 0.0.
      • May 9, 2019 - Version 0.0.43
      • May 15, 2019 - Version 0.0.44
      • May 29, 2019 - Version 0.0.45
      • July 27, 2019 - Version 0.0.50
      • Feb 24, 2020 - Version 0.0.56
      • Mar 18, 2020 - Version 0.0.59
      • Oct 13, 2020 - Version 0.0.71
      • Oct 24, 2020 - Version 0.0.71
      • Nov 1, 2020 - Version 0.0.73
      • Nov 13, 2020 - Version 0.0.76
      • Feb 2, 2021 - Version 0.0.78
      • Mar 9, 2021 - Version 0.0.80
      • April 23, 2021 - Version 0.0.82
      • Dec 31, 2022 - Version 0.1.3
      • Jan 6, 2023 - Version 0.1.5
      • Jan 11, 2023 - Version 0.1.7
      • Jan 15, 2023 - Version 0.1.8
      • Dec 15, 2024 - Version 0.2.0
      • April 15, 2025 - Version 0.3.0
        • Breaking Change
        • Fixes
      • Jan 15, 2026 - Version 0.3.3
        • Breaking Change
        • Fixes
      • Version 0.3.4
        • Breaking Change
        • Changes
        • New Features
      • Version 0.3.5
        • Changes
  • Backlog / Roadmap
    • Dropped items
  • Installation Steps
    • 1 - Install Node-RED and Homebridge
    • 2 - Prepare Homebridge for integration with Homebridge-Automation
    • 3 - Install Homebridge-Automation into Node-Red
    • 4 - Start Node-Red
    • 5 - Initial setup and configuration inside Node-Red
    • 6 - Configure 'hb event' to receive updates from your Accessories
  • Node-RED Homebridge-Automation Message Structure
    • hb event
      • Output
    • hb resume
      • input
      • output
    • hb status
      • input
      • output
    • hb control
      • Input
  • Flows Shared from Community
  • Donations
  • Troubleshooting / DEBUG MODE
    • To start Node-RED in DEBUG mode, and output Homebridge-Automation debug logs start Node-RED like this.

Introduction

This is a release of the ability to integrate Homebridge Accessories into Node-RED so that you can start flows from Homebridge accessory events and control your existing homebridge accessories. ( To create accessories in HomeKit, please use node-red-contrib-homekit-bridged. )

Four different node types are available, the first node hb event listens for changes to an accessory (ie on/off) and sends a message into Node-Red containing the updated accessory status. The second node hb resume holds the state of an accessory and supports creating a state resume function. The third node hb status allows you to poll an accessory for status. The forth node hb control allows you to control a homebridge accessory. Each node is tied to an individual Home App Tile/Service of an accessory (ie on/off and brightness).

Payload from a dimmable lightbulb.

{ "On":true, "Brightness":100 }

Caveats

  • Please keep in mind that this integration only works with devices supported/exposed with HomeBridge Plugins. This does not have visibility to Native HomeKit devices. ( Similar to my homebridge-alexa plugin. )

  • For the hb event node, the ability of a Accessory to generate events in Real Time is dependent on how the plugin was architected and the actual device. Some are very good at generating events in real time, and others only generate events when the Home App is opened to the accessory. YMMV.

With a plugin, you can see if it supports Real Time events, by opening the Home App, and looking at an accessory. Then trigger a local event outside of homebridge/homekit. If the accessory updates in real time, then it support Real Events. ( An example of a local event can be turning on a Smart Light Switch, by the local switch. Another example would be using the vendor app to control an accessory.)

Changes

Mar 18, 2019 - Version 0.0.39

  • Changed hb state to hb resume to make the use case for the node more self-explanatory. If you had used the hb state node in your existing flow, nodeRed will not start unless you manually change the node type in the flow file. To fix the issue, manually edit the flow file in your .node-red directory, and change the type reference hb-state to hb resume
  • Changed individual nodes from being characteristic based to device/service based. When updating from previous versions, you will need to select your devices again.
  • With the change in nodes to be device/service based, the payload message structure changed from being individual characteristic based to a JSON object containing all the characteristics you want to update on the device. ie in the previous version a device control message payload of true going to the On characteristic would turn on a light, with this version it would be be represented with a message payload of { "On":true, "Brightness":100 }. This particular payload would turn on a light and set the brightness to 100. I made this change to enable easier intergradation with node-red-contrib-homekit-bridged.
  • If you send an incorrect message payload to the hb resume or hb control nodes it would output a debug message containing the valid/supported characteristics for use in the payload object.
  • Updated the Homebridge accessory parser, so more diverse devices will now be exposed.

Mar 19, 2019 - Version 0.0.42

  • Fix for events being missed after homebridge restarts

Mar 31, 2019 - Version 0.0.

  • Fix for a crash when events are received by an accessory with multiple services.

May 9, 2019 - Version 0.0.43

  • Added retries for registering of events during startup. ( 1000 retries, retry delay of 30 seconds )

May 15, 2019 - Version 0.0.44

  • Added reqTimeout and set default timeout on homebridge requests to 14 seconds

May 29, 2019 - Version 0.0.45

  • Name Change to Homebridge-Automation

July 27, 2019 - Version 0.0.50

  • Publish as a NPM package to resolve #17

Feb 24, 2020 - Version 0.0.56

  • Fix for device naming for Nest FAN and ECO Mode

Mar 18, 2020 - Version 0.0.59

  • Support for the new version of HAP-NodeJS

Oct 13, 2020 - Version 0.0.71

  • Realize that I have not updated the change log for a while, so this is a laundry list of changes since 0.0.59
  • Additional error logging
  • Fix for issue #47 and #48
  • Support camera devices - tks dxdc
  • Improved timeout support
  • Support for the latest version of homebridge

Oct 24, 2020 - Version 0.0.71

  • Added support for plugins that allow device name editing within the Home app.

Nov 1, 2020 - Version 0.0.73

  • Added support for Air Pressure and Power devices
  • Fixed issue #69 TV accessory events not firing since update of homebridge-broadlink-rm plugin

Nov 13, 2020 - Version 0.0.76

  • Update HB Control Node to output snapshot images from camera's. Payload output format is a buffer object containing image.

Feb 2, 2021 - Version 0.0.78

  • Change hb-control to display control message payload rather than 'Ok'
  • Tweak device parser to remove these duplicates
    • Camera RTPStream Management
    • Input Source with a name of 'dummy'

Mar 9, 2021 - Version 0.0.80

  • hbEvent: add option to send initial state

April 23, 2021 - Version 0.0.82

  • Support for homebridge instances with different PINS. Tks @dxdc

Dec 31, 2022 - Version 0.1.3

  • Removal of request dependency from hap-node-client

Jan 6, 2023 - Version 0.1.5

  • Remove support for ipv6

Jan 11, 2023 - Version 0.1.7

  • Fix for #110 and homebridge-alexa #564

Jan 15, 2023 - Version 0.1.8

  • Workaround for #111

Dec 15, 2024 - Version 0.2.0

  • Major code base refresh, and migration from hap-node-client to hap-client ( Potential fix for #120 )
  • With the change in connectivity to homebridge, please validate all your nodes are connected after the update. And pay particular attention to Camera nodes, as for some devices the name has changed.
  • Testing and Development was completed on Node-RED version: v4.0.2 and Node.js version: v20.18.1

April 15, 2025 - Version 0.3.0

Breaking Change

  • Problem when choosing between multiple accessories with the same name #142. This fix has a breaking change for the name structure for Fans, Input Sources from TV's, and Camera's. And these devices will need to be configured again.

Fixes

  • Add common supported types Window, Window Covering, Light Sensor #151, tks @HDeKnop
  • HB-Control Node Turns Off then On when this message is received #152
  • Added Debug logging configuration option that creates a file homebridge-automation-endpoints.json, which contains all the homebridge devices discovered. It can be used as part of troubleshooting device issues.
  • Fix for some camara devices not outputing events

Jan 15, 2026 - Version 0.3.3

Breaking Change

  • An early change broke the behaviour of the status node, and it emits all events, and not just on request. Original behaviour has been restored. If you require all events, use the event node.

Fixes

  • Fix for #195 - Status node sends messages on device state change without input trigger

Version 0.3.4

Breaking Change

  • Updated support for power bars and devices with multiple services (#216, #212, #221). As a side effect, the number of devices returned has increased and the names of devices with multiple services have changed. Please revisit your devices after installing. If, after updating, a node cannot connect to the appropriate device, the debug log will contain ERROR: Device registration failed. You will need to re-select the device in the drop down. In my setup, nodes with Camera Motion sensors and Ceiling Fans needed to be revisited.

Changes

  • Fix deploy reconnection, message queuing, and editor UX (thanks @dxdc) #215

New Features

  • Added logging of device naming/uniqueId collisions. Devices with duplicate names present only one option for selection. If a duplicate is detected, the debug log will show it as a `Duplicate u

Issues· 10 开放

查看全部 Issues在 GitHub 打开

暂无开放 Issues,或尚未同步最近议题。

> 标签

JavaScripthomebridgenode-red

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月18日
分类编程语言
定价开源

> 相关工具

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言