AutomationDataset/Martin0475/automation-descriptions.json

769 lines
155 KiB
JSON

[
{
"id": "B2500PKG_B01E1_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_01/CD13. CONDITIONS: None. ACTIONS: Store the message payload in variable 'payload'. Then, for each cell voltage substring (b0= to bf=) present in the payload, publish a corresponding MQTT discovery configuration to create a voltage sensor entity. Finally, turn off this automation [automation.b2500pkg_b01e1_voltage_discovery].",
"natural_language": {
"trigger": "Whenever a new message arrives on the MQTT topic 'B2500PKG/B2500_01/CD13'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the incoming message. It then checks the saved content for the presence of specific strings like 'b0=', 'b1=', and so on up to 'bf='. For each string that is found, it publishes a special MQTT configuration message. This configuration message tells Home Assistant to create a new sensor for monitoring a battery cell voltage. After processing all possible cell voltage strings, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for a specific MQTT message and uses its data to automatically create sensors for monitoring individual battery cell voltages, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B01E2_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_01/CD13. CONDITIONS: None. ACTIONS: Store the message payload in variable 'payload'. Then, for each of 16 possible substrings (c0= through cf=), if the substring is present in the payload, publish a corresponding MQTT configuration message to a specific topic (homeassistant/sensor/b2500_01/voltage_cX/config) to create a voltage sensor entity named 'B01E2 ZelleYY' (where YY is 01-16). Finally, turn off this automation [automation.b2500pkg_b01e2_voltage_discovery].",
"natural_language": {
"trigger": "Whenever a message is published to the MQTT topic 'B2500PKG/B2500_01/CD13'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the received MQTT message. It then checks this content for the presence of specific identifiers (c0=, c1=, ..., cf=). For each identifier found, it sends a new MQTT message. This new message is a configuration payload that instructs Home Assistant to create a new voltage sensor. Each sensor is given a name like 'B01E2 Zelle01', is set to read its value from the same incoming topic, and extracts the specific voltage data using a template. After processing all possible identifiers, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for a data packet and uses it to automatically create up to 16 voltage sensor entities in Home Assistant for monitoring individual battery cells, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B01_CD16_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_01/CD16. CONDITIONS: None. ACTIONS: Store the message payload in a variable. Then, for each of the following key patterns present in the payload, publish a corresponding MQTT discovery configuration message to the Home Assistant topic and then turn off this automation [automation.b2500pkg_b01_cd16_sensor_discovery]. The key patterns and their corresponding sensor configurations are: 'm1=' creates B01 PV1 Input Voltage [sensor.b2500_01_cd16m1], 'm2=' creates B01 PV2 Input Voltage [sensor.b2500_01_cd16m2], 'i1=' creates B01 Output1 Voltage [sensor.b2500_01_cd16i1], 'i2=' creates B01 Output2 Voltage [sensor.b2500_01_cd16i2], 'c1=' creates B01 PV1 Input Current [sensor.b2500_01_cd16c1], 'c2=' creates B01 PV2 Input Current [sensor.b2500_01_cd16c2], 'c3=' creates B01 Output1 Current [sensor.b2500_01_cd16c3], 'c4=' creates B01 Output2 Current [sensor.b2500_01_cd16c4], 'bv=' creates B01 Akku Voltage [sensor.b2500_01_cd16bv], 'bc=' creates B01 Akku Current [sensor.b2500_01_cd16bc], 'bb=' creates B01 Akku Power [sensor.b2500_01_cd16bb].",
"natural_language": {
"trigger": "The automation is triggered whenever a new message is published to the MQTT topic 'B2500PKG/B2500_01/CD16'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the incoming MQTT message. It then checks this content for specific data keys. For each key found, it publishes a Home Assistant MQTT discovery configuration to create a corresponding sensor entity. These sensors are for monitoring a power system's input voltages, output voltages, input currents, output currents, battery voltage, battery current, and battery power. Finally, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for a device's status message and automatically creates the necessary sensor entities in Home Assistant to monitor its various electrical parameters.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B01_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_01/CD01. CONDITIONS: None. ACTIONS: Store the message payload in variable 'payload'. Then, for each of the following 66 distinct key patterns, if the key is present in the payload, publish a corresponding MQTT configuration message to the Home Assistant discovery topic. The configuration messages define new binary sensors, sensors, and their properties (name, state_topic, value_template, device_class, unit_of_measurement, etc.) for the B2500 device. The keys and their corresponding entity names are: l0 (bits 0-3: B01 Entladen, B01 Laden, B01 DOD erreicht, B01 Unterspannung), l1 (bits 0-7: B01E2 Entladen, B01E2 Laden, B01E2 DOD erreicht, B01E2 Unterspannung, B01E1 Entladen, B01E1 Laden, B01E1 DOD erreicht, B01E1 Unterspannung), b1 (B01 E1 verbunden), b2 (B01 E2 verbunden), p1 (B01 Solar1 Input Status), p2 (B01 Solar2 Input Status), w1 (B01 PV1 Leistung), w2 (B01 PV2 Leistung), pe (B01 Batterie SOC), vv (B01 Geräteversion), sv (B01 Gerätesubversion), cs (B01 Ladeeinstellung), cd (B01 Entladeeinstellung), am (B01 AM), o1 (B01 Output Status 1), o2 (B01 Output Status 2), do (B01 DOD Entnehmbare Kapazität in %), lv (B01 Entladeschwelle), cj (B01 CJ Scene), kn (B01 Gesamtkapazität), g1 (B01 Output1 Leistung), g2 (B01 Output2 Leistung), tl (B01 Temperatur low), th (B01 Temperatur high), tc (B01 Temperaturalarm (Laden)), tf (B01 Temperaturalarm (Entladen)), fc (B01 Chip Version), id (B01 Geräte ID), a0 (B01 Ladezustand Hauptspeicher), a1 (B01 Ladezustand Erweiterung1), a2 (B01 Ladezustand Erweiterung2), e1 (B01 Timer1 Beginn), f1 (B01 Timer1 Ende), h1 (B01 Timer1 Ausgabeleistung), e2 (B01 Timer2 Beginn), f2 (B01 Timer2 Ende), h2 (B01 Timer2 Ausgabeleistung), e3 (B01 Timer3 Beginn), f3 (B01 Timer3 Ende), h3 (B01 Timer3 Ausgabeleistung), e4 (B01 Timer4 Beginn), f4 (B01 Timer4 Ende), h4 (B01 Timer4 Ausgabeleistung), e5 (B01 Timer5 Beginn), f5 (B01 Timer5 Ende), h5 (B01 Timer5 Ausgabeleistung), d1 (B01 Timer1 aktiv), d2 (B01 Timer2 aktiv), d3 (B01 Timer3 aktiv), d4 (B01 Timer4 aktiv), d5 (B01 Timer5 aktiv), bc (B01 Tägliche Battterieladung), bs (B01 Tägliche Batterieentladung), pt (B01 Tägliche PV Erzeugung), md (B01 Entlademodus Timer/Selbstanpassung), sg (B01 CT Sensor verbunden), sp (B01 SP), st (B01 ST), c0 (B01 CTCH Kanal), c1 (B01 Status CT), it (B01 IT Tägliche abgegebene Leistung), m0 (B01 Leistungsmessung Phase1), m1 (B01 Leistungsmessung Phase2), m2 (B01 Leistungsmessung Phase3), m3 (B01 M3), lmo (B01 LMO Nennausgangsleistung), lmi (B01 LMI Nennaufnahmeleistung), lmf (B01 LMF Gerätebeschränkung). Finally, turn off the automation B2500PKG B01 Sensor Discovery Automation [automation.b2500pkg_b01_sensor_discovery].",
"natural_language": {
"trigger": "Whenever a message is published to the MQTT topic 'B2500PKG/B2500_01/CD01'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the incoming message content into a variable. It then checks the payload for the presence of 66 different data keys (like 'l0=', 'b1=', 'pe='). For each key found, it publishes a specific MQTT configuration message to Home Assistant's discovery topics. These configuration messages instruct Home Assistant to create and manage a wide array of sensors and binary sensors for the B2500 device, covering its status, power measurements, battery information, timers, and diagnostic data. After processing all possible keys, the automation turns itself off to prevent running again."
},
"human_like": "This automation automatically discovers and creates all necessary sensors for a B2500 battery system when it first sends data via MQTT, then disables itself.",
"complexity": "high"
}
},
{
"id": "B2500PKG_B01_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_01/CD13. CONDITIONS: None. ACTIONS: Store the message payload in a variable. Then, for each of the following substrings present in the payload, publish a corresponding MQTT configuration message to the Home Assistant discovery topic: If 'a0=' is present, publish sensor configuration for B01 Zelle01. If 'a1=' is present, publish sensor configuration for B01 Zelle02. If 'a2=' is present, publish sensor configuration for B01 Zelle03. If 'a3=' is present, publish sensor configuration for B01 Zelle04. If 'a4=' is present, publish sensor configuration for B01 Zelle05. If 'a5=' is present, publish sensor configuration for B01 Zelle06. If 'a6=' is present, publish sensor configuration for B01 Zelle07. If 'a7=' is present, publish sensor configuration for B01 Zelle08. If 'a8=' is present, publish sensor configuration for B01 Zelle09. If 'a9=' is present, publish sensor configuration for B01 Zelle10. If 'aa=' is present, publish sensor configuration for B01 Zelle11. If 'ab=' is present, publish sensor configuration for B01 Zelle12. If 'ac=' is present, publish sensor configuration for B01 Zelle13. If 'ad=' is present, publish sensor configuration for B01 Zelle14. If 'ae=' is present, publish sensor configuration for B01 Zelle15. If 'af=' is present, publish sensor configuration for B01 Zelle16. Finally, turn off B2500PKG B01 Voltage Discovery Automation [automation.b2500pkg_b01_voltage_discovery].",
"natural_language": {
"trigger": "The automation is triggered whenever a message is published to the MQTT topic 'B2500PKG/B2500_01/CD13'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the received MQTT message. It then checks this content for specific patterns. For each pattern found (like 'a0=', 'a1=', up to 'af='), it publishes a corresponding MQTT configuration message to Home Assistant's discovery system. This effectively creates or updates a sensor entity for a specific battery cell (e.g., 'B01 Zelle01' for 'a0=') with details like its name, state topic, and unit of measurement. After processing all possible patterns, the automation turns itself off."
},
"human_like": "This automation listens for a specific MQTT message and uses its data to automatically create sensor entities in Home Assistant for up to 16 battery cell voltages, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B02E1_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_02/CD13. CONDITIONS: None. ACTIONS: Store the message payload in variable 'payload'. Then, for each of the 16 possible cell voltage keys (b0= through bf=), if the key is present in the payload, publish a corresponding MQTT configuration message to create a voltage sensor entity for that cell. After processing all keys, turn off the automation B2500PKG B02E1 Voltage Discovery Automation [automation.b2500pkg_b02e1_voltage_discovery].",
"natural_language": {
"trigger": "The automation is triggered whenever a message is published to the MQTT topic 'B2500PKG/B2500_02/CD13'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the received MQTT message. It then checks this content for the presence of specific keys (like 'b0=', 'b1=', up to 'bf='). For each key found, it sends a new MQTT message to the Home Assistant discovery topic. This message contains the configuration needed for Home Assistant to create a new voltage sensor for a specific battery cell. After checking for all 16 possible keys, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for a specific MQTT message and uses its data to automatically create sensor entities for up to 16 battery cell voltages, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B02E2_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_02/CD13. CONDITIONS: None. ACTIONS: Store the message payload in variable 'payload'. Then, for each cell identifier (c0 through cf), IF the identifier string is present in the payload, THEN publish a corresponding MQTT configuration message to create a voltage sensor entity for that cell. Finally, turn off this automation [automation.b2500pkg_b02e2_voltage_discovery].",
"natural_language": {
"trigger": "The automation is triggered whenever an MQTT message arrives on the topic 'B2500PKG/B2500_02/CD13'.",
"conditions": "There are no conditions that need to be met for the actions to run.",
"action": "The automation first saves the content of the incoming MQTT message. It then checks the saved content for the presence of specific cell identifiers (like 'c0=', 'c1=', up to 'cf='). For each identifier found, it publishes a new MQTT configuration message. This configuration message instructs Home Assistant to create a new voltage sensor for that specific battery cell, with a name like 'B02E2 Zelle01', and configures it to listen for future updates on the same MQTT topic. After processing all possible cells, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for a data message from a battery pack and automatically creates sensors in Home Assistant to monitor the voltage of each individual battery cell it detects.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B02_CD16_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_02/CD16. CONDITIONS: None. ACTIONS: Store the message payload in a variable. Then, for each of the following key patterns present in the payload, publish a corresponding MQTT discovery configuration message: IF 'm1=' THEN publish config for B02 PV1 Input Voltage [sensor.b2500_02_cd16m1]. IF 'm2=' THEN publish config for B02 PV2 Input Voltage [sensor.b2500_02_cd16m2]. IF 'i1=' THEN publish config for B02 Output1 Voltage [sensor.b2500_02_cd16i1]. IF 'i2=' THEN publish config for B02 Output2 Voltage [sensor.b2500_02_cd16i2]. IF 'c1=' THEN publish config for B02 PV1 Input Current [sensor.b2500_02_cd16c1]. IF 'c2=' THEN publish config for B02 PV2 Input Current [sensor.b2500_02_cd16c2]. IF 'c3=' THEN publish config for B02 Output1 Current [sensor.b2500_02_cd16c3]. IF 'c4=' THEN publish config for B02 Output2 Current [sensor.b2500_02_cd16c4]. IF 'bv=' THEN publish config for B02 Akku Voltage [sensor.b2500_02_cd16bv]. IF 'bc=' THEN publish config for B02 Akku Current [sensor.b2500_02_cd16bc]. IF 'bb=' THEN publish config for B02 Akku Power [sensor.b2500_02_cd16bb]. Finally, turn off this automation [automation.b2500pkg_b02_cd16_sensor_discovery].",
"natural_language": {
"trigger": "Whenever a new message arrives on the MQTT topic 'B2500PKG/B2500_02/CD16'.",
"conditions": "There are no conditions that must be met.",
"action": "The automation first saves the content of the received message. It then checks the message for specific data fields. For each field found (like 'm1=', 'm2=', 'i1=', etc.), it publishes a separate MQTT configuration message. These configuration messages are used to create Home Assistant sensors for monitoring various voltages, currents, and power of a device labeled 'B02'. After all potential configuration messages are sent, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for data from a specific device and automatically creates the necessary Home Assistant sensors for monitoring its solar power and battery metrics, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B02_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_02/CD01. CONDITIONS: None. ACTIONS: Set variable 'payload' to the trigger payload. Then, for each of the following key presence checks in the payload, if true, publish a corresponding MQTT configuration message to the Home Assistant discovery topic with a retained flag: IF 'l0=' in payload THEN publish binary sensor config for B02 Entladen [binary_sensor.b2500_02_l0_bit0], B02 Laden [binary_sensor.b2500_02_l0_bit1], B02 DOD erreicht [binary_sensor.b2500_02_l0_bit2], B02 Unterspannung [binary_sensor.b2500_02_l0_bit3]. IF 'l1=' in payload THEN publish binary sensor config for B02E2 Entladen [binary_sensor.b2500_02_l1_bit0], B02E2 Laden [binary_sensor.b2500_02_l1_bit1], B02E2 DOD erreicht [binary_sensor.b2500_02_l1_bit2], B02E2 Unterspannung [binary_sensor.b2500_02_l1_bit3], B02E1 Entladen [binary_sensor.b2500_02_l1_bit4], B02E1 Laden [binary_sensor.b2500_02_l1_bit5], B02E1 DOD erreicht [binary_sensor.b2500_02_l1_bit6], B02E1 Unterspannung [binary_sensor.b2500_02_l1_bit7]. IF 'b1=' in payload THEN publish binary sensor config for B02 E1 verbunden [binary_sensor.b2500_02_b1]. IF 'b2=' in payload THEN publish binary sensor config for B02 E2 verbunden [binary_sensor.b2500_02_b2]. IF 'p1=' in payload THEN publish sensor config for B02 Solar1 Input Status [sensor.b2500_02_p1]. IF 'p2=' in payload THEN publish sensor config for B02 Solar2 Input Status [sensor.b2500_02_p2]. IF 'w1=' in payload THEN publish sensor config for B02 PV1 Leistung [sensor.b2500_02_w1]. IF 'w2=' in payload THEN publish sensor config for B02 PV2 Leistung [sensor.b2500_02_w2]. IF 'pe=' in payload THEN publish sensor config for B02 Batterie SOC [sensor.b2500_02_pe]. IF 'vv=' in payload THEN publish sensor config for B02 Geräteversion [sensor.b2500_02_vv]. IF 'sv=' in payload THEN publish sensor config for B02 Gerätesubversion [sensor.b2500_02_sv]. IF 'cs=' in payload THEN publish sensor config for B02 Ladeeinstellung [sensor.b2500_02_cs]. IF 'cd=' in payload THEN publish sensor config for B02 Entladeeinstellung [sensor.b2500_02_cd]. IF 'am=' in payload THEN publish sensor config for B02 AM [sensor.b2500_02_am]. IF 'o1=' in payload THEN publish sensor config for B02 Output Status 1 [sensor.b2500_02_o1]. IF 'o2=' in payload THEN publish sensor config for B02 Output Status 2 [sensor.b2500_02_o2]. IF 'do=' in payload THEN publish sensor config for B02 DOD Entnehmbare Kapazität in % [sensor.b2500_02_do]. IF 'lv=' in payload THEN publish sensor config for B02 Entladeschwelle [sensor.b2500_02_lv]. IF 'cj=' in payload THEN publish sensor config for B02 CJ Scene [sensor.b2500_02_cj]. IF 'kn=' in payload THEN publish sensor config for B02 Gesamtkapazität [sensor.b2500_02_kn]. IF 'g1=' in payload THEN publish sensor config for B02 Output1 Leistung [sensor.b2500_02_g1]. IF 'g2=' in payload THEN publish sensor config for B02 Output2 Leistung [sensor.b2500_02_g2]. IF 'tl=' in payload THEN publish sensor config for B02 Temperatur low [sensor.b2500_02_tl]. IF 'th=' in payload THEN publish sensor config for B02 Temperatur high [sensor.b2500_02_th]. IF 'tc=' in payload THEN publish sensor config for B02 Temperaturalarm (Laden) [sensor.b2500_02_tc]. IF 'tf=' in payload THEN publish sensor config for B02 Temperaturalarm (Entladen) [sensor.b2500_02_tf]. IF 'fc=' in payload THEN publish sensor config for B02 Chip Version [sensor.b2500_02_fc]. IF 'id=' in payload THEN publish sensor config for B02 Geräte ID [sensor.b2500_02_id]. IF 'a0=' in payload THEN publish sensor config for B02 Ladezustand Hauptspeicher [sensor.b2500_02_a0]. IF 'a1=' in payload THEN publish sensor config for B02 Ladezustand Erweiterung1 [sensor.b2500_02_a1]. IF 'a2=' in payload THEN publish sensor config for B02 Ladezustand Erweiterung2 [sensor.b2500_02_a2]. IF 'e1=' in payload THEN publish sensor config for B02 Timer1 Beginn [sensor.b2500_02_e1]. IF 'f1=' in payload THEN publish sensor config for B02 Timer1 Ende [sensor.b2500_02_f1]. IF 'h1=' in payload THEN publish sensor config for B02 Timer1 Ausgabeleistung [sensor.b2500_02_h1]. IF 'e2=' in payload THEN publish sensor config for B02 Timer2 Beginn [sensor.b2500_02_e2]. IF 'f2=' in payload THEN publish sensor config for B02 Timer2 Ende [sensor.b2500_02_f2]. IF 'h2=' in payload THEN publish sensor config for B02 Timer2 Ausgabeleistung [sensor.b2500_02_h2]. IF 'e3=' in payload THEN publish sensor config for B02 Timer3 Beginn [sensor.b2500_02_e3]. IF 'f3=' in payload THEN publish sensor config for B02 Timer3 Ende [sensor.b2500_02_f3]. IF 'h3=' in payload THEN publish sensor config for B02 Timer3 Ausgabeleistung [sensor.b2500_02_h3]. IF 'e4=' in payload THEN publish sensor config for B02 Timer4 Beginn [sensor.b2500_02_e4]. IF 'f4=' in payload THEN publish sensor config for B02 Timer4 Ende [sensor.b2500_02_f4]. IF 'h4=' in payload THEN publish sensor config for B02 Timer4 Ausgabeleistung [sensor.b2500_02_h4]. IF 'e5=' in payload THEN publish sensor config for B02 Timer5 Beginn [sensor.b2500_02_e5]. IF 'f5=' in payload THEN publish sensor config for B02 Timer5 Ende [sensor.b2500_02_f5]. IF 'h5=' in payload THEN publish sensor config for B02 Timer5 Ausgabeleistung [sensor.b2500_02_h5]. IF 'd1=' in payload THEN publish binary sensor config for B02 Timer1 aktiv [binary_sensor.b2500_02_d1]. IF 'd2=' in payload THEN publish binary sensor config for B02 Timer2 aktiv [binary_sensor.b2500_02_d2]. IF 'd3=' in payload THEN publish binary sensor config for B02 Timer3 aktiv [binary_sensor.b2500_02_d3]. IF 'd4=' in payload THEN publish binary sensor config for B02 Timer4 aktiv [binary_sensor.b2500_02_d4]. IF 'd5=' in payload THEN publish binary sensor config for B02 Timer5 aktiv [binary_sensor.b2500_02_d5]. IF 'bc=' in payload THEN publish sensor config for B02 Tägliche Battterieladung [sensor.b2500_02_bc]. IF 'bs=' in payload THEN publish sensor config for B02 Tägliche Batterieentladung [sensor.b2500_02_bs]. IF 'pt=' in payload THEN publish sensor config for B02 Tägliche PV Erzeugung [sensor.b2500_02_pt]. IF 'md=' in payload THEN publish sensor config for B02 Entlademodus Timer/Selbstanpassung [sensor.b2500_02_md]. IF 'sg=' in payload THEN publish sensor config for B02 CT Sensor verbunden [sensor.b2500_02_sg]. IF 'sp=' in payload THEN publish sensor config for B02 SP [sensor.b2500_02_sp]. IF 'st=' in payload THEN publish sensor config for B02 ST [sensor.b2500_02_st]. IF 'c0=' in payload THEN publish sensor config for B02 CTCH Kanal [sensor.b2500_02_c0]. IF 'c1=' in payload THEN publish sensor config for B02 Status CT [sensor.b2500_02_c1]. IF 'it=' in payload THEN publish sensor config for B02 IT Tägliche abgegebene Leistung [sensor.b2500_02_it]. IF 'm0=' in payload THEN publish sensor config for B02 Leistungsmessung Phase1 [sensor.b2500_02_m0]. IF 'm1=' in payload THEN publish sensor config for B02 Leistungsmessung Phase2 [sensor.b2500_02_m1]. IF 'm2=' in payload THEN publish sensor config for B02 Leistungsmessung Phase3 [sensor.b2500_02_m2]. IF 'm3=' in payload THEN publish sensor config for B02 M3 [sensor.b2500_02_m3]. IF 'lmo=' in payload THEN publish sensor config for B02 LMO Nennausgangsleistung [sensor.b2500_02_lmo]. IF 'lmi=' in payload THEN publish sensor config for B02 LMI Nennaufnahmeleistung [sensor.b2500_02_lmi]. IF 'lmf=' in payload THEN publish sensor config for B02 LMF Gerätebeschränkung [sensor.b2500_02_lmf]. Finally, turn off the automation B2500PKG B02 Sensor Discovery Automation [automation.b2500pkg_b02_sensor_discovery].",
"natural_language": {
"trigger": "When a message is received on the MQTT topic B2500PKG/B2500_02/CD01.",
"conditions": "There are no conditions; the automation runs every time the trigger occurs.",
"action": "The automation first stores the received message payload into a variable. It then checks the payload for the presence of specific keys (like 'l0=', 'l1=', 'b1=', etc.). For each key found, it publishes a corresponding MQTT configuration message to the Home Assistant discovery topic. These configuration messages define a wide range of sensors and binary sensors for a B2500 device (B02), covering battery status, solar input, power measurements, timers, temperatures, device information, and energy statistics. Each configuration is published with the retained flag set to true. After publishing all relevant configurations, the automation turns itself off to prevent repeated execution."
},
"human_like": "This automation automatically discovers and creates a comprehensive set of sensors for a B2500 battery system when it receives its first status message, then disables itself.",
"complexity": "high"
}
},
{
"id": "B2500PKG_B02_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_02/CD13. CONDITIONS: None. ACTIONS: Set variable 'payload' to the trigger payload. Then, for each of the 16 possible substrings ('a0=' through 'af='), if the substring is present in the payload, publish a specific MQTT configuration message to a corresponding topic (homeassistant/sensor/b2500_02/voltage_[key]/config) to create or update a sensor entity for a battery cell voltage. Finally, turn off the automation B2500PKG B02 Voltage Discovery Automation [automation.b2500pkg_b02_voltage_discovery].",
"natural_language": {
"trigger": "The automation is triggered whenever an MQTT message arrives on the topic 'B2500PKG/B2500_02/CD13'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the received MQTT message. It then checks the message for the presence of specific markers (like 'a0=', 'a1=', up to 'af='). For each marker found, it sends a new MQTT message to a specific configuration topic. This configuration message instructs Home Assistant to create or update a sensor entity for a specific battery cell (e.g., 'B02 Zelle01'), using the voltage data from the original message. After processing all possible markers, the automation turns itself off to prevent further runs."
},
"human_like": "This automation listens for battery data messages and automatically creates the necessary voltage sensors in Home Assistant for up to 16 individual cells, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B03E1_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_03/CD13. CONDITIONS: None. ACTIONS: Store the message payload in variable 'payload'. Then, for each of the 16 possible substrings ('b0=' to 'bf='), if the substring is present in the payload, publish a corresponding MQTT configuration message to create a voltage sensor entity. The configuration includes a name (e.g., 'B03E1 Zelle01'), state topic, device class, unit of measurement, a value template to extract the voltage value, a unique ID, an object ID, and an entity category of 'diagnostic'. Finally, turn off the automation B2500PKG B03E1 Voltage Discovery Automation [automation.b2500pkg_b03e1_voltage_discovery].",
"natural_language": {
"trigger": "Whenever a message is published to the MQTT topic 'B2500PKG/B2500_03/CD13'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the received MQTT message. It then checks this content for the presence of specific text patterns, from 'b0=' up to 'bf='. For each pattern found, it sends out a new MQTT message. This new message is a configuration payload that instructs Home Assistant to create a new sensor. Each sensor is configured to report a voltage value in millivolts, with a name like 'B03E1 Zelle01', and is linked to the original MQTT topic for its data. After processing all possible patterns, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for a specific MQTT message and uses its data to automatically create and configure up to 16 voltage sensors in Home Assistant, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B03E2_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_03/CD13. CONDITIONS: None. ACTIONS: Store the message payload in a variable named 'payload'. Then, for each cell identifier from c0 to cf, if the payload contains that identifier, publish a corresponding MQTT configuration message to create a voltage sensor entity for that cell. Finally, turn off the automation B2500PKG B03E2 Voltage Discovery Automation [automation.b2500pkg_b03e2_voltage_discovery].",
"natural_language": {
"trigger": "Whenever a message is published to the MQTT topic 'B2500PKG/B2500_03/CD13'.",
"conditions": "There are no conditions that must be met.",
"action": "The automation first saves the content of the received message. It then checks the saved content for the presence of specific cell identifiers (c0 through cf). For each identifier found, it sends a configuration message via MQTT to create a new voltage sensor in Home Assistant. Each sensor is configured to extract its voltage value from the original message, is given a name like 'B03E2 Zelle01', and is marked as a diagnostic entity. After processing all possible cells, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for a specific MQTT message and uses its data to automatically create and configure up to 16 voltage sensor entities for a battery pack, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B03_CD16_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_03/CD16. CONDITIONS: None. ACTIONS: Store the message payload in variable 'payload'. Then, for each of the following key-value pairs, if the key is present in the payload, publish a corresponding MQTT discovery configuration message: IF 'm1' present THEN publish config for B03 PV1 Input Voltage [sensor.b2500_03_cd16m1]. IF 'm2' present THEN publish config for B03 PV2 Input Voltage [sensor.b2500_03_cd16m2]. IF 'i1' present THEN publish config for B03 Output1 Voltage [sensor.b2500_03_cd16i1]. IF 'i2' present THEN publish config for B03 Output2 Voltage [sensor.b2500_03_cd16i2]. IF 'c1' present THEN publish config for B03 PV1 Input Current [sensor.b2500_03_cd16c1]. IF 'c2' present THEN publish config for B03 PV2 Input Current [sensor.b2500_03_cd16c2]. IF 'c3' present THEN publish config for B03 Output1 Current [sensor.b2500_03_cd16c3]. IF 'c4' present THEN publish config for B03 Output2 Current [sensor.b2500_03_cd16c4]. IF 'bv' present THEN publish config for B03 Akku Voltage [sensor.b2500_03_cd16bv]. IF 'bc' present THEN publish config for B03 Akku Current [sensor.b2500_03_cd16bc]. IF 'bb' present THEN publish config for B03 Akku Power [sensor.b2500_03_cd16bb]. Finally, turn off B2500PKG B03 CD16 Sensor Discovery Automation [automation.b2500pkg_b03_cd16_sensor_discovery].",
"natural_language": {
"trigger": "An MQTT message arrives on the topic B2500PKG/B2500_03/CD16.",
"conditions": "There are no conditions; the automation runs every time a message is received.",
"action": "The automation first saves the message content. It then checks the payload for specific keywords. For each keyword found, it publishes a corresponding Home Assistant MQTT discovery configuration message to create a sensor entity. The keywords and their associated sensors are: 'm1' for B03 PV1 Input Voltage, 'm2' for B03 PV2 Input Voltage, 'i1' for B03 Output1 Voltage, 'i2' for B03 Output2 Voltage, 'c1' for B03 PV1 Input Current, 'c2' for B03 PV2 Input Current, 'c3' for B03 Output1 Current, 'c4' for B03 Output2 Current, 'bv' for B03 Akku Voltage, 'bc' for B03 Akku Current, and 'bb' for B03 Akku Power. After processing all possible keys, the automation turns itself off to prevent further runs."
},
"human_like": "This automation listens for a data message from a device and automatically creates the necessary sensor entities in Home Assistant for monitoring its various voltage, current, and power readings.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B03_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_03/CD01. CONDITIONS: None. ACTIONS: Store the message payload in a variable named payload. Then, for each of the following 66 key patterns, if the pattern is present in the payload, publish a corresponding MQTT configuration message to the Home Assistant discovery topic to create a sensor or binary sensor entity. The patterns and their corresponding entity names are: l0= (for bits 0-3), l1= (for bits 0-7), b1=, b2=, p1=, p2=, w1=, w2=, pe=, vv=, sv=, cs=, cd=, am=, o1=, o2=, do=, lv=, cj=, kn=, g1=, g2=, tl=, th=, tc=, tf=, fc=, id=, a0=, a1=, a2=, e1=, f1=, h1=, e2=, f2=, h2=, e3=, f3=, h3=, e4=, f4=, h4=, e5=, f5=, h5=, d1=, d2=, d3=, d4=, d5=, bc=, bs=, pt=, md=, sg=, sp=, st=, c0=, c1=, it=, m0=, m1=, m2=, m3=, lmo=, lmi=, lmf=. Finally, turn off the automation B2500PKG B03 Sensor Discovery Automation [automation.b2500pkg_b03_sensor_discovery].",
"natural_language": {
"trigger": "Whenever a message is published to the MQTT topic 'B2500PKG/B2500_03/CD01'.",
"conditions": "There are no conditions; the automation runs every time the trigger occurs.",
"action": "The automation saves the incoming message content. It then checks the content for the presence of 66 different data field identifiers (like 'l0=', 'b1=', 'w1=', etc.). For each identifier found, it publishes a specific MQTT configuration message. These configuration messages instruct Home Assistant's MQTT Discovery to create a new sensor or binary sensor entity, defining its name, how to extract its value from the incoming data, and other properties like unit of measurement or device class. After processing all possible identifiers, the automation turns itself off to prevent running again."
},
"human_like": "This automation automatically discovers and creates dozens of sensor entities for a B2500 battery system the first time it receives data, then disables itself.",
"complexity": "high"
}
},
{
"id": "B2500PKG_B03_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_03/CD13. CONDITIONS: None. ACTIONS: Store the message payload in a variable. Then, for each possible substring 'a0=' through 'af=' (16 total), if the substring is present in the payload, publish a corresponding MQTT configuration message to the Home Assistant discovery topic to create a voltage sensor entity for a battery cell. After processing all possible substrings, turn off the automation B2500PKG B03 Voltage Discovery Automation [automation.b2500pkg_b03_voltage_discovery].",
"natural_language": {
"trigger": "When a message is published to the MQTT topic 'B2500PKG/B2500_03/CD13'.",
"conditions": "There are no conditions that must be met.",
"action": "The automation saves the content of the received message. It then checks the content for the presence of specific text patterns (like 'a0=', 'a1=', up to 'af='). For each pattern found, it sends a new MQTT message to a Home Assistant discovery topic. This message instructs Home Assistant to create a new sensor that will monitor the voltage of a specific battery cell, using the data from the original message. Once all checks are complete, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for a data message from a battery pack and automatically creates the necessary voltage sensors in Home Assistant for each detected cell, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B04E1_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_04/CD13. CONDITIONS: None. ACTIONS: Store the message payload in variable 'payload'. Then, for each of the following 16 conditions, if the condition is true, publish a corresponding MQTT configuration message to Home Assistant's discovery topic. The conditions and actions are: IF 'b0=' is in payload THEN publish sensor config for B04E1 Zelle01 [sensor.b2500_04_extern1_zelle01]; IF 'b1=' is in payload THEN publish sensor config for B04E1 Zelle02 [sensor.b2500_04_extern1_zelle02]; IF 'b2=' is in payload THEN publish sensor config for B04E1 Zelle03 [sensor.b2500_04_extern1_zelle03]; IF 'b3=' is in payload THEN publish sensor config for B04E1 Zelle04 [sensor.b2500_04_extern1_zelle04]; IF 'b4=' is in payload THEN publish sensor config for B04E1 Zelle05 [sensor.b2500_04_extern1_zelle05]; IF 'b5=' is in payload THEN publish sensor config for B04E1 Zelle06 [sensor.b2500_04_extern1_zelle06]; IF 'b6=' is in payload THEN publish sensor config for B04E1 Zelle07 [sensor.b2500_04_extern1_zelle07]; IF 'b7=' is in payload THEN publish sensor config for B04E1 Zelle08 [sensor.b2500_04_extern1_zelle08]; IF 'b8=' is in payload THEN publish sensor config for B04E1 Zelle09 [sensor.b2500_04_extern1_zelle09]; IF 'b9=' is in payload THEN publish sensor config for B04E1 Zelle10 [sensor.b2500_04_extern1_zelle10]; IF 'ba=' is in payload THEN publish sensor config for B04E1 Zelle11 [sensor.b2500_04_extern1_zelle11]; IF 'bb=' is in payload THEN publish sensor config for B04E1 Zelle12 [sensor.b2500_04_extern1_zelle12]; IF 'bc=' is in payload THEN publish sensor config for B04E1 Zelle13 [sensor.b2500_04_extern1_zelle13]; IF 'bd=' is in payload THEN publish sensor config for B04E1 Zelle14 [sensor.b2500_04_extern1_zelle14]; IF 'be=' is in payload THEN publish sensor config for B04E1 Zelle15 [sensor.b2500_04_extern1_zelle15]; IF 'bf=' is in payload THEN publish sensor config for B04E1 Zelle16 [sensor.b2500_04_extern1_zelle16]. Finally, turn off the automation B2500PKG B04E1 Voltage Discovery Automation [automation.b2500pkg_b04e1_voltage_discovery].",
"natural_language": {
"trigger": "Whenever a message is published to the MQTT topic 'B2500PKG/B2500_04/CD13'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the received MQTT message. It then checks this content for the presence of specific text patterns (like 'b0=', 'b1=', up to 'bf='). For each pattern found, it publishes a corresponding MQTT discovery configuration message. This message instructs Home Assistant to create a new voltage sensor entity for a specific battery cell (e.g., 'B04E1 Zelle01'), using the data from the original message to extract the voltage value. After checking for all 16 possible cell patterns, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for a battery data message and automatically creates sensor entities in Home Assistant for up to 16 individual battery cells, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B04E2_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_04/CD13. CONDITIONS: None. ACTIONS: Store the message payload in a variable named payload. Then, for each of the following 16 independent checks, if the condition is met, publish a corresponding MQTT configuration message: If payload contains 'c0=', publish a sensor configuration for B04E2 Zelle01. If payload contains 'c1=', publish a sensor configuration for B04E2 Zelle02. If payload contains 'c2=', publish a sensor configuration for B04E2 Zelle03. If payload contains 'c3=', publish a sensor configuration for B04E2 Zelle04. If payload contains 'c4=', publish a sensor configuration for B04E2 Zelle05. If payload contains 'c5=', publish a sensor configuration for B04E2 Zelle06. If payload contains 'c6=', publish a sensor configuration for B04E2 Zelle07. If payload contains 'c7=', publish a sensor configuration for B04E2 Zelle08. If payload contains 'c8=', publish a sensor configuration for B04E2 Zelle09. If payload contains 'c9=', publish a sensor configuration for B04E2 Zelle10. If payload contains 'ca=', publish a sensor configuration for B04E2 Zelle11. If payload contains 'cb=', publish a sensor configuration for B04E2 Zelle12. If payload contains 'cc=', publish a sensor configuration for B04E2 Zelle13. If payload contains 'cd=', publish a sensor configuration for B04E2 Zelle14. If payload contains 'ce=', publish a sensor configuration for B04E2 Zelle15. If payload contains 'cf=', publish a sensor configuration for B04E2 Zelle16. Finally, turn off the automation B2500PKG B04E2 Voltage Discovery Automation [automation.b2500pkg_b04e2_voltage_discovery].",
"natural_language": {
"trigger": "The automation is triggered whenever a message is published to the MQTT topic 'B2500PKG/B2500_04/CD13'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the received MQTT message. It then checks the message for the presence of specific text strings (c0= through cf=). For each string found, it publishes a corresponding MQTT configuration message to Home Assistant's discovery topic. These configuration messages set up individual voltage sensors (named B04E2 Zelle01 through B04E2 Zelle16) that will report their state from the same triggering MQTT topic. After all potential sensor configurations are published, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for a specific MQTT message and uses its contents to automatically create and configure up to 16 voltage sensors for a battery pack, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B04_CD16_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_04/CD16. CONDITIONS: None. ACTIONS: Store the message payload in a variable. Then, for each of the following substrings present in the payload, publish a corresponding MQTT discovery configuration message: If 'm1=' is present, publish config for B04 PV1 Input Voltage [sensor.b2500_04_cd16m1]. If 'm2=' is present, publish config for B04 PV2 Input Voltage [sensor.b2500_04_cd16m2]. If 'i1=' is present, publish config for B04 Output1 Voltage [sensor.b2500_04_cd16i1]. If 'i2=' is present, publish config for B04 Output2 Voltage [sensor.b2500_04_cd16i2]. If 'c1=' is present, publish config for B04 PV1 Input Current [sensor.b2500_04_cd16c1]. If 'c2=' is present, publish config for B04 PV2 Input Current [sensor.b2500_04_cd16c2]. If 'c3=' is present, publish config for B04 Output1 Current [sensor.b2500_04_cd16c3]. If 'c4=' is present, publish config for B04 Output2 Current [sensor.b2500_04_cd16c4]. If 'bv=' is present, publish config for B04 Akku Voltage [sensor.b2500_04_cd16bv]. If 'bc=' is present, publish config for B04 Akku Current [sensor.b2500_04_cd16bc]. If 'bb=' is present, publish config for B04 Akku Power [sensor.b2500_04_cd16bb]. Finally, turn off the automation B2500PKG B04 CD16 Sensor Discovery Automation [automation.b2500pkg_b04_cd16_sensor_discovery].",
"natural_language": {
"trigger": "Whenever a message is published to the MQTT topic 'B2500PKG/B2500_04/CD16'.",
"conditions": "There are no conditions that must be met for the automation to run.",
"action": "The automation first saves the content of the received MQTT message. It then checks the message for specific data fields. For each field found (like 'm1=', 'm2=', 'i1=', etc.), it publishes a corresponding Home Assistant MQTT discovery configuration. This process creates sensors for various voltages, currents, and power readings from a device identified as B04. After publishing all relevant configurations, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for a data message from a device and automatically creates the necessary sensors in Home Assistant for monitoring its voltages, currents, and power, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B04_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_04/CD01. CONDITIONS: None. ACTIONS: Store the message payload in a variable named 'payload'. Then, for each of the following 55 key patterns, if the pattern is present in the payload, publish a corresponding MQTT discovery configuration message to the Home Assistant topic 'homeassistant/{sensor_type}/b2500_04/{entity_suffix}/config' with the retain flag set to true. The configuration defines a new sensor or binary sensor entity with a name, state topic, value template, unique ID, and other attributes. The key patterns and their corresponding entity details are: 'l0=' for binary sensors l0_bit0 (B04 Entladen), l0_bit1 (B04 Laden), l0_bit2 (B04 DOD erreicht), l0_bit3 (B04 Unterspannung); 'l1=' for binary sensors l1_bit0 (B04E2 Entladen), l1_bit1 (B04E2 Laden), l1_bit2 (B04E2 DOD erreicht), l1_bit3 (B04E2 Unterspannung), l1_bit4 (B04E1 Entladen), l1_bit5 (B04E1 Laden), l1_bit6 (B04E1 DOD erreicht), l1_bit7 (B04E1 Unterspannung); 'b1=' for binary sensor b1 (B04 E1 verbunden); 'b2=' for binary sensor b2 (B04 E2 verbunden); 'p1=' for sensor p1 (B04 Solar1 Input Status); 'p2=' for sensor p2 (B04 Solar2 Input Status); 'w1=' for sensor w1 (B04 PV1 Leistung); 'w2=' for sensor w2 (B04 PV2 Leistung); 'pe=' for sensor pe (B04 Batterie SOC); 'vv=' for sensor vv (B04 Geräteversion); 'sv=' for sensor sv (B04 Gerätesubversion); 'cs=' for sensor cs (B04 Ladeeinstellung); 'cd=' for sensor cd (B04 Entladeeinstellung); 'am=' for sensor am (B04 AM); 'o1=' for sensor o1 (B04 Output Status 1); 'o2=' for sensor o2 (B04 Output Status 2); 'do=' for sensor do (B04 DOD Entnehmbare Kapazität in %); 'lv=' for sensor lv (B04 Entladeschwelle); 'cj=' for sensor cj (B04 CJ Scene); 'kn=' for sensor kn (B04 Gesamtkapazität); 'g1=' for sensor g1 (B04 Output1 Leistung); 'g2=' for sensor g2 (B04 Output2 Leistung); 'tl=' for sensor tl (B04 Temperatur low); 'th=' for sensor th (B04 Temperatur high); 'tc=' for sensor tc (B04 Temperaturalarm (Laden)); 'tf=' for sensor tf (B04 Temperaturalarm (Entladen)); 'fc=' for sensor fc (B04 Chip Version); 'id=' for sensor id (B04 Geräte ID); 'a0=' for sensor a0 (B04 Ladezustand Hauptspeicher); 'a1=' for sensor a1 (B04 Ladezustand Erweiterung1); 'a2=' for sensor a2 (B04 Ladezustand Erweiterung2); 'e1=' for sensor e1 (B04 Timer1 Beginn); 'f1=' for sensor f1 (B04 Timer1 Ende); 'h1=' for sensor h1 (B04 Timer1 Ausgabeleistung); 'e2=' for sensor e2 (B04 Timer2 Beginn); 'f2=' for sensor f2 (B04 Timer2 Ende); 'h2=' for sensor h2 (B04 Timer2 Ausgabeleistung); 'e3=' for sensor e3 (B04 Timer3 Beginn); 'f3=' for sensor f3 (B04 Timer3 Ende); 'h3=' for sensor h3 (B04 Timer3 Ausgabeleistung); 'e4=' for sensor e4 (B04 Timer4 Beginn); 'f4=' for sensor f4 (B04 Timer4 Ende); 'h4=' for sensor h4 (B04 Timer4 Ausgabeleistung); 'e5=' for sensor e5 (B04 Timer5 Beginn); 'f5=' for sensor f5 (B04 Timer5 Ende); 'h5=' for sensor h5 (B04 Timer5 Ausgabeleistung); 'd1=' for binary sensor d1 (B04 Timer1 aktiv); 'd2=' for binary sensor d2 (B04 Timer2 aktiv); 'd3=' for binary sensor d3 (B04 Timer3 aktiv); 'd4=' for binary sensor d4 (B04 Timer4 aktiv); 'd5=' for binary sensor d5 (B04 Timer5 aktiv); 'bc=' for sensor bc (B04 Tägliche Battterieladung); 'bs=' for sensor bs (B04 Tägliche Batterieentladung); 'pt=' for sensor pt (B04 Tägliche PV Erzeugung); 'md=' for sensor md (B04 Entlademodus Timer/Selbstanpassung); 'sg=' for sensor sg (B04 CT Sensor verbunden); 'sp=' for sensor sp (B04 SP); 'st=' for sensor st (B04 ST); 'c0=' for sensor c0 (B04 CTCH Kanal); 'c1=' for sensor c1 (B04 Status CT); 'it=' for sensor it (B04 IT Tägliche abgegebene Leistung); 'm0=' for sensor m0 (B04 Leistungsmessung Phase1); 'm1=' for sensor m1 (B04 Leistungsmessung Phase2); 'm2=' for sensor m2 (B04 Leistungsmessung Phase3); 'm3=' for sensor m3 (B04 M3); 'lmo=' for sensor lmo (B04 LMO Nennausgangsleistung); 'lmi=' for sensor lmi (B04 LMI Nennaufnahmeleistung); 'lmf=' for sensor lmf (B04 LMF Gerätebeschränkung). Finally, turn off the automation B2500PKG B04 Sensor Discovery Automation [automation.b2500pkg_b04_sensor_discovery].",
"natural_language": {
"trigger": "The automation is triggered whenever an MQTT message arrives on the topic B2500PKG/B2500_04/CD01.",
"conditions": "There are no conditions that must be met; the actions run immediately after the trigger.",
"action": "The automation first saves the content of the incoming MQTT message into a variable called 'payload'. It then checks this payload for the presence of 55 different key patterns (like 'l0=', 'l1=', 'b1=', etc.). For each pattern found, it publishes a specific MQTT configuration message to Home Assistant's discovery topic. These configuration messages instruct Home Assistant to create and manage new sensor or binary sensor entities, each representing a specific piece of data from the B2500 device (e.g., battery status, power levels, temperatures, timer states, and diagnostic information). After publishing all applicable configurations, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for data from a B2500 device and automatically creates all the necessary sensors in Home Assistant to monitor its status, performance, and settings.",
"complexity": "high"
}
},
{
"id": "B2500PKG_B04_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_04/CD13. CONDITIONS: None. ACTIONS: Set variable 'payload' to the received MQTT payload. Then, for each of the 16 possible substrings (a0=, a1=, ..., af=), if the substring is present in the payload, publish a corresponding MQTT configuration message to create a voltage sensor entity for a battery cell (e.g., B04 Zelle01 [sensor.b2500_04_zelle01] for 'a0=', B04 Zelle02 [sensor.b2500_04_zelle02] for 'a1=', etc.). Finally, turn off the automation B2500PKG B04 Voltage Discovery Automation [automation.b2500pkg_b04_voltage_discovery].",
"natural_language": {
"trigger": "The automation is triggered whenever an MQTT message is published to the topic 'B2500PKG/B2500_04/CD13'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first stores the content of the received MQTT message. It then checks the message for the presence of specific identifiers (like 'a0=', 'a1=', up to 'af='). For each identifier found, it sends a new MQTT message to Home Assistant's discovery topic. This message contains the configuration to create a new voltage sensor for a specific battery cell, such as 'B04 Zelle01' or 'B04 Zelle02'. After processing all possible identifiers, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for a specific MQTT message from a battery pack and automatically creates Home Assistant sensors for each individual cell voltage it finds in the data.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B05E1_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_05/CD13. CONDITIONS: None. ACTIONS: Store the message payload in a variable named payload. Then, for each of the following 16 independent checks, if the substring 'b0=' through 'bf=' (inclusive) is present in the payload, publish a corresponding MQTT configuration message to the topic 'homeassistant/sensor/b2500_05/voltage_bX/config' (where X is the hex digit) to create a voltage sensor entity named 'B05E1 ZelleYY' (where YY is the cell number 01-16). Finally, turn off the automation B2500PKG B05E1 Voltage Discovery Automation [automation.b2500pkg_b05e1_voltage_discovery].",
"natural_language": {
"trigger": "The automation is triggered whenever a message is published to the MQTT topic 'B2500PKG/B2500_05/CD13'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the incoming MQTT message. It then checks the message for the presence of specific substrings ('b0=', 'b1=', ..., 'bf='). For each substring found, it publishes a new MQTT configuration message. Each configuration message instructs Home Assistant to create a new voltage sensor for a specific battery cell (named 'B05E1 Zelle01' through 'B05E1 Zelle16'), using the data from the original message. After all potential configuration messages are sent, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for a specific MQTT message and uses its data to automatically create up to 16 voltage sensor entities for a battery pack, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B05E2_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_05/CD13. CONDITIONS: None. ACTIONS: Store the message payload in a variable. Then, for each of the 16 possible cell identifiers (c0 to cf) in the payload, if the identifier is present, publish a corresponding MQTT configuration message to create a voltage sensor entity for that cell. Finally, turn off the automation B2500PKG B05E2 Voltage Discovery Automation [automation.b2500pkg_b05e2_voltage_discovery].",
"natural_language": {
"trigger": "The automation is triggered whenever a message is published to the MQTT topic 'B2500PKG/B2500_05/CD13'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the received MQTT message. It then checks the message for the presence of specific cell identifiers, ranging from 'c0' to 'cf'. For each identifier found, it sends a new MQTT message to the Home Assistant configuration topic. This message defines a new voltage sensor for a specific battery cell (e.g., 'B05E2 Zelle01' for 'c0'), instructing Home Assistant to create it. After processing all possible cells, the automation turns itself off to prevent further runs."
},
"human_like": "This automation listens for a battery data message and automatically creates the necessary sensor entities in Home Assistant for up to 16 battery cells, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B05_CD16_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_05/CD16. CONDITIONS: None. ACTIONS: Store the message payload in a variable named payload. Then, for each of the following key-value pairs present in the payload, publish a corresponding MQTT discovery configuration message: If 'm1=' is in payload, publish sensor config for B05 PV1 Input Voltage [sensor.b2500_05_cd16m1]. If 'm2=' is in payload, publish sensor config for B05 PV2 Input Voltage [sensor.b2500_05_cd16m2]. If 'i1=' is in payload, publish sensor config for B05 Output1 Voltage [sensor.b2500_05_cd16i1]. If 'i2=' is in payload, publish sensor config for B05 Output2 Voltage [sensor.b2500_05_cd16i2]. If 'c1=' is in payload, publish sensor config for B05 PV1 Input Current [sensor.b2500_05_cd16c1]. If 'c2=' is in payload, publish sensor config for B05 PV2 Input Current [sensor.b2500_05_cd16c2]. If 'c3=' is in payload, publish sensor config for B05 Output1 Current [sensor.b2500_05_cd16c3]. If 'c4=' is in payload, publish sensor config for B05 Output2 Current [sensor.b2500_05_cd16c4]. If 'bv=' is in payload, publish sensor config for B05 Akku Voltage [sensor.b2500_05_cd16bv]. If 'bc=' is in payload, publish sensor config for B05 Akku Current [sensor.b2500_05_cd16bc]. If 'bb=' is in payload, publish sensor config for B05 Akku Power [sensor.b2500_05_cd16bb]. Finally, turn off B2500PKG B05 CD16 Sensor Discovery Automation [automation.b2500pkg_b05_cd16_sensor_discovery].",
"natural_language": {
"trigger": "Whenever a message is published to the MQTT topic 'B2500PKG/B2500_05/CD16'.",
"conditions": "There are no conditions that must be met.",
"action": "The automation first saves the content of the received message. It then checks the message for specific data fields. For each field found (like 'm1=', 'm2=', 'i1=', etc.), it sends a corresponding MQTT configuration message to Home Assistant's discovery topic. This creates or updates sensors for PV input voltages, output voltages, input currents, output currents, battery voltage, battery current, and battery power. After processing all possible fields, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for data from a device and automatically creates the necessary sensors in Home Assistant for monitoring its solar and battery parameters, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B05_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_05/CD01. CONDITIONS: None. ACTIONS: Store the trigger payload in a variable named 'payload'. Then, for each of the following 73 key substrings present in the payload, publish a corresponding MQTT configuration message to the Home Assistant discovery topic. The keys and their corresponding sensor types and topics are: If 'l0=' is present, publish binary sensor configs for B05 Entladen, B05 Laden, B05 DOD erreicht, B05 Unterspannung. If 'l1=' is present, publish binary sensor configs for B05E2 Entladen, B05E2 Laden, B05E2 DOD erreicht, B05E2 Unterspannung, B05E1 Entladen, B05E1 Laden, B05E1 DOD erreicht, B05E1 Unterspannung. If 'b1=' is present, publish binary sensor config for B05 E1 verbunden. If 'b2=' is present, publish binary sensor config for B05 E2 verbunden. If 'p1=' is present, publish sensor config for B05 Solar1 Input Status. If 'p2=' is present, publish sensor config for B05 Solar2 Input Status. If 'w1=' is present, publish sensor config for B05 PV1 Leistung. If 'w2=' is present, publish sensor config for B05 PV2 Leistung. If 'pe=' is present, publish sensor config for B05 Batterie SOC. If 'vv=' is present, publish sensor config for B05 Geräteversion. If 'sv=' is present, publish sensor config for B05 Gerätesubversion. If 'cs=' is present, publish sensor config for B05 Ladeeinstellung. If 'cd=' is present, publish sensor config for B05 Entladeeinstellung. If 'am=' is present, publish sensor config for B05 AM. If 'o1=' is present, publish sensor config for B05 Output Status 1. If 'o2=' is present, publish sensor config for B05 Output Status 2. If 'do=' is present, publish sensor config for B05 DOD Entnehmbare Kapazität in %. If 'lv=' is present, publish sensor config for B05 Entladeschwelle. If 'cj=' is present, publish sensor config for B05 CJ Scene. If 'kn=' is present, publish sensor config for B05 Gesamtkapazität. If 'g1=' is present, publish sensor config for B05 Output1 Leistung. If 'g2=' is present, publish sensor config for B05 Output2 Leistung. If 'tl=' is present, publish sensor config for B05 Temperatur low. If 'th=' is present, publish sensor config for B05 Temperatur high. If 'tc=' is present, publish sensor config for B05 Temperaturalarm (Laden). If 'tf=' is present, publish sensor config for B05 Temperaturalarm (Entladen). If 'fc=' is present, publish sensor config for B05 Chip Version. If 'id=' is present, publish sensor config for B05 Geräte ID. If 'a0=' is present, publish sensor config for B05 Ladezustand Hauptspeicher. If 'a1=' is present, publish sensor config for B05 Ladezustand Erweiterung1. If 'a2=' is present, publish sensor config for B05 Ladezustand Erweiterung2. If 'e1=' is present, publish sensor config for B05 Timer1 Beginn. If 'f1=' is present, publish sensor config for B05 Timer1 Ende. If 'h1=' is present, publish sensor config for B05 Timer1 Ausgabeleistung. If 'e2=' is present, publish sensor config for B05 Timer2 Beginn. If 'f2=' is present, publish sensor config for B05 Timer2 Ende. If 'h2=' is present, publish sensor config for B05 Timer2 Ausgabeleistung. If 'e3=' is present, publish sensor config for B05 Timer3 Beginn. If 'f3=' is present, publish sensor config for B05 Timer3 Ende. If 'h3=' is present, publish sensor config for B05 Timer3 Ausgabeleistung. If 'e4=' is present, publish sensor config for B05 Timer4 Beginn. If 'f4=' is present, publish sensor config for B05 Timer4 Ende. If 'h4=' is present, publish sensor config for B05 Timer4 Ausgabeleistung. If 'e5=' is present, publish sensor config for B05 Timer5 Beginn. If 'f5=' is present, publish sensor config for B05 Timer5 Ende. If 'h5=' is present, publish sensor config for B05 Timer5 Ausgabeleistung. If 'd1=' is present, publish binary sensor config for B05 Timer1 aktiv. If 'd2=' is present, publish binary sensor config for B05 Timer2 aktiv. If 'd3=' is present, publish binary sensor config for B05 Timer3 aktiv. If 'd4=' is present, publish binary sensor config for B05 Timer4 aktiv. If 'd5=' is present, publish binary sensor config for B05 Timer5 aktiv. If 'bc=' is present, publish sensor config for B05 Tägliche Battterieladung. If 'bs=' is present, publish sensor config for B05 Tägliche Batterieentladung. If 'pt=' is present, publish sensor config for B05 Tägliche PV Erzeugung. If 'md=' is present, publish sensor config for B05 Entlademodus Timer/Selbstanpassung. If 'sg=' is present, publish sensor config for B05 CT Sensor verbunden. If 'sp=' is present, publish sensor config for B05 SP. If 'st=' is present, publish sensor config for B05 ST. If 'c0=' is present, publish sensor config for B05 CTCH Kanal. If 'c1=' is present, publish sensor config for B05 Status CT. If 'it=' is present, publish sensor config for B05 IT Tägliche abgegebene Leistung. If 'm0=' is present, publish sensor config for B05 Leistungsmessung Phase1. If 'm1=' is present, publish sensor config for B05 Leistungsmessung Phase2. If 'm2=' is present, publish sensor config for B05 Leistungsmessung Phase3. If 'm3=' is present, publish sensor config for B05 M3. If 'lmo=' is present, publish sensor config for B05 LMO Nennausgangsleistung. If 'lmi=' is present, publish sensor config for B05 LMI Nennaufnahmeleistung. If 'lmf=' is present, publish sensor config for B05 LMF Gerätebeschränkung. Finally, turn off the automation B2500PKG B05 Sensor Discovery Automation [automation.b2500pkg_b05_sensor_discovery].",
"natural_language": {
"trigger": "When a message is published to the MQTT topic 'B2500PKG/B2500_05/CD01'.",
"conditions": "There are no conditions; the automation runs every time the trigger occurs.",
"action": "The automation first saves the content of the received MQTT message. It then checks this message for the presence of 73 different key substrings (like 'l0=', 'l1=', 'b1=', etc.). For each key found, it publishes a specific MQTT configuration payload to the Home Assistant discovery topic. These configuration messages instruct Home Assistant to create and manage a wide array of sensors and binary sensors for a device identified as 'B2500_05'. The sensors cover operational status, power measurements, battery information, temperature, timers, and various diagnostic parameters. After publishing all relevant configurations, the automation turns itself off to prevent running again."
},
"human_like": "This automation automatically discovers and creates dozens of sensors for a B2500 device when it sends its first status message, then disables itself.",
"complexity": "high"
}
},
{
"id": "B2500PKG_B05_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_05/CD13. CONDITIONS: None. ACTIONS: Store the message payload in a variable. Then, for each of the 16 possible substrings (a0, a1, a2, a3, a4, a5, a6, a7, a8, a9, aa, ab, ac, ad, ae, af), if the substring is present in the payload, publish a corresponding MQTT configuration message to create a voltage sensor entity for a battery cell (e.g., B05 Zelle01 [sensor.b2500_05_zelle01] for a0). Finally, turn off this automation [automation.b2500pkg_b05_voltage_discovery].",
"natural_language": {
"trigger": "When an MQTT message is received on the topic 'B2500PKG/B2500_05/CD13'.",
"conditions": "There are no conditions that must be met.",
"action": "The automation first saves the content of the received MQTT message. It then checks this content for the presence of specific codes (a0 through af). For each code found, it sends a new MQTT configuration message to Home Assistant. Each configuration message instructs Home Assistant to create a new voltage sensor for a specific battery cell, with a name like 'B05 Zelle01' and a unique ID. After processing all possible codes, the automation turns itself off to prevent running again."
},
"human_like": "Automatically creates Home Assistant sensor entities for up to 16 battery cell voltages when a specific MQTT message is received, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B06E1_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_06/CD13. CONDITIONS: None. ACTIONS: Store the message payload in a variable named payload. Then, for each of the following 16 conditions, if the condition is true, publish a corresponding MQTT configuration message. The conditions check for specific substrings in the payload: if 'b0=' is present, publish a config for B06E1 Zelle01; if 'b1=' is present, publish a config for B06E1 Zelle02; if 'b2=' is present, publish a config for B06E1 Zelle03; if 'b3=' is present, publish a config for B06E1 Zelle04; if 'b4=' is present, publish a config for B06E1 Zelle05; if 'b5=' is present, publish a config for B06E1 Zelle06; if 'b6=' is present, publish a config for B06E1 Zelle07; if 'b7=' is present, publish a config for B06E1 Zelle08; if 'b8=' is present, publish a config for B06E1 Zelle09; if 'b9=' is present, publish a config for B06E1 Zelle10; if 'ba=' is present, publish a config for B06E1 Zelle11; if 'bb=' is present, publish a config for B06E1 Zelle12; if 'bc=' is present, publish a config for B06E1 Zelle13; if 'bd=' is present, publish a config for B06E1 Zelle14; if 'be=' is present, publish a config for B06E1 Zelle15; if 'bf=' is present, publish a config for B06E1 Zelle16. Finally, turn off the automation B2500PKG B06E1 Voltage Discovery Automation [automation.b2500pkg_b06e1_voltage_discovery].",
"natural_language": {
"trigger": "Whenever a message is published to the MQTT topic 'B2500PKG/B2500_06/CD13'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the received MQTT message. It then checks the saved message for the presence of specific text patterns (like 'b0=', 'b1=', etc.). For each pattern found, it publishes a new MQTT message to a specific configuration topic. These configuration messages are used to create or update Home Assistant sensors for individual battery cells (named B06E1 Zelle01 through B06E1 Zelle16), setting them up to report voltage in millivolts. After all potential configuration messages are sent, the automation turns itself off."
},
"human_like": "This automation listens for a specific MQTT message and uses its data to automatically create sensor entities for up to 16 battery cell voltages, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B06E2_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_06/CD13. CONDITIONS: None. ACTIONS: Set variable 'payload' to the trigger payload. Then, for each of the 16 possible cell voltage substrings (c0= to cf=), if the substring is present in the payload, publish a corresponding MQTT configuration message to a specific topic (homeassistant/sensor/b2500_06/voltage_cX/config) to create a sensor entity for that cell. Finally, turn off the automation B2500PKG B06E2 Voltage Discovery Automation [automation.b2500pkg_b06e2_voltage_discovery].",
"natural_language": {
"trigger": "When an MQTT message arrives on the topic B2500PKG/B2500_06/CD13.",
"conditions": "There are no conditions that must be met.",
"action": "The automation first stores the content of the received message. It then checks the message for the presence of specific substrings (c0=, c1=, ..., cf=). For each substring found, it sends a new MQTT message to a specific configuration topic. This MQTT message contains the setup instructions for a new voltage sensor entity in Home Assistant, corresponding to a specific battery cell. After processing all possible cells, the automation turns itself off."
},
"human_like": "This automation listens for a specific MQTT message and uses its data to automatically create sensor entities for monitoring individual battery cell voltages, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B06_CD16_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_06/CD16. CONDITIONS: None. ACTIONS: Store the message payload in a variable named payload. Then, for each of the following key-value pairs, if the key is present in the payload, publish a corresponding MQTT discovery configuration message: If 'm1=' is present, publish sensor config for B06 PV1 Input Voltage [sensor.b2500_06_cd16m1]. If 'm2=' is present, publish sensor config for B06 PV2 Input Voltage [sensor.b2500_06_cd16m2]. If 'i1=' is present, publish sensor config for B06 Output1 Voltage [sensor.b2500_06_cd16i1]. If 'i2=' is present, publish sensor config for B06 Output2 Voltage [sensor.b2500_06_cd16i2]. If 'c1=' is present, publish sensor config for B06 PV1 Input Current [sensor.b2500_06_cd16c1]. If 'c2=' is present, publish sensor config for B06 PV2 Input Current [sensor.b2500_06_cd16c2]. If 'c3=' is present, publish sensor config for B06 Output1 Current [sensor.b2500_06_cd16c3]. If 'c4=' is present, publish sensor config for B06 Output2 Current [sensor.b2500_06_cd16c4]. If 'bv=' is present, publish sensor config for B06 Akku Voltage [sensor.b2500_06_cd16bv]. If 'bc=' is present, publish sensor config for B06 Akku Current [sensor.b2500_06_cd16bc]. If 'bb=' is present, publish sensor config for B06 Akku Power [sensor.b2500_06_cd16bb]. Finally, turn off B2500PKG B06 CD16 Sensor Discovery Automation [automation.b2500pkg_b06_cd16_sensor_discovery].",
"natural_language": {
"trigger": "Whenever an MQTT message arrives on the topic 'B2500PKG/B2500_06/CD16'.",
"conditions": "There are no conditions that must be met.",
"action": "The automation first saves the content of the message into a variable. It then checks the message for the presence of specific data keys. For each key found, it publishes a corresponding Home Assistant MQTT discovery configuration message to create a sensor entity. The keys and their associated sensors are: 'm1=' for B06 PV1 Input Voltage [sensor.b2500_06_cd16m1], 'm2=' for B06 PV2 Input Voltage [sensor.b2500_06_cd16m2], 'i1=' for B06 Output1 Voltage [sensor.b2500_06_cd16i1], 'i2=' for B06 Output2 Voltage [sensor.b2500_06_cd16i2], 'c1=' for B06 PV1 Input Current [sensor.b2500_06_cd16c1], 'c2=' for B06 PV2 Input Current [sensor.b2500_06_cd16c2], 'c3=' for B06 Output1 Current [sensor.b2500_06_cd16c3], 'c4=' for B06 Output2 Current [sensor.b2500_06_cd16c4], 'bv=' for B06 Akku Voltage [sensor.b2500_06_cd16bv], 'bc=' for B06 Akku Current [sensor.b2500_06_cd16bc], and 'bb=' for B06 Akku Power [sensor.b2500_06_cd16bb]. After processing all possible keys, the automation turns itself off to prevent further runs."
},
"human_like": "This automation listens for a data message from a device and automatically creates the necessary sensor entities in Home Assistant based on the data fields present, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B06_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_06/CD01. CONDITIONS: None. ACTIONS: Store the message payload in variable 'payload'. Then, for each of the following 62 distinct key patterns, if the pattern is found in the payload, publish a corresponding MQTT configuration message to the Home Assistant discovery topic. The patterns and their associated configuration topics are: 'l0=' -> homeassistant/binary_sensor/b2500_06/l0_bit0/config, homeassistant/binary_sensor/b2500_06/l0_bit1/config, homeassistant/binary_sensor/b2500_06/l0_bit2/config, homeassistant/binary_sensor/b2500_06/l0_bit3/config; 'l1=' -> homeassistant/binary_sensor/b2500_06/l1_bit0/config, homeassistant/binary_sensor/b2500_06/l1_bit1/config, homeassistant/binary_sensor/b2500_06/l1_bit2/config, homeassistant/binary_sensor/b2500_06/l1_bit3/config, homeassistant/binary_sensor/b2500_06/l1_bit4/config, homeassistant/binary_sensor/b2500_06/l1_bit5/config, homeassistant/binary_sensor/b2500_06/l1_bit6/config, homeassistant/binary_sensor/b2500_06/l1_bit7/config; 'b1=' -> homeassistant/binary_sensor/b2500_06/b1/config; 'b2=' -> homeassistant/binary_sensor/b2500_06/b2/config; 'p1=' -> homeassistant/sensor/b2500_06/p1/config; 'p2=' -> homeassistant/sensor/b2500_06/p2/config; 'w1=' -> homeassistant/sensor/b2500_06/w1/config; 'w2=' -> homeassistant/sensor/b2500_06/w2/config; 'pe=' -> homeassistant/sensor/b2500_06/pe/config; 'vv=' -> homeassistant/sensor/b2500_06/vv/config; 'sv=' -> homeassistant/sensor/b2500_06/sv/config; 'cs=' -> homeassistant/sensor/b2500_06/cs/config; 'cd=' -> homeassistant/sensor/b2500_06/cd/config; 'am=' -> homeassistant/sensor/b2500_06/am/config; 'o1=' -> homeassistant/sensor/b2500_06/o1/config; 'o2=' -> homeassistant/sensor/b2500_06/o2/config; 'do=' -> homeassistant/sensor/b2500_06/do/config; 'lv=' -> homeassistant/sensor/b2500_06/lv/config; 'cj=' -> homeassistant/sensor/b2500_06/cj/config; 'kn=' -> homeassistant/sensor/b2500_06/kn/config; 'g1=' -> homeassistant/sensor/b2500_06/g1/config; 'g2=' -> homeassistant/sensor/b2500_06/g2/config; 'tl=' -> homeassistant/sensor/b2500_06/tl/config; 'th=' -> homeassistant/sensor/b2500_06/th/config; 'tc=' -> homeassistant/sensor/b2500_06/tc/config; 'tf=' -> homeassistant/sensor/b2500_06/tf/config; 'fc=' -> homeassistant/sensor/b2500_06/fc/config; 'id=' -> homeassistant/sensor/b2500_06/id/config; 'a0=' -> homeassistant/sensor/b2500_06/a0/config; 'a1=' -> homeassistant/sensor/b2500_06/a1/config; 'a2=' -> homeassistant/sensor/b2500_06/a2/config; 'e1=' -> homeassistant/sensor/b2500_06/e1/config; 'f1=' -> homeassistant/sensor/b2500_06/f1/config; 'h1=' -> homeassistant/sensor/b2500_06/h1/config; 'e2=' -> homeassistant/sensor/b2500_06/e2/config; 'f2=' -> homeassistant/sensor/b2500_06/f2/config; 'h2=' -> homeassistant/sensor/b2500_06/h2/config; 'e3=' -> homeassistant/sensor/b2500_06/e3/config; 'f3=' -> homeassistant/sensor/b2500_06/f3/config; 'h3=' -> homeassistant/sensor/b2500_06/h3/config; 'e4=' -> homeassistant/sensor/b2500_06/e4/config; 'f4=' -> homeassistant/sensor/b2500_06/f4/config; 'h4=' -> homeassistant/sensor/b2500_06/h4/config; 'e5=' -> homeassistant/sensor/b2500_06/e5/config; 'f5=' -> homeassistant/sensor/b2500_06/f5/config; 'h5=' -> homeassistant/sensor/b2500_06/h5/config; 'd1=' -> homeassistant/binary_sensor/b2500_06/d1/config; 'd2=' -> homeassistant/binary_sensor/b2500_06/d2/config; 'd3=' -> homeassistant/binary_sensor/b2500_06/d3/config; 'd4=' -> homeassistant/binary_sensor/b2500_06/d4/config; 'd5=' -> homeassistant/binary_sensor/b2500_06/d5/config; 'bc=' -> homeassistant/sensor/b2500_06/bc/config; 'bs=' -> homeassistant/sensor/b2500_06/bs/config; 'pt=' -> homeassistant/sensor/b2500_06/pt/config; 'md=' -> homeassistant/sensor/b2500_06/md/config; 'sg=' -> homeassistant/sensor/b2500_06/sg/config; 'sp=' -> homeassistant/sensor/b2500_06/sp/config; 'st=' -> homeassistant/sensor/b2500_06/st/config; 'c0=' -> homeassistant/sensor/b2500_06/c0/config; 'c1=' -> homeassistant/sensor/b2500_06/c1/config; 'it=' -> homeassistant/sensor/b2500_06/it/config; 'm0=' -> homeassistant/sensor/b2500_06/m0/config; 'm1=' -> homeassistant/sensor/b2500_06/m1/config; 'm2=' -> homeassistant/sensor/b2500_06/m2/config; 'm3=' -> homeassistant/sensor/b2500_06/m3/config; 'lmo=' -> homeassistant/sensor/b2500_06/lmo/config; 'lmi=' -> homeassistant/sensor/b2500_06/lmi/config; 'lmf=' -> homeassistant/sensor/b2500_06/lmf/config. Finally, turn off the automation B2500PKG B06 Sensor Discovery Automation [automation.b2500pkg_b06_sensor_discovery].",
"natural_language": {
"trigger": "When a message is published to the MQTT topic 'B2500PKG/B2500_06/CD01'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the received message into a variable. It then checks the message for the presence of 62 specific data field identifiers (like 'l0=', 'b1=', 'pe='). For each identifier found, it publishes a corresponding MQTT configuration message to Home Assistant's discovery topics. These configuration messages define a wide range of sensors and binary sensors for a device labeled 'B06', covering status, power, energy, temperature, timers, and system information. After all potential configuration messages are sent, the automation turns itself off to prevent running again."
},
"human_like": "This automation automatically discovers and creates a comprehensive set of sensors for a B2500PKG B06 device when it first sends data via MQTT, then disables itself.",
"complexity": "high"
}
},
{
"id": "B2500PKG_B06_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_06/CD13. CONDITIONS: None. ACTIONS: Store the message payload in a variable named payload. Then, for each of the following 16 conditions, if the condition is met, publish a specific MQTT configuration message: IF (payload contains 'a0=') THEN publish sensor config for B06 Zelle01 [sensor.b2500_06_zelle01]. IF (payload contains 'a1=') THEN publish sensor config for B06 Zelle02 [sensor.b2500_06_zelle02]. IF (payload contains 'a2=') THEN publish sensor config for B06 Zelle03 [sensor.b2500_06_zelle03]. IF (payload contains 'a3=') THEN publish sensor config for B06 Zelle04 [sensor.b2500_06_zelle04]. IF (payload contains 'a4=') THEN publish sensor config for B06 Zelle05 [sensor.b2500_06_zelle05]. IF (payload contains 'a5=') THEN publish sensor config for B06 Zelle06 [sensor.b2500_06_zelle06]. IF (payload contains 'a6=') THEN publish sensor config for B06 Zelle07 [sensor.b2500_06_zelle07]. IF (payload contains 'a7=') THEN publish sensor config for B06 Zelle08 [sensor.b2500_06_zelle08]. IF (payload contains 'a8=') THEN publish sensor config for B06 Zelle09 [sensor.b2500_06_zelle09]. IF (payload contains 'a9=') THEN publish sensor config for B06 Zelle10 [sensor.b2500_06_zelle10]. IF (payload contains 'aa=') THEN publish sensor config for B06 Zelle11 [sensor.b2500_06_zelle11]. IF (payload contains 'ab=') THEN publish sensor config for B06 Zelle12 [sensor.b2500_06_zelle12]. IF (payload contains 'ac=') THEN publish sensor config for B06 Zelle13 [sensor.b2500_06_zelle13]. IF (payload contains 'ad=') THEN publish sensor config for B06 Zelle14 [sensor.b2500_06_zelle14]. IF (payload contains 'ae=') THEN publish sensor config for B06 Zelle15 [sensor.b2500_06_zelle15]. IF (payload contains 'af=') THEN publish sensor config for B06 Zelle16 [sensor.b2500_06_zelle16]. Finally, turn off the automation itself, B2500PKG B06 Voltage Discovery Automation [automation.b2500pkg_b06_voltage_discovery].",
"natural_language": {
"trigger": "The automation is triggered whenever a message is published to the MQTT topic 'B2500PKG/B2500_06/CD13'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the received MQTT message. It then checks this content for the presence of specific strings, each representing a different cell voltage reading (from 'a0=' to 'af='). For each string found, it publishes a corresponding MQTT configuration message to Home Assistant's discovery topic. This creates a new voltage sensor entity for that specific battery cell, with a name like 'B06 Zelle01' and a unique ID. After processing all possible cell readings, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for a battery data message and automatically creates Home Assistant sensor entities for up to 16 individual battery cell voltages, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B07E1_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_07/CD13. CONDITIONS: None. ACTIONS: Store the message payload in a variable named payload. Then, for each of the following 16 conditions, if the substring is found in the payload, publish a corresponding MQTT configuration message to create a voltage sensor entity. The conditions and their corresponding configuration topics are: if 'b0=' in payload then publish to homeassistant/sensor/b2500_07/voltage_b0/config; if 'b1=' in payload then publish to homeassistant/sensor/b2500_07/voltage_b1/config; if 'b2=' in payload then publish to homeassistant/sensor/b2500_07/voltage_b2/config; if 'b3=' in payload then publish to homeassistant/sensor/b2500_07/voltage_b3/config; if 'b4=' in payload then publish to homeassistant/sensor/b2500_07/voltage_b4/config; if 'b5=' in payload then publish to homeassistant/sensor/b2500_07/voltage_b5/config; if 'b6=' in payload then publish to homeassistant/sensor/b2500_07/voltage_b6/config; if 'b7=' in payload then publish to homeassistant/sensor/b2500_07/voltage_b7/config; if 'b8=' in payload then publish to homeassistant/sensor/b2500_07/voltage_b8/config; if 'b9=' in payload then publish to homeassistant/sensor/b2500_07/voltage_b9/config; if 'ba=' in payload then publish to homeassistant/sensor/b2500_07/voltage_ba/config; if 'bb=' in payload then publish to homeassistant/sensor/b2500_07/voltage_bb/config; if 'bc=' in payload then publish to homeassistant/sensor/b2500_07/voltage_bc/config; if 'bd=' in payload then publish to homeassistant/sensor/b2500_07/voltage_bd/config; if 'be=' in payload then publish to homeassistant/sensor/b2500_07/voltage_be/config; if 'bf=' in payload then publish to homeassistant/sensor/b2500_07/voltage_bf/config. Finally, turn off B2500PKG B07E1 Voltage Discovery Automation [automation.b2500pkg_b07e1_voltage_discovery].",
"natural_language": {
"trigger": "When a message is published to the MQTT topic 'B2500PKG/B2500_07/CD13'.",
"conditions": "There are no conditions that must be met for the automation to run.",
"action": "The automation first stores the content of the received MQTT message. It then checks the message for the presence of specific substrings ('b0=', 'b1=', up to 'bf='). For each substring found, it publishes a corresponding MQTT configuration message to a specific topic. These configuration messages are used to create individual voltage sensor entities in Home Assistant for up to 16 battery cells (named B07E1 Zelle01 through B07E1 Zelle16). After performing all these checks and potential publications, the automation turns itself off."
},
"human_like": "This automation listens for a specific MQTT message and uses its content to automatically create sensor entities for monitoring the voltage of up to 16 battery cells, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B07E2_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_07/CD13. CONDITIONS: None. ACTIONS: Store the message payload in a variable named payload. Then, for each cell number from 0 to 15 (represented by hex digits c0 to cf), if the payload contains the corresponding substring (e.g., 'c0='), publish a specific MQTT configuration message to the topic homeassistant/sensor/b2500_07/voltage_cX/config (where X is the hex digit) to create a voltage sensor entity for that cell. Finally, turn off the automation B2500PKG B07E2 Voltage Discovery Automation [automation.b2500pkg_b07e2_voltage_discovery].",
"natural_language": {
"trigger": "When a message is published to the MQTT topic 'B2500PKG/B2500_07/CD13'.",
"conditions": "There are no conditions that must be met.",
"action": "The automation saves the content of the incoming message. It then checks the content for specific markers (like 'c0=', 'c1=', up to 'cf='). For each marker found, it sends a new MQTT message. This new message is a configuration payload that tells Home Assistant to create a new sensor for a battery cell voltage. It creates sensors named 'B07E2 Zelle01' through 'B07E2 Zelle16' as needed. After processing the message, the automation turns itself off."
},
"human_like": "This automation listens for a data message and uses it to automatically create sensors for up to 16 battery cell voltages, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B07_CD16_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_07/CD16. CONDITIONS: None. ACTIONS: Store the message payload in a variable. Then, for each of the following substrings present in the payload, publish a corresponding MQTT discovery configuration message: If 'm1=' is present, publish config for B07 PV1 Input Voltage [sensor.b2500_07_cd16m1]. If 'm2=' is present, publish config for B07 PV2 Input Voltage [sensor.b2500_07_cd16m2]. If 'i1=' is present, publish config for B07 Output1 Voltage [sensor.b2500_07_cd16i1]. If 'i2=' is present, publish config for B07 Output2 Voltage [sensor.b2500_07_cd16i2]. If 'c1=' is present, publish config for B07 PV1 Input Current [sensor.b2500_07_cd16c1]. If 'c2=' is present, publish config for B07 PV2 Input Current [sensor.b2500_07_cd16c2]. If 'c3=' is present, publish config for B07 Output1 Current [sensor.b2500_07_cd16c3]. If 'c4=' is present, publish config for B07 Output2 Current [sensor.b2500_07_cd16c4]. If 'bv=' is present, publish config for B07 Akku Voltage [sensor.b2500_07_cd16bv]. If 'bc=' is present, publish config for B07 Akku Current [sensor.b2500_07_cd16bc]. If 'bb=' is present, publish config for B07 Akku Power [sensor.b2500_07_cd16bb]. Finally, turn off B2500PKG B07 CD16 Sensor Discovery Automation [automation.b2500pkg_b07_cd16_sensor_discovery].",
"natural_language": {
"trigger": "When an MQTT message arrives on the topic 'B2500PKG/B2500_07/CD16'.",
"conditions": "There are no conditions; the actions run immediately after the trigger.",
"action": "The automation first saves the message payload. It then checks the payload for specific key patterns. For each pattern found, it publishes a corresponding MQTT discovery configuration message to Home Assistant. This creates sensors for various voltage, current, and power readings from a device identified as 'B07'. The patterns and their corresponding sensors are: 'm1=' creates B07 PV1 Input Voltage [sensor.b2500_07_cd16m1]; 'm2=' creates B07 PV2 Input Voltage [sensor.b2500_07_cd16m2]; 'i1=' creates B07 Output1 Voltage [sensor.b2500_07_cd16i1]; 'i2=' creates B07 Output2 Voltage [sensor.b2500_07_cd16i2]; 'c1=' creates B07 PV1 Input Current [sensor.b2500_07_cd16c1]; 'c2=' creates B07 PV2 Input Current [sensor.b2500_07_cd16c2]; 'c3=' creates B07 Output1 Current [sensor.b2500_07_cd16c3]; 'c4=' creates B07 Output2 Current [sensor.b2500_07_cd16c4]; 'bv=' creates B07 Akku Voltage [sensor.b2500_07_cd16bv]; 'bc=' creates B07 Akku Current [sensor.b2500_07_cd16bc]; 'bb=' creates B07 Akku Power [sensor.b2500_07_cd16bb]. After all potential discovery messages are sent, the automation turns itself off."
},
"human_like": "This automation listens for a data message from a device and automatically creates the necessary sensors in Home Assistant for monitoring its voltage, current, and power, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B07_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_07/CD01. CONDITIONS: None. ACTIONS: Store the message payload in a variable named 'payload'. Then, for each of the following 70 conditional checks, if the specified substring is present in the payload, publish a corresponding MQTT configuration message to the Home Assistant discovery topic. The configuration messages define binary sensors and sensors for various device parameters (e.g., charging/discharging status, battery state of charge, power readings, temperatures, timers, energy totals, and device information). After all conditional actions are processed, turn off the automation B2500PKG B07 Sensor Discovery Automation [automation.b2500pkg_b07_sensor_discovery].",
"natural_language": {
"trigger": "The automation is triggered whenever a new message arrives on the MQTT topic 'B2500PKG/B2500_07/CD01'.",
"conditions": "There are no conditions that must be met; the actions run immediately after the trigger.",
"action": "The automation first saves the content of the incoming MQTT message. It then checks this content for the presence of over 70 different keywords (like 'l0=', 'l1=', 'b1=', 'pe=', etc.). For each keyword found, it publishes a specific configuration payload to a corresponding Home Assistant MQTT discovery topic. These configurations create and set up entities (binary sensors and sensors) in Home Assistant to monitor the B2500 device's status, including battery details, solar input, power output, temperatures, timer schedules, and daily energy statistics. Finally, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for data from a B2500 device and automatically creates all the necessary sensors in Home Assistant to monitor its battery, solar, and power status.",
"complexity": "high"
}
},
{
"id": "B2500PKG_B07_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_07/CD13. CONDITIONS: None. ACTIONS: Set variable 'payload' to the trigger payload. Then, for each of the 16 possible substrings ('a0=' through 'af='), if the substring is present in the payload, publish a specific MQTT configuration message to the corresponding topic (homeassistant/sensor/b2500_07/voltage_[key]/config) to create a voltage sensor entity for a battery cell. Finally, turn off the automation B2500PKG B07 Voltage Discovery Automation [automation.b2500pkg_b07_voltage_discovery].",
"natural_language": {
"trigger": "When a message arrives on the MQTT topic B2500PKG/B2500_07/CD13.",
"conditions": "There are no conditions that must be met.",
"action": "The automation first stores the incoming message content. It then checks the message for up to 16 different voltage data markers (a0= through af=). For each marker found, it sends a configuration message via MQTT to Home Assistant to create a corresponding voltage sensor for a battery cell (e.g., B07 Zelle01, B07 Zelle02, etc.). After processing the message, the automation turns itself off to prevent further runs."
},
"human_like": "This automation listens for a specific MQTT message and uses its data to automatically create sensor entities for monitoring individual battery cell voltages.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B08E1_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_08/CD13. CONDITIONS: None. ACTIONS: Store the message payload in variable 'payload'. Then, for each possible substring 'b0=' through 'bf=' (representing 16 cells), IF the substring is present in the payload, publish a corresponding MQTT configuration message to create a voltage sensor entity for that cell. After processing all possible cells, turn off the automation B2500PKG B08E1 Voltage Discovery Automation [automation.b2500pkg_b08e1_voltage_discovery].",
"natural_language": {
"trigger": "Whenever a message is published to the MQTT topic 'B2500PKG/B2500_08/CD13'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the received MQTT message. It then checks this content for the presence of specific identifiers ('b0=', 'b1=', up to 'bf='). For each identifier found, it publishes a new MQTT configuration message. Each configuration message instructs Home Assistant to create a new voltage sensor for a specific battery cell (e.g., 'B08E1 Zelle01'), using the data from the original message to extract the cell's voltage. Finally, the automation turns itself off to prevent it from running again."
},
"human_like": "This automation listens for a specific MQTT message and uses its data to automatically create and configure 16 voltage sensors for a battery pack, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B08E2_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_08/CD13. CONDITIONS: None. ACTIONS: Store the message payload in variable 'payload'. Then, for each of the 16 possible cell identifiers (c0 to cf), if the identifier string (e.g., 'c0=') is present in the payload, publish a corresponding MQTT configuration message to the topic homeassistant/sensor/b2500_08/voltage_[identifier]/config. Each configuration message defines a voltage sensor entity (e.g., B08E2 Zelle01 [sensor.b2500_08_extern2_zelle01]) with a value_template that extracts the voltage value from the payload. Finally, turn off this automation [automation.b2500pkg_b08e2_voltage_discovery].",
"natural_language": {
"trigger": "When a message is published to the MQTT topic 'B2500PKG/B2500_08/CD13'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the received message. It then checks the saved content for the presence of specific cell identifier strings, ranging from 'c0=' to 'cf='. For each identifier found, it publishes a new MQTT configuration message. This configuration message sets up a new voltage sensor in Home Assistant, such as B08E2 Zelle01 [sensor.b2500_08_extern2_zelle01], instructing it to listen to the same incoming topic and extract its specific voltage value. After processing all possible identifiers, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for a specific MQTT message and uses its data to automatically create and configure up to 16 voltage sensor entities in Home Assistant for battery cell monitoring.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B08_CD16_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_08/CD16. CONDITIONS: None. ACTIONS: Set variable 'payload' to the trigger payload. Then, for each of the following substrings present in the payload, publish a corresponding MQTT discovery configuration: If 'm1=' is present, publish config for B08 PV1 Input Voltage [sensor.b2500_08_cd16m1]. If 'm2=' is present, publish config for B08 PV2 Input Voltage [sensor.b2500_08_cd16m2]. If 'i1=' is present, publish config for B08 Output1 Voltage [sensor.b2500_08_cd16i1]. If 'i2=' is present, publish config for B08 Output2 Voltage [sensor.b2500_08_cd16i2]. If 'c1=' is present, publish config for B08 PV1 Input Current [sensor.b2500_08_cd16c1]. If 'c2=' is present, publish config for B08 PV2 Input Current [sensor.b2500_08_cd16c2]. If 'c3=' is present, publish config for B08 Output1 Current [sensor.b2500_08_cd16c3]. If 'c4=' is present, publish config for B08 Output2 Current [sensor.b2500_08_cd16c4]. If 'bv=' is present, publish config for B08 Akku Voltage [sensor.b2500_08_cd16bv]. If 'bc=' is present, publish config for B08 Akku Current [sensor.b2500_08_cd16bc]. If 'bb=' is present, publish config for B08 Akku Power [sensor.b2500_08_cd16bb]. Finally, turn off B2500PKG B08 CD16 Sensor Discovery Automation [automation.b2500pkg_b08_cd16_sensor_discovery].",
"natural_language": {
"trigger": "Whenever a new message is published to the MQTT topic 'B2500PKG/B2500_08/CD16'.",
"conditions": "There are no conditions; the automation runs every time the trigger occurs.",
"action": "The automation first stores the incoming message content. It then checks the message for specific data fields. For each field found (like 'm1=', 'm2=', 'i1=', etc.), it publishes a corresponding MQTT discovery configuration message to Home Assistant. These messages are designed to create or update sensors for various voltage, current, and power readings from a device labeled 'B08'. After publishing all relevant discovery messages, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for data from a device and automatically creates the necessary sensors in Home Assistant for monitoring its voltage, current, and power, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B08_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_08/CD01. CONDITIONS: None. ACTIONS: Store the message payload in a variable named 'payload'. Then, for each of the following 60 conditional checks, if the specified substring is present in the 'payload' variable, publish a corresponding MQTT configuration message (with retain flag true) to a specific Home Assistant discovery topic. The configuration messages define binary sensors and sensors for various device parameters (e.g., charging/discharging status, power levels, temperatures, timers, energy totals, device info). After all conditional actions, turn off the automation B2500PKG B08 Sensor Discovery Automation [automation.b2500pkg_b08_sensor_discovery].",
"natural_language": {
"trigger": "Whenever a message is published to the MQTT topic 'B2500PKG/B2500_08/CD01'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the received MQTT message. It then checks this content for the presence of over 60 different key substrings (like 'l0=', 'l1=', 'b1=', 'pe=', etc.). For each key found, it publishes a specific configuration payload to a corresponding Home Assistant MQTT discovery topic. These configurations automatically create entities in Home Assistant to monitor the battery system's status, including charging states, power input/output, temperatures, timer settings, daily energy statistics, and device information. Finally, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for a data message from a battery system and uses it to automatically set up all the monitoring sensors in Home Assistant, then disables itself.",
"complexity": "high"
}
},
{
"id": "B2500PKG_B08_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_08/CD13. CONDITIONS: None. ACTIONS: Set variable 'payload' to the received MQTT payload. Then, for each of the following 16 independent checks, if the condition is true, publish a corresponding MQTT configuration message: IF ('a0=' in payload) THEN publish sensor config for B08 Zelle01. IF ('a1=' in payload) THEN publish sensor config for B08 Zelle02. IF ('a2=' in payload) THEN publish sensor config for B08 Zelle03. IF ('a3=' in payload) THEN publish sensor config for B08 Zelle04. IF ('a4=' in payload) THEN publish sensor config for B08 Zelle05. IF ('a5=' in payload) THEN publish sensor config for B08 Zelle06. IF ('a6=' in payload) THEN publish sensor config for B08 Zelle07. IF ('a7=' in payload) THEN publish sensor config for B08 Zelle08. IF ('a8=' in payload) THEN publish sensor config for B08 Zelle09. IF ('a9=' in payload) THEN publish sensor config for B08 Zelle10. IF ('aa=' in payload) THEN publish sensor config for B08 Zelle11. IF ('ab=' in payload) THEN publish sensor config for B08 Zelle12. IF ('ac=' in payload) THEN publish sensor config for B08 Zelle13. IF ('ad=' in payload) THEN publish sensor config for B08 Zelle14. IF ('ae=' in payload) THEN publish sensor config for B08 Zelle15. IF ('af=' in payload) THEN publish sensor config for B08 Zelle16. Finally, turn off B2500PKG B08 Voltage Discovery Automation [automation.b2500pkg_b08_voltage_discovery].",
"natural_language": {
"trigger": "Whenever a message is published to the MQTT topic 'B2500PKG/B2500_08/CD13'.",
"conditions": "There are no conditions that must be met for the automation to proceed.",
"action": "The automation first stores the content of the received MQTT message. It then checks this content for the presence of specific substrings ('a0=' through 'af='). For each substring found, it publishes a corresponding MQTT configuration message to Home Assistant's discovery topic. These configuration messages set up voltage sensors (named B08 Zelle01 through B08 Zelle16) that will read their state from the same incoming MQTT topic. After performing all these checks and potential publications, the automation turns itself off to prevent running again."
},
"human_like": "Automatically creates and configures up to 16 battery cell voltage sensors in Home Assistant when a specific data message is received, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B09E1_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_09/CD13. CONDITIONS: None. ACTIONS: Store the message payload in variable 'payload'. Then, for each of the following 16 independent checks, if the condition is true, publish a corresponding MQTT configuration message. The checks are: IF 'b0=' is in payload THEN publish sensor config for B09E1 Zelle01; IF 'b1=' is in payload THEN publish sensor config for B09E1 Zelle02; IF 'b2=' is in payload THEN publish sensor config for B09E1 Zelle03; IF 'b3=' is in payload THEN publish sensor config for B09E1 Zelle04; IF 'b4=' is in payload THEN publish sensor config for B09E1 Zelle05; IF 'b5=' is in payload THEN publish sensor config for B09E1 Zelle06; IF 'b6=' is in payload THEN publish sensor config for B09E1 Zelle07; IF 'b7=' is in payload THEN publish sensor config for B09E1 Zelle08; IF 'b8=' is in payload THEN publish sensor config for B09E1 Zelle09; IF 'b9=' is in payload THEN publish sensor config for B09E1 Zelle10; IF 'ba=' is in payload THEN publish sensor config for B09E1 Zelle11; IF 'bb=' is in payload THEN publish sensor config for B09E1 Zelle12; IF 'bc=' is in payload THEN publish sensor config for B09E1 Zelle13; IF 'bd=' is in payload THEN publish sensor config for B09E1 Zelle14; IF 'be=' is in payload THEN publish sensor config for B09E1 Zelle15; IF 'bf=' is in payload THEN publish sensor config for B09E1 Zelle16. Finally, turn off B2500PKG B09E1 Voltage Discovery Automation [automation.b2500pkg_b09e1_voltage_discovery].",
"natural_language": {
"trigger": "The automation is triggered whenever an MQTT message arrives on the topic 'B2500PKG/B2500_09/CD13'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the incoming MQTT message. It then checks this content for specific text patterns ('b0=', 'b1=', up to 'bf='). For each pattern found, it publishes a corresponding MQTT configuration message to the Home Assistant discovery topic. These configuration messages set up individual voltage sensors (named B09E1 Zelle01 through B09E1 Zelle16) that will read their state from the same incoming MQTT topic. After performing all these checks and potential publications, the automation turns itself off."
},
"human_like": "This automation listens for a specific MQTT message and uses its content to automatically create and configure up to 16 voltage sensor entities in Home Assistant, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B09E2_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_09/CD13. CONDITIONS: None. ACTIONS: Store the message payload in a variable named payload. Then, for each of the following 16 conditions, if the condition is true, publish a corresponding MQTT configuration message. The conditions check if the payload contains the specific substring: c0=, c1=, c2=, c3=, c4=, c5=, c6=, c7=, c8=, c9=, ca=, cb=, cc=, cd=, ce=, or cf=. For each true condition, publish a retained MQTT configuration to the respective topic (e.g., homeassistant/sensor/b2500_09/voltage_c0/config) to create a sensor entity for a battery cell (e.g., B09E2 Zelle01) with a value_template that extracts the voltage in mV from the payload. Finally, turn off the automation B2500PKG B09E2 Voltage Discovery Automation [automation.b2500pkg_b09e2_voltage_discovery].",
"natural_language": {
"trigger": "Whenever an MQTT message arrives on the topic B2500PKG/B2500_09/CD13.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first saves the content of the incoming message. It then checks this content for the presence of 16 different substrings, each representing a battery cell identifier (c0= through cf=). For each substring found, it publishes a special configuration message to the MQTT broker. These configuration messages instruct Home Assistant to create a new voltage sensor for that specific cell, naming it accordingly (e.g., B09E2 Zelle01), setting it to read its value from the same incoming topic, and extracting the correct numerical voltage from the message. After processing all possible cells, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for a specific MQTT message and uses its data to automatically create sensor entities for up to 16 battery cell voltages, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B09_CD16_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_09/CD16. CONDITIONS: None. ACTIONS: Store the message payload in a variable. Then, for each of the following key-value patterns present in the payload, publish a corresponding MQTT discovery configuration message: IF 'm1=' THEN publish sensor config for B09 PV1 Input Voltage [sensor.b2500_09_cd16m1]. IF 'm2=' THEN publish sensor config for B09 PV2 Input Voltage [sensor.b2500_09_cd16m2]. IF 'i1=' THEN publish sensor config for B09 Output1 Voltage [sensor.b2500_09_cd16i1]. IF 'i2=' THEN publish sensor config for B09 Output2 Voltage [sensor.b2500_09_cd16i2]. IF 'c1=' THEN publish sensor config for B09 PV1 Input Current [sensor.b2500_09_cd16c1]. IF 'c2=' THEN publish sensor config for B09 PV2 Input Current [sensor.b2500_09_cd16c2]. IF 'c3=' THEN publish sensor config for B09 Output1 Current [sensor.b2500_09_cd16c3]. IF 'c4=' THEN publish sensor config for B09 Output2 Current [sensor.b2500_09_cd16c4]. IF 'bv=' THEN publish sensor config for B09 Akku Voltage [sensor.b2500_09_cd16bv]. IF 'bc=' THEN publish sensor config for B09 Akku Current [sensor.b2500_09_cd16bc]. IF 'bb=' THEN publish sensor config for B09 Akku Power [sensor.b2500_09_cd16bb]. Finally, turn off B2500PKG B09 CD16 Sensor Discovery Automation [automation.b2500pkg_b09_cd16_sensor_discovery].",
"natural_language": {
"trigger": "Whenever an MQTT message is published to the topic 'B2500PKG/B2500_09/CD16'.",
"conditions": "There are no conditions that must be met.",
"action": "The automation first saves the content of the received MQTT message. It then checks the content for specific data fields. For each field found, it publishes a corresponding Home Assistant MQTT discovery configuration to create a sensor entity. Specifically, it looks for fields like 'm1=', 'm2=', 'i1=', 'i2=', 'c1=', 'c2=', 'c3=', 'c4=', 'bv=', 'bc=', and 'bb='. For each one found, it sends a configuration message to create sensors for PV input voltages, output voltages, input currents, output currents, battery voltage, battery current, and battery power. After processing all possible fields, the automation turns itself off to prevent running again."
},
"human_like": "This automation listens for data from a device and automatically creates the necessary sensor entities in Home Assistant for monitoring its solar and battery parameters, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_B09_Sensor_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_09/CD01. CONDITIONS: None. ACTIONS: Store the message payload in variable 'payload'. Then, for each of the following key prefixes present in the payload, publish a corresponding MQTT configuration message to the Home Assistant discovery topic. The configuration messages define sensors and binary sensors for the B2500PKG device B09. The prefixes and their corresponding entity definitions are: 'l0=' (bits 0-3: B09 Entladen, B09 Laden, B09 DOD erreicht, B09 Unterspannung), 'l1=' (bits 0-7: B09E2 Entladen, B09E2 Laden, B09E2 DOD erreicht, B09E2 Unterspannung, B09E1 Entladen, B09E1 Laden, B09E1 DOD erreicht, B09E1 Unterspannung), 'b1=' (B09 E1 verbunden), 'b2=' (B09 E2 verbunden), 'p1=' (B09 Solar1 Input Status), 'p2=' (B09 Solar2 Input Status), 'w1=' (B09 PV1 Leistung), 'w2=' (B09 PV2 Leistung), 'pe=' (B09 Batterie SOC), 'vv=' (B09 Geräteversion), 'sv=' (B09 Gerätesubversion), 'cs=' (B09 Ladeeinstellung), 'cd=' (B09 Entladeeinstellung), 'am=' (B09 AM), 'o1=' (B09 Output Status 1), 'o2=' (B09 Output Status 2), 'do=' (B09 DOD Entnehmbare Kapazität in %), 'lv=' (B09 Entladeschwelle), 'cj=' (B09 CJ Scene), 'kn=' (B09 Gesamtkapazität), 'g1=' (B09 Output1 Leistung), 'g2=' (B09 Output2 Leistung), 'tl=' (B09 Temperatur low), 'th=' (B09 Temperatur high), 'tc=' (B09 Temperaturalarm (Laden)), 'tf=' (B09 Temperaturalarm (Entladen)), 'fc=' (B09 Chip Version), 'id=' (B09 Geräte ID), 'a0=' (B09 Ladezustand Hauptspeicher), 'a1=' (B09 Ladezustand Erweiterung1), 'a2=' (B09 Ladezustand Erweiterung2), 'e1=' (B09 Timer1 Beginn), 'f1=' (B09 Timer1 Ende), 'h1=' (B09 Timer1 Ausgabeleistung), 'e2=' (B09 Timer2 Beginn), 'f2=' (B09 Timer2 Ende), 'h2=' (B09 Timer2 Ausgabeleistung), 'e3=' (B09 Timer3 Beginn), 'f3=' (B09 Timer3 Ende), 'h3=' (B09 Timer3 Ausgabeleistung), 'e4=' (B09 Timer4 Beginn), 'f4=' (B09 Timer4 Ende), 'h4=' (B09 Timer4 Ausgabeleistung), 'e5=' (B09 Timer5 Beginn), 'f5=' (B09 Timer5 Ende), 'h5=' (B09 Timer5 Ausgabeleistung), 'd1=' (B09 Timer1 aktiv), 'd2=' (B09 Timer2 aktiv), 'd3=' (B09 Timer3 aktiv), 'd4=' (B09 Timer4 aktiv), 'd5=' (B09 Timer5 aktiv), 'bc=' (B09 Tägliche Battterieladung), 'bs=' (B09 Tägliche Batterieentladung), 'pt=' (B09 Tägliche PV Erzeugung), 'md=' (B09 Entlademodus Timer/Selbstanpassung), 'sg=' (B09 CT Sensor verbunden), 'sp=' (B09 SP), 'st=' (B09 ST), 'c0=' (B09 CTCH Kanal), 'c1=' (B09 Status CT), 'it=' (B09 IT Tägliche abgegebene Leistung), 'm0=' (B09 Leistungsmessung Phase1), 'm1=' (B09 Leistungsmessung Phase2), 'm2=' (B09 Leistungsmessung Phase3), 'm3=' (B09 M3), 'lmo=' (B09 LMO Nennausgangsleistung), 'lmi=' (B09 LMI Nennaufnahmeleistung), 'lmf=' (B09 LMF Gerätebeschränkung). Finally, turn off the automation B2500PKG B09 Sensor Discovery Automation [automation.b2500pkg_b09_sensor_discovery].",
"natural_language": {
"trigger": "Whenever a message is published to the MQTT topic B2500PKG/B2500_09/CD01.",
"conditions": "There are no conditions; the automation runs every time the trigger occurs.",
"action": "The automation first saves the incoming message content. It then checks the saved content for the presence of many specific key prefixes (like 'l0=', 'l1=', 'b1=', etc.). For each prefix found, it publishes a configuration message to Home Assistant's MQTT discovery topics. These configuration messages instruct Home Assistant to create and manage a wide array of sensors and binary sensors for the B2500PKG device B09, covering battery status, solar input, power output, timers, temperatures, device information, and energy statistics. After publishing all relevant configurations, the automation turns itself off to prevent running again."
},
"human_like": "This automation automatically discovers and sets up all monitoring sensors for a B2500PKG B09 battery system when it receives its first status message, then disables itself.",
"complexity": "high"
}
},
{
"id": "B2500PKG_B09_Voltage_Discovery",
"result": {
"structured": "TRIGGER: When an MQTT message is received on topic B2500PKG/B2500_09/CD13. CONDITIONS: None. ACTIONS: Set variable 'payload' to the trigger payload. Then, for each substring 'a0=' to 'af=' in the payload, if present, publish a corresponding MQTT configuration message to create a voltage sensor entity. Specifically: IF 'a0=' in payload THEN publish config for B09 Zelle01 [sensor.b2500_09_zelle01]; IF 'a1=' in payload THEN publish config for B09 Zelle02 [sensor.b2500_09_zelle02]; IF 'a2=' in payload THEN publish config for B09 Zelle03 [sensor.b2500_09_zelle03]; IF 'a3=' in payload THEN publish config for B09 Zelle04 [sensor.b2500_09_zelle04]; IF 'a4=' in payload THEN publish config for B09 Zelle05 [sensor.b2500_09_zelle05]; IF 'a5=' in payload THEN publish config for B09 Zelle06 [sensor.b2500_09_zelle06]; IF 'a6=' in payload THEN publish config for B09 Zelle07 [sensor.b2500_09_zelle07]; IF 'a7=' in payload THEN publish config for B09 Zelle08 [sensor.b2500_09_zelle08]; IF 'a8=' in payload THEN publish config for B09 Zelle09 [sensor.b2500_09_zelle09]; IF 'a9=' in payload THEN publish config for B09 Zelle10 [sensor.b2500_09_zelle10]; IF 'aa=' in payload THEN publish config for B09 Zelle11 [sensor.b2500_09_zelle11]; IF 'ab=' in payload THEN publish config for B09 Zelle12 [sensor.b2500_09_zelle12]; IF 'ac=' in payload THEN publish config for B09 Zelle13 [sensor.b2500_09_zelle13]; IF 'ad=' in payload THEN publish config for B09 Zelle14 [sensor.b2500_09_zelle14]; IF 'ae=' in payload THEN publish config for B09 Zelle15 [sensor.b2500_09_zelle15]; IF 'af=' in payload THEN publish config for B09 Zelle16 [sensor.b2500_09_zelle16]. Finally, turn off B2500PKG B09 Voltage Discovery Automation [automation.b2500pkg_b09_voltage_discovery].",
"natural_language": {
"trigger": "The automation is triggered whenever an MQTT message is received on the topic 'B2500PKG/B2500_09/CD13'.",
"conditions": "There are no conditions that must be met for the actions to run.",
"action": "The automation first stores the content of the received MQTT message. It then checks this content for the presence of specific substrings (from 'a0=' to 'af='). For each substring found, it publishes a corresponding MQTT configuration message. These configuration messages set up Home Assistant sensor entities for battery cell voltages, each with a specific name, state topic, and value extraction template. After processing all possible cell voltage entries, the automation turns itself off to prevent further runs."
},
"human_like": "This automation listens for a specific MQTT message from a battery pack and automatically creates sensor entities for up to 16 individual cell voltages, then disables itself.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_update",
"result": {
"structured": "TRIGGER: When Update Button [input_button.b2500pkg_update] changes state. CONDITIONS: None. ACTIONS: Execute shell command 'mkdir /config/packages/b2500pkg && sleep 3' via shell_command.run_custom_command. Execute shell command 'rm -f /config/packages/b2500pkg/basicsystem.sh && sleep 5' via shell_command.run_custom_command. Send a persistent notification with title 'B2500PKG' and message 'Update gestartet'. Execute shell command 'wget -q -O /config/packages/b2500pkg/basicsystem.sh https://raw.githubusercontent.com/Martin0475/b2500pkg/main/install_scripts/basicsystem.sh && sh /config/packages/b2500pkg/basicsystem.sh' via shell_command.run_custom_command. Send a persistent notification with title 'B2500PKG' and message 'Update fertig: yaml-Dateien werden neu geladen'. Wait for 10 seconds. Reload all Home Assistant core configuration via homeassistant.reload_all.",
"natural_language": {
"trigger": "When the Update Button [input_button.b2500pkg_update] is pressed or changes state.",
"conditions": "There are no conditions for this automation.",
"action": "The automation performs a series of steps to update a package. First, it creates a directory for the package and waits briefly. Then, it removes any existing installation script and waits. It sends a notification that the update has started. Next, it downloads the latest installation script from a GitHub repository and executes it. After the script runs, it sends a notification that the update is complete and that YAML files will be reloaded. It then waits for 10 seconds before finally reloading all of Home Assistant's core configuration."
},
"human_like": "Updates the B2500PKG system package by downloading and running the latest installer script, then reloads Home Assistant configuration.",
"complexity": "medium"
}
},
{
"id": "b2500pkg_low_voltage_protection",
"result": {
"structured": "TRIGGER: When any of the battery voltage sensors (B01 Minimum Voltage [sensor.b01_min_spannung], B02 Minimum Voltage [sensor.b02_min_spannung], B03 Minimum Voltage [sensor.b03_min_spannung], B04 Minimum Voltage [sensor.b04_min_spannung], B05 Minimum Voltage [sensor.b05_min_spannung], B06 Minimum Voltage [sensor.b06_min_spannung], B07 Minimum Voltage [sensor.b07_min_spannung], B08 Minimum Voltage [sensor.b08_min_spannung], B09 Minimum Voltage [sensor.b09_min_spannung]) changes state. CONDITIONS: The current value of the triggering sensor is less than the value of LVP Voltage Cutoff Input [input_number.lvp_voltage_cutoff] OR greater than the value of LVP Voltage Normal Input [input_number.lvp_voltage_normal]. ACTIONS: Extract the battery number from the triggering sensor's entity ID and construct an MQTT topic using related input_text entities. Then, based on the voltage and the current depth of discharge (DOD) for that battery: IF the current voltage is below the cutoff AND the current DOD is not zero, publish an MQTT command 'cd=19,md=0' to the constructed topic. ELSE IF the current voltage is above the normal voltage AND the current DOD is not equal to the normal DOD value from LVP DOD Normal Input [input_number.lvp_dod_normal], publish an MQTT command 'cd=19,md={{ dod_normal }}' to the constructed topic.",
"natural_language": {
"trigger": "Whenever the state of any of the nine battery minimum voltage sensors (B01 through B09) changes.",
"conditions": "If the new voltage reading from the sensor that triggered the automation is either lower than the configured low-voltage cutoff threshold or higher than the configured normal voltage threshold.",
"action": "The automation identifies which specific battery triggered the event and builds a custom MQTT topic for it. If the battery's voltage has dropped below the cutoff level and its current depth of discharge (DOD) is not already zero, it sends an MQTT command to set the DOD to zero. Conversely, if the battery's voltage has recovered above the normal level and its current DOD is different from the configured normal DOD value, it sends an MQTT command to set the DOD back to that normal value."
},
"human_like": "Protects batteries from deep discharge by sending commands to adjust their depth of discharge when their voltage falls too low or recovers to a normal level.",
"complexity": "high"
}
},
{
"id": "B2500PKG_MQTT_Publish",
"result": {
"structured": "TRIGGER: Every minute (time pattern minutes: /1). CONDITIONS: None. ACTIONS: For each item in the list ['01', '02', '03', '04', '05', '06', '07', '08', '09']: IF the state of the input_text entity with ID constructed as 'input_text.b' + item + '_mac' is not equal to the string '0', THEN calculate variables (voltage_mv, voltage, soc, capacity, power_in, power_out, ampere, topic) using a series of template expressions that sum sensor values and perform arithmetic, and then publish four MQTT messages to topics derived from the 'topic' variable with payloads containing the calculated soc, voltage, capacity, and ampere values.",
"natural_language": {
"trigger": "The automation runs every minute.",
"conditions": "There are no conditions that must be met for the automation to proceed.",
"action": "For each battery unit identified by the numbers 01 through 09, the automation checks if a corresponding MAC address text field is not set to '0'. If it is not, it calculates the battery's total voltage, state of charge, capacity, and current based on a series of sensor readings. It then publishes these four calculated values as separate MQTT messages to a topic specific to that battery unit."
},
"human_like": "This automation periodically calculates and publishes key battery statistics (like voltage and charge level) for up to nine battery units to MQTT topics.",
"complexity": "high"
}
},
{
"id": "B2500PKG_Repost_CD01_CD15_CD16_und_CD13",
"result": {
"structured": "TRIGGER: When an MQTT message is received on a topic matching the pattern '+/+/device/+/ctrl' with payload starting with 'w1=' and the third comma-separated part's first three characters extracted OR when an MQTT message is received on a topic matching the pattern '+/+/device/+/ctrl' with payload starting with 'a0=' and the first three characters extracted OR when an MQTT message is received on a topic matching the pattern '+/+/device/+/ctrl' with payload starting with 'pe=' and the first three characters extracted OR when an MQTT message is received on a topic matching the pattern '+/+/device/+/ctrl' with payload starting with 'm1=' and the third comma-separated part's first three characters extracted. CONDITIONS: None. ACTIONS: First, set a variable 'speicher_nummer' based on the trigger topic: if the topic matches the concatenation of B01 Topic Input [input_text.b01_topic], '/', B01 Type Input [input_text.b01_typ], '/device/', B01 MAC Input [input_text.b01_mac], '/ctrl', then set to 'B2500_01'; else if it matches the concatenation of B02 Topic Input [input_text.b02_topic], '/', B02 Type Input [input_text.b02_typ], '/device/', B02 MAC Input [input_text.b02_mac], '/ctrl', then set to 'B2500_02'; else if it matches the concatenation of B03 Topic Input [input_text.b03_topic], '/', B03 Type Input [input_text.b03_typ], '/device/', B03 MAC Input [input_text.b03_mac], '/ctrl', then set to 'B2500_03'; else if it matches the concatenation of B04 Topic Input [input_text.b04_topic], '/', B04 Type Input [input_text.b04_typ], '/device/', B04 MAC Input [input_text.b04_mac], '/ctrl', then set to 'B2500_04'; else if it matches the concatenation of B05 Topic Input [input_text.b05_topic], '/', B05 Type Input [input_text.b05_typ], '/device/', B05 MAC Input [input_text.b05_mac], '/ctrl', then set to 'B2500_05'; else if it matches the concatenation of B06 Topic Input [input_text.b06_topic], '/', B06 Type Input [input_text.b06_typ], '/device/', B06 MAC Input [input_text.b06_mac], '/ctrl', then set to 'B2500_06'; else if it matches the concatenation of B07 Topic Input [input_text.b07_topic], '/', B07 Type Input [input_text.b07_typ], '/device/', B07 MAC Input [input_text.b07_mac], '/ctrl', then set to 'B2500_07'; else if it matches the concatenation of B08 Topic Input [input_text.b08_topic], '/', B08 Type Input [input_text.b08_typ], '/device/', B08 MAC Input [input_text.b08_mac], '/ctrl', then set to 'B2500_08'; else if it matches the concatenation of B09 Topic Input [input_text.b09_topic], '/', B09 Type Input [input_text.b09_typ], '/device/', B09 MAC Input [input_text.b09_mac], '/ctrl', then set to 'B2500_09'; else set to 'unknown'. Then, if 'speicher_nummer' is not 'unknown', choose an action based on the trigger ID: if the trigger ID is 'b2500_cd01', publish an MQTT message to topic 'B2500PKG/{{ speicher_nummer }}/CD01' with the original trigger payload appended with ',end01'; if the trigger ID is 'b2500_cd13', publish to topic 'B2500PKG/{{ speicher_nummer }}/CD13' with payload appended with ',end13'; if the trigger ID is 'b2500_cd15', publish to topic 'B2500PKG/{{ speicher_nummer }}/CD15' with payload appended with ',end15'; if the trigger ID is 'b2500_cd16', publish to topic 'B2500PKG/{{ speicher_nummer }}/CD16' with payload appended with ',end16'.",
"natural_language": {
"trigger": "The automation is triggered by specific MQTT messages arriving on a topic pattern that matches '+/+/device/+/ctrl'. There are four distinct triggers: one for messages with a payload beginning with 'w1=', one for 'a0=', one for 'pe=', and one for 'm1='. Each trigger extracts a specific part of the payload (the first three characters or the first three characters of the third comma-separated value) for identification.",
"conditions": "There are no conditions that must be met for the automation to proceed.",
"action": "First, the automation determines which specific storage unit (B2500_01 through B2500_09) the message originated from by comparing the full MQTT topic against predefined templates constructed from configuration input_text entities (like B01 Topic Input [input_text.b01_topic], B01 Type Input [input_text.b01_typ], and B01 MAC Input [input_text.b01_mac]). If a match is found, it stores the unit identifier (e.g., 'B2500_01'). If the source is identified (not 'unknown'), it then republishes the message. The destination topic and payload suffix depend on which original trigger fired: messages from the 'w1=' trigger are republished to a CD01 topic with ',end01' appended; 'a0=' messages go to CD13 with ',end13'; 'pe=' messages go to CD15 with ',end15'; and 'm1=' messages go to CD16 with ',end16'."
},
"human_like": "This automation listens for specific MQTT commands from up to nine storage units, identifies which unit sent the message, and forwards it to a new, organized topic structure for further processing.",
"complexity": "high"
}
},
{
"id": "B2500PKG_Infos und Zellenspannung anfordern",
"result": {
"structured": "TRIGGER: When the time pattern matches minutes divisible by 5 (every 5 minutes) OR When an automation_reloaded event occurs OR When Request Start Input [input_boolean.req_start] turns on. CONDITIONS: None. ACTIONS: In a loop that repeats while Request Start Input [input_boolean.req_start] is on: 1. Set variables: current_count from CD01 Tracker Input [input_number.cd01_tracker], limit from CD01 Ratio Input [input_number.cd01_ratio], delay_seconds from Request Delay Input [input_number.req_delay], delay2_seconds from Request Delay 2 Input [input_number.req_delay2]. 2. Choose: IF current_count < limit THEN: a. Increment CD01 Tracker Input [input_number.cd01_tracker] by 1. b. For each item in list ['01','02','03','04','05','06','07','08','09']: IF the state of input_text.b[item]_mac is not '0', THEN publish MQTT message with topic and payload to request info (cd=01) and wait delay2_seconds. c. IF Request CD16 Input [input_boolean.req_cd16] is on, THEN for each item in the same list: IF the state of input_text.b[item]_mac is not '0', THEN publish MQTT message with topic and payload to request info (cd=16) and wait delay2_seconds. ELSE IF current_count >= limit THEN: a. For each item in the same list: IF the state of input_text.b[item]_mac is not '0', THEN publish MQTT message with topic and payload to request voltages (cd=13) and wait delay2_seconds. b. Reset CD01 Tracker Input [input_number.cd01_tracker] to 0. 3. Wait delay_seconds.",
"natural_language": {
"trigger": "The automation runs every five minutes, whenever Home Assistant automations are reloaded, or when the Request Start Input [input_boolean.req_start] is manually turned on.",
"conditions": "There are no conditions that must be met for the automation to proceed.",
"action": "The automation performs a loop that continues as long as the Request Start Input [input_boolean.req_start] remains on. In each loop iteration, it first reads several configuration values. It then checks a counter (CD01 Tracker Input [input_number.cd01_tracker]) against a limit (CD01 Ratio Input [input_number.cd01_ratio]). If the counter is below the limit, it increments the counter and sends a series of MQTT commands (cd=01) to up to nine devices (identified by their MAC addresses stored in input_text entities) to request general information. If the Request CD16 Input [input_boolean.req_cd16] is enabled, it also sends additional MQTT commands (cd=16). If the counter has reached the limit, it instead sends MQTT commands (cd=13) to request cell voltage information from the same devices and then resets the counter to zero. After each loop iteration, it waits for a configurable delay before checking if it should run again."
},
"human_like": "This automation periodically requests information and cell voltage data from a set of battery devices via MQTT, using a counter to alternate between different types of requests.",
"complexity": "high"
}
},
{
"id": "B2500PKG Send Restart",
"result": {
"structured": "TRIGGER: When Restart Button [input_button.b2500_restart] changes state. CONDITIONS: None. ACTIONS: Set variable b2500_mac based on the value of Battery Selection Input [input_select.speicherauswahl]. If the selection is 'b2500_01', use B01 MAC Input [input_text.b01_mac]. If 'b2500_02', use B02 MAC Input [input_text.b02_mac]. If 'b2500_03', use B03 MAC Input [input_text.b03_mac]. If 'b2500_04', use B04 MAC Input [input_text.b04_mac]. If 'b2500_05', use B05 MAC Input [input_text.b05_mac]. If 'b2500_06', use B06 MAC Input [input_text.b06_mac]. If 'b2500_07', use B07 MAC Input [input_text.b07_mac]. If 'b2500_08', use B08 MAC Input [input_text.b08_mac]. If 'b2500_09', use B09 MAC Input [input_text.b09_mac]. Otherwise, set to 'unknown'. Set variable b2500_typ based on the value of Battery Selection Input [input_select.speicherauswahl]. If the selection is 'b2500_01', use B01 Type Input [input_text.b01_typ]. If 'b2500_02', use B02 Type Input [input_text.b02_typ]. If 'b2500_03', use B03 Type Input [input_text.b03_typ]. If 'b2500_04', use B04 Type Input [input_text.b04_typ]. If 'b2500_05', use B05 Type Input [input_text.b05_typ]. If 'b2500_06', use B06 Type Input [input_text.b06_typ]. If 'b2500_07', use B07 Type Input [input_text.b07_typ]. If 'b2500_08', use B08 Type Input [input_text.b08_typ]. If 'b2500_09', use B09 Type Input [input_text.b09_typ]. Otherwise, set to 'unknown'. Set variable b2500_topic based on the value of Battery Selection Input [input_select.speicherauswahl]. If the selection is 'b2500_01', use B01 Topic Input [input_text.b01_topic]. If 'b2500_02', use B02 Topic Input [input_text.b02_topic]. If 'b2500_03', use B03 Topic Input [input_text.b03_topic]. If 'b2500_04', use B04 Topic Input [input_text.b04_topic]. If 'b2500_05', use B05 Topic Input [input_text.b05_topic]. If 'b2500_06', use B06 Topic Input [input_text.b06_topic]. If 'b2500_07', use B07 Topic Input [input_text.b07_topic]. If 'b2500_08', use B08 Topic Input [input_text.b08_topic]. If 'b2500_09', use B09 Topic Input [input_text.b09_topic]. Otherwise, set to 'unknown'. Publish an MQTT message with the topic '{{ b2500_topic }}/{{ b2500_typ }}/App/{{ b2500_mac }}/ctrl' and the payload 'cd=10'.",
"natural_language": {
"trigger": "The automation is triggered whenever the Restart Button [input_button.b2500_restart] is pressed or its state changes.",
"conditions": "There are no conditions that must be met for the action to run.",
"action": "The automation first determines which battery is currently selected in the Battery Selection Input [input_select.speicherauswahl]. Based on this selection, it retrieves the corresponding MAC address, device type, and MQTT topic from a set of input text fields (e.g., B01 MAC Input [input_text.b01_mac], B01 Type Input [input_text.b01_typ], B01 Topic Input [input_text.b01_topic]). It then publishes an MQTT command with the payload 'cd=10' to a topic constructed from these values, formatted as '<topic>/<type>/App/<mac>/ctrl'. This command is intended to send a restart signal to the selected battery device."
},
"human_like": "Sends a restart command to a selected battery device via MQTT when the restart button is pressed.",
"complexity": "medium"
}
},
{
"id": "B2500PKG Set Charging Mode",
"result": {
"structured": "TRIGGER: When Set Charging Mode Button [input_button.b2500_lademodus_setzen] is pressed. CONDITIONS: None. ACTIONS: 1. Set variable b2500_mac based on Battery Selection Input [input_select.speicherauswahl] value: if selection is 'b2500_01' then use B01 MAC Input [input_text.b01_mac] state, else if 'b2500_02' then use B02 MAC Input [input_text.b02_mac] state, else if 'b2500_03' then use B03 MAC Input [input_text.b03_mac] state, else if 'b2500_04' then use B04 MAC Input [input_text.b04_mac] state, else if 'b2500_05' then use B05 MAC Input [input_text.b05_mac] state, else if 'b2500_06' then use B06 MAC Input [input_text.b06_mac] state, else if 'b2500_07' then use B07 MAC Input [input_text.b07_mac] state, else if 'b2500_08' then use B08 MAC Input [input_text.b08_mac] state, else if 'b2500_09' then use B09 MAC Input [input_text.b09_mac] state, else 'unknown'. 2. Set variable b2500_typ based on Battery Selection Input [input_select.speicherauswahl] value: if selection is 'b2500_01' then use B01 Type Input [input_text.b01_typ] state, else if 'b2500_02' then use B02 Type Input [input_text.b02_typ] state, else if 'b2500_03' then use B03 Type Input [input_text.b03_typ] state, else if 'b2500_04' then use B04 Type Input [input_text.b04_typ] state, else if 'b2500_05' then use B05 Type Input [input_text.b05_typ] state, else if 'b2500_06' then use B06 Type Input [input_text.b06_typ] state, else if 'b2500_07' then use B07 Type Input [input_text.b07_typ] state, else if 'b2500_08' then use B08 Type Input [input_text.b08_typ] state, else if 'b2500_09' then use B09 Type Input [input_text.b09_typ] state, else 'unknown'. 3. Set variable b2500_topic based on Battery Selection Input [input_select.speicherauswahl] value: if selection is 'b2500_01' then use B01 Topic Input [input_text.b01_topic] state, else if 'b2500_02' then use B02 Topic Input [input_text.b02_topic] state, else if 'b2500_03' then use B03 Topic Input [input_text.b03_topic] state, else if 'b2500_04' then use B04 Topic Input [input_text.b04_topic] state, else if 'b2500_05' then use B05 Topic Input [input_text.b05_topic] state, else if 'b2500_06' then use B06 Topic Input [input_text.b06_topic] state, else if 'b2500_07' then use B07 Topic Input [input_text.b07_topic] state, else if 'b2500_08' then use B08 Topic Input [input_text.b08_topic] state, else if 'b2500_09' then use B09 Topic Input [input_text.b09_topic] state, else 'unknown'. 4. Publish MQTT message to topic '{{ b2500_topic }}/{{ b2500_typ }}/App/{{ b2500_mac }}/ctrl' with payload 'cd=17,md={{ states('input_select.lademodus').replace(\"Laden vor dem Entladen\",\"1\").replace(\"Laden und Entladen gleichzeitig\",\"0\") }}'. 5. Wait for 3 seconds. 6. Publish MQTT message to topic '{{ b2500_topic }}/{{ b2500_typ }}/App/{{ b2500_mac }}/ctrl' with payload 'cd=01'.",
"natural_language": {
"trigger": "When the Set Charging Mode Button [input_button.b2500_lademodus_setzen] is pressed.",
"conditions": "There are no conditions for this automation.",
"action": "The automation first determines which battery is selected by checking the Battery Selection Input [input_select.speicherauswahl]. Based on this selection, it sets three variables: the MAC address, the device type, and the MQTT topic, using the corresponding configuration inputs (e.g., B01 MAC Input [input_text.b01_mac], B01 Type Input [input_text.b01_typ], B01 Topic Input [input_text.b01_topic] for selection 'b2500_01'). It then sends an MQTT command to the constructed topic to set the charging mode. The payload for this command encodes the current value of the Charging Mode Input [input_select.lademodus], translating 'Laden vor dem Entladen' to '1' and 'Laden und Entladen gleichzeitig' to '0'. After a 3-second delay, it sends a second MQTT command to the same topic with a different payload ('cd=01')."
},
"human_like": "Sends a charging mode configuration command to a selected battery system via MQTT when a button is pressed.",
"complexity": "medium"
}
},
{
"id": "B2500PKG Set DOD",
"result": {
"structured": "TRIGGER: When input_button.b2500_dod_setzen [input_button.b2500_dod_setzen] changes state. CONDITIONS: None. ACTIONS: Set variables b2500_mac, b2500_typ, and b2500_topic based on the current value of Battery Selection Input [input_select.speicherauswahl] by selecting the corresponding MAC, type, and topic from the B01-B09 input_text entities. Publish an MQTT message to the constructed topic '{{ b2500_topic }}/{{ b2500_typ }}/App/{{ b2500_mac }}/ctrl' with payload 'cd=19,md={{ states('input_number.b2500_dod')|int }}'. Wait for 3 seconds. Publish a second MQTT message to the same topic with payload 'cd=01'.",
"natural_language": {
"trigger": "When the Set DOD Button [input_button.b2500_dod_setzen] is pressed.",
"conditions": "There are no conditions for this automation.",
"action": "First, the automation determines which battery is selected by checking the Battery Selection Input [input_select.speicherauswahl]. It then looks up the corresponding MAC address, device type, and MQTT topic from the associated input_text entities (B01 through B09). It sends an MQTT command to the selected battery to set its Depth of Discharge (DOD) to the value specified in the DOD Input [input_number.b2500_dod]. After a three-second delay, it sends a second MQTT command to the same battery, likely to confirm or finalize the setting."
},
"human_like": "Sends a Depth of Discharge (DOD) setting to a selected battery via MQTT when a button is pressed.",
"complexity": "medium"
}
},
{
"id": "B2500PKG Set Outputs",
"result": {
"structured": "TRIGGER: When Set Outputs Button [input_button.b2500_outputs_setzen] changes state. CONDITIONS: None. ACTIONS: Set variable b2500_mac to the value of B01 MAC Input [input_text.b01_mac] if Battery Selection Input [input_select.speicherauswahl] is 'b2500_01', else B02 MAC Input [input_text.b02_mac] if 'b2500_02', else B03 MAC Input [input_text.b03_mac] if 'b2500_03', else B04 MAC Input [input_text.b04_mac] if 'b2500_04', else B05 MAC Input [input_text.b05_mac] if 'b2500_05', else B06 MAC Input [input_text.b06_mac] if 'b2500_06', else B07 MAC Input [input_text.b07_mac] if 'b2500_07', else B08 MAC Input [input_text.b08_mac] if 'b2500_08', else B09 MAC Input [input_text.b09_mac] if 'b2500_09', else 'unknown'. Set variable b2500_typ to the value of B01 Type Input [input_text.b01_typ] if Battery Selection Input [input_select.speicherauswahl] is 'b2500_01', else B02 Type Input [input_text.b02_typ] if 'b2500_02', else B03 Type Input [input_text.b03_typ] if 'b2500_03', else B04 Type Input [input_text.b04_typ] if 'b2500_04', else B05 Type Input [input_text.b05_typ] if 'b2500_05', else B06 Type Input [input_text.b06_typ] if 'b2500_06', else B07 Type Input [input_text.b07_typ] if 'b2500_07', else B08 Type Input [input_text.b08_typ] if 'b2500_08', else B09 Type Input [input_text.b09_typ] if 'b2500_09', else 'unknown'. Set variable b2500_topic to the value of B01 Topic Input [input_text.b01_topic] if Battery Selection Input [input_select.speicherauswahl] is 'b2500_01', else B02 Topic Input [input_text.b02_topic] if 'b2500_02', else B03 Topic Input [input_text.b03_topic] if 'b2500_03', else B04 Topic Input [input_text.b04_topic] if 'b2500_04', else B05 Topic Input [input_text.b05_topic] if 'b2500_05', else B06 Topic Input [input_text.b06_topic] if 'b2500_06', else B07 Topic Input [input_text.b07_topic] if 'b2500_07', else B08 Topic Input [input_text.b08_topic] if 'b2500_08', else B09 Topic Input [input_text.b09_topic] if 'b2500_09', else 'unknown'. Publish an MQTT message to topic '{{ b2500_topic }}/{{ b2500_typ }}/App/{{ b2500_mac }}/ctrl' with payload 'cd=04,md=' plus the numeric code derived from Outputs Input [input_select.outputs] where 'Ausgang PV1 und PV2 off' maps to '0', 'Ausgang PV1 on, PV2 off' maps to '1', 'Ausgang PV1 off, PV2 on' maps to '2', and 'Ausgang PV1 und PV2 on' maps to '3'. Wait for 3 seconds. Publish an MQTT message to topic '{{ b2500_topic }}/{{ b2500_typ }}/App/{{ b2500_mac }}/ctrl' with payload 'cd=01'.",
"natural_language": {
"trigger": "When the Set Outputs Button [input_button.b2500_outputs_setzen] is pressed.",
"conditions": "There are no conditions.",
"action": "The automation first determines which battery is selected. It looks at the Battery Selection Input [input_select.speicherauswahl] and uses that to fetch the corresponding MAC address, device type, and MQTT topic from the relevant configuration input_text entities (B01 through B09). It then sends an MQTT command to the selected battery device. The command sets the outputs based on the current selection in the Outputs Input [input_select.outputs], translating the human-readable option into a numeric code. After a 3-second delay, it sends a second MQTT command to the same device, likely to confirm or finalize the setting."
},
"human_like": "Sends output configuration commands to a selected battery system when the user presses the 'Set Outputs' button.",
"complexity": "medium"
}
},
{
"id": "B2500PKG Set Smartmeter",
"result": {
"structured": "TRIGGER: When Set Smartmeter Button [input_button.b2500_smartmeter_setzen] is pressed. CONDITIONS: None. ACTIONS: First, set variables based on Battery Selection Input [input_select.speicherauswahl]: b2500_mac to the MAC address of the selected battery, b2500_typ to the type of the selected battery, and b2500_topic to the topic of the selected battery. Then, based on the state of Smartmeter Input [input_select.smartmeter], publish a specific MQTT command: If state is CT001, publish 'cd=27,meter=0,mac=000000000000'. If state is Shelly Pro 3EM, publish 'cd=27,meter=1,mac=000000000000'. If state is CT002, publish 'cd=27,meter=3,mac=000000000000'. If state is CT003, publish 'cd=27,meter=4,mac=000000000000'. If state is Shelly EM gen3, publish 'cd=27,meter=5,mac=000000000000'. If state is Shelly Pro EM50, publish 'cd=27,meter=6,mac=000000000000'. All commands are published to the topic '{{ b2500_topic }}/{{ b2500_typ }}/App/{{ b2500_mac }}/ctrl'. Wait 3 seconds, then publish 'cd=01' to the same topic. Wait another 3 seconds, then publish 'cd=10' to the same topic.",
"natural_language": {
"trigger": "The automation is triggered when the Set Smartmeter Button [input_button.b2500_smartmeter_setzen] is pressed.",
"conditions": "There are no conditions that must be met for the automation to run.",
"action": "First, the automation determines which battery is selected via the Battery Selection Input [input_select.speicherauswahl]. It then reads the corresponding MAC address, device type, and MQTT topic from the associated input_text entities (e.g., B01 MAC Input [input_text.b01_mac], B01 Type Input [input_text.b01_typ], B01 Topic Input [input_text.b01_topic]). Next, it checks the current selection in the Smartmeter Input [input_select.smartmeter] and sends a specific configuration command via MQTT to the selected battery's control topic. The command varies depending on the selected smart meter type (e.g., CT001, Shelly Pro 3EM). After a 3-second delay, it sends a 'cd=01' command, and after another 3-second delay, it sends a 'cd=10' command, both to the same MQTT topic, likely to finalize the configuration."
},
"human_like": "Configures a selected battery system with a specific smart meter type when the user presses a button, sending a sequence of MQTT commands to apply the settings.",
"complexity": "medium"
}
},
{
"id": "B2500PKG_Set_Surplus",
"result": {
"structured": "TRIGGER: When Set Surplus Button [input_button.surplus_set] is pressed. CONDITIONS: None. ACTIONS: First, set variables based on Battery Selection Input [input_select.speicherauswahl]: b2500_mac to the MAC address of the selected battery (from B01 MAC Input [input_text.b01_mac] to B09 MAC Input [input_text.b09_mac]), b2500_typ to the type of the selected battery (from B01 Type Input [input_text.b01_typ] to B09 Type Input [input_text.b09_typ]), and b2500_topic to the topic of the selected battery (from B01 Topic Input [input_text.b01_topic] to B09 Topic Input [input_text.b09_topic]). Then, choose an action based on Surplus Input [input_select.surplus]: If it is 'Überschusseinspeisung an', publish an MQTT command to enable surplus feed-in to the topic constructed from the variables. If it is 'Überschusseinspeisung aus', publish an MQTT command to disable surplus feed-in to the same topic. Wait for 2 seconds. Finally, publish a standard MQTT command (cd=01) to the same topic.",
"natural_language": {
"trigger": "When the Set Surplus Button [input_button.surplus_set] is pressed.",
"conditions": "There are no conditions for this automation.",
"action": "The automation first determines which battery is selected using the Battery Selection Input [input_select.speicherauswahl]. It reads the corresponding MAC address, device type, and MQTT topic from the associated input_text entities (B01 through B09). Then, it checks the current setting of the Surplus Input [input_select.surplus]. If the setting is 'Überschusseinspeisung an', it sends an MQTT command to enable surplus feed-in for the selected battery. If the setting is 'Überschusseinspeisung aus', it sends an MQTT command to disable surplus feed-in. After a short 2-second delay, it sends a final standard MQTT command (cd=01) to the same device topic."
},
"human_like": "Sends a command to enable or disable surplus feed-in for a selected battery when the user presses the 'Set Surplus' button.",
"complexity": "medium"
}
},
{
"id": "B2500PKG Set Timer",
"result": {
"structured": "TRIGGER: When Set Timer Power Button [input_button.b2500_leistung_setzen] changes state OR When Set Timer Status Button [input_button.b2500_timer_status_setzen] changes state OR When Set Time Button [input_button.zeit_setzen] changes state OR When Set Self-Adaptation Button [input_button.b2500_selbstanpassung] changes state. CONDITIONS: None. ACTIONS: First, compute a set of variables (a1-a5, b1-b5, e1-e5, v1-v5, b2500_mac, b2500_typ, b2500_topic) based on the state of Battery Selection Input [input_select.speicherauswahl] and other entities. Then, based on which trigger fired: IF trigger is Set Timer Power Button [input_button.b2500_leistung_setzen], update the power variable (v1-v5) for the selected Timer Slot Input [input_select.timerslot] with the value from Timer Power Input [input_number.timer_leistung] AND publish an MQTT command with all timer parameters. IF trigger is Set Timer Status Button [input_button.b2500_timer_status_setzen], update the activation variable (a1-a5) for the selected Timer Slot Input [input_select.timerslot] based on Timer Active Input [input_boolean.timer_aktiv] AND publish an MQTT command with all timer parameters. IF trigger is Set Time Button [input_button.zeit_setzen], update the start (b1-b5) and end (e1-e5) time variables for the selected Timer Slot Input [input_select.timerslot] with the values from Timer Start Input [input_datetime.timer_beginn] and Timer End Input [input_datetime.timer_ende] AND publish an MQTT command with all timer parameters. IF trigger is Set Self-Adaptation Button [input_button.b2500_selbstanpassung], publish an MQTT command to enable self-adaptation mode. After a 3-second delay, publish a final MQTT command to request status (cd=01).",
"natural_language": {
"trigger": "The automation is triggered whenever any of the four control buttons changes state: the Set Timer Power Button [input_button.b2500_leistung_setzen], the Set Timer Status Button [input_button.b2500_timer_status_setzen], the Set Time Button [input_button.zeit_setzen], or the Set Self-Adaptation Button [input_button.b2500_selbstanpassung].",
"conditions": "There are no conditions; the automation runs immediately upon any of the triggers firing.",
"action": "The automation first gathers a large set of data from the system. It reads the currently selected battery from Battery Selection Input [input_select.speicherauswahl] and uses that to look up the current state of five timer slots (whether they are active, their start and end times, and their power levels). It also determines the MAC address, device type, and MQTT topic for the selected battery by checking a series of input_text entities. Depending on which button was pressed, it then modifies specific parts of this timer data: setting the power level, toggling the timer's active state, or setting the start and end times, based on the selected timer slot from Timer Slot Input [input_select.timerslot] and the corresponding input entities. After updating the relevant data, it sends an MQTT command to the selected battery device with the complete set of timer parameters. If the self-adaptation button was pressed, it sends a different MQTT command to enable that feature. Finally, after a three-second pause, it sends a final MQTT command to request the device's status."
},
"human_like": "This automation configures timer settings for a selected battery system, allowing you to set power levels, schedule times, activate timers, or enable self-adaptation mode with the press of a button.",
"complexity": "high"
}
},
{
"id": "B2500PKG_Test_Config",
"result": {
"structured": "TRIGGER: When Test Config Button [input_button.test_config] is pressed (state changes to null). CONDITIONS: None. ACTIONS: Set variables b2500_mac, b2500_typ, and b2500_topic based on the current value of Battery Selection Input [input_select.speicherauswahl] using a nested conditional lookup from corresponding input_text entities (B01 MAC Input [input_text.b01_mac], B01 Type Input [input_text.b01_typ], B01 Topic Input [input_text.b01_topic], etc., up to B09). Publish an MQTT command with payload 'cd=01' to the constructed topic '{{ b2500_topic }}/{{ b2500_typ }}/App/{{ b2500_mac }}/ctrl'. Send a persistent notification stating the test is starting. Wait up to 10 seconds for an MQTT response on topic '{{ b2500_topic }}/{{ b2500_typ }}/device/{{ b2500_mac }}/ctrl'. If a response is received within the timeout, send a notification with the payload. If no response is received, send a notification stating 'Keine Antwort empfangen.'.",
"natural_language": {
"trigger": "When the Test Config Button [input_button.test_config] is pressed.",
"conditions": "There are no conditions that must be met.",
"action": "The automation first determines which battery storage unit to test based on the current selection in Battery Selection Input [input_select.speicherauswahl]. It looks up the corresponding MAC address, device type, and MQTT topic from a set of configuration input fields (like B01 MAC Input [input_text.b01_mac], B01 Type Input [input_text.b01_typ], B01 Topic Input [input_text.b01_topic], and so on up to B09). It then sends an MQTT command to that specific device to initiate a test and notifies the user that the test has started. The automation waits for a response from the device for up to 10 seconds. If a response is received, it shows a notification with the response data. If no response is received within the time limit, it notifies the user that no answer was received."
},
"human_like": "Tests the configuration and connectivity of a selected battery storage unit by sending a command and checking for a response.",
"complexity": "medium"
}
},
{
"id": "b2500pkg_zeropower_trigger",
"result": {
"structured": "TRIGGER: When Zeropower Measure Load [sensor.zeropower_measure_load] changes state OR every 5 minutes (time pattern). CONDITIONS: (Zeropower Main Script [script.b2500pkg_zeropower_main] is off AND (Zeropower Measure Load [sensor.zeropower_measure_load] value is greater than (Zeropower Target Value Input [input_number.zeropower_target_value] + Zeropower Target Deviation Input [input_number.zeropower_target_deviation]) OR Zeropower Measure Load [sensor.zeropower_measure_load] value is less than (Zeropower Target Value Input [input_number.zeropower_target_value] - Zeropower Target Deviation Input [input_number.zeropower_target_deviation]))) OR (trigger is from the time pattern). ACTIONS: If triggered by sensor state change, turn on Zeropower Main Script [script.b2500pkg_zeropower_main] with variable force_redistribution set to false. If triggered by the time pattern, turn on Zeropower Main Script [script.b2500pkg_zeropower_main] with variable force_redistribution set to true.",
"natural_language": {
"trigger": "The automation is triggered either when the Zeropower Measure Load [sensor.zeropower_measure_load] sensor changes its state, or every 5 minutes based on a scheduled time pattern.",
"conditions": "The conditions require that either the Zeropower Main Script [script.b2500pkg_zeropower_main] is not running (off) and the measured load is outside a target range, or the trigger is the scheduled time pattern. The target range is defined by the Zeropower Target Value Input [input_number.zeropower_target_value] plus or minus the Zeropower Target Deviation Input [input_number.zeropower_target_deviation]. The load is considered out of range if it is above the upper limit or below the lower limit.",
"action": "Depending on the trigger source, the Zeropower Main Script [script.b2500pkg_zeropower_main] is started. If triggered by a change in the load sensor, the script runs with a parameter to not force a redistribution. If triggered by the 5-minute timer, the script runs with a parameter to force a redistribution."
},
"human_like": "This automation starts a power management script either when the measured power load deviates from a target range or on a regular 5-minute schedule, adjusting its behavior based on the trigger.",
"complexity": "medium"
}
}
]