Received this and as an amateur in the home assistant world I got it up and running with ease. I did follow another blog because I was completely unfamiliar MQTT, and they seemed to mention that the “sensor:” in configuration.yaml was capitalized in the initial instructions, which causes errors. I had chatGPT write a script for me if the sensor was below 10, 5, and 1 to send an alert and do so everyday until I filled it. Waited until my salt was low to test and it worked! Thanks. I looked around for something like this for a long time. Well done
Tried placing an order using Edge Chromium browser and it gave me no way to proceed with paying for the order
There seem to be some error in the console:
Did not work neither with card payment nor paypal.
I was really hoping to order one for myself.
… after a few retries it seem to have worked! Can you confirm that you got an order from me (Niklas in Sweden)
I received the order and shipped the package
Hi @ErikNL,
I just put my email on the waitlist.
If the holdup is just 3D printed enclosures can you ship it sooner without the enclosure and I can print it on my own 3D printer? (assuming you could provide an STL or STEP)
Just thought I would share how I have integrated this sensor in to my automations.
Perhaps it can be used by others too, or serve for inspiration.
In short:
This automation monitors the salt tank level using sensor.salt_tank_percentage
.
It triggers warnings and critical alarms, sending notifications via notify.notify
and notify.smtp_microsoft365
and creates Microsoft Tasks using o365.new_task
for a defined O365 sensor.
The automation also keeps track whether a warning or a critical alarm is active or not using custom boolean entities (I am using helpers to serve this need). These are used to prevent repeated warnings and alarms, and can also be used to trigger e.g. UI visuals to show on the dashboard that you have active warnings/alarms to attend.
Daily reminders are sent at specific times as long as the critical alarm is still active.
Entities used:
sensor.salt_tank_percentage
: Represents the current percentage of salt in the tank. This sensor’s value is crucial for triggering different actions based on specific thresholds.input_boolean.salt_tank_level_warning_triggered
: A boolean entity used to track whether the warning trigger has been activated. This is necessary for preventing repeated warnings until the condition is reset.input_boolean.salt_tank_level_critical_alarm_triggered
: A boolean entity used to track whether the critical alarm trigger has been activated. Similar to the warning boolean, this prevents repeated critical alarms until the condition is reset.
Triggers:
- Warning Trigger: Activates when the salt tank level is between 10% and 25%, not previously triggering the warning boolean.
- Critical Alarm Trigger: Activates when the salt tank level drops below 10%, not previously triggering the critical alarm boolean.
- Above Warning Level Trigger: Activates when the salt tank level rises above 25%, turning off both warning and critical alarm triggers.
- Above Alarm Level Trigger: Activates when the salt tank level rises above 10%, turning off the critical alarm trigger.
- Daily Alarm Trigger: Activates at specific times (08:00, 13:00, 18:00, 22:00) if the critical alarm is active.
Actions:
- Warning Trigger:
- Sends notifications and creates a task to refill the salt tank if the level is below 25%.
- Turns on the warning boolean.
- Critical Alarm Trigger:
- Sends urgent notifications and creates a task to refill the salt tank if the level is below 10%.
- Turns on the critical alarm boolean.
- Above Warning Level:
- Turns off both warning and critical alarm triggers if the salt tank level goes above 25%.
- Above Alarm Level:
- Turns off the critical alarm trigger if the salt tank level goes above 10%.
- Notifies users when the salt tank is no longer critically low.
- Daily Alarm Trigger:
- Sends a daily reminder notification to refill the salt tank if the critical alarm is still active.
YAML:
alias: Monitoring - Salt tank level
description: Monitors the salt tank level in the water filtration room
trigger:
- platform: template
value_template: |
{{ 10 <= states('sensor.salt_tank_percentage') | float < 25 and not
is_state('input_boolean.salt_tank_level_warning_triggered', 'on') }}
id: trigger_warning
- platform: template
value_template: |
{{ states('sensor.salt_tank_percentage') | float < 10 and not
is_state('input_boolean.salt_tank_level_critical_alarm_triggered', 'on') }}
id: trigger_alarm
- platform: numeric_state
entity_id: sensor.salt_tank_percentage
above: 25
id: trigger_above_warning
- platform: numeric_state
entity_id: sensor.salt_tank_percentage
above: 10
id: trigger_above_alarm
- platform: template
value_template: |
{{ (now().strftime('%H:%M') in ['08:00', '13:00', '18:00', '22:00']) and
is_state('input_boolean.salt_tank_level_critical_alarm_triggered', 'on') }}
id: trigger_daily_alarm
action:
- choose:
- conditions:
- condition: trigger
id: trigger_warning
sequence:
- service: notify.notify
data:
title: Salt tank level is below 25%. Refill soon!
message: >-
Salt tank level is below 25% (currently at {{
trigger.to_state.state }}%). Refill soon!
- service: notify.smtp_microsoft365
data:
title: Salt tank level is below 25%. Refill soon!
message: >-
Salt tank level is below 25% (currently at {{
trigger.to_state.state }}%). Refill soon!
- service: o365.new_task
target:
entity_id: sensor.house_o365
data:
subject: Refill salt tank
description: >-
Salt tank level is below 25% (was at {{ trigger.to_state.state
}}% when this task was created). Refill soon!
due: "{{ (now() + timedelta(days=7)).strftime('%Y-%m-%d') }}"
reminder: >-
{{ (now().replace(hour=8, minute=0, second=0) +
timedelta(days=7)).strftime('%Y-%m-%d %H:%M:%S%z') }}
- service: input_boolean.turn_on
target:
entity_id: input_boolean.salt_tank_level_warning_triggered
data: {}
- conditions:
- condition: trigger
id: trigger_alarm
sequence:
- service: notify.notify
data:
title: Salt tank level is critically low (below 10%). Refill NOW!
message: >-
Salt tank level is critically low (below 10% (currently at {{
trigger.to_state.state }}%)). Refill NOW!
- service: notify.smtp_microsoft365
data:
title: Salt tank level is critically low (below 10%). Refill NOW!
message: >-
Salt tank level is critically low (below 10% (currently at {{
trigger.to_state.state }}%)). Refill NOW!
- service: o365.new_task
target:
entity_id: sensor.house_o365
data:
subject: Refill salt tank ASAP!
description: >-
Salt tank level is critically low (below 10% (was at {{
trigger.to_state.state }}% when this task was created)). Refill
NOW!
due: "{{ (now() + timedelta(days=1)).strftime('%Y-%m-%d') }}"
reminder: >-
{{ (now().replace(hour=8, minute=0, second=0) +
timedelta(days=1)).strftime('%Y-%m-%d %H:%M:%S%z') }}
- service: input_boolean.turn_on
target:
entity_id: input_boolean.salt_tank_level_critical_alarm_triggered
data: {}
- conditions:
- condition: trigger
id: trigger_above_warning
sequence:
- service: input_boolean.turn_off
target:
entity_id: input_boolean.salt_tank_level_warning_triggered
data: {}
- service: input_boolean.turn_off
target:
entity_id: input_boolean.salt_tank_level_critical_alarm_triggered
data: {}
- conditions:
- condition: trigger
id: trigger_above_alarm
sequence:
- service: input_boolean.turn_off
target:
entity_id: input_boolean.salt_tank_level_critical_alarm_triggered
data: {}
- service: notify.notify
data:
title: The salt tank is no longer below critical level
tag: ha_salt_tank_level_critical_daily_alarm
message: >-
The salt tank is no longer below critical level (currently at {{
states('sensor.salt_tank_percentage') }}%).
- conditions:
- condition: trigger
id: trigger_daily_alarm
sequence:
- service: notify.notify
data:
title: Refill the salt tank today!
message: >-
This is a daily reminder to refill your salt tank since it is
still critically low (currently at {{
states('sensor.salt_tank_percentage') }}%).
data:
persistent: true
tag: ha-salt-tank-level-critical-daily-alarm
color: "#FF0000"
- service: notify.smtp_microsoft365
data:
title: Refill the salt tank today!
message: >-
This is a daily reminder to refill your salt tank since it is
still critically low (currently at {{
states('sensor.salt_tank_percentage') }}%).
I’ve had some problems with the distance. I measured the exact distance of a full and an empty tank from the sensor with a tape measure and entered this on the configuration page. But that is not the distance it measure with the sensor it itself. So I waited until the tank was at a low level and looked at the value it received in HA. Then filled it and checked which value it measured and entered it as a full level. Now the percentage matches. It looks like the sensor needs an offset.
It would be useful if you could see the current value that the sensor is currently measuring on the config page. Then you can easily set it up.
At the moment, I’m in the midst of managing some private matters, which have temporarily impacted my ability to fulfill orders. I’m truly sorry for any inconvenience this may cause. I am planning to resume sales in March, once things have settled down.
Best wishes ErikNL and hope to see you back soon. Thank you for your work on this.
I’m in the market for a Sentry when you have another batch. on the indie mailing list.
Some questions for the wider group:
- Is there any feedback on reducing the update frequency? I imagine once per hour would still be more than enough and like to minimise readings. - where the update frequency is lengthened, is anybody putting their device into deep sleep in between?
- ESPhome vs. MQTT - any advantages to either since ErikNL’s progress with ESPhome approach?
- Any more advances in a self contained battery-powered option?
I am thinking of possibility (and risks) of adding a flow sensor to the GPIO to check and monitor softener output - has anybody tried this already, appreciate feedback if so.
Many thanks
Just came across this and interested as I’ve been meaning to get something for my softener for years!
My initial question as someone else posted about some time ago is the potential of corrosion. Salt softeners are very harsh environments with salt and moisture. My old Kinetico softener has gone through stainless steel door hinges and even the kitchen cabinet door hinges where the softener is positioned have corroded badly. My worry is any exposed metal WILL eventually corrode - looks like the USB power port is exposed? I would 3D print my own enclosure I think and encase the USB connector. Are there any other parts open to the environment? The laser sensor?
Would you consider selling just the PCB?
Also interested in the ESPHome vs MQTT question. I have had MQTT running in the past on another HA instal but don’t have it running now. I see it as yet another service that can fail and take up system resources, so ESPHome would seem to make sense?
Thanks.
I’s been a long while, but as some of you might already have noticed, I finally have a batch of salt sentries back in stock!
I’ve been using it in my own water softener for about 3 years now, and do not have any corrosion issues at all. The usb connector is indeed exposed, as it the sensor itself.
I currently only off the Salt sentry with the 3d printed enclosure.
If you rather not use MQTT, using ESPHome would be the right way to go, I tested it a while back (config is somewhere in this thread) and it worked pretty well.
I’ve also been working on a custom integration, but that was quite a bit harder than I thought, so I don’t expect to finalize that anytime soon.
With the standard firmware, the device sends a measurement every 5 minutes.
This may sound like a boneheaded question, but you were very specific about noting that your system uses salt blocks. Is there any reason why this wouldn’t work as well for those of us with systems that use salt tabs that come in bags?
I use tablets (in the US, the kind you get from homedepot in 40lb bags). Salt sentry works great for measuring our tank.
I use tablets with ToF sensor and it works great. Not using Salt Sentry but very similar hardware with ESP32-C6 and ESPHome.
Do you think this could work in a septic tank to see if it is backing up?
As reported by @fred99 , tablets should not be a problem. The only issue that I’m aware of is that loose crystals (like these: https://www.diamondcrystalsalt.com/product/water-softener-salt-crystals) can sometimes give some inaccurate readings.
It would probably work, if the fluids in the tank are not too clear (The sensor I use is not that suitable for clear water).
The sensor has a 50mm to 1200mm range of distance it can measure, so depending on your tank it might be usable or not.
@ErikNL i just received mine and am trying to hook it up on a different platform (Homeseer). I’m severely visually impaired and not the brightest lightbulb in the room, so I need a little extra help. I have the device setup with my mqtt broker ip/port/topic and the dimensions for full and empty. The device shows up on my router table and is shown as a client in the mqtt plugin I’m using. The salt sentry device webpage shows mqtt status as connected. Where I’m lost, and forgive me as I’m totally new to mqtt and this is my first device using mqtt, is in the instructions (I know, it’s for home assistant but I thought it would be similar-ish) and creating devices for salt_sentry and salt_sentry_distance. I can’t figure out where in the mqtt broker/plugin settings to do this. A lot of this could be me as I use a screen reader and most all of this stuff is not fully compatible and does not get read aloud for me to understand. I messaged the mqtt plug-in dev on the Homeseer forum and he says that I need to setup esphome and link that to mqtt and the device. So, I’m totally confused here. I know I’m right there, like at the finish line, but just not getting it. Any chance that you, or anyone, could dumb this down enough for me to understand? I know it’s a different platform and all, but I’m hoping someone is familiar with it. Thank you for any assistance. I can’t wait to get this working! It’s an excellent idea! I’m mobility challenged as well so loading that salt bin is cumbersome and I always forget. I’m wanting to set up the empty height right where a single, small bag of salt will top it up and automatically add salt to my shopping list or maybe even order it for delivery for me.