hhaim / hass Goto Github PK
View Code? Open in Web Editor NEWhome assistant and appdaemon scripts and configuration file
home assistant and appdaemon scripts and configuration file
Hi, your tasmota_sensor looks promising :)
Would it be possible to add any description?
I've tried to test it, but simple adding of tasmota_counter.py
seems to be not the proper way.
No issue, but i wanted to share my 3d printed rain gauge, which may work quite well. Atm I'm just testing it. It uses a small Zigbee Aqara Door Sensor to report open/close everytime the gauge switches.
Any idea how this can be integrated in your solution?
https://photos.google.com/photo/AF1QipPsEOi6qeQwNFq2c2TEBiIA5mh4LYOdDKFP-1TJ
heat_app.py has the following imports:
import ada.schedule import ada.temp_sensor import ada.temp
I am only interested in the CWBIrrigation and I do not see why there would be a dependency on ADA in that. Can you remove this dependency or make it optional?
First off, this is really cool! Thanks for taking the time to share your code and write a very clear wiki!
Question:
I see you used the
Sonoff 4 ch pro to switch on/off the taps
But how does a relay turn the taps on/off... Im a bit new, but i understand the relays are just the on/off switch. They must be attached to some device that turns the tap on/off. If so, what is the device you use to turn the water on and off?
I know you linked to the Orbit Sprinkler but this doesnt seem like something electronic that can be controlled by a relay.
Unless i misunderstood?
A couple spelling mistakes:
several instances of typo: "liter=litter" (i edited the page)
typo: "use-case"="usec-case" (im new to github - i couldn't, or dont know how, to edit the wiki page)
Also i rotated the image for you (although it could be more clear) for item #3. https://i.imgur.com/1XJbmQa.png
Toda Raba!
P.S.
I know you must be busy, but pictures of your devices for out door irrigation would be a reallly cool addition to this page :)... you can just throw them in anywhere
This would be really helpful for easy installation and updates. Thanks!
It is probably a hardware capacitor issue.
To fix this in software:
This would allow esp devices to run relays for irrigation etc based on the algorithmn used by this addon.
I expect this part of heat.app.py (mandatorily used by wbirrigation) to cause unwanted ios deivce tracking notifications.
Maybe you can confirm this and make it user on/off or tell me how to disable it at all.
class TrackerNotification(hass.Hass):
def initialize(self):
self.notify("start TrackerNotification")
self.listen_state(self.do_tracer_change, 'device_tracker')
def do_tracer_change (self,entity, attribute, old, new, kwargs):
if old != new:
entity = entity.split('.')[1]
t=datetime.datetime.now().strftime("%H:%M:%S")
notify_msg=" {3} tracker *{0}* *{1}* to *{2}* ".format(entity,old,new,t)
self.log(notify_msg);
self.notify(notify_msg)
This leads to unwanted output like this (information not needed and unwanted for me personally):
Hi. I am trying to install your custom component, but it doesn't seem to work for me. I copied the folder tasmota to the folder custom_components and added this -
to the my configuration.yaml file. After restart, in states sensor.hot_water_total - shows unavailable
On the other hand, this component works fine.
I started the mgt_dump service and this is what we have:
tele / tasmota_4B0C0B / SENSOR, {"Time": "2020-08-02T11: 05: 20", "COUNTER": {"C1": 9, "C2": 311, "C3": 53}, "ANALOG" : {"A0": 4}, "DS18B20": {"Id": "021618547BEE", "Temperature": 33.3}, "TempUnit": "C"}
tele / tasmota_4B0C0B / STATE, {"Time": "2020-08-02T11: 06: 20", "Uptime": "0T07: 23: 12", "UptimeSec": 26592, "Heap": 26, "SleepMode" : "Dynamic", "Sleep": 250, "LoadAvg": 37, "MqttCount": 1, "Wifi": {"AP": 1, "SSId": "Igor", "BSSId": "D0: 54 : 2D: 01: 24: 70 "," Channel ": 1," RSSI ": 62," Signal ": - 69," LinkCount ": 1," Downtime ":" 0T00: 00: 03 "}}
tele / tasmota_4B0C0B / SENSOR, {"Time": "2020-08-02T11: 06: 20", "COUNTER": {"C1": 9, "C2": 311, "C3": 53}, "ANALOG" : {"A0": 4}, "DS18B20": {"Id": "021618547BEE", "Temperature": 33.3}, "TempUnit": "C"}
tele / tasmota_4B0C0B / STATE, {"Time": "2020-08-02T11: 07: 20", "Uptime": "0T07: 24: 12", "UptimeSec": 26652, "Heap": 24, "SleepMode" : "Dynamic", "Sleep": 250, "LoadAvg": 26, "MqttCount": 1, "Wifi": {"AP": 1, "SSId": "Igor", "BSSId": "D0: 54 : 2D: 01: 24: 70 "," Channel ": 1," RSSI ": 70," Signal ": - 65," LinkCount ": 1," Downtime ":" 0T00: 00: 03 "}}
tele / tasmota_4B0C0B / SENSOR, {"Time": "2020-08-02T11: 07: 20", "COUNTER": {"C1": 9, "C2": 311, "C3": 53}, "ANALOG" : {"A0": 4}, "DS18B20": {"Id": "021618547BEE", "Temperature": 33.3}, "TempUnit": "C"}
MQQT works!
Home Assistant version 0.113.2
What am I doing wrong?
Hello,
I am trying tu use accumulator to count "ON time" of the heater.
It works, but in the weird way:
If I restart hassio, accumulator starts accumulate, does not matter the state of the switch (relay) in the time of hassio restart.
It simply counts in both cases ie. relay is ON or OFF after hassio restart.
If it is OFF I have to manually ON and back to OFF again to stop counting.
Switch configuration:
switch:
- platform: mqtt
name: "heater_b"
command_topic: "cmnd/bathroom/power"
state_topic: "stat/bathroom/POWER"
qos: 1
payload_on: "ON"
payload_off: "OFF"
Accumulator config:
- platform: accumulator
name: bathroom_clock
entity_id: switch.heater_b
state_on: 'on'
state_off: 'off'
Is there any way around hot to make it working properly?
Hi Haim
I receive this error all the time, and it doesn't make any sense. Any idea what it means and how to handle it?
2020-04-07 12:00:00 ERROR (MainThread) [custom_components.wb_irrigation.sensor] wbi_raw_data {'coord': {'lon': xxxxx, 'lat': xxxx}, 'weather': [{'id': 800, 'main': 'Clear', 'description': 'clear sky', 'icon': '01d'}], 'base': 'stations', 'main': {'temp': 15.91, 'feels_like': 7.72, 'temp_min': 15, 'temp_max': 16.67, 'pressure': 1032, 'humidity': 26}, 'visibility': 10000, 'wind': {'speed': 8.2, 'deg': 140}, 'clouds': {'all': 0}, 'dt': 1586253600, 'sys': {'type': 1, 'id': 6878, 'country': 'AT', 'sunrise': 1586233220, 'sunset': 1586280795}, 'timezone': 7200, 'id': 2771940, 'name': 'xxxxx', 'cod': 200}
@hhaim @theunreal hi guys, thanks for the great project. I am new to homeassistant. Trying to follow your guide and set up a pulse sensor water meter. I have flashed a wemo D1 mini with Tasmota. Now I need to integrate it into my homeassistant 0.95.4. I have homeassistant, mosquitto, grafana, influxdb, etc. all running in docker containers under docker-compose. Mosquitto is accessed with login/password for each client. How do i configure the wemo and your custom-components/ to work with my setup? Thank you
wb_irrigation_rain_day and wb_irrigation_rain(?) gets reset to ZERO in case of HA restart (or reboot of course).
If the restart is after some heavy rain, this will lead to a wrong remaining EV value.
Hi,
thanks for this great project!
As a first step I tried to use the schedule class for a simple switch.
So I implemented a class
import appdaemon.plugins.hass.hassapi as hass
import datetime
import schedule
class ScheduleTest(hass.Hass):
def initialize(self):
self.log("start scheduleTest {0}".format(str(self.args)));
self.sch = schedule.Schedule(self,
self.args['schedule'],
self.on_schedule_event,None)
self.sch.init()
def on_schedule_event(self,kwargs):
self.log("event occured" )
and initiated it as
simple_schedule_test:
module: simpleSwitch
class: ScheduleTest
schedule:
- { mode: c, start: { t: "11:19:00", d: 7}, end: { t: "11:20:00", d: 7} }
So I'd expect a "event occurred" msg in my log file.
Whenever run_daily fires (in this case 11:20:00 on sun) an event I got the message (in error.log)
Unexpected error during exec_schedule() for App: simple_schedule_test
2020-09-06 11:20:00.169493 WARNING simple_schedule_test: Args: {'name': 'simple_schedule_test', 'id': '29f9b8d5fcec4692a7e336576f353119', 'callback': <bound method Schedule._cb_event of <Schedule with 1 rules>
=================================
'timestamp': datetime.datetime(2020, 9, 7, 9, 20, tzinfo=), 'interval': 86400, 'basetime': datetime.datetime(2020, 9, 7, 9, 20, tzinfo=), 'repeat': True, 'offset': 0, 'type': None, 'pin_app': True, 'pin_thread': 0, 'kwargs': {'interval': 86400, 'constrain_days': 'sat', 'rule': , 'state': 'off'}}
2020-09-06 11:20:00.169958 WARNING simple_schedule_test: ------------------------------------------------------------
2020-09-06 11:20:00.170932 WARNING simple_schedule_test: Traceback (most recent call last):
File "/Users/fiedel/appdaemon/lib/python3.8/site-packages/appdaemon/scheduler.py", line 181, in exec_schedule
await self.AD.state.set_state(
File "/Users/fiedel/appdaemon/lib/python3.8/site-packages/appdaemon/state.py", line 472, in set_state
old_state = deepcopy(self.state[namespace][entity])
File "/usr/local/opt/[email protected]/Frameworks/Python.framework/Versions/3.8/lib/python3.8/copy.py", line 146, in deepcopy
y = copier(x, memo)
.............
..........TypeError: cannot pickle '_thread.RLock' object
2020-09-06`` 11:20:00.171552 WARNING simple_schedule_test: ------------------------------------------------------------
2020-09-06 11:20:00.172243 WARNING simple_schedule_test: Scheduler entry has been deleted
2020-09-06 11:20:00.172565 WARNING simple_schedule_test: ------------------------------------------------------------
I'm running Appdaemon (Version 4.0.5) in a virtualenv with, as you can see, python 3.8.
Initializing the app works fine:
2020-09-06 11:18:59.594615 INFO AppDaemon: Found 1 total apps
2020-09-06 11:18:59.599411 INFO AppDaemon: Terminating simple_schedule_test
2020-09-06 11:18:59.600421 INFO AppDaemon: Initializing app simple_schedule_test using class ScheduleTest from module simpleSwitch
2020-09-06 11:18:59.602966 INFO simple_schedule_test: start scheduleTest {'module': 'simpleSwitch', 'class': 'ScheduleTest', 'schedule': [{'mode': 'c', 'start': {'t': '11:19:00', 'd': 7}, 'end': {'t': '11:20:00', 'd': 7}}]}
2020-09-06 11:18:59.605594 INFO simple_schedule_test: event occured
2020-09-06 11:19:00.161988 WARNING AppDaemon: Logged an error to .homeassistant/conf/logs/errors.log
2020-09-06 11:20:00.171914 WARNING AppDaemon: Logged an error to .homeassistant/conf/logs/errors.log
I'd love to integrate this app but to be honest I'm a little bit lost at this stage.
Thank you for tips, hints, comments
Michael
When the irrigation is triggered automatically, I receive the corrent notification, but I also get the manual start notification.
Example of the logs:
2020-04-05 07:00:00.208066 INFO wb_irrigation: irrigation event for p1
2020-04-05 07:00:01.170713 INFO wb_irrigation: 07:00:01 irrigation time tap p1 timer 15 min
2020-04-05 07:00:02.629552 INFO wb_irrigation: turn on by user p1 30 min
2020-04-05 07:00:02.776351 INFO wb_irrigation: 07:00:02 irrigation time tap p1 manual 30 min
2020-04-05 07:15:58.068002 INFO wb_irrigation: irrigation stop for p1 on
Is it possible to use this Weather based irrigation solution to toggle an smart switch? I have a very basic setup for my sprinklers, just a smart switch that will turn on/off my water pump. I was looking for something like this and itβs all I want, but I need to be able to set an other action.
Can you give me some directions to get started? I installed the component, I see all the sensors, but I can't find a way to include my smart switch.
So I want/need to be able to start the water pump (smart switch) when the ev_day (or fao56?) reaches a certain value at a certain time. Turn off the switch after x minutes. I guess another value must be updated with the amount of water that is used to update the ev_day (or fao56?)?
Also a small suggestion, maybe rename some off the sensors. If you are new into this, ev_day, fao56, p1, wp1,... doesn't say much. If you give this a more user friendly name, people will understand it more easily.
Thanks in advance!
During my config checking got
Configuration invalid
Integration not found: water_monitor
here is my setup I used
in configuration.yaml
''
variable: !include variable.yaml
water_monitor:
module: heat_app
class: CWaterMonitor
sensor_water_total: sensor.water_total
sensor_water_leak_detector: variable.water_leak_detector
#sensor_water_bursts: variable.water_bursts
sensor_water_bursts: variable.water_usage_bursts
watchdog_duration_min: 50
watchdog_leakage_ticks: 3
max_day: 2000
max_burst_l0: 400
max_burst_l1: 600
taps_switchs: [ switch.wbi_p1] # when one of them is enabled move to burstl1 ''
in sensor.yaml
``- platform: tasmota
name: "water_total"
stopic: ECS
id: 1
max_valid_diff: 2000
icon: mdi:water
expire_after: 300
value_template: "{{ ((0 + (value))|int) }}"
in variable.yaml
''
water_leak_detector:
value: 0
restore: true
attributes:
friendly_name: 'water leaks detector'
unit_of_measurement: "l"
water_bursts:
value: 0
restore: true
attributes:
friendly_name: 'water usage bursts'
unit_of_measurement: "l"
''
Hello, after upgrade HA to 117 version custom component tasmota stop working
2020-11-22 23:45:21 WARNING (MainThread) [homeassistant.loader] You are using a custom integration for tasmota which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant.
2020-11-22 23:45:21 ERROR (MainThread) [homeassistant.config_entries] Error occurred loading configuration flow for integration tasmota: No module named 'custom_components.tasmota.config_flow'
2020-11-22 23:45:21 ERROR (MainThread) [homeassistant.config_entries] Error occurred loading configuration flow for integration tasmota: No module named 'custom_components.tasmota.config_flow'
These are errors in the server log file.
Maybe due to the fact that they added integration
New Integrations
We welcome the following new integration this release:
Advantage Air, added by @Bre77
Gree, added by @cmroche
Profiler, added by @bdraco
Ruckus Unleashed, added by @gabe565
Tasmota, added by @emontnemery
Xbox, added by @hunterjm
A declarative, efficient, and flexible JavaScript library for building user interfaces.
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. πππ
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google β€οΈ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.