Tutorial.EsploraBlink History

Hide minor edits - Show changes to markup

December 24, 2012, at 02:55 AM by Tom Igoe -
Changed lines 16-17 from:

Only your Arduino Espora is needed for this example. Connect the Esplora to your computer with a USB cable.

to:

Only your Arduino Esplora is needed for this example. Connect the Esplora to your computer with a USB cable.

December 24, 2012, at 02:34 AM by Tom Igoe -
Changed lines 15-20 from:

Connect the Esplora to your computer with a USB cable.

to:

Only your Arduino Espora is needed for this example. Connect the Esplora to your computer with a USB cable.

RGB led on the Esplora

December 23, 2012, at 06:38 PM by Scott Fitzgerald -
December 23, 2012, at 06:24 PM by Scott Fitzgerald -
Changed lines 15-16 from:

Only your Arduino Esplora is needed for this example.

to:

Connect the Esplora to your computer with a USB cable.

December 23, 2012, at 06:24 PM by Scott Fitzgerald -
Changed lines 15-16 from:

Only your Arduino Espora is needed for this example.

to:

Only your Arduino Esplora is needed for this example.

December 23, 2012, at 06:24 PM by Scott Fitzgerald -
Changed line 5 from:

This example shows you how to read the values from the joystick. The output will be displayed through the serial monitor and as a color on the RGB LED.

to:

This sketch blinks the Esplora's RGB LED. It goes through all three primary colors (red, green, blue), then it combines them for secondary colors(yellow, cyan, magenta), then it turns on all the colors to create white.

Changed lines 7-8 from:

The joystick has two axes, X and Y. Each axis controls a color of the RGB LED: red with the X-axis, and green with the Y-axis. The brightness of the blue element will be controlled by the position of the linear potentiometer.

to:

For best results, cover the LED with a piece of white paper to see the colors blend.

Changed lines 16-18 from:

joystick and slider to control the color of the RGB led on the Esplora

to:
Changed lines 23-24 from:

Each of these light's brightness is individually controllable with functions in the Esplora library:

to:

To control all the colors with one instruction you use the writeRGB() function. It take three arguments. Each value represents the brightness of the red, green, and blue element, respectively. The brightness scales between 0 (for completely off) to 255 (for completely on).

After setting the brightness of an LED, use delay() to pause the sketch for a second, so the light stays in the state you left it.

It's also possible to control each light individually with the following functions :

Changed lines 33-36 from:

If you want to control all the colors with one instruction you can use the writeRGB() function.

Moving the joystick and changing the position of the linear potentiometer will generate different values. These values are used to produce two different outputs: one will appear by opening the serial monitor, and the other is displayed physically through the RGB led.

to:
Changed lines 40-43 from:
to:
December 23, 2012, at 06:16 PM by Scott Fitzgerald -
Changed line 35 from:
to:
December 23, 2012, at 06:06 PM by Scott Fitzgerald -
Added lines 1-43:

Share