i have it.I'm too stupid to set up mqtt. Maybe it would be a good idea to test the connection to mqtt server in the webgui.?
home-assistant.log
Code:2024-05-30 19:03:49.658 ERROR (MainThread) [homeassistant.components.automation.start_dosing_pump] Start Dosing Pump: Error executing script. Error for call_service at point of sale 1: Error rendering data template: ValueError: Template error: float got invalid input 'unknown' when rendering template '{ "id": 1, "direction": {% if is_state('input_boolean.dosing_pump_direction', 'on') %}1{% else %}0{% endif %}, "amount": {{ states('input_number.dosing_pump_amount') | float }}, "duration": {{ states('input_number.dosing_pump_duration') | float }} }' but no default was specified 2024-05-30 19:03:49.658 ERROR (MainThread) [homeassistant.components.automation.start_dosing_pump] Error while executing automation automation.start_dosing_pump: Error rendering data template: ValueError: Template error: float got invalid input 'unknown' when rendering template '{ "id": 1, "direction": {% if is_state('input_boolean.dosing_pump_direction', 'on') %}1{% else %}0{% endif %}, "amount": {{ states('input_number.dosing_pump_amount') | float }}, "duration": {{ states('input_number.dosing_pump_duration') | float }} }' but no default was specified 2024-05-30 19:03:51.190 ERROR (MainThread) [homeassistant.components.automation.start_dosing_pump] Start Dosing Pump: Error executing script. Error for call_service at point of sale 1: Error rendering data template: ValueError: Template error: float got invalid input 'unknown' when rendering template '{ "id": 1, "direction": {% if is_state('input_boolean.dosing_pump_direction', 'on') %}1{% else %}0{% endif %}, "amount": {{ states('input_number.dosing_pump_amount') | float }}, "duration": {{ states('input_number.dosing_pump_duration') | float }} }' but no default was specified 2024-05-30 19:03:51.191 ERROR (MainThread) [homeassistant.components.automation.start_dosing_pump] Error while executing automation automation.start_dosing_pump: Error rendering data template: ValueError: Template error: float got invalid input 'unknown' when rendering template '{ "id": 1, "direction": {% if is_state('input_boolean.dosing_pump_direction', 'on') %}1{% else %}0{% endif %}, "amount": {{ states('input_number.dosing_pump_amount') | float }}, "duration": {{ states('input_number.dosing_pump_duration') | float }} }' but no default was specified
automations.yaml
Code:- id: Start Dosing Pump alias: "Start Dosing Pump" trigger: - platform: event event_type: state_changed event_data: entity_id: input_button.start_dosing_pump action: - service: mqtt.publish data_template: topic: "/ReefRhythm/24587cda78dc/dose" payload: > { "id": 1, "direction": {% if is_state('input_boolean.dosing_pump_direction', 'on') %}1{% else %}0{% endif %}, "amount": {{ states('input_number.dosing_pump_amount') | float }}, "duration": {{ states('input_number.dosing_pump_duration') | float }} } mode: single - id: Stop Dosing Pump alias: "Stop Dosing Pump" trigger: - platform: event event_type: state_changed event_data: entity_id: input_button.stop_dosing_pump action: - service: mqtt.publish data_template: topic: "/ReefRhythm/24587cda78dc/stop" payload: > {"id": 1} mode: single
If I start one of the pumps in the reefrhythm webgui, it should be displayed in mqtt explorer, right? Unfortunately it won't for me.
I somehow have the feeling that the reff rhythm can't connect with the mqtt brocker. I'm probably making a mistake somewhere.
mqtt broker: homeassistant
im stupid, was testing broker adresses: core-mosquitto, core-mosquitto.hass.io and so on. Simply homeassistant