lab report

Anonymous
timer Asked: Apr 25th, 2017

Question description

i need lab report

i also have picture of what we did.

Scanned by CamScanner Scanned by CamScanner Scanned by CamScanner Scanned by CamScanner Scanned by CamScanner Scanned by CamScanner Scanned by CamScanner Scanned by CamScanner
Project 1 for Circuits I Sensor Indicator using Arduino microcontroller Objectives • To use a schematic diagram to connect a circuit. • To observe the resistance output of resistance based sensors • To use a voltage divider to convert change in resistance to change in voltage • To become familiar with LEDs and Microcontroller programming Submission Items • • • Complete project report according to the given format (Group Report) Video of introduction of team and demonstration of project operation (Group Report) Completion of assessment survey (Individual submission) Introduction This project measures the light and temperature and outputs the values via the LEDS. For the light sensor, the green light is on when the sensor is lighted and red light is on when the sensor is dark. The one led blinks the number of tens in the temperature value and the ones LED blinks the number of ones. The temperature is in Fahrenheit. The serial sensor output from the Arduino can also be viewed by opening the serial monitor in the Arduino IDE. Use the information in the background to download and install the Arduino IDE. Background Light Dependent Resistor This sensor is constructed with semiconductor material. The photons of light which are incident upon the lens of their energy is transferred to the valence electrons which gain energy to become free electrons, making the resistor more conductive, thus decreasing its resistance. A picture and the symbol for a light dependent resistor are shown in Figure 1. Figure 1: Picture and Symbol for Light Dependent Resistor (LDR) Thermistor A thermistor is a resistor whose resistance is based on temperature. These are also made from semiconductor material. They are used as over current protectors and as temperature sensor. They have a stated resistance at a stated temperature. As the temperature goes above the stated value, the resistance decreases. Thus it displays a negative temperature coefficient (PTC). Some thermistor can also have a negative temperature coefficient (NTC) Figure 2: Picture and Symbol for Thermistor Light Emitting Diode An LED is a basic semiconductor device. A PN diode is designed to act as a one way switch. It allows electrons to flow in one direction with little resistance and has a large resistance to electrons flowing in the opposite direction. An LED is designed using a unique combination of materials so that as the electrons flow through the diode, they have to give up energy because of the different valence energy levels of the two semiconductor materials. This energy is emits as photons through the above lens. In forward bias the LED conducts current. For forward bias, the anode which can be identifies as the longer lead on the component is connected to the positive terminal of the voltage source while the cathode must be connected to the negative terminal of the voltage source and the forward voltage must be applies to the terminals. The voltage drop across the LED is a constant 2.2 V. The maximum forward bias current rating is 20 mA. This current is set by using a suitable current limiting resistor. Figure 3: Picture and Symbol for Light Emitting Diode Video on getting started with Arduino https://www.youtube.com/watch?v=YWY_Is0L7fE https://www.youtube.com/watch?v=CqrQmQqpHXc https://www.youtube.com/watch?v=E6KwXYmMiak Video on thermistors with Arduino http://www.circuitbasics.com/arduino-thermistor-temperature-sensor-tutorial/ https://computers.tutsplus.com/tutorials/how-to-read-temperatures-with-arduino--mac-53714 Materials 1. 2. 3. 4. 5. 6. 7. 8. Arduino microcontroller Light dependent resistor Thermistor Carbon color code resistors (4: 470 ohm, 1: 1K ohm, 1: 10K ohm) LED lights (08L53GD) Solderless Breadboard Connecting wires (11 Jumpers) Computer with Arduino IDE software Total Components in Kit Component Quantity RED LED 2 GREEN LED 2 THERMISTOR 1 LDR 1 470 OHM RESISTOR 4 1K RESISTOR 1 10K RESISOR 1 JUMPERS 10 Component Specifications Component Specifications LED (08L53GD) F Voltage Drop: 2.2V Max Current: 20mA LDR Nominal Resistance at 25 deg. C ( 1000 ohms) Max Permissible Current at 25 deg. C ( 80 mA) Thermal Dissipation Constant ( 6 mW/deg. C) Thermistor TDC05C210 Nominal Resistance at 25 deg. C ( 1000 ohms) Max Permissible Current at 25 deg. C ( 80 mA) Circuit Figure 3: Circuit Diagram Showing pin connections for Sensor Indicator Figure 4 Picture showing construction and wire connections for Sensor Indicator Circuit on Breadboard Procedure (place data in Tables in Data) 1. 2. 3. 4. 5. Measure resistance of resistors Measure Resistance of LDR bright light condition Measure Resistance of LDR dark condition Measure Resistance of Thermistor at room Temperature Measure Resistance of Thermistor when placed near wrapped ice cube 6. Measure Resistance of Thermistor when squeezed by two fingers 7. Connect the circuit as shown 8. Power the circuit by connecting the Arduino to a computer via a USB cable 9. Measure Voltage across the LDR bright light condition 10. Measure Voltage across the LDR dark condition 11. Measure Voltage across the Thermistor at room Temperature 12. Measure Voltage across the Thermistor when placed near wrapped ice cube 13. Measure Voltage across the Thermistor when squeezed by two fingers 14. Download Arduino IDE at https://www.arduino.cc/en/Main/Donate 15. Install the program unto your computer 16. Connect your Arduino the computer using a USB A or printer cable. 17. Open a new program. Delete the code inside. 18. Copy and paste the given Sensor indicator code into the IDE. 19. Compile the code. Ensure that the Arduino UNO board and Arduino port are selected under tools. 20. Upload the program to the Arduino Board. 21. Test and observe the LEDS for the correct operation. 22. Test the temperature sensor for the three conditions. Record the temperature. 23. Determine if the thermistor has positive or negative temperature coefficient. 24. Exchange the R12 and the thermistor and repeat the temperature measurements. What did you observe 25. In Your discussion. State what you have learned, or what laws or principles have been reinforced by this project. Data Resistor Values Measured 470 470 470 470 1.0K 10.0K Measurement LDR Bright LDR Dark Thermistor Room Temp Thermistor ice Resistance Voltage Thermistor Squeezed 470 Condition Output Temperature Thermistor Room Temp Thermistor ice Thermistor Squeezed Discussion What observations can be made when comparing the change in resistance from the sensors to the change in voltage? Calculate the current flowing through the LED when it is on. Discuss how the limiting resistor value is chosen. Discuss the difference between digital and analog. Conclusion State whether the Project objectives were met, the challenges you faced, and the lessons you learned. Also state the main roles of each team member. //Sensor Indicator Code //Define Pin Names...........use // to write comments. (they are inhert and not executed) int temptensled = 4; int temponesled = 3; int lightled = 2; int darknesled = 5; int lightSensor = A0; int tempSensor = A1; //initialize Variables int value; double volts, Temperature; void setup() // setup loop { //initialize pins as input or output pinMode(temptensled, OUTPUT); // declares pin 4 as output pinMode(temponesled, OUTPUT); pinMode(lightled, OUTPUT); pinMode(darknesled, OUTPUT); // declares pin 5 as output Serial.begin(9600); // initializes serial protocol, sets data rate to 9600 bps //initialize LED as low (OFF) digitalWrite(temptensled, LOW); digitalWrite(temponesled, LOW); digitalWrite(lightled, LOW); digitalWrite(darknesled, LOW); } double Thermister(int RawADC) { //Function to perform the fancy math of the Steinhart-Hart equation double Temp; Temp = log(((10240000/RawADC) - 10000)); Temp = 1 / (0.001129148 + (0.000234125 + (0.0000000876741 * Temp * Temp ))* Temp ); Temp = Temp - 273.15; // Convert Kelvin to Celsius Temp = (Temp * 9.0)/ 5.0 + 32.0; // Celsius to Fahrenheit - comment out this line if you need Celsius return Temp; } void loop() { // Check Light Sensor value=analogRead (lightSensor); //read analog value from A0 volts=(value/1024.0)*5.0; //conversion from ADC value to volts Serial.print("LIGHT Sensor ADC = "); Serial.print (value); Serial.print(" LIGHT Sensor VOLTAGE = "); Serial.print (volts); //Light Indicator Logic if (volts < 3.8) { // Sensor is dark. Sensor resistance is very High and so the majority of the voltage drop is across it. digitalWrite(lightled, HIGH); //turn lightled HIGH delay (500); // Check Temperature Sensor value=analogRead (tempSensor); Temperature = Thermister(value) ; //read analog value from A1 // pass Value to Termister function Serial.print("Temperature Sensor ADC = "); Serial.print (value); Serial.print(" Temperature Sensor VOLTAGE = "); Serial.print ((value/1024.0)*5.0); Serial.print(" Temperature = "); Serial.println (Temperature); //Temperature Indicator Logic int t = (int)Temperature / 10; //Find number of tens(divide by 10) int o = (int)Temperature % 10; //Find number of ones (remainder from division) //............................................................................................... // Bling tens led for number of tens for ( int i=1; i<=t;i++) //loop for number of tens { digitalWrite(temptensled, HIGH); // one blink involves turning led on for 500 milli seconds delay (400); digitalWrite(temptensled, LOW); delay (400); } //................................................................................................ // Bling tens led for number of ones for ( int i=1; i<=t;i++) //loop for number of tens { digitalWrite(temponesled, HIGH); // one blink involves turning led on for 500 milli seconds delay (400); digitalWrite(temponesled, LOW); delay (400); } } else if (volts > 3.8) { // Sensor is lighted. Sensor resistance is very low and so the the voltage drop is across it is not significant. digitalWrite(lightled, LOW); //turn lightled LOW delay (500); } //................................................................................................ // Sequence to indicate end of cycle for ( int i=2; i<=5;i++) //loop for number led pins { digitalWrite(i, HIGH); // one blink involves turning led on for 500 milli seconds delay (100); digitalWrite(i, LOW); delay (100); } for ( int i=5; i<=2;i--) //loop for number led pins { digitalWrite(i, HIGH); // one blink involves turning led on for 500 milli seconds delay (100); digitalWrite(i, LOW); delay (100); } Serial.println (".............................End of Sequence..................................."); }

Tutor Answer

(Top Tutor) Studypool Tutor
School: New York University
Studypool has helped 1,244,100 students
flag Report DMCA
Similar Questions
Hot Questions
Related Tags
Study Guides

Brown University





1271 Tutors

California Institute of Technology




2131 Tutors

Carnegie Mellon University




982 Tutors

Columbia University





1256 Tutors

Dartmouth University





2113 Tutors

Emory University





2279 Tutors

Harvard University





599 Tutors

Massachusetts Institute of Technology



2319 Tutors

New York University





1645 Tutors

Notre Dam University





1911 Tutors

Oklahoma University





2122 Tutors

Pennsylvania State University





932 Tutors

Princeton University





1211 Tutors

Stanford University





983 Tutors

University of California





1282 Tutors

Oxford University





123 Tutors

Yale University





2325 Tutors