The project is a small circuit to control a group of tri-colored LEDs with common anode or grouped colored LEDs (which are used in this case) by the PWM controller. To be truly simple scheme used minimal components and microcontroller low-end of the company Microchip. Therefore I do not think that would be a problem to assemble for beginners. No use of exotic components which are not easily available.
This project is based on the idea that the simplest things are usually the most successful. Microcontroller controls the operation of the LEDs is PIC12F629. He was 8-Krakow low grade and therefore 3 way switches has a low price ($ 0.70 at the manufacturer's site). Mode selection is done with the help of a single buton.Kontrolerat modified work as a PWM (pulse 3 way switches width modulation) controller that creates the feeling of a smooth change 3 way switches of color and intensity of the emitted light. Low-end of the device means that it does not have built-in PWM module is therefore composed by such code. In addition, not used and an external oscillator or resonator. This limits the clock frequency up to 4 MHz or 1 million operations per second. Taking into account the small memory of this microcontroller impose some restrictions. The most significant of these are low frequency PWM generator (of the order of 400 Hz), and no manual setting odds of filling the three generators (one for each primary color). 3 way switches
The principle 3 way switches of operation of the scheme is as follows. When the power voltage microcontroller adjusts itself to work and load the last saved operation. Pins 5, 6 and 7 give signals to the transistors Q1, Q2 and Q3, which powered LED groups. The need for the use of transistors is derived from the fact that the controller can pass a maximum of 25 mA current in their conclusions (recommended 20 mA), and this is completely insufficient for a single LED operates at approximately 20 mA current. The power source must provide two lines - 5V and 12V with a total mass. There is no problem of course also be used 12V 5V source and stabilizer for power supply of the controller. Switch SW1 is used for switching modes, which will be listed later. Using the built-in lifting the level of conclusions that are configured as inputs, do not have the connection of an external 3 way switches resistor. The base resistor R1, R2 and R3 are selected with a value of 1kΩ, and are preferably even with a higher value (for example, 10kΩ) to limit the current through the transistors in the event that by mistake be overloaded. Selected transistors are BC547C, which have a coefficient of transmission 500. This increases the energy efficiency of the system. For the same reason used voltage 12V to power the LEDs. As shown in the scheme below are used in the diodes of three primary colors. 4 are connected in the block by 3 groups of 3 LEDs. To put it more clearly, can not be separated circuits 4 containing 3 LEDs of each color. Resistors connected to current limiting, are approximate and depend 3 way switches on themselves emitting diode (forward voltage drop across them and their nominal operating current). In the event you decide to assemble this scheme, you must select the appropriate resistors themselves. Red LEDs are made from semiconductor material with low fall on PN-transition is thus "burn" at a low voltage. Because of this, the resistors for this color are more valuable than others.
Transistors are able to provide the current to 100m or 0,5 W, which is greater. You have to measure the current through the units that will be connected to the circuitry in order not to be congested. They of course can be replaced with a more powerful, while respecting their basic electricity, not to overload the output of the microcontroller. It is possible that the use of MOSFET transistors capable of operating with TTL levels of the gate voltage. 3 way switches The latter have a significantly higher rate (up to 10 times, and sometimes 3 way switches more). For this reason they are not preferred in this project.
Generalized control scheme offers the following functions: 14 preset lighting modes to selected mode and load it automatically at startup (done by holding the button for at least 2 seconds until the desired mode is active) 3 outputs 3 way switches open collector type with a maximum current and voltage 3 way switches 100m collector-emitter voltage 45V
List of lighting modes: 3 way switches all outputs are shut down permanently light of all lights (white) lights constantly red LED permanently lit green LED constantly lit blue LED lights constantly red and green LED lights constantly red and blue LED lights constantly on green and blue LED smooth color change with blend of the three primary colors 3 way switches gradual change of the three primary colors without overflow (gradual increase from minimum to maximum and back to minimum for each color in a row) smooth
No comments:
Post a Comment