• No se han encontrado resultados

La participació en la potestat legislativa

1 El Govern de la Generalitat: la direcció de la política valenciana

1.2 Les facultats de la direcció política

1.2.6 La participació en la potestat legislativa

The colour sensing circuit of the project contains three different coloured LED emitter and three separate receivers. The light is reflected off of the target such as a blue piece of paper and returns to the sensor. The receivers are tuned to look for a specific wavelength of light working out its RGB or Red, Green and blue values.

The light sensors are able to record the components of the reflected light and its intensity. The sensor then compares these values to the settings on the computer to determine the necessary action. Many of the colour sensors today have the ability to recognize Red, Blue, Green (RGB) or primary. Figure 4.5 shows the colour sensing circuit.

Programmable tolerance settings in the sensor also make it possible to tightly control the match of the target to the programmed value. This capability is important

when sorting or matching objects of similar colour. The more exact the required match, the more tight the colour tolerance level is set.

Fig. 4.5 Colour sensor

LDRs or Light Dependent Resistors are very useful especially in light/dark sensor circuits. Normally the resistance of an LDR is very high, sometimes as high as 1000 000 ohms, but when they are illuminated with light resistance drops dramatically. When a light level of 1000 lux (bright light) is directed towards it, the resistance is 400R (ohms).

When a light level of 10 lux (very low light level) is directed towards it, the resistance has risen dramatically to 10.43M (10430000 ohms).

Fig. 4.6 LED based LDR Sensor

When the light level is low the resistance of the LDR is high. This prevents current from flowing to the base of the transistors. Consequently the LED does not light.

Figure 4.6 shows LED based LDR Sensor

However, when light shines onto the LDR its resistance falls and current flows into the base of the first transistor and then the second transistor. The LED lights.

The preset resistor can be turned up or down to increase or decrease resistance, in this way it can make the circuit more or less sensitive.

The LEDs are water clear when turned off. Black electrical tape surrounds the photocell in the center of the LEDs. The tape blocks the direct light from the LEDs from reaching the photocell, thus detecting only reflected light.

After the amount of red light, green light, and blue light is measured, each component is individually scaled based on minimum and maximum values obtained at calibration. One-time calibration consists of aiming the completed sensor first at a white piece of paper and then at a piece of black conductive foam. The maximum and minimum values are plugged into the EEPROM of the microcontroller. Scaling based on actual data allows the individual attributes of that particular sensor and set of LEDs to be accounted for.

Alternatively, one can adjust the balance of the colours in hardware by using with three separate trimpots (trimmer potentiometers). Dialing a trimpot changes the brightness of a particular LED. For example, if there is too much red light being sensed, simply increase the resistance to decrease the LED brightness by turning the trimpot attached to the red LED.

Include a minimum fixed resistor value (100 ohms to 150 ohms) in series with each trimpot so that if one accidentally dial the trimpot to 0 ohms the LED won't be damaged.

The object whose colour is required to be detected should be placed in front of the system. The light rays reflected from the object will fall on the three convex lenses which are fixed in front of the three LDRs. The convex lenses are used to converge light rays.

This helps to increase the sensitivity of LDRs. Blue, green and red glass plates (filters) are fixed in front of LDR1, LDR2 and LDR3 respectively. When reflected light rays from the object fall on the gadget, the coloured filter glass plates determine which of the LDRs would get triggered.

When a primary coloured light ray falls on the system, the glass plate corresponding to that primary colour will allow that specific light to pass through Fig 4.7. But the other two glass plates will not allow any light to pass through. Thus only one LDR will get triggered and the gate output corresponding to that LDR will become logic 1 to indicate

which colour it is. Similarly, when a secondary coloured light ray falls on the system, the two primary glass plates corres- ponding to the mixed colour will allow that light to pass through while the remaining one will not allow any light ray to pass through it. As a result two of the LDRs get triggered and the gate output corresponding to these will become logic 1 and indicate which colour it is.

When all the LDRs get triggered or remain untriggered, one will observe white and black light indications respectively. Following points may be carefully noted:

1. Potmeters VR1, VR2 and VR3 may be used to adjust the sensitivity of the LDRs.

2. Common ends of the LDRs should be connected to positive supply.

3. Use good quality light filters.

The LDR is mounded in a tube, behind a lens, and aimed at the object. The coloured glass filter should be fixed in front of the LDR as shown in the figure. Make three of that kind and fix them in a suitable case. Adjustments are critical and the gadget performance would depend upon its proper fabrication and use of correct filters as well as light conditions. Figure 4.8 shows LDR with cellophane filter.

Fig. 4.7 LDR with cellophane filter

4.4.1 COLOUR SENSING CIRCUIT

Figure 4.8 shows the circuit which is the combination of LDR, LED and voltage comparator.

41 LEDs