I’m trying to use a 433 remote control but something is wrong. I’ve tried:
- alias: Test kontroll nexa on
initial_state: 'on'
trigger:
platform: event
event_type: pilight_received
event_data:
protocol: arctech_switch
uuid: '0000-b8-27-eb-4395d9'
unit: '11'
state: 'on'
action:
- service: notify.notify
data_template:
message: >
Event data is {{ trigger.event.data.event }}
…but there is no event data is the notifications. Are you supposed to use the values you get from:
sudo pilight-receive -S 127.0.0.1 -P 5000
…directly or do you have to enter them into the pilight config file first. I was under the impression that the entries into the _/etc/pilight/settings.json_was only for the pilight webinterface, which I’m not interested in. But since the yaml above doesn’t work, I’d be happy for some guidance.
With the even_data included I don’t see anything relevant in the log, so I guess my trigger isn’t matching. To me, it looks like it should. Do you see what’s wrong?
Looks to me like your trigger matches the event. Is the event firing or is the event data emtpy? You may just need {{ trigger.event }}. That may push all the info you care about
I’ll try that. I tried using just the protocol in the event_data. Now it’s firing. Still, notify gives me no data so I went to the log. The strange thing is, even though I’ve changed nothing, the log function doesn’t work any more. it just says:
2018-05-11 19:01:27 ERROR (MainThread) [homeassistant.core] Timer got out of sync. Resetting
Well, I don’t think you ahve any event data. Event data is data passed in the data section. Everything your event contains is at the root level. So I would think it would just be {{ trigger.event }} to see everything. {{ trigger.event.state }} to get the state, {{ trigger.event.unit }} to get the unit and so forth.
it works, but the delay needed between two presses is a bit disappointing for my purposes. I think the problem is in the implementation of the HA module. With pilight-receive I see no such restriction. I understand why it’s there – over zealous controllers – but I wish there was a way to choose yourself how restrictive the filtering should be. Maybe @DavidLP could implement such a feature at some point. I think it would be great in the cases where you would want to use a button to increase/decrease a light incrementally with multiple presses or just holding the button. Would that be possible? Or is it already possible, and I’m just too daft to realize it?
I’m not entirely sure how the device itself works because I’ve never used it so I can’t really give input. Typically devices that have double press and hold capabilities report different events. There may be settings in the device it self to expose these events.