RGB LED _ shyam

Post on 01-Jul-2015

167 views 2 download

description

This presents the working of RGB LEDs and their importance in today's technology.

transcript

RGB LEDs

RGB : Reason behind colourful world

RGB : Red Green Blue

• When using digital equipment to capture, store, modify and view photographic images, they must first be converted to a set of numbers in a process called digitization or scanning.

• Digital images are composed of pixels

• Types of digital images a) Black & white (different shades of grey)

b) colour images (colored pixels)

‘‘Because of the way we perceive colors using three different sets of wavelengths, there are three primary colors. ’’

COLOR IMAGES• A color image is made up of pixels each of which holds three numbers corresponding

to the red, green, and blue levels of the image at a particular location.

• Red, green, and blue (sometimes referred to as RGB) are the primary colors for mixing light—these so-called additive primary colors are different from the subtractive primary colors used for mixing paints (cyan, magenta, and yellow).

• Any color can be created by mixing the correct amounts of red, green, and blue light.

• Assuming 256 levels for each primary, each color pixel can be stored in three bytes (24 bits) of memory. This corresponds to roughly 16.7 million different possible colors.

• Note that for images of the same size, a black and white version will use three times less memory than a color version.

RGB COLOR SPACE• Most computer monitors work by specifying colors according to their red, Green, and blue

components.

• These three values define a 3-D color space call the RGB color space.

• The RGB color space can be visualized as a cube with red varying along one axis, green

varying along the second, and blue varying along the third.

• Every color that can be created by mixing red, green, and blue light is located somewhere

within the cube.

• The images show the outside of the RGB cube viewed from two different directions.

RGB LED

An RGB LED is actually three single color LEDs (Red, Green and Blue) combined

into a single package. Because of this controlling it is very similar to controlling a

single color LED. The one difference is the 3 LEDs share a common anode

(long lead (+)).

EMBEDDED SYSTEMS : RGB LED• Programme:

DDRB=0xff;

RED : PORTB=0b00000001;

_delay_ms(1000);

GREEN : PORTB=0b00000100;

_delay_ms(1000);

BLUE : PORTB=0b00001000;

_delay_ms(1000);

PRESENTATION BY:V SHYAM PRASADA RAOAMITY INSTITUTE OF SPACE SCIENCE & TECHNOLOGY(vsprasad.10@gmail.com)