DanielWinks / HassOS-Addons

MIT License
20 stars 5 forks source link

Kerui-Security magnetic door sensor #6

Closed jeffcostantino closed 1 year ago

jeffcostantino commented 3 years ago

I have some door sensors that show up but don't match your "type" field, they say "state = open" is there any way to add that in?

DanielWinks commented 3 years ago

Can you post a screenshot of what this device emits on MQTT from MQTT Explorer? I've got a few of these cheap chinese things to test out, and they just aren't worthwhile in my experience. I tried a Kerui contact sensor and it didn't register open/close events more than about half the time if you opened and closed the door quickly. Looking at it on Wireshark showed why: the sensor spent like 2 seconds sending the first event over and over again, usually 21 times over the course of about 2 seconds. If there was another event during that time, it was just ignored entirely.

I can see if they can be added easily if you post a screenshot, but if what you've got from them is anything like the couple of items I tested, they just don't provide enough info to rtl_433 to generate a proper device in HA with. You can still use this add-on, and manually make an MQTT entity for them, but there's not really any point to making a "device" with a single entity associated.

jeffcostantino commented 3 years ago

I've attached a clip of it, I have two different types of sensors - one does "open" only and the other one also reports "close" and a tamper setting as well. They seem to be pretty robust, only lacking a battery indicator flag.

Oddly they also identify as a smoke detector but I guess there are only so many slots and those probably happen to overlap.

Capture

DanielWinks commented 3 years ago

Cool, thanks. I think that should be easy enough to add. The reason they report as a smoke detector is because of the el cheapo chip they use. A few of the cheapie chinese things I've tried also had the same issue, and it came down to that. At some point I might try messing around with some custom decoders for the ones I have, as they don't even show up as anything usable with what's already in rtl_433. But since you've got ones that do, I'll add a support for id-only stuff.

jeffcostantino commented 3 years ago

Ok thanks a lot! I heard that some of these cheaper sensors don't have a hard coded ID and they can lose them if the battery dies. Not sure if this is one of them, I sort of gave up on them with the sonoff rf and picked them back up with rtl-433.

On Fri, Oct 29, 2021, 11:21 AM Daniel Winks @.***> wrote:

Cool, thanks. I think that should be easy enough to add. The reason they report as a smoke detector is because of the el cheapo chip they use. A few of the cheapie chinese things I've tried also had the same issue, and it came down to that. At some point I might try messing around with some custom decoders for the ones I have, as they don't even show up as anything usable with what's already in rtl_433. But since you've got ones that do, I'll add a support for id-only stuff.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/DanielWinks/HassOS-Addons/issues/6#issuecomment-954829655, or unsubscribe https://github.com/notifications/unsubscribe-auth/AMKFYAZSRI3SSUGISLGJYELUJK3XFANCNFSM5GKRFRTQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

DanielWinks commented 1 year ago

Closing this as I am no longer maintaining this add-on (I've moved my home automation to Hubitat and no longer use Home Assistant).