Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
more than 12 channels
#1
Can I code more than 12 relays in relay_board.py?  Is there a reason you never went beyond 12?
Reply
#2
The 12 station limitation was because of the limited number of GPIO pins on the Raspi when the relay_board plugin was written.

If you are willing to build a simple shift register circuit you can add as many stations as you need:
https://github.com/Dan-in-CA/SIP/wiki/Relay-interface

Also, with this setup you will not need to use the relay_board plugin. it will work directly with SIP's native code.


Dan
Reply
#3
So I can't just add the new gpio pin numbers to the relay-board plugin code?  I am using a pi2.

When I do the shift register route how do I control the relays using your sip software I don't see a way to do it in sip? How does sip know how to call the other relays? Where is that setup?

This is great software!!
Reply
#4
Hi, I am a new user and have a 16 relay board on my RPI 3. The SIP GUI only shows 8, but I need at least 10 for my project...how can I increase this to show 10 please?
Reply
#5
http://nosack.com/sipforum/showthread.php?tid=21
Reply
#6
(2017 Mar 28, 12:00 AM)joeb@drumwerx.com Wrote: So I can't just add the new gpio pin numbers to the relay-board plugin code?  I am using a pi2.

When I do the shift register route how do I control the relays using your sip software I don't see a way to do it in sip? How does sip know how to call the other relays? Where is that setup?

This is great software!!

The pins are defined in relay_board.py in the plugins dir. line ~55.

The software was originally written to work with shift registers. It will work with them without software modification. When a station is turned on the software disables the shift register outputs, feeds a list of ones and zeros into the shift registers (serial input), 1 for a station that is on and 0s for the rest. Then the outputs of the shift registers are enable and the corresponding relays are turned on or off (Parallel output). I hope that makes sense.

This operation is coded in the set_output() function in gpio_pins.py line ~193 in the SIP dir.

You might find this helpful:
http://www.electronics-tutorials.ws/sequ...seq_5.html

This is also interesting:
http://www.electronics-tutorials.ws/blog...rcuit.html

Dan
Reply
#7
Hi Dan,

It has been a few weeks of running a controller and today I noticed that one of my relays or zones was not working. I am using 12 zones with #1 as a pump master. In looking at it I found out that a GPIO pin on the pi stopped working.  I did not test it to see because it is in a live situation and did not want to change things yet. I will test the pin to ground and see when I turn it on if it gets 3 or 5 volts, not sure what it is but should be more than 0 when I test.

In the last post you let me know where in relay_board.py the GPIO pins were at line 55.  I am having an issue with the pi pin number 7 which is the 8th number listed in the line. 

if I take out 7 in line 55 ,will I then just use pin # 3 as the 8th pin and move up all the numbers in the list for the zones?

Thanks for your help
Reply
#8
Yes, If you take out the 7 from line 55 you can use the rest of the pins in the list.

You will also need to change the wires for stations 8 - 12 to match the new numbering.

Or I think you could just move the wire from pin 7 to e.g. pin 29 and replace the 7 on line 55 with 29. You would also need to remove the other 29 on line 55. That way you would only need to move one wire.

There is a helpful pin diagram for the Pi:
https://pinout.xyz/#

Dan
Reply
#9
Great I will give it a try in the morning and report back.
Reply
#10
I could not wait and changed it anyway and it worked.

Hi Dan,

Still wanting to find out if I add another zone under Stations using #13 and enable it won't the script see that and let me use the 13th gpio pin in the list? That GPIO pin is #31 because I moved 29.

Or are there other items that need to be changed as well.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)