Ks0251 keyestudio 4-channel Relay Shield: Difference between revisions
Jump to navigation
Jump to search
Keyestudio (talk | contribs) |
Keyestudio (talk | contribs) |
||
(9 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
[[image:Ks0251 4-relay.png|thumb|800px|right|Keyestudio 4-channel Relay Shield]] | [[image:Ks0251 4-relay.png|thumb|800px|right|Keyestudio 4-channel Relay Shield]] | ||
<br> | |||
==Introduction== | ==Introduction== | ||
The keyestudio relay shield has integrated a 4-channel 5V relay module, which is fully compatible with [http://wiki.keyestudio.com/index.php/Ks0001_keyestudio_UNO_R3_BOARD UNO R3 control board]. | The keyestudio relay shield has integrated a 4-channel 5V relay module, which is fully compatible with [http://wiki.keyestudio.com/index.php/Ks0001_keyestudio_UNO_R3_BOARD UNO R3 control board]. The 4-channel relay on the shield is active at HIGH level. Separately connect the 4-channel relay to the digital port 4, 5, 6, 7 on the UNO R3 board, then through controlling output HIGH or LOW to control the relay on and off. <br> | ||
The 4-channel relay on the shield is active at HIGH level. Separately connect the 4-channel relay to the digital port 4, 5, 6, 7 on the UNO R3 board, then through controlling output HIGH or LOW to control the relay on and off. <br> | |||
<br> | |||
==Features== | ==Features== | ||
* The relay shield is 5V active HIGH | * The relay shield is 5V active HIGH | ||
Line 19: | Line 19: | ||
* PCB Color: Black | * PCB Color: Black | ||
<br> | |||
==Details== | ==Details== | ||
* Size: 69mm*54mm*26mm | * '''Size:''' 69mm*54mm*26mm | ||
* Weight: 39.4g | * '''Weight:''' 39.4g | ||
[[Image:ks0251 dimensions.png|600px|frameless]] | [[Image:ks0251 dimensions.png|600px|frameless]] | ||
<br> | <br> | ||
Line 29: | Line 29: | ||
[[Image:ks0251 pinouts.jpg|800px|frameless]] | [[Image:ks0251 pinouts.jpg|800px|frameless]] | ||
<br> | <br> | ||
'''Relay Terminals:''' <br> | |||
*Terminal high-power, high-current high voltage can be connected to the device.<br> | |||
*When D4 is High, RELAY 4 turns on, LED4 lights up, COM4 and NO4 connected, COM4 and NC4 disconnected. If D4 is LOW, RELAY 4 turns off, LED4 not light, COM4 and NO4 disconnected, COM4 and NC4 connected. <br> | |||
Terminal high-power, high-current high voltage can be connected to the device.<br> | *When D5 is High, RELAY 3 turns on, LED3 lights up, COM3 and NO3 connected, COM3 and NC3 disconnected. If D5 is LOW, RELAY 3 turns off, LED3 not light, COM3 and NO3 disconnected, COM3 and NC3 connected. <br> | ||
When D4 is High, RELAY 4 turns on, LED4 lights up, COM4 and NO4 connected, COM4 and NC4 disconnected. | *When D6 is High, RELAY 2 turns on, LED2 lights up, COM2 and NO2 connected, COM2 and NC2 disconnected. If D6 is LOW, RELAY 2 turns off, LED2 not light, COM2 and NO2 disconnected, COM2 and NC2 connected. <br> | ||
If D4 is LOW, RELAY 4 turns off, LED4 not light, COM4 and NO4 disconnected, COM4 and NC4 connected. <br> | *When D7 is High, RELAY 1 turns on, LED1 lights up, COM1 and NO1 connected, COM1 and NC1 disconnected. If D7 is LOW, RELAY 1 turns off, LED1 not light, COM1 and NO1 disconnected, COM1 and NC1 connected. | ||
When D5 is High, RELAY 3 turns on, LED3 lights up, COM3 and NO3 connected, COM3 and NC3 disconnected. | |||
If D5 is LOW, RELAY 3 turns off, LED3 not light, COM3 and NO3 disconnected, COM3 and NC3 connected. <br> | |||
When D6 is High, RELAY 2 turns on, LED2 lights up, COM2 and NO2 connected, COM2 and NC2 disconnected. | |||
If D6 is LOW, RELAY 2 turns off, LED2 not light, COM2 and NO2 disconnected, COM2 and NC2 connected. <br> | |||
When D7 is High, RELAY 1 turns on, LED1 lights up, COM1 and NO1 connected, COM1 and NC1 disconnected. | |||
If D7 is LOW, RELAY 1 turns off, LED1 not light, COM1 and NO1 disconnected, COM1 and NC1 connected. | |||
<br> | <br> | ||
==Hookup Guide== | ==Hookup Guide== | ||
Simply stack the shield on the UNO board. | Simply stack the shield on the [http://wiki.keyestudio.com/index.php/Ks0001_keyestudio_UNO_R3_BOARD UNO board ]. | ||
<br>[[Image:ks0251 Connect.png|800px|frameless]] | <br>[[Image:ks0251 Connect.png|800px|frameless]] | ||
<br> | <br> | ||
==Sample Code== | ==Sample Code== | ||
* How to download and install [http://wiki.keyestudio.com/index.php/How_to_Download_Arduino_IDE Arduino IDE] and [http://wiki.keyestudio.com/index.php/How_to_Install_Arduino_Driver driver].<br> | *How to download and install [http://wiki.keyestudio.com/index.php/How_to_Download_Arduino_IDE Arduino IDE] and [http://wiki.keyestudio.com/index.php/How_to_Install_Arduino_Driver driver].<br> | ||
* [https://drive.google.com/open?id=1CR31iSw5coJIWzdxIYO2381jesIuTm__ Click here to download the code] or directly copy the code below to IDE. | *[https://drive.google.com/open?id=1CR31iSw5coJIWzdxIYO2381jesIuTm__ Click here to download the code] or directly copy the code below to IDE. | ||
<pre> | <pre> | ||
Line 80: | Line 75: | ||
</pre> | </pre> | ||
[[Image:ks0251 upload.png|800px|frameless]] | [[Image:ks0251 upload.png|800px|frameless]] | ||
<br> | <br> | ||
Line 89: | Line 85: | ||
==Resources == | ==Resources == | ||
'''Download the PDF file | '''Download the PDF file and code:''' <br> | ||
https://fs.keyestudio.com/KS0251 | |||
https:// | |||
'''VIDEO:''' <br> | '''VIDEO:''' <br> | ||
http:// | http://video.keyestudio.com/KS0251/ | ||
<br> | |||
==Get One Now == | ==Get One Now == | ||
'''Official Website''' | *[https://www.keyestudio.com/keyestudio-4-channel-5v-relay-shield-module-for-arduino-uno-r3-p0140.html '''Official Website'''] | ||
*[https://www.aliexpress.com/store/product/Keyestudio-4-channel-5V-Relay-Shield-module-for-Arduino-UNO-R3/1452162_32668782199.html?spm=2114.12010612.8148356.18.7902276fG5lTah '''Shop on Aliexpress'''] | |||
*[https://www.ebay.com/itm/Keyestudio-4-Channel-5V-Relay-Module-for-Arduino-UNO-Mega-2560-Raspberry-Pi/132739030014?hash=item1ee7dcdbfe:g:86EAAOSwk6hbX6PT '''Shop on eBay'''] | |||
*[https://www.amazon.com/dp/B07B2FTZD1 '''Shop on Amazon'''] | |||
[[Category: Shield]] | [[Category: Shield]] |
Latest revision as of 14:00, 6 January 2021
Introduction
The keyestudio relay shield has integrated a 4-channel 5V relay module, which is fully compatible with UNO R3 control board. The 4-channel relay on the shield is active at HIGH level. Separately connect the 4-channel relay to the digital port 4, 5, 6, 7 on the UNO R3 board, then through controlling output HIGH or LOW to control the relay on and off.
Features
- The relay shield is 5V active HIGH
- Contact capacity: AC120V / 3A ; DC24V/3A
- Onboard LED indicator for relay output status
- Indicator: 4 LEDs are red when the relay is driven high, the corresponding indicator will light up.
- Standard interface can be directly connected with microcontrollers.
- Fully compatible with UNO R3 board
- Be able to control various appliances and other equipment with large current.
- 3 M3 screw positioning holes for easy installation
- Power Interface: 5V DC power interface
- Channel: 4 channel
- PCB Color: Black
Details
- Size: 69mm*54mm*26mm
- Weight: 39.4g
PINOUTS
- Terminal high-power, high-current high voltage can be connected to the device.
- When D4 is High, RELAY 4 turns on, LED4 lights up, COM4 and NO4 connected, COM4 and NC4 disconnected. If D4 is LOW, RELAY 4 turns off, LED4 not light, COM4 and NO4 disconnected, COM4 and NC4 connected.
- When D5 is High, RELAY 3 turns on, LED3 lights up, COM3 and NO3 connected, COM3 and NC3 disconnected. If D5 is LOW, RELAY 3 turns off, LED3 not light, COM3 and NO3 disconnected, COM3 and NC3 connected.
- When D6 is High, RELAY 2 turns on, LED2 lights up, COM2 and NO2 connected, COM2 and NC2 disconnected. If D6 is LOW, RELAY 2 turns off, LED2 not light, COM2 and NO2 disconnected, COM2 and NC2 connected.
- When D7 is High, RELAY 1 turns on, LED1 lights up, COM1 and NO1 connected, COM1 and NC1 disconnected. If D7 is LOW, RELAY 1 turns off, LED1 not light, COM1 and NO1 disconnected, COM1 and NC1 connected.
Hookup Guide
Simply stack the shield on the UNO board .
Sample Code
- How to download and install Arduino IDE and driver.
- Click here to download the code or directly copy the code below to IDE.
int BASE = 4 ; //The first relay is connected to the I / O port int NUM = 4; //Total number of relays void setup() { for (int i = BASE; i < BASE + NUM; i ++) { pinMode(i, OUTPUT); //Set the number I/O port to outputs } } void loop() { for (int i = BASE; i < BASE + NUM; i ++) { digitalWrite(i, LOW); //Set the number I/O port outputs to "low", that is, gradually turn off the relay. delay(200); //delay 0.2S } for (int i = BASE; i < BASE + NUM; i ++) { digitalWrite(i, HIGH); //Set the number I/O port outputs to "high", that is, gradually turn on relay. delay(200); //delay 0.2S } }
Test Result
Done uploading the above code, you should see the 4-channel relay is first connected, and then disconnected one after another, repeatedly.
Resources
Download the PDF file and code:
https://fs.keyestudio.com/KS0251
VIDEO:
http://video.keyestudio.com/KS0251/