How to integrate TMD switch

A newbie problem: I find it hard to capture the events from the KNX bus, and use them in my HA.

So, I was able to define my motion sensors and light in my yaml files.
Capturing a motion event triggers automation scripts and turns on some lights. So far so good.

My problem - and ignorance - starts when I want to capture events happening on my switches.

What I want to do is, just to get started, log a message whenever I push a particular button.
In the KNX group monitor I see the correct message appearing:

Incoming message → destination 0/3/57 → value0x34
which translated in my BOS config to the correct switch, correct button

Now, I tried to capture this via the following automate script:

alias: LivingRoomSwitch
description: ""
trigger:
  - platform: event
    event_type: knx_event
    event_data:
      address: 0/3/57
condition: []
action:
  - service: logbook.log
    data:
      name: Test !!!
      message: Yiehaa!!!
mode: single

It doesn’t fire.

I’m obviously missing something, any hints - to solve this, or to point my to
some really newbie documentation, would be appreciated.

Did you add the event GA to your

knx:
  event:
    - ...

like stated in the documentation?

Better yet, use Knx Interface Telegram device trigger. See

Thank you for your response.

  1. I did not add it as an event. By looking more closely in the documentation,
    It did find it.
  2. The event trigger: both for my first solutions, as for the Knx Interface Telegram device trigger.

next problem, I do not succeed in evaluating the data.
Altough I see (and log ) the payload value I expect, it does not pass my condition.

The reason could be in the following, the payload is send as :

payload:
      - 52

instead of:

payload: 52

It does not pass my condition

if:
  - condition: template
    value_template: '{{ trigger.payload == 52 }}'

It’s a list of integers (an item for every byte - 0…255). Try
'{{ trigger.payload == [52] }}'

Or upload your knxproj file and use value.

Thanks for getting me on the right track!

The following solved it :

{{trigger.payload == (52,) }}