DFR0274

DFR0274 Datasheet


Use IR transmitter from dfrobot for controlling the RGB led strip. // by pmalmsten // by farkinga // by farkinga - adds cool behaviors /* by pstrobl

Part Datasheet
DFR0274 DFR0274 DFR0274 (pdf)
PDF Datasheet Preview
RGB LED Strip Driver Shield

Contents
• 1 Introduction
• 2 Specification
• 3 Pin Out
• 4 Sample Code

LED Strip driving code IR Receiving Code IR Remote control Demo

Introduction

The RGB LED Strip Driver Shield allows an Arduino board to drive the RGB LED Strip. Through control the 3 MOSFEET on the board,you can turn the RGB LED ON/OFF,and show colors differently. You can also control the RGB LED Strip Driver Shield by the IR remote controller. The RGB LED Strip Driver Shield connects to an Arduino board using long wire-wrap headers which extend through the shield. This keeps the pin layout intact and allows another shield to be stacked on top. Arduino uses digital PWM pins 9, 10, 11 to control the MOSFEET on the RGB LED Strip Driver Shield. and the digital pin 4 is used to receive the IR signal.These pins cannot be used for general i/o. The shield have a can limit the current.

Specification
• Supply voltage:<=12V
• Compatible
• Compatible with 12V RGB LED Strip
• Maximum power is 72W (2A per
• Support IR remote control

Pin Out

Arduino Driving Pins
• D9 -> PWM1 Blue Output control
• D10 -> PWM2 Red Output control
• D11 -> PWM3 Green Output control

IR Recieving Pin
• D4 -> IR data receiving

PS This feature could be disable by removing the jumper cap on the shield. Note Commonly we use the common anode RGB LED Strip. So when connecting the RGB Strip to the driver shield, it requires a independent 12v power source for the high power LED strip. The maximum powering current from this shield is about 9A totally 3A for each way . So it could almost directly drive a 10 meter RGB LED strip.

Sample Code

LED Strip driving code

Here's the basic code for controlling the color of the RGB LED strip.
int RedPin = 10 int GreenPin = 11 int BluePin = 9;
//Arduino driving pin for Red //Arduino driving pin for Green //Arduino driving pin for Blue
void setColor int red, int green, int blue
analogWrite RedPin, red analogWrite GreenPin, green analogWrite BluePin, blue ;
void setup
pinMode RedPin, OUTPUT //Init Arduino driving pins pinMode GreenPin, OUTPUT pinMode BluePin, OUTPUT Serial.begin 9600 ;
void loop
for int i=0;i<255;i++ //Changing Red brightness
setColor i, 0, 0 delay 10 delay 2000 for int i=0;i<255;i++ //Changing Green brightness
setColor 0, i, 0 delay 10 delay 2000 for int i=0;i<255;i++ //Changing Blue brightness setColor 0, 0, i delay 10 delay 2000 for int i=0;i<255;i++ setColor i, 0, 255-i delay 10 for int i=0;i<255;i++ setColor 255-i, i, 0 delay 10 for int i=0;i<255;i++ setColor 0, 255-i, i delay 10 ;

IR Receiving Code

For the ir receiving feature, we recommend to use Arduino IRRemote library created by Ken Shirriff. This library is quite easy to use and directly support decoding several different IR protocol.
//Please download the arduino library and install it before compiling the sam ple code /*
* IRremote IRrecvDemo - demonstrates receiving IR codes with IRrecv * An IR detector/demodulator must be connected to the input RECV_PIN. * Version July, 2009 * Copyright 2009 Ken Shirriff * */
#include <IRremote.h>
int RECV_PIN = 4 //IR Receiving pin on the driver shield

IRrecv RECV_PIN ;
decode_results results;
void setup

Serial.begin 9600 irrecv.enableIRIn // Start the receiver
void loop if irrecv.decode &results Serial.println results.value, HEX irrecv.resume // Receive the next value

IR Remote control Demo

Use IR transmitter from dfrobot for controlling the RGB led strip. // by pmalmsten // by farkinga // by farkinga - adds cool behaviors /* by pstrobl
changed the original program to use on IR Kit For Arduino Model DFR0107 32 bit controller.

All keypresses are sent to the serial monitor at 9600 baud. pulseIn is always HIGH. The phototransistor in the kit does not invert the signal. uses pin 13 for heartbeat debug 32 bits requires a long variable, so divided up into two 15 bit so can use integer variables use the first 15 bits of the 32 bits for remote and data stream verification. This code is always the same for every button press use the last 15 of the 32 bits for button press selection. This code changes for each button. ignore the middle 2 bits, it never changes. */
#define IR_BIT_LENGTH 32 // number of bits sent by IR remote
More datasheets: ASA03G48-L | ASA03F48-L | ASA02A24-L | ASA00B48-L | CS-JUICYBOARD-02 | CS-JUICYBOARD-04 | CS-JUICYBOARD-03 | CS-JUICYBOARD-01 | CS-JUICYBOARD-05 | CS-JUICYBOARD-06


Notice: we do not provide any warranties that information, datasheets, application notes, circuit diagrams, or software stored on this website are up-to-date or error free. The archived DFR0274 Datasheet file may be downloaded here without warranties.

Datasheet ID: DFR0274 508702