Moonraker in Home Assistant

By zw_038_olle Nov 27, 2023 #3d printing

https://github.com/marcolivierarsenault/moonraker-home-assistant

cards:
      - type: custom:mushroom-title-card
        title: MainSail – {{ states('sensor.mainsail_current_display_message') }}
        subtitle: '''{{ states("sensor.mainsail_filename") }}'
        alignment: center
        title_tap_action:
          action: url
          url_path: http://mainsail.local/
        subtitle_tap_action:
          action: none
      - square: false
        type: grid
        cards:
          - type: tile
            entity: sensor.mainsail_current_print_state
            name: Status
            show_entity_picture: false
            vertical: false
            color: primary
          - type: tile
            entity: sensor.mainsail_print_duration
            name: Elapsed
            color: accent
          - type: tile
            entity: sensor.mainsail_print_eta
            name: Completion
            color: green
            show_entity_picture: false
            vertical: false
            columns: 3
      - type: custom:bar-card
        name: Print Progress...
        icon: mdi:clock-end
        color: green
        positions:
          indicator: inside
          name: inside
        entities:
          - entity: sensor.mainsail_progress
      - square: false
        type: grid
        columns: 4
        cards:
          - type: custom:button-card
            entity: button.mainsail_pause_print
            color_type: icon
            tap_action:
              action: toggle
            name: Pause
          - type: custom:button-card
            entity: button.mainsail_resume_print
            color_type: icon
            tap_action:
              action: toggle
            name: Resume
          - type: custom:button-card
            entity: button.mainsail_cancel_print
            color_type: icon
            tap_action:
              action: toggle
            name: Cancel
            lock:
              enabled: false
            confirmation:
              text: Dit zal het printen stoppen, weet je het zeker?
          - type: custom:button-card
            entity: button.mainsail_emergency_stop
            color_type: icon
            color: red
            tap_action:
              action: toggle
            name: Emergency
            lock:
              enabled: false
            confirmation:
              text: Dit zal je printer herstarten, weet je het zeker?
      - type: conditional
        conditions:
          - entity: sensor.mainsail_current_print_state
            state_not: unavailable
        card:
          type: picture-entity
          entity: camera.mainsail_cam_1
          camera_view: live
          show_name: false
          show_state: false
          aspect_ratio: 4x3
      - type: custom:apexcharts-card
        graph_span: 1h
        header:
          show: true
          title: Fan Speeds
          show_states: true
          colorize_states: true
        apex_config:
          chart:
            height: 200px
          legend:
            show: false
          grid:
            xaxis:
              lines:
                show: true
            borderColor: '#555'
        yaxis:
          - opposite: true
            decimals: 0
            apex_config:
              tickAmount: 2
        all_series_config:
          stroke_width: 2
          show:
            name_in_header: true
        series:
          - entity: sensor.mainsail_fan_speed
            name: Parts
      - type: grid
        square: false
        columns: 1
        cards:
          - type: entities
            entities:
              - entity: sensor.mainsail_bed_power
                name: Bed Power
              - entity: sensor.mainsail_bed_target
                name: Bed Target
              - entity: sensor.mainsail_bed_temperature
                name: Bed Temperature
              - entity: sensor.mainsail_current_display_message
                name: Current Display Message
              - entity: sensor.mainsail_current_layer
                name: Current Layer
              - entity: sensor.mainsail_current_print_message
                name: Current Print Message
              - entity: sensor.mainsail_current_print_state
                name: Current Print State
              - entity: sensor.mainsail_extruder_power
                name: Extruder Power
              - entity: sensor.mainsail_extruder_target
                name: Extruder Target
              - entity: sensor.mainsail_extruder_temperature
                name: Extruder Temperature
              - entity: sensor.mainsail_fan_speed
                name: Fan speed
              - entity: sensor.mainsail_filament_used
                name: Filament Used
              - entity: sensor.mainsail_filename
                name: Filename
              - entity: sensor.mainsail_longest_print
                name: Longest Print
              - entity: sensor.mainsail_print_duration
                name: Print Duration
              - entity: sensor.mainsail_print_eta
                name: Print ETA
              - entity: sensor.mainsail_print_projected_total_duration
                name: Print Projected Total Duration
              - entity: sensor.mainsail_print_time_left
                name: Print Time Left
              - entity: sensor.mainsail_printer_message
                name: Printer Message
              - entity: sensor.mainsail_printer_state
                name: Printer State
              - entity: sensor.mainsail_progress
                name: Progress
              - entity: sensor.mainsail_slicer_print_duration_estimate
                name: Slicer Print Duration Estimate
              - entity: sensor.mainsail_slicer_print_time_left_estimate
                name: Slicer Print Time Left Estimate
              - entity: sensor.mainsail_toolhead_position_x
                name: Toolhead position X
              - entity: sensor.mainsail_toolhead_position_y
                name: Toolhead position Y
              - entity: sensor.mainsail_toolhead_position_z
                name: Toolhead position Z
              - entity: sensor.mainsail_total_layer
                name: Total Layer
              - entity: sensor.mainsail_totals_filament_used
                name: Totals Filament Used
              - entity: sensor.mainsail_totals_jobs
                name: Totals jobs
              - entity: sensor.mainsail_totals_print_time
                name: Totals Print Time
            title: mainsail
      - type: entities
        entities:
          - entity: button.mainsail_cancel_print
            name: Cancel Print
          - entity: button.mainsail_emergency_stop
            name: Emergency Stop
          - entity: button.mainsail_firmware_restart
            name: Firmware Restart
          - entity: button.mainsail_host_restart
            name: Host Restart
          - entity: button.mainsail_host_shutdown
            name: Host Shutdown
          - entity: button.mainsail_macro_end_print
            name: Macro End Print
          - entity: button.mainsail_macro_start_print
            name: Macro Start Print
          - entity: button.mainsail_pause_print
            name: Pause Print
          - entity: button.mainsail_resume_print
            name: Resume Print
          - entity: button.mainsail_server_restart
            name: Server Restart
        title: mainsail
      - type: custom:apexcharts-card
        graph_span: 1h
        header:
          show: true
          title: Printer Temperatures
          show_states: true
          colorize_states: true
        apex_config:
          chart:
            height: 200px
          legend:
            show: false
          grid: null
          xaxis:
            lines:
              show: true
          borderColor: '#555'
          yaxis:
            - opposite: true
              decimals: 0
              apex_config:
                tickAmount: 2
          all_series_config: null
          stroke_width: 2
          float_precision: 0
        series:
          - entity: sensor.mainsail_extruder_temperature
            name: Hotend
          - entity: sensor.mainsail_bed_temperature
            name: Bed
      - type: conditional
        conditions:
          - entity: sensor.mainsail_current_print_state
            state_not: unavailable
        card:
          type: picture-entity
          entity: camera.mainsail_thumbnail
          camera_view: auto
          show_name: false
          show_state: false

Related Post

Leave a Reply

Your email address will not be published. Required fields are marked *