Can somebody tell me why this action wont send the actuall number of the luminicity sensor to my phone but instead the word states.sensor.aeotec_zw100_multisensor_6_luminance.state?
When i test it in the developer console i always get the number
id: test_switch
alias: ‘Test switch’
trigger:
platform: state
entity_id: input_boolean.alarm
from: ‘on’
to: ‘off’
action:
service: joaoapps_join.note3_send_tasker
data:
command: "luminance=:= {{ states.sensor.aeotec_zw100_multisensor_6_luminance.state }} "
I just struggled with a similar problem and finally came up with this code. Maybe it will help you?
- alias: Battery Front Door Lock
trigger:
- platform: time
minutes: '/360'
seconds: 00
action:
service: joaoapps_join.phoebe_join_send_tasker
data_template:
command: >
{% set Data = states.sensor.front_door_lock_88_battery.state.split('.')%}
{% set output = 'setvar=:=Batt_front_door_lock=:='+Data[0] %}
{{output}}
1 Like
Thx a million, that did the trick!!!
bachoo786
(Bachoo786)
March 28, 2018, 11:30pm
4
Hi @ciswindell @mefistofelis
Did you have to do anything in tasker to accommodate your automation and receive the luminosity value?
If yes then can you please tell me how you have setup your tasker?
Many thanks.
Here is the script that i use in order to give me the info of the traffic when i open the door to leave home
morning_traffic:
alias: “MORNING TRAFFIC”
sequence:
- service: joaoapps_join.mate10_send_tasker
data_template:
message: >-
command: “notification=:=Home Assistant=:=Time to work {{ states.sensor.to_work.state }} – {{ states.sensor.dark_sky_hourly_summary.state }}=:=Info”
On tasker side i have a profile that gets triggered when %joincomm matches notification.
I have only one profile and then i pass the the other variables as joincomm(1), joincomm(2) etc in the task that generates an autonotification as seen in the picture.
Notice i use the join comm(3) as group command. What this does is that it overwrites previous notification with the same group id in order to avoid multiple notifications
bachoo786
(Bachoo786)
March 31, 2018, 1:40am
6
Hey @mefistofelis Thanks for the reply.
I am already confused with the tasker part as I am completely new.
Is it possible that you could explain the tasker part in steps so that I could set it up please? It seems easy but I cannot get my head around it.
Thanks buddy.
Here is an xml with the profile i use. It listens for the word notification as set in text filter and then passes all the other data after the first =:= as joincomm(1) etc in autontification which presents them nicely
Silent_Notification_From_Ha.prf.xml (23.1 KB)
Edit: Never mind, I finally figured out the templating business
I can’t make the joaoapps_join.send_tasker work when including variables in the command. I’ve tried this:
{
"command": "setvar=:=Occupancy_kitchen=:={{ states.binary_sensor.kitchen_occupancy.state }}"
}
This simply sets the variable Occupancy_kitchen to {{ states.binary_sensor.kitchen_occupancy.state }} instead of on or off
Has the join component changed since you had a working solution? How could I make this work?
gene
May 31, 2019, 4:12pm
9
Also interested in getting this to work… Thanks
osmoen
May 31, 2019, 4:26pm
10
I finally got it working by creating templates in automations.yaml. It can’t be done through the Automation Editor.
Here’s an example of one of my lights:
- id: '1557769459216'
alias: Tasker - Entry
trigger:
entity_id: light.door
platform: state
condition: []
action:
- data_template:
command: >
{% set Data = states.light.door.state %}
{% set output = 'setvar=:=Entry=:='+Data %}
{{output}}
service: joaoapps_join.send_tasker
This sends a command with the variable Entry and its value changes based on the new state.