Opensprinkler tutorial
- #Opensprinkler tutorial software
- #Opensprinkler tutorial code
- #Opensprinkler tutorial plus
- #Opensprinkler tutorial series
The code defines a new class called ShiftRegisterSwitch which implements some methods that are required to be an esphome switch. It creates a global object named sr for accessing the shift register pins. I suggest reading through the esphome docs on custom switches to get a baseline for what we’re trying to do here.Įssentially the below code makes use of the open source ShiftRegister74HC595 library. Custom Switch Classįirst off, we’ll need to write a little C++ code to model each one of the shift register outputs as an esphome switch object.
However, we can make use of the Custom Switch Component to implement our own. Unfortunately, there is not a dedicated 74HC595 component (yet). If you’ve read some of my previous tutorials, I’ve recently been using esphome for all my DIY ESP8266 projects. Again, refer back to the my DIY WiFi Sprinkler Controller using ESP8266 (Part 1) article to learn more about the shift register. You could extend this to more than 8 zones by simply daisy-chaining shift registers together to get more IOs. My design uses a 74HC595 shift register to control the 8 relays individually. ESPHomeįirst off, let’s tackle the firmware running on the NodeMCU ESP8266. You can also view the Sprinkler Firmware on GitHub. You can view my Home Assistant configuration on GitHub.
#Opensprinkler tutorial software
Today’s article will be looking closer at the software of the system. It goes in depth to all the components used. Last week I wrote an article on the hardware involved in the project, definitely check it out if you haven’t already.
#Opensprinkler tutorial series
To close the window, I'll use a raspberry with a hacked sonoff SV.īy the way: I didn't buy the kit, because I didn't know if I can make the modifications.Welcome to part 2 of my series on my DIY WiFi Sprinkler Controller using ESP8266. This is my question: doing your hack, you saw how the sensor functions do you think that I can bypass the mechanical contact, to link my rain sensor to the rainbird sensor somehow? I know that it is using hygroscopic discs, which in presence of water will press a mechanical contact which will wirelessly will send a message to the controller. So, I came with an idea to open the sensor and somehow connect it to a rain sensor like thisīut, I don't know how the sensor works. the kit reaction is too slow, because the sensor reacts only when the rain is too heavy (5 liters/sqm) it is OK for an irrigation system where time reaction doesn't matter but for my attic will be a disaster. and the wireless sensor I'm thinking this will fit perfect with my needs, but it has problem: And because this package has a controller with battery indicator, signal strength. I'll tell you what my project is: I need to close automatically an attic window when rain starts. I searched a lot regarding projects with RainBird WR2-RFC, but I found just your post here.Īs I see it is an old project, and I hope you are still present in this forum. Pretty easy when you don't need a display or buttons! I hope to be able to program the relay station using MicroPython but if that proves to be too buggy I'll use Arduino instead. Other than that, I'll need a regulated DC power source. Another option is to use an I2C port expander to control the relays which would take care of the buffering too. I don't think the current output capability of the chip is enough to drive the relays so I'll have to use a buffer chip. It should be perfect for this since it has 9 GPIO and I have 8 sprinkler zones and a rain sensor. I'll use JSON for the machine-to-machine communication.įor the remote relay control station, I want to use the fully broken out ESP8266 module from to control the relays. I'll need to read through the code and find all the places where the actual hardware is being controlled or read and modify that.
#Opensprinkler tutorial plus
Another plus is that the OpenSprinkler Pi project is programmed in Python. I have one already and it should have enough horsepower to expand into more home automation tasks I have planned. A RaspberryPi will be the main controller for two reasons. I want to break this link and have the hardware control separated from the software. The OpenSprinkler project currently has the software and hardware control on same board. This is basically a software project with a small hardware component.