Difference between revisions of "Pirelay-V2"
From SB-Components Wiki
(26 intermediate revisions by the same user not shown) | |||
Line 5: | Line 5: | ||
=== Features === | === Features === | ||
− | + | * High-quality Relay and loads up to 250VAC/7A, 30VDC/10A. | |
− | + | * Optocoupler | |
− | + | * Standardized shield shape and design. | |
− | + | * LED working status indicators for each Relay. | |
− | + | * High-quality Relays. | |
− | + | * Pin Stacking Header for accessing GPIO of RPi. | |
− | |||
− | |||
− | |||
=== Specifications === | === Specifications === | ||
− | + | * Channel - 4 CH | |
− | + | * Operating Voltage - 5V | |
− | + | * AC Control Voltage - 7A / 250V | |
− | + | * DC Control Voltage - 10A / 30V | |
+ | * Dimensions - 6.5cm x 5.5cm | ||
</div> | </div> | ||
<div class="large-4 column"> | <div class="large-4 column"> | ||
− | [[File:Pirelay_v2.png]] | + | [[File:Pirelay_v2.png|thumb|left|alt=PiRelay v2| Buy it From : ''[https://shop.sb-components.co.uk/products/pirelay-relay-board-shield-for-raspberry-pi Click Here]'']] |
</div> | </div> | ||
</div> | </div> | ||
− | === | + | == Pinout == |
+ | <table class="wikitable"> | ||
+ | <tr> <th> Relays </th> <th>BOARD </th> <th> BCM</th> </tr> | ||
+ | <tr><td> Relay 1 </td> <td> 35 </td> <td> GPIO 19 </td></tr> | ||
+ | <tr><td> Relay 2 </td> <td> 33 </td> <td> GPIO 13 </td></tr> | ||
+ | <tr><td> Relay 3 </td> <td> 31 </td> <td> GPIO 6 </td></tr> | ||
+ | <tr><td> Relay 4 </td> <td> 29 </td> <td> GPIO 5 </td></tr> | ||
+ | |||
+ | </table> | ||
+ | |||
+ | == Hardware Details == | ||
+ | * There are a total of 5 led's on the PiRelay-V2 board. | ||
+ | [[File:Pirelay-V2-indicator.PNG | 300px]] | ||
+ | |||
+ | The power led will light up when the board is powered via gpio header. The status/indicator led will light up when the relay1-relay4 is activated. | ||
+ | |||
+ | * '''Output Terminal Block''': We have 3 channels of Relay labeled as NO, COM and NC. | ||
+ | ** '''COM''' (Common): Connect this pin to the signal you want to switch. | ||
+ | ** '''NC''' (Normally Close): In this configuration, the relay always remains closed until you send a signal to the relay to open the circuit. | ||
+ | ** '''NO''' (Normally Open): This configuration is totally opposite of NC Terminal configuration, It remain open until you send a signal to relay to close the circuit. | ||
+ | |||
+ | [[File:PiRelay-NO-NC-Con.PNG | 300px]] | ||
+ | |||
+ | * On-Board jumpers are provided to use default pins of Pi internally connected with GPIO Header. In case you need to use any other GPIO rather than the default one, you can remove these jumpers and connect relay pins directly to the GPIO of Raspberry Pi Pins. | ||
+ | |||
+ | [[File:PiRelay-v2-Jumper.png | 300px]] | ||
+ | |||
+ | * On-Board optocouplers are provided to protect the circuit from high voltage/current to avoid any kind of mishappening. it also offers isolation between the analog and digital grounds to ensure that switching currents in the relay coils do not affect the noise margin of the digital circuit. | ||
+ | |||
+ | [[File:PiRelay-V2-Optocoupler.PNG | 300px]] | ||
== Installation == | == Installation == | ||
==== Python ==== | ==== Python ==== | ||
+ | * Stack PiRelay-V2 HAT on Raspberry Pi 40 Pin GPIO header. | ||
+ | * Make sure all four jumpers are connected. | ||
* Open Terminal and clone/download the repository by typing below command in terminal: | * Open Terminal and clone/download the repository by typing below command in terminal: | ||
− | < | + | <source lang="shell"> git clone https://github.com/sbcshop/PiRelay-V2.git </source> |
* Your code will be downloaded to '/home/pi' directory. Use 'ls' command to check the list of directories and 'cd' command to enter directory. | * Your code will be downloaded to '/home/pi' directory. Use 'ls' command to check the list of directories and 'cd' command to enter directory. | ||
− | < | + | <source lang="shell"> cd PiRelay-V2 </source> |
* 'test.py' is example code for PiRelay-V2. Run test file and play with PiRelay-V2 by running below python command. | * 'test.py' is example code for PiRelay-V2. Run test file and play with PiRelay-V2 by running below python command. | ||
− | < | + | <source lang="shell"> python3 test.py </source> |
+ | |||
+ | * You can also use any other GPIO of Raspberry Pi by removing the jumpers and connecting the relay pin directly to the Raspberry Pi GPIO header using jumper cables or wire. | ||
+ | |||
+ | <b> GPIO 4 Relay Not working Fix </b> | ||
+ | |||
+ | * Click on <b> Start button >> Preferences >> Raspberry Pi Configuration</b>, Then click on Interfaces Tab and make sure 1-Wire is disabled. | ||
+ | * Click on the OK button then reboot Raspberry pi. | ||
+ | |||
+ | https://github.com/sbcshop/PiRelay-V2/raw/main/Images/Relay4Fix.PNG | ||
== Resources == | == Resources == | ||
+ | |||
+ | ''' Github ''' | ||
+ | |||
+ | * [https://github.com/sbcshop/PiRelay-V2 Source Code] |
Latest revision as of 08:54, 14 September 2021
PiRelay-V2
PiRelay V2 is developed by SB Components with the potential to control 4 appliances and loads up to 250V AC/ 7 A, 30V DC/ 10A to provide a way to control the high voltage/current devices. It helps the user to enhance the intelligence of the appliances. It comprises an “Optocoupler” that allows the circuit to transmit an electrical signal between two isolated circuits through light energy. Optocoupler helps the user to prevent the high voltages in one part of the circuit from affecting the other part of the circuit which provides safety to the system. It provides a better connection of Pi Relay V2 with the Raspberry Pi that gets enabled from the standardized shield form factor. One can enable the IoT technology of their home appliances using Pi Relay V2 that will make their life efficient.
Features
- High-quality Relay and loads up to 250VAC/7A, 30VDC/10A.
- Optocoupler
- Standardized shield shape and design.
- LED working status indicators for each Relay.
- High-quality Relays.
- Pin Stacking Header for accessing GPIO of RPi.
Specifications
- Channel - 4 CH
- Operating Voltage - 5V
- AC Control Voltage - 7A / 250V
- DC Control Voltage - 10A / 30V
- Dimensions - 6.5cm x 5.5cm
Pinout
Relays | BOARD | BCM |
---|---|---|
Relay 1 | 35 | GPIO 19 |
Relay 2 | 33 | GPIO 13 |
Relay 3 | 31 | GPIO 6 |
Relay 4 | 29 | GPIO 5 |
Hardware Details
- There are a total of 5 led's on the PiRelay-V2 board.
The power led will light up when the board is powered via gpio header. The status/indicator led will light up when the relay1-relay4 is activated.
- Output Terminal Block: We have 3 channels of Relay labeled as NO, COM and NC.
- COM (Common): Connect this pin to the signal you want to switch.
- NC (Normally Close): In this configuration, the relay always remains closed until you send a signal to the relay to open the circuit.
- NO (Normally Open): This configuration is totally opposite of NC Terminal configuration, It remain open until you send a signal to relay to close the circuit.
- On-Board jumpers are provided to use default pins of Pi internally connected with GPIO Header. In case you need to use any other GPIO rather than the default one, you can remove these jumpers and connect relay pins directly to the GPIO of Raspberry Pi Pins.
- On-Board optocouplers are provided to protect the circuit from high voltage/current to avoid any kind of mishappening. it also offers isolation between the analog and digital grounds to ensure that switching currents in the relay coils do not affect the noise margin of the digital circuit.
Installation
Python
- Stack PiRelay-V2 HAT on Raspberry Pi 40 Pin GPIO header.
- Make sure all four jumpers are connected.
- Open Terminal and clone/download the repository by typing below command in terminal:
git clone https://github.com/sbcshop/PiRelay-V2.git
- Your code will be downloaded to '/home/pi' directory. Use 'ls' command to check the list of directories and 'cd' command to enter directory.
cd PiRelay-V2
- 'test.py' is example code for PiRelay-V2. Run test file and play with PiRelay-V2 by running below python command.
python3 test.py
- You can also use any other GPIO of Raspberry Pi by removing the jumpers and connecting the relay pin directly to the Raspberry Pi GPIO header using jumper cables or wire.
GPIO 4 Relay Not working Fix
- Click on Start button >> Preferences >> Raspberry Pi Configuration, Then click on Interfaces Tab and make sure 1-Wire is disabled.
- Click on the OK button then reboot Raspberry pi.
Resources
Github