Difference between revisions of "Raspberry Relay"
Jump to navigation
Jump to search
Line 3: | Line 3: | ||
== Overview == |
== Overview == |
||
The Raspberry Relay board can be connected to a Raspberry Pi using the 26-pin GPIO connector. The relays can be controlled using the Raspberry Pi GPIO pins. Optionally, the Pi can be powered by the micro USB port on the Relay board. This way, the connectors for power, ethernet and USB are on one side. Please note that the polyfuse will be bypassed if the Pi is powered via the Relay board. The polyfuse prevents damage when a short-circuit occurs. |
The Raspberry Relay board can be connected to a Raspberry Pi using the 26-pin GPIO connector. The relays can be controlled using the Raspberry Pi GPIO pins. Optionally, the Pi can be powered by the micro USB port on the Relay board. This way, the connectors for power, ethernet and USB are on one side. Please note that the polyfuse will be bypassed if the Pi is powered via the Relay board. The polyfuse prevents damage when a short-circuit occurs. |
||
== Usage == |
|||
The module can be controlled with the GPIO pins on the Pi. Set a pin high, the relay will switch on and when the pin is low the relay will switch off. The pins are wired as follows: |
|||
{| border=1 |
|||
! Relay no. !! Pin number !! Pin name ([http://elinux.org/File:GPIOs.png Broadcom ref.]) !! Pin name ([http://wiringpi.com/pins/ wiringPi]) |
|||
|- |
|||
| 1 || 11 || GPIO17 || 0 |
|||
|- |
|||
| 2 || 12 || GPIO18 || 1 |
|||
|- |
|||
| 3 || 13 || GPIO27 || 2 |
|||
|- |
|||
| 4 || 15 || GPIO22 || 3 |
|||
|} |
Revision as of 13:37, 25 August 2014
Overview
The Raspberry Relay board can be connected to a Raspberry Pi using the 26-pin GPIO connector. The relays can be controlled using the Raspberry Pi GPIO pins. Optionally, the Pi can be powered by the micro USB port on the Relay board. This way, the connectors for power, ethernet and USB are on one side. Please note that the polyfuse will be bypassed if the Pi is powered via the Relay board. The polyfuse prevents damage when a short-circuit occurs.
Usage
The module can be controlled with the GPIO pins on the Pi. Set a pin high, the relay will switch on and when the pin is low the relay will switch off. The pins are wired as follows:
Relay no. | Pin number | Pin name (Broadcom ref.) | Pin name (wiringPi) |
---|---|---|---|
1 | 11 | GPIO17 | 0 |
2 | 12 | GPIO18 | 1 |
3 | 13 | GPIO27 | 2 |
4 | 15 | GPIO22 | 3 |