572 lines
26 KiB
JSON
572 lines
26 KiB
JSON
[
|
|
{
|
|
"id": "Gbox420 Hempy Bucket State Notification",
|
|
"automation": "- alias: Gbox420 Hempy Bucket State Notification\n description: Notify and manage persistent notification for Hempy bucket state changes.\n IMPORTANT Update mobile_app_bits20 to mobile_app_<your_mobile_name> using lowercase\n letters, as listed in Home Assistant under Settings > Devices & Services > Devices\n triggers:\n - entity_id:\n - sensor.hempy_bucket1_state\n - sensor.hempy_bucket2_state\n trigger: state\n - event_type: mobile_app_notification_action\n event_data:\n action: START_WATERING\n trigger: event\n - event_type: mobile_app_notification_action\n event_data:\n action: STOP_WATERING\n trigger: event\n conditions: []\n actions:\n - variables:\n bucket_number: '{{ trigger.entity_id.split(''_'')[-2][-1] if ''entity_id'' in\n trigger else ''-1'' }}'\n new_state: '{{ (trigger.to_state.state if trigger.to_state is defined else ''UNKNOWN'').strip()\n }}'\n - choose:\n - conditions:\n - condition: template\n value_template: '{{ new_state == ''DISABLED'' }}'\n sequence:\n - data:\n notification_id: hempy_bucket{{ bucket_number }}_disabled\n title: Gbox420\n message: \"Hempy bucket {{ bucket_number }} is {{ new_state }} \\\n \\ \\n\"\n action: persistent_notification.create\n - data:\n title: Gbox420\n message: 'Hempy bucket {{ bucket_number }} is {{ new_state }}\n\n '\n data:\n actions:\n - action: START_WATERING\n title: Start Watering\n - action: STOP_WATERING\n title: Stop watering\n - action: DISMISS_NOTIFICATION\n title: Dismiss\n action: notify.mobile_app_bits20\n - conditions:\n - condition: template\n value_template: '{{ new_state != ''DISABLED'' }}'\n sequence:\n - data:\n notification_id: hempy_bucket{{ bucket_number }}_disabled\n action: persistent_notification.dismiss\n - choose:\n - conditions:\n - condition: template\n value_template: '{{ trigger.platform == ''event'' and trigger.event.event_type\n == ''mobile_app_notification_action'' }}'\n sequence:\n - choose:\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.action == ''START_WATERING'' }}'\n sequence:\n - action: esphome.hempy_bucket1_start_watering\n data: {}\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.action == ''STOP_WATERING'' }}'\n sequence:\n - action: esphome.hempy_bucket1_stop_watering\n data: {}\n mode: parallel",
|
|
"config": [
|
|
{
|
|
"name": "hempy bucket1 state",
|
|
"room": "gbox420",
|
|
"type": "sensor",
|
|
"id": {
|
|
"entity_id": "sensor.hempy_bucket1_state",
|
|
"device_id": null
|
|
}
|
|
},
|
|
{
|
|
"name": "hempy bucket2 state",
|
|
"room": "gbox420",
|
|
"type": "sensor",
|
|
"id": {
|
|
"entity_id": "sensor.hempy_bucket2_state",
|
|
"device_id": null
|
|
}
|
|
},
|
|
{
|
|
"name": "mobile app bits20",
|
|
"room": null,
|
|
"type": "notify",
|
|
"id": {
|
|
"entity_id": "notify.mobile_app_bits20",
|
|
"device_id": null
|
|
}
|
|
},
|
|
{
|
|
"name": "hempy bucket1 start watering",
|
|
"room": "gbox420",
|
|
"type": "esphome",
|
|
"id": {
|
|
"entity_id": "esphome.hempy_bucket1_start_watering",
|
|
"device_id": null
|
|
}
|
|
},
|
|
{
|
|
"name": "hempy bucket1 stop watering",
|
|
"room": "gbox420",
|
|
"type": "esphome",
|
|
"id": {
|
|
"entity_id": "esphome.hempy_bucket1_stop_watering",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Light1 Brightness via MQTT",
|
|
"automation": "- alias: Send Light1 Brightness via MQTT\n trigger:\n - platform: state\n entity_id: number.gbox420_light1_brightness\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Lt1_B\n payload: '{{ trigger.to_state.state | int }}'",
|
|
"config": [
|
|
{
|
|
"name": "light1 brightness",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_light1_brightness",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Light1 OnTime via MQTT",
|
|
"automation": "- alias: Send Light1 OnTime via MQTT\n mode: single\n trigger:\n - platform: state\n entity_id:\n - number.gbox420_light1_ontimehour\n - number.gbox420_light1_ontimeminute\n action:\n - delay: 00:00:03\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Lt1_OnT\n payload: '{% set hour = states(''number.gbox420_light1_ontimehour'') | int %}\n {% set minute = states(''number.gbox420_light1_ontimeminute'') | int %} {{\n \"%02d%02d\" | format(hour, minute) }}\n\n '",
|
|
"config": [
|
|
{
|
|
"name": "light1 on time hour",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_light1_ontimehour",
|
|
"device_id": null
|
|
}
|
|
},
|
|
{
|
|
"name": "light1 on time minute",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_light1_ontimeminute",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Light1 OffTime via MQTT",
|
|
"automation": "- alias: Send Light1 OffTime via MQTT\n mode: single\n trigger:\n - platform: state\n entity_id:\n - number.gbox420_light1_offtimehour\n - number.gbox420_light1_offtimeminute\n action:\n - delay: 00:00:03\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Lt1_OfT\n payload: '{% set hour = states(''number.gbox420_light1_offtimehour'') | int\n %} {% set minute = states(''number.gbox420_light1_offtimeminute'') | int %}\n {{ \"%02d%02d\" | format(hour, minute) }}\n\n '",
|
|
"config": [
|
|
{
|
|
"name": "light1 off time hour",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_light1_offtimehour",
|
|
"device_id": null
|
|
}
|
|
},
|
|
{
|
|
"name": "light1 off time minute",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_light1_offtimeminute",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Light2 OnTime via MQTT",
|
|
"automation": "- alias: Send Light2 OnTime via MQTT\n trigger:\n - platform: state\n entity_id: number.gbox420_light2_brightness\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Lt2_B\n payload: '{{ trigger.to_state.state | int }}'",
|
|
"config": [
|
|
{
|
|
"name": "light2 brightness",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_light2_brightness",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send MQTT when Light2 OnTime Changes",
|
|
"automation": "- alias: Send MQTT when Light2 OnTime Changes\n mode: single\n trigger:\n - platform: state\n entity_id:\n - number.gbox420_light2_ontimehour\n - number.gbox420_light2_ontimeminute\n action:\n - delay: 00:00:03\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Lt2_OnT\n payload: '{% set hour = states(''number.gbox420_light2_ontimehour'') | int %}\n {% set minute = states(''number.gbox420_light2_ontimeminute'') | int %} {{\n \"%02d%02d\" | format(hour, minute) }}\n\n '",
|
|
"config": [
|
|
{
|
|
"name": "light2 on time hour",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_light2_ontimehour",
|
|
"device_id": null
|
|
}
|
|
},
|
|
{
|
|
"name": "light2 on time minute",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_light2_ontimeminute",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Light2 OffTime via MQTT",
|
|
"automation": "- alias: Send Light2 OffTime via MQTT\n mode: single\n trigger:\n - platform: state\n entity_id:\n - number.gbox420_light2_offtimehour\n - number.gbox420_light2_offtimeminute\n action:\n - delay: 00:00:03\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Lt2_OfT\n payload: '{% set hour = states(''number.gbox420_light2_offtimehour'') | int\n %} {% set minute = states(''number.gbox420_light2_offtimeminute'') | int %}\n {{ \"%02d%02d\" | format(hour, minute) }}\n\n '",
|
|
"config": [
|
|
{
|
|
"name": "light2 off time hour",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_light2_offtimehour",
|
|
"device_id": null
|
|
}
|
|
},
|
|
{
|
|
"name": "light2 off time minute",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_light2_offtimeminute",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Hempy bucket1 StartWeight",
|
|
"automation": "- alias: Send Hempy bucket1 StartWeight\n trigger:\n - platform: state\n entity_id: number.gbox420_bucket1_startweight\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Hemp1_B1SW\n payload: '{{ trigger.to_state.state | float }}'",
|
|
"config": [
|
|
{
|
|
"name": "bucket1 start weight",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_bucket1_startweight",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Hempy bucket1 WateringIncrement",
|
|
"automation": "- alias: Send Hempy bucket1 WateringIncrement\n trigger:\n - platform: state\n entity_id: number.gbox420_bucket1_wateringincrement\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Hemp1_B1WI\n payload: '{{ trigger.to_state.state | float }}'",
|
|
"config": [
|
|
{
|
|
"name": "bucket1 watering increment",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_bucket1_wateringincrement",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Hempy bucket1 MaxWeight",
|
|
"automation": "- alias: Send Hempy bucket1 MaxWeight\n trigger:\n - platform: state\n entity_id: number.gbox420_bucket1_maxweight\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Hemp1_B1MW\n payload: '{{ trigger.to_state.state | float }}'",
|
|
"config": [
|
|
{
|
|
"name": "bucket1 max weight",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_bucket1_maxweight",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Hempy bucket1 EvaporationTarget",
|
|
"automation": "- alias: Send Hempy bucket1 EvaporationTarget\n trigger:\n - platform: state\n entity_id: number.gbox420_bucket1_evaporationtarget\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Hemp1_B1ET\n payload: '{{ trigger.to_state.state | float }}'",
|
|
"config": [
|
|
{
|
|
"name": "bucket1 evaporation target",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_bucket1_evaporationtarget",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Hempy bucket1 DrainTarget",
|
|
"automation": "- alias: Send Hempy bucket1 DrainTarget\n trigger:\n - platform: state\n entity_id: number.gbox420_bucket1_draintarget\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Hemp1_B1DT\n payload: '{{ trigger.to_state.state | float }}'",
|
|
"config": [
|
|
{
|
|
"name": "bucket1 drain target",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_bucket1_draintarget",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Hempy bucket1 DrainTime",
|
|
"automation": "- alias: Send Hempy bucket1 DrainTime\n trigger:\n - platform: state\n entity_id: number.gbox420_bucket1_draintime\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Hemp1_B1D\n payload: '{{ trigger.to_state.state | int }}'",
|
|
"config": [
|
|
{
|
|
"name": "bucket1 drain time",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_bucket1_draintime",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Hempy bucket1 PumpSpeed",
|
|
"automation": "- alias: Send Hempy bucket1 PumpSpeed\n trigger:\n - platform: state\n entity_id: number.gbox420_bucket1_pumpspeed\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Hemp1_B1PS\n payload: '{{ trigger.to_state.state | int }}'",
|
|
"config": [
|
|
{
|
|
"name": "bucket1 pump speed",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_bucket1_pumpspeed",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Hempy bucket1 PumpTimeout",
|
|
"automation": "- alias: Send Hempy bucket1 PumpTimeout\n trigger:\n - platform: state\n entity_id: number.gbox420_bucket1_pumptimeout\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Hemp1_B1T\n payload: '{{ trigger.to_state.state | int }}'",
|
|
"config": [
|
|
{
|
|
"name": "bucket1 pump timeout",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_bucket1_pumptimeout",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Hempy bucket2 StartWeight",
|
|
"automation": "- alias: Send Hempy bucket2 StartWeight\n trigger:\n - platform: state\n entity_id: number.gbox420_bucket2_startweight\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Hemp1_B2SW\n payload: '{{ trigger.to_state.state | float }}'",
|
|
"config": [
|
|
{
|
|
"name": "bucket2 start weight",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_bucket2_startweight",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Hempy bucket2 WateringIncrement",
|
|
"automation": "- alias: Send Hempy bucket2 WateringIncrement\n trigger:\n - platform: state\n entity_id: number.gbox420_bucket2_wateringincrement\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Hemp1_B2WI\n payload: '{{ trigger.to_state.state | float }}'",
|
|
"config": [
|
|
{
|
|
"name": "bucket2 watering increment",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_bucket2_wateringincrement",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Hempy bucket2 MaxWeight",
|
|
"automation": "- alias: Send Hempy bucket2 MaxWeight\n trigger:\n - platform: state\n entity_id: number.gbox420_bucket2_maxweight\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Hemp1_B2MW\n payload: '{{ trigger.to_state.state | float }}'",
|
|
"config": [
|
|
{
|
|
"name": "bucket2 max weight",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_bucket2_maxweight",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Hempy bucket2 EvaporationTarget",
|
|
"automation": "- alias: Send Hempy bucket2 EvaporationTarget\n trigger:\n - platform: state\n entity_id: number.gbox420_bucket2_evaporationtarget\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Hemp1_B2ET\n payload: '{{ trigger.to_state.state | float }}'",
|
|
"config": [
|
|
{
|
|
"name": "bucket2 evaporation target",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_bucket2_evaporationtarget",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Hempy bucket2 DrainTarget",
|
|
"automation": "- alias: Send Hempy bucket2 DrainTarget\n trigger:\n - platform: state\n entity_id: number.gbox420_bucket2_draintarget\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Hemp1_B2DT\n payload: '{{ trigger.to_state.state | float }}'",
|
|
"config": [
|
|
{
|
|
"name": "bucket2 drain target",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_bucket2_draintarget",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Hempy bucket2 DrainTime",
|
|
"automation": "- alias: Send Hempy bucket2 DrainTime\n trigger:\n - platform: state\n entity_id: number.gbox420_bucket2_draintime\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Hemp1_B2D\n payload: '{{ trigger.to_state.state | int }}'",
|
|
"config": [
|
|
{
|
|
"name": "bucket2 drain time",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_bucket2_draintime",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Hempy bucket2 PumpSpeed",
|
|
"automation": "- alias: Send Hempy bucket2 PumpSpeed\n trigger:\n - platform: state\n entity_id: number.gbox420_bucket2_pumpspeed\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Hemp1_B2PS\n payload: '{{ trigger.to_state.state | int }}'",
|
|
"config": [
|
|
{
|
|
"name": "bucket2 pump speed",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_bucket2_pumpspeed",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Hempy bucket2 PumpTimeout",
|
|
"automation": "- alias: Send Hempy bucket2 PumpTimeout\n trigger:\n - platform: state\n entity_id: number.gbox420_bucket2_pumptimeout\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Hemp1_B2T\n payload: '{{ trigger.to_state.state | int }}'",
|
|
"config": [
|
|
{
|
|
"name": "bucket2 pump timeout",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_bucket2_pumptimeout",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Aeroponics MinPressure",
|
|
"automation": "- alias: Send Aeroponics MinPressure\n trigger:\n - platform: state\n entity_id: number.gbox420_aero1_minpressure\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Aero1_PMn\n payload: '{{ trigger.to_state.state | float }}'",
|
|
"config": [
|
|
{
|
|
"name": "aero1 min pressure",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_aero1_minpressure",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Aeroponics MaxPressure",
|
|
"automation": "- alias: Send Aeroponics MaxPressure\n trigger:\n - platform: state\n entity_id: number.gbox420_aero1_maxpressure\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Aero1_PMx\n payload: '{{ trigger.to_state.state | float }}'",
|
|
"config": [
|
|
{
|
|
"name": "aero1 max pressure",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_aero1_maxpressure",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Aeroponics DayInterval",
|
|
"automation": "- alias: Send Aeroponics DayInterval\n trigger:\n - platform: state\n entity_id: number.gbox420_aero1_dayinterval\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Aero1_DInt\n payload: '{{ trigger.to_state.state | int }}'",
|
|
"config": [
|
|
{
|
|
"name": "aero1 day interval",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_aero1_dayinterval",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Aeroponics NightInterval",
|
|
"automation": "- alias: Send Aeroponics NightInterval\n trigger:\n - platform: state\n entity_id: number.gbox420_aero1_nightinterval\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Aero1_NInt\n payload: '{{ trigger.to_state.state | int }}'",
|
|
"config": [
|
|
{
|
|
"name": "aero1 night interval",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_aero1_nightinterval",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Aeroponics SprayDuration",
|
|
"automation": "- alias: Send Aeroponics SprayDuration\n trigger:\n - platform: state\n entity_id: number.gbox420_aero1_sprayduration\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Aero1_Dur\n payload: '{{ trigger.to_state.state | float }}'",
|
|
"config": [
|
|
{
|
|
"name": "aero1 spray duration",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_aero1_sprayduration",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Aeroponics PumpSpeed",
|
|
"automation": "- alias: Send Aeroponics PumpSpeed\n trigger:\n - platform: state\n entity_id: number.gbox420_aero1_pumpspeed\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Aero1_PS\n payload: '{{ trigger.to_state.state | int }}'",
|
|
"config": [
|
|
{
|
|
"name": "aero1 pump speed",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_aero1_pumpspeed",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Aeroponics PumpPrimingTime",
|
|
"automation": "- alias: Send Aeroponics PumpPrimingTime\n trigger:\n - platform: state\n entity_id: number.gbox420_aero1_pumpprimingtime\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Aero1_PPT\n payload: '{{ trigger.to_state.state | int }}'",
|
|
"config": [
|
|
{
|
|
"name": "aero1 pump priming time",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_aero1_pumpprimingtime",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Send Aeroponics PumpTimeout",
|
|
"automation": "- alias: Send Aeroponics PumpTimeout\n trigger:\n - platform: state\n entity_id: number.gbox420_aero1_pumptimeout\n action:\n - service: mqtt.publish\n data:\n topic: Gbox420CMD/Aero1_PT\n payload: '{{ trigger.to_state.state | int }}'",
|
|
"config": [
|
|
{
|
|
"name": "aero1 pump timeout",
|
|
"room": "gbox420",
|
|
"type": "number",
|
|
"id": {
|
|
"entity_id": "number.gbox420_aero1_pumptimeout",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "Gbox420 Hempy Bucket State Notification",
|
|
"automation": "- alias: Gbox420 Hempy Bucket State Notification\n description: 'Notify and manage persistent notification for Hempy bucket state changes.\n IMPORTANT: Update mobile_app_bits20 to mobile_app_<your_mobile_name> using lowercase\n letters, as listed in Home Assistant under Settings > Devices & Services > Devices'\n triggers:\n - entity_id:\n - sensor.hempy_bucket1_state\n - sensor.hempy_bucket2_state\n trigger: state\n - event_type: mobile_app_notification_action\n event_data:\n action: START_WATERING\n trigger: event\n - event_type: mobile_app_notification_action\n event_data:\n action: STOP_WATERING\n trigger: event\n conditions: []\n actions:\n - variables:\n bucket_number: \"{% if trigger.entity_id == 'sensor.hempy_bucket1_state' %}\\n\\\n \\ 1\\n{% elif trigger.entity_id == 'sensor.hempy_bucket2_state' %}\\n 2\\n\\\n {% else %}\\n {{ trigger.event.data.message[13] if trigger.event.data.message|length\\\n \\ > 13 else '-1' }}\\n{% endif %}\"\n new_state: '{{ (trigger.to_state.state if trigger.to_state is defined else ''UNKNOWN'').strip()\n }}'\n - if:\n - condition: template\n value_template: '{{ new_state == ''DISABLED'' or new_state == ''DRY'' }}'\n then:\n - data:\n notification_id: hempy_bucket{{ bucket_number }}_alert\n title: Gbox420\n message: 'Hempy bucket {{ bucket_number }} is {{ new_state }}\n\n '\n action: persistent_notification.create\n - data:\n title: Gbox420\n message: 'Hempy bucket {{ bucket_number }} is {{ new_state }}\n\n '\n data:\n actions:\n - action: START_WATERING\n title: Start watering\n data:\n bucket_number: '{{ bucket_number }}'\n - action: STOP_WATERING\n title: Stop watering\n data:\n bucket_number: '{{ bucket_number }}'\n - action: DISMISS_NOTIFICATION\n title: Dismiss\n action: notify.mobile_app_bits20\n - if:\n - condition: template\n value_template: '{{ new_state != ''DISABLED'' and new_state != ''DRY''}}'\n then:\n - data:\n notification_id: hempy_bucket{{ bucket_number }}_alert\n action: persistent_notification.dismiss\n - if:\n - condition: template\n value_template: '{{ trigger.event.data.action in [''START_WATERING'', ''STOP_WATERING'']\n }}'\n then:\n - action: \"{% if trigger.event.data.action == 'START_WATERING' %}\\n esphome.hempy_bucket{{\\\n \\ bucket_number }}_start_watering\\n{% else %}\\n esphome.hempy_bucket{{ bucket_number\\\n \\ }}_stop_watering\\n{% endif %}\"\n mode: parallel",
|
|
"config": [
|
|
{
|
|
"name": "hempy bucket1 state",
|
|
"room": "gbox420",
|
|
"type": "sensor",
|
|
"id": {
|
|
"entity_id": "sensor.hempy_bucket1_state",
|
|
"device_id": null
|
|
}
|
|
},
|
|
{
|
|
"name": "hempy bucket2 state",
|
|
"room": "gbox420",
|
|
"type": "sensor",
|
|
"id": {
|
|
"entity_id": "sensor.hempy_bucket2_state",
|
|
"device_id": null
|
|
}
|
|
},
|
|
{
|
|
"name": "mobile app bits20",
|
|
"room": null,
|
|
"type": "notify",
|
|
"id": {
|
|
"entity_id": "notify.mobile_app_bits20",
|
|
"device_id": null
|
|
}
|
|
}
|
|
]
|
|
}
|
|
] |