diff --git a/automations/01_home_and_lighting.yaml b/automations/01_home_and_lighting.yaml index 4ea94ef..315ed79 100644 --- a/automations/01_home_and_lighting.yaml +++ b/automations/01_home_and_lighting.yaml @@ -1,5 +1,34 @@ # Home and lighting automations. +- id: '1760000000001' + alias: Fireplace mantle outlet schedule + description: Turn the fireplace mantle outlet off overnight. + triggers: + - trigger: time + at: '00:00:00' + id: off + - trigger: time + at: '06:00:00' + id: on + conditions: [] + actions: + - choose: + - conditions: + - condition: trigger + id: off + sequence: + - action: switch.turn_off + target: + entity_id: switch.fireplace + - conditions: + - condition: trigger + id: on + sequence: + - action: switch.turn_on + target: + entity_id: switch.fireplace + mode: single + - id: '1738951431044' alias: Turn off living room lights description: '' diff --git a/automations/print_log_automations/01_prints_charming_print_log.yaml b/automations/print_log_automations/01_prints_charming_print_log.yaml deleted file mode 100644 index b445b88..0000000 --- a/automations/print_log_automations/01_prints_charming_print_log.yaml +++ /dev/null @@ -1,73 +0,0 @@ -# ------------------------------------------------------------ -# BAMBU: PrintsCharming (P1S) -# ------------------------------------------------------------ -- alias: "Print Log - PrintsCharming - Start" - id: print_log_printcharming_start - description: "Creates Notion entry when PrintsCharming begins printing" - mode: single - trigger: - - platform: state - entity_id: sensor.p1s_01p09c470102673_print_status - to: "running" - condition: - - condition: template - value_template: "{{ trigger.from_state.state != 'running' }}" - - condition: template - value_template: "{{ states('input_text.notion_page_id_printcharming') | length < 10 }}" - action: - - delay: "00:00:05" - - action: rest_command.notion_create_print - data: - file_name: "{{ states('sensor.p1s_01p09c470102673_gcode_filename') }}" - printer_name: "PrintsCharming" - filament_type: "{{ state_attr('sensor.p1s_01p09c470102673_active_tray', 'type') | default('Unknown') }}" - filament_color: "{{ state_attr('sensor.p1s_01p09c470102673_active_tray', 'color') | default('Unknown') }}" - started: "{{ now().strftime('%Y-%m-%dT%H:%M:%S') }}" - response_variable: notion_response - - action: input_text.set_value - target: - entity_id: input_text.notion_page_id_printcharming - data: - value: "{{ notion_response.content.id | default('') }}" - -- alias: "Print Log - PrintsCharming - Finish" - id: print_log_printcharming_finish - description: "Updates Notion entry when PrintsCharming finishes, fails, or is cancelled" - mode: single - trigger: - - platform: state - entity_id: sensor.p1s_01p09c470102673_print_status - to: "finish" - id: completed - - platform: state - entity_id: sensor.p1s_01p09c470102673_print_status - to: "failed" - id: failed - - platform: state - entity_id: sensor.p1s_01p09c470102673_print_status - to: "cancelled" - id: cancelled - condition: - - condition: template - value_template: "{{ states('input_text.notion_page_id_printcharming') | length > 10 }}" - action: - - delay: "00:00:05" - - variables: - page_id: "{{ states('input_text.notion_page_id_printcharming') }}" - - condition: template - value_template: "{{ page_id | length > 10 }}" - - action: rest_command.notion_update_print - data: - page_id: "{{ page_id }}" - status: > - {% if trigger.id == 'completed' %}Completed - {% elif trigger.id == 'failed' %}Failed - {% else %}Cancelled{% endif %} - weight: "{{ states('sensor.p1s_01p09c470102673_print_weight') | float(0) }}" - length: "{{ states('sensor.p1s_01p09c470102673_print_length') | float(0) }}" - completed: "{{ now().strftime('%Y-%m-%dT%H:%M:%S') }}" - - action: input_text.set_value - target: - entity_id: input_text.notion_page_id_printcharming - data: - value: "" diff --git a/automations/print_log_automations/02_ds_turd_flinger_print_log.yaml b/automations/print_log_automations/02_ds_turd_flinger_print_log.yaml deleted file mode 100644 index 2a91232..0000000 --- a/automations/print_log_automations/02_ds_turd_flinger_print_log.yaml +++ /dev/null @@ -1,73 +0,0 @@ -# ------------------------------------------------------------ -# BAMBU: Ds-Turd-Flinger (A1) -# ------------------------------------------------------------ -- alias: "Print Log - Ds-Turd-Flinger - Start" - id: print_log_turd_flinger_start - description: "Creates Notion entry when Ds-Turd-Flinger begins printing" - mode: single - trigger: - - platform: state - entity_id: sensor.a1_03919d540806387_print_status - to: "running" - condition: - - condition: template - value_template: "{{ trigger.from_state.state != 'running' }}" - - condition: template - value_template: "{{ states('input_text.notion_page_id_turd_flinger') | length < 10 }}" - action: - - delay: "00:00:05" - - action: rest_command.notion_create_print - data: - file_name: "{{ states('sensor.a1_03919d540806387_gcode_filename') }}" - printer_name: "Ds-Turd-Flinger" - filament_type: "{{ state_attr('sensor.a1_03919d540806387_active_tray', 'type') | default('Unknown') }}" - filament_color: "{{ state_attr('sensor.a1_03919d540806387_active_tray', 'color') | default('Unknown') }}" - started: "{{ now().strftime('%Y-%m-%dT%H:%M:%S') }}" - response_variable: notion_response - - action: input_text.set_value - target: - entity_id: input_text.notion_page_id_turd_flinger - data: - value: "{{ notion_response.content.id | default('') }}" - -- alias: "Print Log - Ds-Turd-Flinger - Finish" - id: print_log_turd_flinger_finish - description: "Updates Notion entry when Ds-Turd-Flinger finishes, fails, or is cancelled" - mode: single - trigger: - - platform: state - entity_id: sensor.a1_03919d540806387_print_status - to: "finish" - id: completed - - platform: state - entity_id: sensor.a1_03919d540806387_print_status - to: "failed" - id: failed - - platform: state - entity_id: sensor.a1_03919d540806387_print_status - to: "cancelled" - id: cancelled - condition: - - condition: template - value_template: "{{ states('input_text.notion_page_id_turd_flinger') | length > 10 }}" - action: - - delay: "00:00:05" - - variables: - page_id: "{{ states('input_text.notion_page_id_turd_flinger') }}" - - condition: template - value_template: "{{ page_id | length > 10 }}" - - action: rest_command.notion_update_print - data: - page_id: "{{ page_id }}" - status: > - {% if trigger.id == 'completed' %}Completed - {% elif trigger.id == 'failed' %}Failed - {% else %}Cancelled{% endif %} - weight: "{{ states('sensor.a1_03919d540806387_print_weight') | float(0) }}" - length: "{{ states('sensor.a1_03919d540806387_print_length') | float(0) }}" - completed: "{{ now().strftime('%Y-%m-%dT%H:%M:%S') }}" - - action: input_text.set_value - target: - entity_id: input_text.notion_page_id_turd_flinger - data: - value: "" diff --git a/automations/print_log_automations/03_polly_pocket_print_log.yaml b/automations/print_log_automations/03_polly_pocket_print_log.yaml deleted file mode 100644 index df0da1c..0000000 --- a/automations/print_log_automations/03_polly_pocket_print_log.yaml +++ /dev/null @@ -1,73 +0,0 @@ -# ------------------------------------------------------------ -# BAMBU: Polly-Pocket (A1 Mini) -# ------------------------------------------------------------ -- alias: "Print Log - Polly-Pocket - Start" - id: print_log_polly_pocket_start - description: "Creates Notion entry when Polly-Pocket begins printing" - mode: single - trigger: - - platform: state - entity_id: sensor.a1mini_0309ca580403653_print_status - to: "running" - condition: - - condition: template - value_template: "{{ trigger.from_state.state != 'running' }}" - - condition: template - value_template: "{{ states('input_text.notion_page_id_polly_pocket') | length < 10 }}" - action: - - delay: "00:00:05" - - action: rest_command.notion_create_print - data: - file_name: "{{ states('sensor.a1mini_0309ca580403653_gcode_filename') }}" - printer_name: "Polly-Pocket" - filament_type: "{{ state_attr('sensor.a1mini_0309ca580403653_active_tray', 'type') | default('Unknown') }}" - filament_color: "{{ state_attr('sensor.a1mini_0309ca580403653_active_tray', 'color') | default('Unknown') }}" - started: "{{ now().strftime('%Y-%m-%dT%H:%M:%S') }}" - response_variable: notion_response - - action: input_text.set_value - target: - entity_id: input_text.notion_page_id_polly_pocket - data: - value: "{{ notion_response.content.id | default('') }}" - -- alias: "Print Log - Polly-Pocket - Finish" - id: print_log_polly_pocket_finish - description: "Updates Notion entry when Polly-Pocket finishes, fails, or is cancelled" - mode: single - trigger: - - platform: state - entity_id: sensor.a1mini_0309ca580403653_print_status - to: "finish" - id: completed - - platform: state - entity_id: sensor.a1mini_0309ca580403653_print_status - to: "failed" - id: failed - - platform: state - entity_id: sensor.a1mini_0309ca580403653_print_status - to: "cancelled" - id: cancelled - condition: - - condition: template - value_template: "{{ states('input_text.notion_page_id_polly_pocket') | length > 10 }}" - action: - - delay: "00:00:05" - - variables: - page_id: "{{ states('input_text.notion_page_id_polly_pocket') }}" - - condition: template - value_template: "{{ page_id | length > 10 }}" - - action: rest_command.notion_update_print - data: - page_id: "{{ page_id }}" - status: > - {% if trigger.id == 'completed' %}Completed - {% elif trigger.id == 'failed' %}Failed - {% else %}Cancelled{% endif %} - weight: "{{ states('sensor.a1mini_0309ca580403653_print_weight') | float(0) }}" - length: "{{ states('sensor.a1mini_0309ca580403653_print_length') | float(0) }}" - completed: "{{ now().strftime('%Y-%m-%dT%H:%M:%S') }}" - - action: input_text.set_value - target: - entity_id: input_text.notion_page_id_polly_pocket - data: - value: "" diff --git a/automations/print_log_automations/04_constipation_orion_print_log.yaml b/automations/print_log_automations/04_constipation_orion_print_log.yaml deleted file mode 100644 index 27038ac..0000000 --- a/automations/print_log_automations/04_constipation_orion_print_log.yaml +++ /dev/null @@ -1,73 +0,0 @@ -# ------------------------------------------------------------ -# BAMBU: Constipation-Orion -# ------------------------------------------------------------ -- alias: "Print Log - Constipation-Orion - Start" - id: print_log_constipation_orion_start - description: "Creates Notion entry when Constipation-Orion begins printing" - mode: single - trigger: - - platform: state - entity_id: sensor.constipation_orion_print_status - to: "running" - condition: - - condition: template - value_template: "{{ trigger.from_state.state != 'running' }}" - - condition: template - value_template: "{{ states('input_text.notion_page_id_constipation_orion') | length < 10 }}" - action: - - delay: "00:00:05" - - action: rest_command.notion_create_print - data: - file_name: "{{ states('sensor.constipation_orion_gcode_filename') }}" - printer_name: "Constipation-Orion" - filament_type: "{{ state_attr('sensor.constipation_orion_active_tray', 'type') | default('Unknown') }}" - filament_color: "{{ state_attr('sensor.constipation_orion_active_tray', 'color') | default('Unknown') }}" - started: "{{ now().strftime('%Y-%m-%dT%H:%M:%S') }}" - response_variable: notion_response - - action: input_text.set_value - target: - entity_id: input_text.notion_page_id_constipation_orion - data: - value: "{{ notion_response.content.id | default('') }}" - -- alias: "Print Log - Constipation-Orion - Finish" - id: print_log_constipation_orion_finish - description: "Updates Notion entry when Constipation-Orion finishes, fails, or is cancelled" - mode: single - trigger: - - platform: state - entity_id: sensor.constipation_orion_print_status - to: "finish" - id: completed - - platform: state - entity_id: sensor.constipation_orion_print_status - to: "failed" - id: failed - - platform: state - entity_id: sensor.constipation_orion_print_status - to: "cancelled" - id: cancelled - condition: - - condition: template - value_template: "{{ states('input_text.notion_page_id_constipation_orion') | length > 10 }}" - action: - - delay: "00:00:05" - - variables: - page_id: "{{ states('input_text.notion_page_id_constipation_orion') }}" - - condition: template - value_template: "{{ page_id | length > 10 }}" - - action: rest_command.notion_update_print - data: - page_id: "{{ page_id }}" - status: > - {% if trigger.id == 'completed' %}Completed - {% elif trigger.id == 'failed' %}Failed - {% else %}Cancelled{% endif %} - weight: "{{ states('sensor.constipation_orion_print_weight') | float(0) }}" - length: "{{ states('sensor.constipation_orion_print_length') | float(0) }}" - completed: "{{ now().strftime('%Y-%m-%dT%H:%M:%S') }}" - - action: input_text.set_value - target: - entity_id: input_text.notion_page_id_constipation_orion - data: - value: "" diff --git a/automations/print_log_automations/05_jordyns_layer_slayer_print_log.yaml b/automations/print_log_automations/05_jordyns_layer_slayer_print_log.yaml deleted file mode 100644 index 093d260..0000000 --- a/automations/print_log_automations/05_jordyns_layer_slayer_print_log.yaml +++ /dev/null @@ -1,73 +0,0 @@ -# ------------------------------------------------------------ -# BAMBU: Jordyns-Layer-Slayer -# ------------------------------------------------------------ -- alias: "Print Log - Jordyns-Layer-Slayer - Start" - id: print_log_jordyns_layer_slayer_start - description: "Creates Notion entry when Jordyns-Layer-Slayer begins printing" - mode: single - trigger: - - platform: state - entity_id: sensor.jordyns_layer_slayer_print_status - to: "running" - condition: - - condition: template - value_template: "{{ trigger.from_state.state != 'running' }}" - - condition: template - value_template: "{{ states('input_text.notion_page_id_jordyns_layer_slayer') | length < 10 }}" - action: - - delay: "00:00:05" - - action: rest_command.notion_create_print - data: - file_name: "{{ states('sensor.jordyns_layer_slayer_gcode_filename') }}" - printer_name: "Jordyns-Layer-Slayer" - filament_type: "{{ state_attr('sensor.jordyns_layer_slayer_active_tray', 'type') | default('Unknown') }}" - filament_color: "{{ state_attr('sensor.jordyns_layer_slayer_active_tray', 'color') | default('Unknown') }}" - started: "{{ now().strftime('%Y-%m-%dT%H:%M:%S') }}" - response_variable: notion_response - - action: input_text.set_value - target: - entity_id: input_text.notion_page_id_jordyns_layer_slayer - data: - value: "{{ notion_response.content.id | default('') }}" - -- alias: "Print Log - Jordyns-Layer-Slayer - Finish" - id: print_log_jordyns_layer_slayer_finish - description: "Updates Notion entry when Jordyns-Layer-Slayer finishes, fails, or is cancelled" - mode: single - trigger: - - platform: state - entity_id: sensor.jordyns_layer_slayer_print_status - to: "finish" - id: completed - - platform: state - entity_id: sensor.jordyns_layer_slayer_print_status - to: "failed" - id: failed - - platform: state - entity_id: sensor.jordyns_layer_slayer_print_status - to: "cancelled" - id: cancelled - condition: - - condition: template - value_template: "{{ states('input_text.notion_page_id_jordyns_layer_slayer') | length > 10 }}" - action: - - delay: "00:00:05" - - variables: - page_id: "{{ states('input_text.notion_page_id_jordyns_layer_slayer') }}" - - condition: template - value_template: "{{ page_id | length > 10 }}" - - action: rest_command.notion_update_print - data: - page_id: "{{ page_id }}" - status: > - {% if trigger.id == 'completed' %}Completed - {% elif trigger.id == 'failed' %}Failed - {% else %}Cancelled{% endif %} - weight: "{{ states('sensor.jordyns_layer_slayer_print_weight') | float(0) }}" - length: "{{ states('sensor.jordyns_layer_slayer_print_length') | float(0) }}" - completed: "{{ now().strftime('%Y-%m-%dT%H:%M:%S') }}" - - action: input_text.set_value - target: - entity_id: input_text.notion_page_id_jordyns_layer_slayer - data: - value: "" diff --git a/automations/print_log_automations/06_printney_spears_print_log.yaml b/automations/print_log_automations/06_printney_spears_print_log.yaml deleted file mode 100644 index 2c6f591..0000000 --- a/automations/print_log_automations/06_printney_spears_print_log.yaml +++ /dev/null @@ -1,75 +0,0 @@ -# ------------------------------------------------------------ -# ELEGOO: Printney Spears (Centauri Carbon) -# Note: Uses current_status + file_name sensors (Elegoo integration) -# No weight, length, or filament data available -# Status values: "printing" / "complete" / "failed" — verify in Dev Tools -# ------------------------------------------------------------ -- alias: "Print Log - Printney Spears - Start" - id: print_log_printney_spears_start - description: "Creates Notion entry when Printney Spears begins printing" - initial_state: false - mode: single - trigger: - - platform: state - entity_id: sensor.saturn_iv_print_status - from: - - "idle" - - "stopped" - - "complete" - to: "printing" - condition: - - condition: template - value_template: "{{ states('input_text.notion_page_id_centauri_carbon') | length < 10 }}" - action: - - delay: "00:00:05" - - action: rest_command.notion_create_print - data: - file_name: "{{ states('sensor.centauri_carbon_file_name') }}" - printer_name: "Printney Spears" - filament_type: "Unknown" - filament_color: "Unknown" - started: "{{ now().strftime('%Y-%m-%dT%H:%M:%S') }}" - response_variable: notion_response - - action: input_text.set_value - target: - entity_id: input_text.notion_page_id_centauri_carbon - data: - value: "{{ notion_response.content.id | default('') }}" - -- alias: "Print Log - Printney Spears - Finish" - id: print_log_printney_spears_finish - description: "Updates Notion entry when Printney Spears finishes or fails" - initial_state: false - mode: single - trigger: - - platform: state - entity_id: sensor.saturn_iv_print_status - to: "complete" - id: completed - - platform: state - entity_id: sensor.saturn_iv_print_status - to: "failed" - id: failed - condition: - - condition: template - value_template: "{{ states('input_text.notion_page_id_centauri_carbon') | length > 10 }}" - action: - - delay: "00:00:05" - - variables: - page_id: "{{ states('input_text.notion_page_id_centauri_carbon') }}" - - condition: template - value_template: "{{ page_id | length > 10 }}" - - action: rest_command.notion_update_print - data: - page_id: "{{ page_id }}" - status: > - {% if trigger.id == 'completed' %}Completed - {% else %}Failed{% endif %} - weight: 0 - length: 0 - completed: "{{ now().strftime('%Y-%m-%dT%H:%M:%S') }}" - - action: input_text.set_value - target: - entity_id: input_text.notion_page_id_centauri_carbon - data: - value: "" diff --git a/automations/print_log_automations/07_saturn_iv_print_log.yaml b/automations/print_log_automations/07_saturn_iv_print_log.yaml deleted file mode 100644 index 1a8742a..0000000 --- a/automations/print_log_automations/07_saturn_iv_print_log.yaml +++ /dev/null @@ -1,73 +0,0 @@ -# ------------------------------------------------------------ -# ELEGOO: Saturn (resin printer) -# Note: Uses current_status + file_name sensors (Elegoo integration) -# No weight, length, or filament data available -# Status values: "printing" / "complete" / "failed" — verify in Dev Tools -# ------------------------------------------------------------ -- alias: "Print Log - Saturn - Start" - id: print_log_saturn_start - description: "Creates Notion entry when Saturn begins printing" - mode: single - trigger: - - platform: state - entity_id: sensor.saturn_iv_print_status - from: - - "idle" - - "stopped" - - "complete" - to: "printing" - condition: - - condition: template - value_template: "{{ states('input_text.notion_page_id_saturn') | length < 10 }}" - action: - - delay: "00:00:05" - - action: rest_command.notion_create_print - data: - file_name: "{{ states('sensor.saturn_file_name') }}" - printer_name: "Saturn" - filament_type: "Unknown" - filament_color: "Unknown" - started: "{{ now().strftime('%Y-%m-%dT%H:%M:%S') }}" - response_variable: notion_response - - action: input_text.set_value - target: - entity_id: input_text.notion_page_id_saturn - data: - value: "{{ notion_response.content.id | default('') }}" - -- alias: "Print Log - Saturn - Finish" - id: print_log_saturn_finish - description: "Updates Notion entry when Saturn finishes or fails" - mode: single - trigger: - - platform: state - entity_id: sensor.saturn_iv_print_status - to: "complete" - id: completed - - platform: state - entity_id: sensor.saturn_iv_print_status - to: "failed" - id: failed - condition: - - condition: template - value_template: "{{ states('input_text.notion_page_id_saturn') | length > 10 }}" - action: - - delay: "00:00:05" - - variables: - page_id: "{{ states('input_text.notion_page_id_saturn') }}" - - condition: template - value_template: "{{ page_id | length > 10 }}" - - action: rest_command.notion_update_print - data: - page_id: "{{ page_id }}" - status: > - {% if trigger.id == 'completed' %}Completed - {% else %}Failed{% endif %} - weight: 0 - length: 0 - completed: "{{ now().strftime('%Y-%m-%dT%H:%M:%S') }}" - - action: input_text.set_value - target: - entity_id: input_text.notion_page_id_saturn - data: - value: ""