Closed Riaan111209 closed 5 years ago
Riaan, Another user reported a similar problem to what you described only after connecting the power for the irrigation valves (24V AC). It looks like it might be necessary to use a separate 5V power supply for the relays rather than using the 5V power from the Raspberry Pi.
I did not see this problem when using high level trigger relay boards. SIP was originally designed to work with shift registers which are the equivalent of high level trigger.
Hi Dan Thank you for the info. I have high level relays as well. If I use this without the shift registers, which gpio pins are SIP using for the relay triggers. I also have a seperate 5v power supply for the relays.
Kind Regards
On 17 Jun 2017 20:54, "Dan" notifications@github.com wrote:
Riaan, Another user reported a similar problem to what you described only after connecting the power for the irrigation valves (24V AC). It looks like it might be necessary to use a separate 5V power supply for the relays rather than using the 5V power from the Raspberry Pi.
I did not see this problem when using high level trigger relay boards. SIP was originally designed to work with shift registers which are the equivalent of high level trigger.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/Dan-in-CA/SIP/issues/189#issuecomment-309233342, or mute the thread https://github.com/notifications/unsubscribe-auth/ARRkIqW0B1M3ZEZ_26TcxIWukNyjRjbVks5sFCDhgaJpZM4NvE98 .
If you need more than 12 stations you should probably use the shift registers with high level trigger relay boards.
If you want to try without the shift registers you will need to use the "relay_board" plugin. The documentation describing the pins to use is: https://github.com/KanyonKris/relay_board/wiki
You can install the plugin from the SIP plugins page.
Thank you I will install the plugin and try to get the 12 stations working then go for 24 stations.
On 18 Jun 2017 20:16, "Dan" notifications@github.com wrote:
If you need more than 12 stations you should probably use the shift registers with high level trigger relay boards.
If you want to try without the shift registers you will need to use the "relay_board" plugin. The documentation describing the pins to use is: https://github.com/KanyonKris/relay_board/wiki
You can install the plugin from the SIP plugins page.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/Dan-in-CA/SIP/issues/189#issuecomment-309293543, or mute the thread https://github.com/notifications/unsubscribe-auth/ARRkInB9jyg-RYzQ_mAwZMkav0TyfdI3ks5sFWl5gaJpZM4NvE98 .
Hi there!, @Dan-in-CA
im trying to configure my orangepi zero to run SIP. I have downloaded last version or SIP of branch ORANGE, please, check the print out:
takezo@orangepizero:~/OrangeSIP/SIP$ lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description: Debian GNU/Linux 8.8 (jessie)
Release: 8.8
Codename: jessie
takezo@orangepizero:~/OrangeSIP/SIP$ git branch
master
* orange
I also modified the path of home directorey where is located SIP, modified into file sip.sh
The case is, when i try to run the sip, Im getting the following errors:
takezo@orangepizero:~/OrangeSIP/SIP$ sudo python sip.py
[sudo] password for takezo:
ALARM from Example_Sender!: Just and example!
plugins loaded:
mobile_app
plugin_manager
signaling_examples
system_update
Traceback (most recent call last):
Starting timing loop
File "sip.py", line 247, in <module>
set_output()
File "/home/takezo/OrangeSIP/SIP/gpio_pins.py", line 228, in set_output
disableShiftRegisterOutput()
File "/home/takezo/OrangeSIP/SIP/gpio_pins.py", line 169, in disableShiftRegisterOutput
setup_pins()
File "/home/takezo/OrangeSIP/SIP/gpio_pins.py", line 149, in setup_pins
gpio.setcfg(pin_sr_noe, gpio.OUT)
AttributeError: 'module' object has no attribute 'OUT'
thank you so much to support me whith this installation,
BR!
The GPIO error you are getting indicates that the Python GPIO library is not being found. What GPIO library are you using?
@Dan-in-CA
Thank you so much for your answer. Due that i cannot use this software, i have configured a python script with this setup, to control the system via cron:
`#import the library from pyA20.gpio import gpio from pyA20.gpio import port from time import sleep
gpio.init()
gpio.setcfg(port.PA6, gpio.OUTPUT)
gpio.output(port.PA6, gpio.LOW)
sleep(180) gpio.output(port.PA6, gpio.HIGH)`
on the other hand, if I have understood correctly your question , I'm using pyA20 library, but, I have not idea how to configure SIP to use this library..
do i need to configure this library in any file into the SIP?
Hi @Dan-in-CA ,
please could you take a look this last post..?
thanks!
Sorry for the delay. I have been very busy.
I am traveling today and should get back to you tomorrow.
After looking at the code you posted for the cron set up. It looks like the SIP code in the gpio_pins.py file on lines 149 through 152 should b OUTPUT instead of OUT. I pushed an update to the repository. Let me know if this works.
If you will be using a relay board to control the sprinkler valves that will bring another set of problems. It may require making a modified version of the relay_board plugin.
hi Dan,
seems that now i can start the system, but the system start with all valves on/actives, i mean with valves with status open. When i try to stop the stations, seems that the system accepts the command "stop all zones", pressin the button of the gui, but nothing happens, the valvules continue open/active but the gui show all zones stopped.
here you have the log when i start the system:
takezo@orangepizero:~/OrangeSIP/SIP$ sudo /usr/bin/python sip.py ALARM from Example_Sender!: Just and example! plugins loaded: mobile_app plugin_manager signaling_examples system_update zones changed [Starting timing loop 0, 0 , 0, 0, 0, 0, 0, 0] http://0.0.0.0:80/ qdict: <Storage {'rsn': u'1'}> zones changed [0, 0, 0, 0, 0, 0, 0, 0] 192.168.1.105:63173 - - [13/Aug/2017 20:40:00] "HTTP/1.1 GET /cv" - 303 See Other 192.168.1.105:63174 - - [13/Aug/2017 20:40:01] "HTTP/1.1 GET /" - 200 OK 192.168.1.105:63173 - - [13/Aug/2017 20:40:02] "HTTP/1.1 GET /api/status" - 200 OK 192.168.1.105:63174 - - [13/Aug/2017 20:40:02] "HTTP/1.1 GET /api/log" - 200 OK 192.168.1.105:63174 - - [13/Aug/2017 20:40:02] "HTTP/1.1 GET /api/log" - 200 OK 192.168.1.105:63177 - - [13/Aug/2017 20:40:33] "HTTP/1.1 GET /api/status" - 200 OK 192.168.1.105:63177 - - [13/Aug/2017 20:40:33] "HTTP/1.1 GET /api/log" - 200 OK 192.168.1.105:63177 - - [13/Aug/2017 20:40:36] "HTTP/1.1 GET /vr" - 200 OK 192.168.1.105:63177 - - [13/Aug/2017 20:40:37] "HTTP/1.1 GET /api/log" - 200 OK Some Stations has been scheduled: [[1502656839, 1502656844, 5, 98], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]] 192.168.1.105:63177 - - [13/Aug/2017 20:40:40] "HTTP/1.1 GET /cr" - 303 See Other zones changed [1, 0, 0, 0, 0, 0, 0, 0] 192.168.1.105:63177 - - [13/Aug/2017 20:40:40] "HTTP/1.1 GET /" - 200 OK 192.168.1.105:63177 - - [13/Aug/2017 20:40:42] "HTTP/1.1 GET /api/log" - 200 OK 192.168.1.105:63179 - - [13/Aug/2017 20:40:42] "HTTP/1.1 GET /api/status" - 200 OK 192.168.1.105:63177 - - [13/Aug/2017 20:40:43] "HTTP/1.1 GET /api/status" - 200 OK 192.168.1.105:63177 - - [13/Aug/2017 20:40:44] "HTTP/1.1 GET /api/status" - 200 OK zones changed [0, 0, 0, 0, 0, 0, 0, 0] Station 1 run completed zones changed [0, 0, 0, 0, 0, 0, 0, 0] 192.168.1.105:63177 - - [13/Aug/2017 20:40:46] "HTTP/1.1 GET /api/status" - 200 OK 192.168.1.105:63177 - - [13/Aug/2017 20:40:46] "HTTP/1.1 GET /api/log" - 200 OK qdict: <Storage {'rsn': u'1'}> zones changed [0, 0, 0, 0, 0, 0, 0, 0] 192.168.1.105:63177 - - [13/Aug/2017 20:40:53] "HTTP/1.1 GET /cv" - 303 See Other 192.168.1.105:63177 - - [13/Aug/2017 20:40:53] "HTTP/1.1 GET /" - 200 OK 192.168.1.105:63180 - - [13/Aug/2017 20:40:55] "HTTP/1.1 GET /api/status" - 200 OK 192.168.1.105:63177 - - [13/Aug/2017 20:40:55] "HTTP/1.1 GET /api/log" - 200 OK 192.168.1.105:63177 - - [13/Aug/2017 20:40:55] "HTTP/1.1 GET /api/log" - 200 OK 192.168.1.105:63182 - - [13/Aug/2017 20:41:14] "HTTP/1.1 GET /vr" - 200 OK 192.168.1.105:63182 - - [13/Aug/2017 20:41:16] "HTTP/1.1 GET /api/log" - 200 OK Some Stations has been scheduled: [[0, 0, 0, 0], [1502656879, 1502656883, 4, 98], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]] 192.168.1.105:63182 - - [13/Aug/2017 20:41:20] "HTTP/1.1 GET /cr" - 303 See Other zones changed [0, 1, 0, 0, 0, 0, 0, 0] 192.168.1.105:63182 - - [13/Aug/2017 20:41:20] "HTTP/1.1 GET /" - 200 OK 192.168.1.105:63182 - - [13/Aug/2017 20:41:22] "HTTP/1.1 GET /api/log" - 200 OK 192.168.1.105:63183 - - [13/Aug/2017 20:41:23] "HTTP/1.1 GET /api/status" - 200 OK zones changed [0, 0, 0, 0, 0, 0, 0, 0] Station 2 run completed zones changed [0, 0, 0, 0, 0, 0, 0, 0] 192.168.1.105:63182 - - [13/Aug/2017 20:41:24] "HTTP/1.1 GET /api/status" - 200 OK 192.168.1.105:63182 - - [13/Aug/2017 20:41:24] "HTTP/1.1 GET /api/log" - 200 OK qdict: <Storage {'rsn': u'1'}> zones changed [0, 0, 0, 0, 0, 0, 0, 0] 192.168.1.105:63182 - - [13/Aug/2017 20:41:30] "HTTP/1.1 GET /cv" - 303 See Other 192.168.1.105:63182 - - [13/Aug/2017 20:41:30] "HTTP/1.1 GET /" - 200 OK 192.168.1.105:63182 - - [13/Aug/2017 20:41:32] "HTTP/1.1 GET /api/log" - 200 OK192.168.1.105:63183 - - [13/Aug/2017 20:41:32] "HTTP/1.1 GET /api/status" - 200 OK
any idea..?
thanks for your support!
How are you connecting the valves to the Orange board?
If you are using relays that are low level trigger type and you can access the SIP UI, go to Options > Station handling and tick the check box at "Active-Low Relay:". That may help.
I should also mention that if you are using a relay board you will need to install and use the relay_board plugin. The plugin can be installed from the PLUGINS menu. The plugin will also need to be modified for use with the orange board.
hi @Dan-in-CA ,
something strange is happening, after apply your setup, nothing happents.. :-/ when i run the syp.py i get following errors: very rare but now, after apply your setup, nothing happents.. :-/ when i run " sudo /usr/bin/python sip.py" i got following errors:
`takezo@orangepizero:~/OrangeSIP/SIP$ sudo /usr/bin/python sip.py No GPIO module was loaded from GPIO Pins module error importing GPIO pins into helpers ALARM from Example_Sender!: Just and example! Ignoring exception while loading the relay_board plug-in. No module named RPi.GPIO Ignoring exception while loading the telegramBot plug-in. No module named telegram.ext plugins loaded: email_adj mobile_app monthly_adj plugin_manager signaling_examples system_update weather_adj weather_level_adj http://0.0.0.0:80/ Starting timing loop
Monthly Adjust: Setting water level to 100% Checking rain status... Exception in thread Thread-3: Traceback (most recent call last): File "/usr/lib/python2.7/threading.py", line 810, in __bootstrap_inner self.run() File "/usr/lib/python2.7/threading.py", line 763, in run self.target(*self.args, **self.__kwargs) File "/home/takezo/OrangeSIP/SIP/plugins/weather_adj.py", line 38, in weather_to_delay weather = get_weather_data() if data['weather_provider'] == "yahoo" else get_wunderground_weather_data() File "/home/takezo/OrangeSIP/SIP/plugins/weather_adj.py", line 151, in get_wunderground_weather_data lid = get_wunderground_lid() File "/home/takezo/OrangeSIP/SIP/plugins/weather_adj.py", line 101, in get_wunderground_lid lid = "zmw:" + data['RESULTS'][0]['zmw'] IndexError: list index out of range
Checking weather status... Weather-base water level encountered error: Traceback (most recent call last): File "/home/takezo/OrangeSIP/SIP/plugins/weather_level_adj.py", line 90, in run history = history_info(self) File "/home/takezo/OrangeSIP/SIP/plugins/weather_level_adj.py", line 318, in history_info raise Exception('No Location ID found!') Exception: No Location ID found!
Email plugin is started
`
any idea..?
new errors:
`^Ctakezo@orangepizero:~/OrangeSIP/SIP$ sudo /usr/bin/python sip.py No GPIO module was loaded from GPIO Pins module error importing GPIO pins into helpers ALARM from Example_Sender!: Just and example! Ignoring exception while loading the relay_board plug-in. No module named RPi.GPIO Ignoring exception while loading the telegramBot plug-in. No module named telegram.ext plugins loaded: email_adj mobile_app monthly_adj plugin_manager signaling_examples system_update weather_adj weather_level_adj http://0.0.0.0:80/ Starting timing loop
Monthly Adjust: Setting water level to 100% Checking rain status... Exception in thread Thread-3: Traceback (most recent call last): File "/usr/lib/python2.7/threading.py", line 810, in __bootstrap_inner self.run() File "/usr/lib/python2.7/threading.py", line 763, in run self.target(*self.args, **self.__kwargs) File "/home/takezo/OrangeSIP/SIP/plugins/weather_adj.py", line 38, in weather_to_delay weather = get_weather_data() if data['weather_provider'] == "yahoo" else get_wunderground_weather_data() File "/home/takezo/OrangeSIP/SIP/plugins/weather_adj.py", line 151, in get_wunderground_weather_data lid = get_wunderground_lid() File "/home/takezo/OrangeSIP/SIP/plugins/weather_adj.py", line 101, in get_wunderground_lid lid = "zmw:" + data['RESULTS'][0]['zmw'] IndexError: list index out of range
Checking weather status... Weather-base water level encountered error: Traceback (most recent call last): File "/home/takezo/OrangeSIP/SIP/plugins/weather_level_adj.py", line 90, in run history = history_info(self) File "/home/takezo/OrangeSIP/SIP/plugins/weather_level_adj.py", line 318, in history_info raise Exception('No Location ID found!') Exception: No Location ID found! `
Some of those errors are from the other plugins you installed. I would suggest that you disable or delete those other plugins and get the relay_board plugin working first.
As I said before you will need to modify the relay board plugin before it will work with the orange pi.
Click the Help button on the relay_board set up page to get instructions about connecting the relay board to the Pi board. Don't forget that the GPIO pins on the Orange Pi board are oriented 180 degrees from the pins on a Raspberry Pi.
I will take a look at the relay_board plugin code to figure out what you will need to change.
Hi @Dan-in-CA ,
the case is that I have disabled other plugins that i installed. Now I have only realy_board pluging. Into menú Plugings i have only available option "manage pluging" , no other pluglings seems to be there to configure... :-/ the way to configure relay_board pluging is from this menu, right?
from Menu "options" i have active box "Active-Low Relay" but nothing happens after check or uncheck this option.. :-/
here you have other print out of messages:
`takezo@orangepizero:~/OrangeSIP/SIP$ sudo /usr/bin/python sip.py
No GPIO module was loaded from GPIO Pins module
error importing GPIO pins into helpers
Ignoring exception while loading the relay_board plug-in.
No module named RPi.GPIO
plugins loaded:
mobile_app
plugin_manager
Starting timing loop
`
why continue saying that "No GPIO module was loaded from GPIO Pins module" ?
thanks for your suppor!
i forgot to say that i have orange pi zero hw.
@aocana The error you need to fix is No module named RPi.GPIO
, the relay_board.py module should be importing pyA20.gpio instead? What happens if you replace RPi.GPIO
by pyA20.gpio
?
hi @mattip !
thanks for your help! i have modified file relay_board.py which is located into path plugings. I have replaced RPi.GPIO by pyA20.gpio, but seems that the issue continue:
file relay_borad.py:
`# Load the Raspberry Pi GPIO (General Purpose Input Output) library
try:
if gv.use_pigpio: import pigpio pi = pigpio.pi() else: _**import pyA20.gpio as GPIO**_ pi = 0
`
error after run command "sudo /usr/bin/python sip.py"
` takezo@orangepizero:~/OrangeSIP/SIP$ sudo /usr/bin/python sip.py
No GPIO module was loaded from GPIO Pins module
error importing GPIO pins into helpers
relay board plugin only supported on pi.
plugins loaded:
mobile_app
plugin_manager
relay_board
http://0.0.0.0:80/Starting timing loop `
The relay_board plugin will need a lot more changes. For example, the code on lines 52 to 62 in relay_board.py will need to be changed to work with the orange pi model you have.
I don't have an orange pi so I can't do any testing.
@Dan-in-CA
welcome to the Lab Orange Pi Zero!!! :-) from which point do you wish to start..? do you need access to the lab..? I'm newcomer to this work of programming.. :-/ but i'm open to test all you need to standardize this HW for your platform.
thanks!!
Python is an easy language to learn. This project should be a good way for you to get started with programming.
Or, if you don't think it would be worth you time and effort, why not just stay with a Raspberry Pi. They are not expensive and will work with SIP without needing to make any changes.
I have one raspberry pi , working as meteo station.. :-/ and i though when i buy this hw i could use it to configure the irrigation.. :-/ I will see the way to swap the hw's..
Old thread. re-open of there is still interest.
Hi Dan I see there is somebody on this page that had questions about this in the past. I also have a Orange Pi One. I want to be able to switch 21 channels/relays with it but SIP will not start. I get a message in the terminal that it is not a raspberry pi. Can you please help me set this up. I have jumped through a lot of different irrigation stuff and so far this software looks like it is what I need for my system. Hope to hear from you soon. Kind Regards