Atmel ATAVRBFLY Fiche De Données

Page de 42
AVR Butterfly User Guide
-23
4271C–AVR–04/05
3.6.2
Light Sensor
The light sensor is located at the front of the AVR Butterfly, over the LCD. See Figure
3-15
.
Figure 3-15.  Light Sensor
An LDR (Light Dependent Resistor) is used to measure the light. An LDR is character-
ised by the fact that when the light decreases the resistance goes up. Using a voltage
divider and reading the voltage over the LDR through the ADC-channels on the
ATmega169, the light can be calculated.
3.6.3
Voltage Reader
The AVR Butterfly is capable of reading voltages from 0V to 5V. The input must be con-
nected to the pins shown in Figure 3-16. Using a voltage divider and reading the voltage
over the resistors through the ADC-channels on the ATmega169, the applied voltage
can be calculated. The accuracy is about 0,1V.
Figure 3-16.  Voltage Readings
Note:
Do not apply voltages above maximum 10V
3.7
Connect to PC
The AVR Butterfly has an on-board level-converter for the RS-232 interface. This means
that no external hardware is required to reprogram the AVR Butterfly using the self pro-
gramming feature in the ATmega169. Figure 3-17 shows how to connect a serial-cable
to the AVR Butterfly. The integrated RS232 level converter operates down to 2.0V sup-
ply voltage.