Integration with ID Lock 150

Hi, U get a sensor with unlock user number. That u can use to make automation or sensor.
Regards Andreas

Hi Andreas, i have tried all of the above mentioned ways to get this working but there are more or less oblivious ups and downs with each way.

Regular Z-wave integration:
Can get all the settings to work but it can more or less just show unlock/lock status.

Open Z-wave (beta) integration: More info but no settings.

Zwavetomqtt: Millions of options but really hard to get it working as expected. I think I should be able to make custom entities with lock info, settings etc but i haven’t figured that part out yet. Andreas you are using zwavetomqtt with idlock? Do you have a good template?

Some follow up on this subject. Tried switching to openhab and got much better results. After changing command poll intervall from 1500 ms to 10 000 ms in openhab i get all the notification reports and it shows instantly if the door is open or closed. Allt the configuration settings works too.

Does anyone know how to fix the command poll problem? I still want to use home assistant but the zwave-integration is not good.

1 Like

This is what I got when the lock was added as unsecure node. Make sure to add the lock as a secure node, after switching over to the new openZwave (still in beta, until Q1 2021) add-on and integration. ID lock 150 does not work out of the box with the standard z-wave component in Home Assistant (soon to be depreciated anyway), as it does not have built-in support for id lock 150.

Nope, it is added as a secure node. For the access control it is only notifications from 3 and 4 and the case locked unlocked via z-wave that it doesn’t report. When the lock it self initiates a notification report all data is recieved.

With the new Zwave JS it works really well.

You get sensors for:

  • The current status of the door
  • Home Security - Tampering, product cover removed
  • Low battery level
  • Battery level
  • Access Control - Lock state
  • Home Security - Cover status
  • Access Control - Lock jammed

But the most important thing:
You can listen to zwave_js_event and easily create template sensors for the last action and which code/tag was used.

Example:

Event 1 fired 9:10: 
{
    "event_type": "zwave_js_event",
    "data": {
        "type": "notification",
        "domain": "zwave_js",
        "node_id": 60,
        "home_id": 3803889724,
        "device_id": "ef43a40a818f97b547dbfc27e76ae191",
        "label": "Keypad unlock operation",
        "parameters": {
            "userId": 1
        }
    },
    "origin": "LOCAL",
    "time_fired": "2021-02-04T08:10:58.309768+00:00",
    "context": {
        "id": "d753c3d15c8507722c786cd35917eb43",
        "parent_id": null,
        "user_id": null
    }
}
Event 0 fired 9:10: 
{
    "event_type": "zwave_js_event",
    "data": {
        "type": "notification",
        "domain": "zwave_js",
        "node_id": 60,
        "home_id": 3803889724,
        "device_id": "ef43a40a818f97b547dbfc27e76ae191",
        "label": "Keypad lock operation",
        "parameters": {
            "userId": 0
        }
    },
    "origin": "LOCAL",
    "time_fired": "2021-02-04T08:10:35.760964+00:00",
    "context": {
        "id": "b49fb3e22ab83e904cbad124a93514c0",
        "parent_id": null,
        "user_id": null
    }
}

I choose to use https://github.com/azogue/eventsensor to create two sensors, one for the last action (sensor.id_lock) and one for the last user (sensor.id_lock_user). Then I combine them in a template sensor which seems to work really well.

    id_lock_last_action_tmpl:
      value_template: >-
        {% if is_state('sensor.id_lock', 'Keypad unlock operation') %}
          Upplåst med kod av {{ states('sensor.id_lock_user')}} 
        {% elif is_state('sensor.id_lock', 'RF unlock operation') %}
          Upplåst av Home Assistant
        {% elif is_state('sensor.id_lock', 'Manual unlock operation') %}
          Upplåst med knapp
        {% elif is_state('sensor.id_lock', 'Manual lock operation') %}
          Låst med knapp
        {% elif is_state('sensor.id_lock', 'RF lock operation') %}
          Låst av Home Assistant
        {% elif is_state('sensor.id_lock', 'Keypad lock operation') %}
          Låst utifrån
        {% elif is_state('sensor.id_lock', 'Auto lock locked operation') %}
          Låst automatiskt
        {% elif is_state('sensor.id_lock', 'Lock jammed') %}
          Låset har fastnat
        {% elif is_state('sensor.id_lock', 'All user code deleted') %}
          Alla koder har tagits bort
        {% elif is_state('sensor.id_lock', 'Single user code deleted') %}
          En kod har tagits bort
        {% elif is_state('sensor.id_lock', 'Single user code added') %}
          En kod har lagts till
        {% elif is_state('sensor.id_lock', 'New user code not added due to duplicate code') %}
          Ny kod kunde inte läggas till (inte unik)
        {% elif is_state('sensor.id_lock', 'Unlock By RF with invalid user code') %}
          Unlock By RF with invalid user code
        {% elif is_state('sensor.id_lock', 'Lock by RF with invalid user code') %}
          Lock by RF with invalid user code
        {% else %}
          Fel: Okänd status
        {% endif %}
      friendly_name: 'Senaste aktivitet'
      icon_template: mdi:shield-home

I haven’t found out how to get the Away Mode which I used to activate the alarm, but there is an open issue on that here: https://github.com/home-assistant/core/issues/45746

2 Likes

Nice! Maybe time to go back to home assistant soon!

But isn’t this a still a limitation for getting status from RF lock/unlock? The lock itself doesn’t send a event for this, it can create a circular loop i guess. Openhab polls the device X seconds after lock/unlock to get the status of this action.

Well, it says in the manual it should send a notification at RF Unlock, and I get the event so it works great for me :slight_smile:

