Hello!
Got PAJ7620 gesture sensor under Tasmota. It sends via MQTT:
MQT: tele/tasmota_XXXXXB/SENSOR = {"Time":"2025-03-25T18:29:05","PAJ7620":{"Up":1}}
MQT: tele/tasmota_XXXXXB/SENSOR = {"Time":"2025-03-25T18:29:08","PAJ7620":{"Down":1}}
MQT: tele/tasmota_XXXXXB/SENSOR = {"Time":"2025-03-25T18:29:12","PAJ7620":{"Up":1}}
MQT: tele/tasmota_XXXXXB/SENSOR = {"Time":"2025-03-25T18:29:15","PAJ7620":{"Up":2}}
MQT: tele/tasmota_XXXXXB/SENSOR = {"Time":"2025-03-25T18:29:18","PAJ7620":{"Up":3}}
MQT: tele/tasmota_XXXXXB/SENSOR = {"Time":"2025-03-25T18:29:35","PAJ7620":{"Right":1}}
MQT: tele/tasmota_XXXXXB/SENSOR = {"Time":"2025-03-25T18:29:41","PAJ7620":{"Up":1}}
MQT: tele/tasmota_XXXXXB/SENSOR = {"Time":"2025-03-25T18:29:42","PAJ7620":{"Up":2}}
MQT: tele/tasmota_XXXXXB/SENSOR = {"Time":"2025-03-25T18:29:43","PAJ7620":{"Up":3}}
MQT: tele/tasmota_XXXXXB/SENSOR = {"Time":"2025-03-25T18:29:44","PAJ7620":{"Up":4}}
MQT: tele/tasmota_XXXXXB/SENSOR = {"Time":"2025-03-25T18:29:45","PAJ7620":{"Up":5}}
MQT: tele/tasmota_XXXXXB/SENSOR = {"Time":"2025-03-25T18:29:50","PAJ7620":{"Down":1}}
MQT: tele/tasmota_XXXXXB/SENSOR = {"Time":"2025-03-25T18:29:54","PAJ7620":{"Near":1}}
MQT: tele/tasmota_XXXXXB/SENSOR = {"Time":"2025-03-25T18:29:57","PAJ7620":{"Far":1}}
MQT: tele/tasmota_XXXXXB/SENSOR = {"Time":"2025-03-25T18:30:00","PAJ7620":{"Far":2}}
MQT: tele/tasmota_XXXXXB/SENSOR = {"Time":"2025-03-25T18:30:03","PAJ7620":{"Near":1}}
MQT: tele/tasmota_XXXXXB/SENSOR = {"Time":"2025-03-25T18:30:06","PAJ7620":{"Far":1}}
so, there is timestamp then sensor data: detected gesture and gesture count.
Created HA sensor template:
mqtt:
sensor:
- name: "MQTT_PAJ7620"
state_topic: "tele/tasmota_XXXXXB/SENSOR"
value_template: "{{ value }}"
which allows me read “{“Time”:“2025-03-25T18:30:06”,“PAJ7620”:{“Far”:1}}” data.
My question is: what sensor template construction should be, which allow to “extract” PAJ7620 raw data - detected gesture and gesture count? My plan is to use gestures in automations.
Regards!