kampto
April 16, 2021, 2:58pm
19
I have a 2500gal tank to supply my house. Using an ultrasonic sensor on the lid.
https://www.amazon.com/gp/product/B07V6HSN8B/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1
That sensor wired into an ESP32 micro controller coded with Arduino and using Hubduino library.
On the Hubitat side using a DH that can report the tank level as a percentage and how many gallons is left.
/* Child Temperature Sensor Advanced
*
* Copyright 2017 T. Kamp (kampto)
* -Starting point from 2017 @ogiewon Smartthings ST_Anything child device DH. Applied major changes/feature additions overtime to fit different applications.
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at:
* http://www.apache.org/licenses/LICENSE-2.0
* Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES
* OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
*
* NOTES: Use the multipler and decimal position options to convert numbers. EX: 12489mV to 12.49V.
* If availible you can also modify decimal on Hub dash or Frontend apps (sharptools, etc..)
* Smartthings: This DH will not compile on Smarthings IDE as of 2020, Its built for Hubitat. Smarthing IDE seems to have changed/broken some legacy Groovy code.
* SharpTools and other frontends: If you switch to this DH with the extra attributes you will need to go (Hubitat) Apps/sharptools/next/done to get them to take.
*
* Change Revision History:
* Date: Who: What:
* 2020-12-05 kampto Added option to not send Zero value
* 2020-11-29 kampto Added Max/Min Value attribute, resetable, notes, unit conversion
* 2020-09-23 kampto Converted from ST to Hubitat format, with eneble/disable debugging, removed color map and tiles
* 2019-07-01 kampto Added decimal poistion and multipler
This file has been truncated. show original