Event 1 fired 9:13:
{
    "event_type": "zwave_js_event",
    "data": {
        "type": "notification",
        "domain": "zwave_js",
        "node_id": 60,
        "home_id": 3803889724,
        "device_id": "ef43a40a818f97b547dbfc27e76ae191",
        "label": "RF lock operation",
        "parameters": {
            "type": "Buffer",
            "data": [
                0
            ]
        }
    },
    "origin": "LOCAL",
    "time_fired": "2021-02-17T08:13:55.871861+00:00",
    "context": {
        "id": "d452ef9352b6b6c057be54af725a1a78",
        "parent_id": null,
        "user_id": null
    }
}
Event 0 fired 9:12:
{
    "event_type": "zwave_js_event",
    "data": {
        "type": "notification",
        "domain": "zwave_js",
        "node_id": 60,
        "home_id": 3803889724,
        "device_id": "ef43a40a818f97b547dbfc27e76ae191",
        "label": "RF unlock operation",
        "parameters": {
            "type": "Buffer",
            "data": [
                0
            ]
        }
    },
    "origin": "LOCAL",
    "time_fired": "2021-02-17T08:12:52.424452+00:00",
    "context": {
        "id": "0c32cc257dcee04cd747164f2d69a953",
        "parent_id": null,
        "user_id": null
    }
}

Im new to HA. I got the idLock working fine with zwave JS!

Thanks for the tip by using eventsensor. I got the unlock operation sensor working. But i hva no sucess with the user code sensor. I only get “bad_state.”

Any idea whats wrong with this setup?

Hi,

try like this:

You don’t need the node_id, but you might want to use the optional state mapping, that’s where you translate a code or tag number to a person (or whatever).

1 Like

Works perfectly! Thanks!

Hi

I cannot decide between IDlock 150 or Yale doorman V2N

Can someone please help out and tell me how difficult it is to integrate IDlock into Hass? Is there any ready available integration if so which one ?

If you can live with this:

  1. Administering the lock on the lock, not from HA
  2. Not being able to use the “Away mode” in HA (yet)

…then I’d say ID Lock works really well with HA and Z-wave JS.
Any status changes as well as which code/tag was used works really well. How-to is described in the 2-3 previous posts.

As far as I know, Doorman can’t speak Z-wave, so I guess you’ll need the Yale hub and some integration for that.

What do you mean in point 1 Administering the lock on the lock?

IDlock has both Z-wave and Zigbee modules. If you go with Zigbee is it the same integration/setup procedure as with Z-wave?

You are right about Doorman. It has either Yale hub or Verisure hub and perhaps others in other countries.

From some Z-wave controllers, you can configure the lock’s codes, tags and behavior.
That doesn’t work directly from HA with Z-wave JS (yet). You need to do all configuration on the lock itself.

On the other hand I don’t know if would work with the Zigbee integration either. I doubt it.

Allright! Good to know that to make up my mind :slight_smile:

Hi!
How to make sensor listen for Tag unlocks?

        "label": "RF unlock operation",
        "parameters": {
            "type": "Buffer",
            "data": [
                21
            ]
        }
    },

parameters.data[0] / parameters.data.0
doesnt work for me = Bad_state

And can you please show me the setup for your (sensor.id_lock) sensor? :slight_smile:

Hi!
The lock doesn’t report if a code or tag is used. It reports “Keypad unlock operation” in both cases.

I think everything is described in the example above, but in short: you need two separate EventSensor sensors:

  1. One that listens to the lock/unlock event, sensor.id_lock

  2. One that fetch the data, sensor.id_lock_user in the example above.

It is the second sensor that decodes the tag/code info.
You need to specify every code/tag slot in the “Optional custom state mapping”
“1: My code, 2: Santa’s code, 26: Grandpa’s tag” and so on.
See EventSensor documentation for more specifics.

Then you combine the states in sensor.id_lock_last_action_tmpl.
The result is in my example if the tag stored in the lock’s slot 26 would be
“Upplåst med kod av Grandpa’s tag”, but since you decide the output text in the template sensor, you can adjust it to your needs.

Good luck!

What do you mean with The lock doesn’t report if a code or tag is used?

i get this when i unlock with my tag/rfid chip in code slot number 21:

        "label": "RF unlock operation",
        "parameters": {
            "type": "Buffer",
            "data": [
                21
            ]
        }
    },

parameters.userid = Not working for me with my tags. Only when unlocking with number code

This this my automation atm to see who is unlocking the lock with code or tags:

  - alias: Senaste Upplåsningen
    id: '23799af2-458b-460b-be85-3ad28167f5e3'
    initial_state: on
    trigger:
    - platform: event
      event_type: zwave_js_event
      event_data:
        node_id: 6
        label: 'RF unlock operation'
    - platform: event
      event_type: zwave_js_event
      event_data:
        node_id: 6
        label: 'Keypad unlock operation'
    condition: []
    action:
    - service: input_text.set_value
      data:
        entity_id: input_text.unlocker
        value: >
          {% set unlocker = {
            0:'name1',
            1:'name1',
            2:'name2',
            3:'name3',
            4:'name4',
            5:'name5',
            6:'name6',
            20:'tag1',
            21:'tag2,'}%}
          {% if trigger.event.data.label == 'RF unlock operation' %}
            {% set selection = trigger.event.data.parameters["data"][0] %}
          {% elif trigger.event.data.label == 'Keypad unlock operation' %}
            {% set selection = trigger.event.data.parameters["userId"] %}
          {% endif %}
          {{ unlocker[selection] if selection in unlocker else 'error' }}