- This topic has 6 replies, 2 voices, and was last updated 5 years, 4 months ago by Anonymous.
July 12, 2018 at 5:25 am #51090
I’m Norbert from Germany.
I’m using OpenSprinkler on a RaspberryPi with attached relay modules for switching magnetic valves.
Everything works fine 🙂
Now I implemented a dry-running protection for the pump if something goes wrong.
It works by using a temperature sensor.
Now it would be nice if I could see this temperature at OpenSprinkler website.
Can someone tell me where I can find this web pages on my Raspi?
Thanks in advance!
NorbertJuly 17, 2018 at 8:36 am #51170
Is there no way to implement additional info into the website?July 17, 2018 at 3:23 pm #51186
You can, but it requires modifying the firmware and also the UI. Not sure how familiar you are with programming, but all source code is given to you so you can feel free to make any changes you want.July 31, 2018 at 4:11 am #51505
I’m not so familar with programming, a bit python, a bit html, but I’m not a programmer.
I’m looking for some html files but I cannot find any.
Can you tell me how can I start?
Thanks in advance,
NorbertJuly 31, 2018 at 11:32 am #51515
Generally the way to start is to follow some existing variable as an example. There are many variables that you can use as example, such as the device time, the rain sensor status, or whatever is changing dynamically. You can take a look at the API document:
to find some relevant variables, and search in the source code to find where they appear, then start adding your additional variables close to these existing variables.
The UI changes are more tricky, since the UI code is fairly large. The easiest way is to bypass the app, and just add another url, such as /get_temperature or something like that, that is only used to display your additional information. This way it really only requires changing the firmware code and you don’t have to touch the UI code. The downside is that it won’t show up in the main app interface, instead you will have to type http://x.x.x.x/get_temperature to go to the page that displays your additional information.
I really think that this is a good motivation for you to learn programming — one of the main reasons I made all our projects open-source is to serve an educational purpose — no matter how full-featured a product is, it’s not going to fulfill everyone’s need. Learning to program and customize the product is really the best way to make it work for you.August 2, 2018 at 3:35 am #51558
Thank you for your detailed explanations.
I’m on vacation for the next 3 weeks.
After this I will go on.
One Question before, how can I add anothe URL?
What kind of webserver is running on OSPi?August 3, 2018 at 4:08 am #51579
For me I’ve found a solution.
I installed apache on a diffrent port.
So I can see my additional information without touching OSPi Firmware.
- You must be logged in to reply to this topic.