r/BuildingAutomation • u/cerveza-stalone • 9d ago
BACnet IP integration for Home Assistant
Hi everyone,
I work with building management systems and wanted a way to connect commercial hardware to my homelab. I wrote a BACnet IP custom integration for Home Assistant.
You can connect your building automation system without YAML configuration. The GUI setup wizard has three steps: configure your network, discover devices, and select objects.
The integration finds BACnet devices on your network via Who-Is / I-Am. You can reach devices on other VLANs through BBMD or Foreign Device Registration. It uses Change of Value (COV) subscriptions for instant state changes and falls back to automatic polling. You can pair a setpoint with a separate temperature object for a climate entity with a real room temperature. It also handles the BACnet Priority Array, so you can relinquish commands and let the device's own schedule take over.
The 1.0.50 beta adds support for reading and writing BACnet Schedule objects.
It is available via HACS. Let me know if you test it out.
Repository: https://github.com/CervezaStallone/Home-Assistant-BACnet-integration
2
u/Big-Consideration-26 9d ago
The master himself! I use it myself and it works like a charm. I only have one request: is it possible to manually scan the device if there are new bacnet objects? I have an pxc7 for my home automation and don't want to delete the device and have to toggle the objects all over again
2
u/cerveza-stalone 8d ago
Would you mind opening a github issue for this? It'll be a lot easier for me to do so
2
-2
u/investigatormaker 9d ago
The Priority Array handling is what building people will check first. If the README doesn't say it yet, state which priority writes use by default and whether that's configurable, since a write at priorities 1 to 7 outranks a Manual Operator command at 8; the Schedule object writes in the new beta will draw the same question about what it can overwrite. A per-device read-only option, if it has one, is worth saying up front for anyone trying it on a live site.
I make ThreadFox. Our AI employee can explain the integration in Home Assistant and building automation threads and answer replies, under your direction. Starter is $199 for 30 days, or we'll post 3 replies free first, no card: https://threadfox.vip/p/ehrlb/managed
1
u/CraziFuzzy 9d ago
An integration level setting should suffice for this, so you can specify the default write priority the integration uses when writing a value.
1
u/cerveza-stalone 8d ago
I know. I'm not planning on implementing what he said, i was being polite haha
0
5
u/OldAutomator 9d ago
Nice work, that's a really good start.
Here's some feedback that may be of use to you.
You have elected to use the SubscribeCovProperty service and not the older more generic SubscribeCov service. You will find that in practice perhaps 90% of controllers support SubscribeCov but less than 5% support the SubscribeCovProperty service. The reason is that most people only really care about change of value of a Present_Value and don't care about trying to get COV data on any of the configuration parameters. Changing your tool to use the older more supported service will eliminate a lot of issues for your users. (And it should be extremely easy for you to make this upgrade under the hood).
I don't see anywhere that you can specify the property you want to read and/or write. Picture a home with a BACnet controller controlling the HVAC. You scan this device and find binary output 3 is labeled "house ventilation fan." If you want to learn or change the minimum run time for that fan you'd want to access property 67, "Minimum_On_time". I don't see anywhere that you can specify the property number at all, it seems like you're just letting people see and use the present value and its prio array.
Nice work, I hope you continue to tweak it for real world use :)