Forum Replies Created
-
AuthorPosts
-
September 19, 2017 at 10:53 am in reply to: safe shutdown on power loss with larger capacitor #47805
JimSParticipantI slipped a decimal place in the capacitance I think and changed the value above. That’s a huge capacitor (or several).
I don’t think most supercapacitors are used directly but have a switching converter so more energy can be extracted by allowing more voltage drop at the cap.
I have a lightly loaded UPS for my routers and such so am thinking of injecting power from UPS on unused ethernet lines. The failure of the main power line could be detected and shutdown the Pi. From what I have read NUT is a UPS supervisor that can run on the Pi and handle everything including restart.
Looks like it could even handle multiple machines via network communication.
JimSParticipantLooks good! I have a AdaFruit LCD that uses the MCP23017. I can’t test it right away but will give it a try. It appears that I can define the MCP23017 and it should work? The use of the small adapter board with pull ups isn’t clear to me – when is that to be used?
You say “temporary” and I am noticing this idea has been kicking around for over two years. Might be one of those permanent temporary things… 🙂
JimSParticipantMissed that somehow. Maybe because it wasn’t obvious it was the schematic. Thanks!
JimSParticipantI found this:
https://github.com/poblabs/OpenSprinkler-Push-Notifications/blob/master/ospi_push_notifications.pyIt is more complex than I need but looks usable as a guide for some of the syntax and such like.
JimSParticipantThat helps but I don’t have a lot of programming experience so I mostly hack up others code. 🙂 Any simple examples that would get me started?
JimSParticipantAre the CAD files for this available? I am thinking of making the case slightly bigger to hold some additional parts and maybe a display.
JimSParticipantQuality/speed of SD card may solve other issues but not this one. If the system is writing to the card when power goes down it may stop mid-cycle andcorrupt the card beyond what the startup checks can recover from. It doesn’t happen every time but it is a definite risk.
A battery backup will help for short outages but is only completely effective if combined with software to shut the board down before the battery runs out. In my case I had a backup battery but the outage lasted 5 hours and was longer than the battery could run the board so eventually I had a uncontrolled shutdown just the same as if I didn’t have any backup battery – possibly worse because it might do strange things as the voltage slowly dropped rather than cutting off quickly. Handling of this would be a nice feature to add to the OSPi and Beaglebone versions. Best case would be that the circuit holds off shutdown for several minutes (which would cover outages where power just briefly goes out) and then shutdown and remove power to the board to handle long outages. Many of the circuits I have seen don’t remove power from the board so it still draws a very small current after shutdown. This isn’t a real problem with running the battery down except in VERY long outages (probably weeks or even months). The real issue I see with this approach is the board doesn’t restart when power source comes back on – power has to be manually disconnected and reapplied.
If you google this issue you will get lots of hits, circuits, and opinions which may or may not be accurate…
JimSParticipantThe signals needed don’t exist on the OSPi. You would need to add capability to monitor current or output voltage. Output voltage would require sensing each output. If you only have one zone on at a time you could peak detect by using a diode to each output and monitor the single combined signal.
A better way (IMHO) is to monitor total current for the system. One sensor is needed. Then you can detect additional things such as open valve coils, bad wiring to valves, etc and the additional wiring is simplified as well. You would need to measure what normal current is for each combination of zones that you will use. Then apply some tolerance to get a window of acceptable values. This calibration step could be automated. The current sensor would need to be added and read with an A/D.
Here’s a link with various suggestions including this one:
http://www.avrfreaks.net/forum/detecting-open-wiringcoils-sprinkler-system
JimSParticipantI second that. All of the above (I could solder the header). I would also like to see buttons for some local control. Something like the Adafruit LCD for the pi – although it uses a different chip than what is being worked on for an open sprinkler pi lcd. And there is physical interference with the case mounting posts.
Would be nice if the ethernet and USB connectors were closer to the side of the case so things could be plugged and unplugged. I am guessing it was done that way so a wireless USB dongle would fit inside the case…
JimSParticipantI am still trying to get my head around the software. There seems to be several choices (unified, python interval program, and sprinklers_pi). I haven’t found much to guide a newbie on the choice except for the comments in the manual that you can choose which one when you start up the system. I want to add a LCD/keypad for local control/maintenance people. People have commented that it’s possible and that they have done it but haven’t posted the details/code (that I know of). Am I missing something or these things not detailed very well? I suppose some of this may become more clear once I get a system and start playing with it but I don’t want to spend lots of time fighting with software. Want to make sure it will do what I want before I jump in.
Was just looking at the github link Ray posted. It links to a PIC I2C decoder. Wondering if the code is compatible with this:
http://www.adafruit.com/products/1115
which uses a MCP23017 I2C chip.Can someone confirm this was rolled into the latest unified software? I see mention of the LCD. Is there any keypad support?
JimSParticipantThanks Ray. It looks like the layout matches the RPi if the RPi were flipped over so if I use long enough pins any board that would plug into the RPi would plug right in sitting above the RPi. It’s obvious now – don’t know how I missed that.
JimSParticipantRegarding the addition of the lcd, it could be stacked above the pi board but the board is faced the wrong way for that. If the pins needed were added to the OSPi board offset from the edge of the RPi board then with long headers it could be easily mounted. A taller case would probably be needed but I would think it would fit into the higher case that has been noted other places (would need the user to cut the holes). I have sketched the stacking if my description isn’t clear. I could also add a board between the RPi and OSPi to bring the header to the side with no changes to the Pi or OSPi but the height increases(top sketch).
I take it the note on hosting the webUI on the RPi is in regard to no network connection. I realize I wouldn’t get automatic time setting/sync so the time would drift a bit and have to be set manually. The battery should handle power outages though. Any other limitations with no network connection?
For some reason the jpg file doesn’t seem to show up when I post.
JimSParticipantIf I could have two sources and just select which source for each zone that would be sufficient for me. I don’t ever need to activate more than one master valve. Once set up, if a zone is activated the proper source valve is automatically triggered too.
JimSParticipantI see how that would work but it sounds like it would require setup of both times which would give poor WAF. Most of the time we use this for watering bushes rather than grass. I have several hose faucets around the yard on zone valves. If something needs watering we hook up a hose and then manually set a time for that zone. I was hoping to be able to do this from a smart phone to keep from going back to the controller as the yard is big. How would I do this without some code changes? Or minor code changes? I would like to just be able to say run zone 3 for 30 minutes (now) and have the pump kick on if its a zone that is set for the pump source.
JimSParticipantI was hoping for something a bit more automatic such as being able to set zones 1 and 4 to run with master valve 1 and zones 2, 3, and 5 from master valve 2. I currently do that with a standard sprinkler controller by using diodes to all zones used with master 2 and building triac outputs for master 1 and master 2. If master from main controller is on and no signal from diode circuit I enable master 1 output. If master from main controller is on and there is signal from diode circuit I enable master 2 output. I could use the same circuitry with opensprinkler but it would be great if it could handle this case in software so the master selection could be reprogrammed.
JimSParticipantThanks but I already figured most of that out. I was looking for a clear yes or no answer.
I looked at the OSPi manual and saw that they had cutouts of some of the connectors on the pi. Since those move on the B+ I am going with the B.
JimSParticipantI understand this is a software thing and I know it can be done. I am more of a hardware guy so was wondering if someone had done something like this or a bit more detail on HOW to do it. I don’t have the OSPi (YET) so am not that familiar with the software. A little over a year ago Ray said it was on the list of things to do here but I guess there wasn’t much call for it…
JimSParticipantI am looking for the very same functionality. Want to be able to program times or manually turn on a zone like a traditional timer and see what is running but still have the computer tie in for automation. Several ways to go about this on the hardware side: Arduino to handle LCD and keypad, maybe LCDproc on the pi side. Any progress on this?
-
AuthorPosts