16
submitted 5 months ago* (last edited 5 months ago) by Lifebandit666@feddit.uk to c/homeassistant@lemmy.world

This week I've been playing with Espresence, which for anyone that doesn't know, is a program that runs on an ESP32 and tracks Bluetooth. It then has a guess where you are based upon the strength of the signal.

So a little backstory, I recently wiped out my HA server and didn't have a backup so I've started from scratch. Since I've started from scratch I've been avoiding Node Red and just using the HA automations, but I am a NR boy at heart.

Previously my bathroom light automation in NR was a massive flow of door, motion, leak sensors.

When I added espresence I decided to reinstall NR to add these new sensors into my automations, and found the Binary Sensor node, so I had a play and managed to make a Front Room Presence binary sensor.

"This is pretty good" I thought and made another for my bathroom, taking in all the sensors I used previously. But this time they triggered a binary sensor instead of the lights.

Now I have the binary sensor triggering the light automation, with extras here and there (like guest mode being on, trigger the lights from the hallway sensor instead of the bathroom sensor. The light automation looks much cleaner and presence is all done on one page.

So I'm using the binary sensor in 2 ways here, as an addition to the motion sensor in my front room, and as a replacement for a full blown automation.

Functionally it's not really any different to using an input boolean helper, but I can make this binary in NR itself.

Edit: Gotchas

So I should probably tell you about the big Gotcha in creating a Binary in Node Red.

You need to set the msg. from string to Boolean. So for each binary you need a Boolean true and a Boolean false nose to set it off and on. Everything else was pretty simple

you are viewing a single comment's thread
view the rest of the comments
[-] Lifebandit666@feddit.uk 4 points 5 months ago

Cool, I'll keep tinkering and let you know when I reinvent quantum computing

[-] NeoNachtwaechter@lemmy.world 2 points 5 months ago

Strawberry please, with lots of cream on top

this post was submitted on 15 May 2024
16 points (100.0% liked)

homeassistant

11921 readers
58 users here now

Home Assistant is open source home automation that puts local control and privacy first. Powered by a worldwide community of tinkerers and DIY enthusiasts. Perfect to run on a Raspberry Pi or a local server. Available for free at home-assistant.io

founded 1 year ago
MODERATORS