This commit is contained in:
Home Assistant Version Control
2026-10-08 16:48:12 +00:00
parent 1cf6531c96
commit 291f0ee7bc
3 changed files with 1027 additions and 0 deletions
+343
View File
@@ -912,6 +912,349 @@
],
"title": "CFS / Fans",
"type": "sections"
},
{
"title": "Spoolman",
"path": "spoolman",
"icon": "mdi:package-variant-closed",
"type": "sections",
"max_columns": 4,
"sections": [
{
"type": "grid",
"cards": [
{
"type": "heading",
"heading": "Overture Black ABS (Spool 1)",
"icon": "mdi:spool"
},
{
"type": "gauge",
"entity": "sensor.spoolman_spool_1",
"name": "Remaining",
"unit": "g",
"min": 0,
"max": 1000,
"severity": {
"red": 0,
"yellow": 300,
"green": 600
},
"grid_options": {
"columns": 6,
"rows": 3
}
},
{
"type": "custom:mushroom-template-card",
"entity": "sensor.spoolman_spool_1_color_hex",
"name": "Color",
"icon": "mdi:palette",
"icon_color": "{% set c = states('sensor.spoolman_spool_1_color_hex')|replace('#','')|lower %}{% if c|length == 6 %}#{{ c }}{% else %}var(--primary-text-color){% endif %}",
"primary": "{{ states('sensor.spoolman_spool_1_color_hex') }}",
"secondary": "{{ states('sensor.spoolman_spool_1_filament_name') }} · {{ states('sensor.spoolman_spool_1_material') }}",
"multiline_secondary": true,
"grid_options": {
"columns": 6
}
},
{
"type": "tile",
"entity": "sensor.spoolman_spool_1_used_weight",
"name": "Used Weight",
"icon": "mdi:scale-balance",
"grid_options": {
"columns": 4
}
},
{
"type": "tile",
"entity": "sensor.spoolman_spool_1_used_percentage",
"name": "Used %",
"icon": "mdi:chart-donut",
"grid_options": {
"columns": 4
}
},
{
"type": "tile",
"entity": "sensor.spoolman_spool_1_remaining_length",
"name": "Remaining Length",
"icon": "mdi:ruler",
"grid_options": {
"columns": 4
}
},
{
"type": "tile",
"entity": "sensor.spoolman_spool_1_used_length",
"name": "Used Length",
"icon": "mdi:ruler-square",
"grid_options": {
"columns": 4
}
},
{
"type": "tile",
"entity": "sensor.spoolman_spool_1_spool_weight",
"name": "Empty Spool Weight",
"icon": "mdi:scale",
"grid_options": {
"columns": 4
}
},
{
"type": "tile",
"entity": "sensor.spoolman_spool_1_filament_weight",
"name": "Full Spool Weight",
"icon": "mdi:weight-kilogram",
"grid_options": {
"columns": 4
}
},
{
"type": "tile",
"entity": "sensor.spoolman_spool_1_vendor",
"name": "Vendor",
"icon": "mdi:factory",
"grid_options": {
"columns": 4
}
},
{
"type": "tile",
"entity": "sensor.spoolman_spool_1_material",
"name": "Material",
"icon": "mdi:layers-triple",
"grid_options": {
"columns": 4
}
},
{
"type": "tile",
"entity": "sensor.spoolman_spool_1_diameter",
"name": "Diameter",
"icon": "mdi:circle-outline",
"grid_options": {
"columns": 4
}
},
{
"type": "tile",
"entity": "sensor.spoolman_spool_1_density",
"name": "Density",
"icon": "mdi:weight-gram",
"grid_options": {
"columns": 4
}
},
{
"type": "tile",
"entity": "sensor.spoolman_spool_1_filament_name",
"name": "Filament Name",
"icon": "mdi:tag-outline",
"grid_options": {
"columns": 4
}
},
{
"type": "tile",
"entity": "select.spoolman_spool_1_location",
"name": "Location",
"icon": "mdi:map-marker-outline",
"grid_options": {
"columns": 4
}
},
{
"type": "tile",
"entity": "sensor.spoolman_spool_1_estimated_runout",
"name": "Est. Runout",
"icon": "mdi:calendar-alert",
"grid_options": {
"columns": 6
}
},
{
"type": "tile",
"entity": "sensor.spoolman_spool_1_registered",
"name": "Registered",
"icon": "mdi:calendar-check-outline",
"grid_options": {
"columns": 6
}
},
{
"type": "tile",
"entity": "binary_sensor.spoolman_spool_1_low_filament",
"name": "Low Filament",
"icon": "mdi:alert-circle-outline",
"grid_options": {
"columns": 4
}
},
{
"type": "tile",
"entity": "sensor.spoolman_spool_1_flow_rate",
"name": "Flow Rate",
"icon": "mdi:progress-clock",
"grid_options": {
"columns": 4
}
},
{
"type": "tile",
"entity": "sensor.spoolman_spool_1_id",
"name": "Spool ID",
"icon": "mdi:identifier",
"grid_options": {
"columns": 4
}
},
{
"type": "markdown",
"content": "**Spoolman UI:** [http://2c829f0e-spoolman.local.hass.io:7912](http://2c829f0e-spoolman.local.hass.io:7912)\n\n**Changing filaments:** 1. Set the slot color in the CFS app. 2. Create the spool in Spoolman with a matching color hex. No Home Assistant changes needed — new spools appear here automatically.",
"grid_options": {
"columns": "full"
}
}
]
},
{
"type": "grid",
"cards": [
{
"type": "heading",
"heading": "Adjust Remaining",
"icon": "mdi:pencil-outline"
},
{
"type": "entities",
"title": "Set value (g)",
"show_header_toggle": false,
"entities": [
"input_number.spoolman_set_remaining"
],
"grid_options": {
"columns": 6
}
},
{
"type": "tile",
"entity": "sensor.spoolman_spool_1",
"name": "Apply to Spool 1",
"icon": "mdi:content-save-outline",
"grid_options": {
"columns": 6
},
"tap_action": {
"action": "perform-action",
"perform_action": "script.spoolman_set_spool_remaining",
"data": {
"spool_id": 1
},
"confirmation": {
"text": "Overwrite Spool 1 remaining weight in Spoolman?"
}
}
},
{
"type": "markdown",
"content": "1. Type the new remaining grams above. 2. Tap **Apply to Spool 1**. The value is **absolute** — it replaces Spoolman's remaining weight, and print deductions continue from there. Wait for a running print to finish before adjusting.",
"grid_options": {
"columns": "full"
}
}
]
},
{
"type": "grid",
"cards": [
{
"type": "heading",
"heading": "Print Linkage",
"icon": "mdi:printer-3d-nozzle"
},
{
"type": "tile",
"entity": "input_text.sparkx_i7_print_spool_latch",
"name": "Latched Spool ID",
"icon": "mdi:link-variant",
"grid_options": {
"columns": 6
}
},
{
"type": "tile",
"entity": "sensor.sparkx_i7_filament_weight_estimated",
"name": "Current Job Weight",
"icon": "mdi:weight-gram",
"grid_options": {
"columns": 6
}
},
{
"type": "tile",
"entity": "automation.sparkx_i7_latch_print_spool_for_spoolman",
"name": "Latch Automation",
"icon": "mdi:link",
"grid_options": {
"columns": 6
}
},
{
"type": "tile",
"entity": "automation.sparkx_i7_deduct_filament_in_spoolman_on_print_complete",
"name": "Deduct Automation",
"icon": "mdi:minus-circle-outline",
"grid_options": {
"columns": 6
}
},
{
"type": "custom:mushroom-template-card",
"name": "Next Deduction Match",
"icon": "mdi:magnet",
"icon_color": "mdi:link",
"primary": "{{ states('sensor.sparkx_i7_active_filament_slot') }}",
"secondary": "{% set slot = states('sensor.sparkx_i7_active_filament_slot') %}{% set ce = 'sensor.sparkx_i7_cfs_' ~ (slot|lower|replace(' ','_')) ~ '_color' %}{% set color = states(ce)|replace('#','')|lower %}{% set ns = namespace(id='') %}{% for e in integration_entities('spoolman') %}{% if e.endswith('_color_hex') and (states(e)|lower) == color %}{% set ns.id = states(e[:-10] ~ '_id') %}{% endif %}{% endfor %}{% if ns.id %}Color #{{ color }} → deducts from spool {{ ns.id }} ({% set fn = 'sensor.spoolman_spool_' ~ ns.id ~ '_filament_name' %}{{ states(fn) }}){% elif color in ['', 'unknown', 'unavailable'] %}Slot color unavailable{% else %}Color #{{ color }} — no matching spool{% endif %}",
"multiline_secondary": true,
"grid_options": {
"columns": "full"
}
}
]
},
{
"type": "grid",
"cards": [
{
"type": "heading",
"heading": "Spool History",
"icon": "mdi:history"
},
{
"type": "history-graph",
"title": "Remaining & Used (7 days)",
"hours_to_show": 168,
"show_names": true,
"entities": [
{
"entity": "sensor.spoolman_spool_1",
"name": "Remaining"
},
{
"entity": "sensor.spoolman_spool_1_used_weight",
"name": "Used"
}
],
"grid_options": {
"columns": "full"
}
}
]
}
]
}
]
}