Coder Social home page Coder Social logo

Comments (6)

marcelveldt avatar marcelveldt commented on June 7, 2024 1

There is an ongoing discussion about forwarding device events to HA. Currently that is NOT implemented. The idea is that that will be a new entity type for events as a global new HA feature. Not only interesting for Matter but for a lot more integrations. So this is not a bug but more like a feature request. Let's wait until the HA feature is implemented and then we will implement this in the Matter integration as well.

from python-matter-server.

marcelveldt avatar marcelveldt commented on June 7, 2024 1

Yeah, I think you have a very valid usecase. Let's wait for the discussion about events in HA so we know where to land events the right way. Previously HA integrations would just have forwarded events to the HA eventbus (just like we do with e.g. Hue, Z-Wave etc.) but that is very user unfriendly so we want to do this with a special entity which is visualized and also allows to show the history of events.

Because this change is so close of being implemented, we decided to hold off implementing "the old" way of doing it for Matter. So for now all I ask is a little bit of patience as this is being sorted out.

from python-matter-server.

marcelveldt avatar marcelveldt commented on June 7, 2024

You need to subscribe to it by adding the attributes in the discovery schema

from python-matter-server.

marcelveldt avatar marcelveldt commented on June 7, 2024

https://github.com/home-assistant/core/blob/dev/homeassistant/components/matter/lock.py#L173

Make sure that all required attributes that need to be watched are either in the required_attributes or optional_attributes and the event subscription will be automatically handled,

from python-matter-server.

marcelveldt avatar marcelveldt commented on June 7, 2024

Ah you want to watch a node event and not attribute change, that is something new. Can you enlighten me why and how we need to consume that in the entity as normally entities consume attributes, not events.

from python-matter-server.

evanjarrett avatar evanjarrett commented on June 7, 2024

I would like to know if the deadbolt/lock was able to close all the way. If I prevent it from latching, the keypad flashes, and beeps a few times trying to close the lock, but eventually gives up and fires off a doorlockalarm.
As far as I can tell the only way to know that is if the DoorLock.Events.DoorLockAlarm event was triggered since there is no LockState value for it:

class DlLockState(MatterIntEnum):
            kNotFullyLocked = 0x00
            kLocked = 0x01
            kUnlocked = 0x02
            kUnlatched = 0x03
            # All received enum values that are not listed above will be mapped
            # to kUnknownEnumValue. This is a helper enum value that should only
            # be used by code to process how it handles receiving and unknown
            # enum value. This specific should never be transmitted.
            kUnknownEnumValue = 4,

The attribute is set to 0 (kNotFullyLocked) which in home assistant is labeled as "Locking". But the lock is no longer in the process of locking.

from python-matter-server.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.