Assignment-1
The Temperature Box: An Introductory Control System Project
Objective
● Problem based learning approach
● To design and implementation of a close loop feedback
temperature control system
● Analogue and digital circuit implementation
● Compare and differentiate by LM35 and DS18B20
COMPONENTS OF THIS PROJECT
● Sensor LM35 and DS18B20
● Scale and shift circuit
● Relay
● LED
● DC source
● Arduino uno
● Resistor
● potentiometer
BLOCK DIAGRAM
EQUATIONS AND CONVERSIONS
We get, Vs=0.975+0.0125Tf
Also, Tf= 70 degree F ; Vs=1.85V
Tf=85 degree F ; Vs=2.04V
Tf=95 degree F ; Vs=2.16V
Tc=70 degree C ; Tf= 21.11 degree F
Tc= 85 degree C ; Tf= 29.44 degree F
Tc= 95 degree C ; Tf= 35 degree F
We will put 0.5V and 4.5V at 85 and 95 degree F in scale and shift equation which is
Vt= α+βVs
SCALE AND SHIFT CIRCUIT FOR LM35
Voltage output at 29 degree (low) , Vs=29*0.01=0.29 volts
Voltage output at 35 degree (high) , Vs = 35*0.01=0.35 volts
Vt=0.5V at 29 degree celsius and Vt=4.5V at 35 degree celsius
We know, Vt= α+βVs
0.5=α+β0.29 ……..(1)
4.5=α+β0.35 ……..(2)
From equation (1) and (2) we get,
α= -18.83 and β= 66.67
Let , R=100K
R1=R/β=100/66.67=1.5K
R2=[-5*(R)]/α=[-5*(100)]/(-18.83)= 26.6K
Scale and Shift circuit
COMPARISON CIRCUIT
● Scaled and shifted sensor voltage is compared
to the predetermined high and low
temperatures.
● A decision is made (using digital logic)
whether to open or close the relay and, hence,
turn the device off or on.
● VH denote the voltage corresponding to the
highest desired temperature and VL denote
voltage corresponding to the lowest desired
temperature.
● The decision is based on three rules
1. The relay is on if VT < VL < VH.
2. The relay is off if VT > VH > VL.
3. The relay state is unchanged if VL < VT < VH.
COMPARISON CIRCUIT
● The decision is based on three rules
1. The relay is on if VT < VL < VH.
2. The relay is off if VT > VH > VL.
3. The relay state is unchanged if VL <
VT <VH.
COMPARISON OF LM35
After scaling,
Input voltage at comparison circuit for 29 degree celsius = 0.29 volts
Input voltage at comparison circuit for 35 degree celsius = 0.35 volts
We know, Vt= α+βVs
VL=Vt= (-18.83)+(66.67*0.29)=0.5V
VH=Vt= (-18.83)+(66.67*0.35)=4.5V
ANALOGUE CONTROLLER (LM35)
● Use to measure precise centigrade temperature.
● It is rated to operate over a -55 degree celsius to
150 degree celsius temperature range.
● Output voltage increases 10mV per degree celsius
rise in temperature.
● Input voltage is from 4 volts to 30 volts.
● Consumes about 60 microamperes of current.
● Output voltages are linearly comparative to the
celsius temperature.
RELAY
● Activated for strong positive
voltage.
● Get pulls on the switch and the
circuit is completed for LED and
then shines.
● Pull goes away when voltage is
released.
● Switch remains in original
position when a little voltage is
given.
DIGITAL AND LOGIC IMPLEMENTATION
● Here we need to define two logical
functions:
A = Vt < Vh, B = Vt >Vl.
1.VT greater than VH Then A =
1 and B = 0
2. VT less than VL Then B = 1 and A = 0
3.VT between VH and VL then A = B
DIGITAL LOGIC
● Bulb will be ON if
VT≤VL<VH
● Bulb will be OFF if VT
≥VH>VL
● Bulb will be UNCHANGED
if VL<VT<VH
A
A B OUT PUT
0 0 Previous
State
0 1 Previous
State
1 0 Off
1 1 Not Possible
DIGITAL CONTROLLER LM35
ADC Value Calculation
For,
29 Degree Celsius (0.29V)
Val = (0.29 × 1023) ÷ 5 = 59.33 = 59 (Approximately)
For ,
35 Degree Celsius (0.35V)
Val = (0.35 × 1023) ÷ 5 = 71.61 = 71 (Approximately)
1.The relay is on if Vt ≤ Vl < Vh [on]
2. The relay is off if Vt ≥ Vh > Vl [off]
3. State is unchanged if Vl < Vt < Vh
DIGITAL CONTROLLER DS18B20
ADC Value Calculation
For,
29 Degree Celsius (0.29V)
Val = (0.29 × 1023) ÷ 5 = 59.33 = 59 (Approximately)
For ,
35 Degree Celsius (0.35V)
Val = (0.35 × 1023) ÷ 5 = 71.61 = 71 (Approximately)
1.The relay is on if Vt ≤ Vl < Vh [on]
2. The relay is off if Vt ≥ Vh > Vl [off]
3. State is unchanged if Vl < Vt < Vh
Complete circuit with LM35 temperature
sensor
When temperature is 28°C i.e. VT<VL<VH
and Lamp turns On
When temperature is 32°C i.e. VL<VT<VH and Lamp
should remain like its previous state but it becomes off.
When temperature is 36°C i.e. VL<VH<VT and
Lamp become off
Complete circuit using DS18B20 temperature
sensor
Temperature increased but no voltage is
generating from DS18B20
LM35 ANALOGUE CIRCUIT
DS18B20 ANALOGUE CIRCUIT
LM35 DIGITAL CIRCUIT
ARDUINO CODE FOR LM35
int sensor = A0, relay = 7, adc_in=0;
float temp=0;
void setup () {
Serial.begin(9600);
pinMode(relay, OUTPUT);
}
void loop() {
adc_in=analogRead(sensor);
temp= ((adc_in*5000.0)/1023.0)/10.0;
Serial.println(temp);
}
if (temp >=35){
digitalWrite(relay, LOW);
Serial.println("Relay off");
}
if (temp <=30){
digitalWrite(relay, HIGH);
Serial.println("Relay on");
}
delay(1000);
DS1820 DIGITAL CIRCUIT
ARDUINO CODE FOR DS18B20
ARDUINO CODE FOR
DS18B20
void loop(void)
{
sensors.requestTemperatures();
temp=sensors.getTempCByIndex(0);
Serial.println(" C ");
Serial.println(temp);
if (temp >=35){
digitalWrite(relay, LOW);
Serial.println("Relay off");
}
if (temp <=30){
digitalWrite(relay, HIGH);
Serial.println("Relay on");
}
delay(1000);
}
COST ALLOCATION AND COMPARISON
DIGITAL CONTROLLER LM35
● LM35 sensor- 140tk
● Voltage source- 110tk
● Arduino-950tk
● RESISTOR-16tk (8 pisces)
● NPN BJT-4tk
● LED-2tk
● Jumper wire-30tk
● Relay-30tk
Total cost : 1282tk
DIGITAL CONTROLLER DS18B20
● DS18B20 sensor-100tk
● Voltage source-110tk
● Arduino-950tk
● NPN BJT-4tk
● LED-2tk
● Relay-30tk
● Jumper wire-30tk
Total cost : 1226tk
REFERENCE
https://techshopbd.com/
Conclusion
From this project we can say that analog circuit system instantly stops while
VT> VL and we also say that Digital circuit is costly but more efficient.

More Related Content

PPTX
Dual Active Bridge Converter a Bidirectional Isolated DC DC Converter
PPTX
Chapter7 response of first order rl and rc circuit.pptx
PPTX
555 timer
PPTX
555 timer
PDF
Temperature box
PDF
Lica unit4 ppt
PPT
Circuits
PPTX
555 timer vibrators
Dual Active Bridge Converter a Bidirectional Isolated DC DC Converter
Chapter7 response of first order rl and rc circuit.pptx
555 timer
555 timer
Temperature box
Lica unit4 ppt
Circuits
555 timer vibrators

Similar to EEE305 Assignment-1.pdf (20)

DOCX
PDF
Signal Conditioninsdf a sdf asdf ad fs.pdf
PPT
Ic 555 timer 0
PDF
EE 330 Lect 26 Spring 2015.pdf
PPTX
PLC LADDER DIAGRAM
PPTX
MATH (PPT).pptx
PPTX
Moodle unit 5 555 timer for electronics engineering student .pptx
PDF
431378390 convertirdor-sepic
PDF
Datasheet lm358
PDF
SE ECS EC Module6 555 Timer.pdf
PPTX
Multivibrators-Astable, Bistable and Monostable.pptx
PDF
IC_555 ppt.pdf 555 Integrated Circuits and its various applications
PPTX
Initial condition
PPTX
GET 201 L3 engineering drawing 100L.pptx
PPTX
Chapter 2 Network analysis and synthesis.pptx
PDF
Chapter 5 DC-DC Converters.pdf
PDF
Datasheet
PPT
7_Temperature_Sensor.ppt_ajinkya_xxxxxxxx
PPT
Temperature sensor_Ajinkya kamble_pptxxx
PPT
Introduction to Interfacing Temperature_Sensor.ppt
Signal Conditioninsdf a sdf asdf ad fs.pdf
Ic 555 timer 0
EE 330 Lect 26 Spring 2015.pdf
PLC LADDER DIAGRAM
MATH (PPT).pptx
Moodle unit 5 555 timer for electronics engineering student .pptx
431378390 convertirdor-sepic
Datasheet lm358
SE ECS EC Module6 555 Timer.pdf
Multivibrators-Astable, Bistable and Monostable.pptx
IC_555 ppt.pdf 555 Integrated Circuits and its various applications
Initial condition
GET 201 L3 engineering drawing 100L.pptx
Chapter 2 Network analysis and synthesis.pptx
Chapter 5 DC-DC Converters.pdf
Datasheet
7_Temperature_Sensor.ppt_ajinkya_xxxxxxxx
Temperature sensor_Ajinkya kamble_pptxxx
Introduction to Interfacing Temperature_Sensor.ppt
Ad

Recently uploaded (20)

PDF
Introduction to Power System StabilityPS
PPTX
CN_Unite_1 AI&DS ENGGERING SPPU PUNE UNIVERSITY
PDF
Unit I -OPERATING SYSTEMS_SRM_KATTANKULATHUR.pptx.pdf
PPTX
mechattonicsand iotwith sensor and actuator
PPT
Chapter 1 - Introduction to Manufacturing Technology_2.ppt
PDF
Unit1 - AIML Chapter 1 concept and ethics
PDF
Soil Improvement Techniques Note - Rabbi
PPTX
ASME PCC-02 TRAINING -DESKTOP-NLE5HNP.pptx
PDF
Accra-Kumasi Expressway - Prefeasibility Report Volume 1 of 7.11.2018.pdf
PPTX
Chapter 2 -Technology and Enginerring Materials + Composites.pptx
PDF
August 2025 - Top 10 Read Articles in Network Security & Its Applications
PPTX
tack Data Structure with Array and Linked List Implementation, Push and Pop O...
PDF
Cryptography and Network Security-Module-I.pdf
PPTX
AUTOMOTIVE ENGINE MANAGEMENT (MECHATRONICS).pptx
PDF
UEFA_Carbon_Footprint_Calculator_Methology_2.0.pdf
PDF
UEFA_Embodied_Carbon_Emissions_Football_Infrastructure.pdf
PPTX
ai_satellite_crop_management_20250815030350.pptx
PDF
First part_B-Image Processing - 1 of 2).pdf
PPTX
Principal presentation for NAAC (1).pptx
PDF
Applications of Equal_Area_Criterion.pdf
Introduction to Power System StabilityPS
CN_Unite_1 AI&DS ENGGERING SPPU PUNE UNIVERSITY
Unit I -OPERATING SYSTEMS_SRM_KATTANKULATHUR.pptx.pdf
mechattonicsand iotwith sensor and actuator
Chapter 1 - Introduction to Manufacturing Technology_2.ppt
Unit1 - AIML Chapter 1 concept and ethics
Soil Improvement Techniques Note - Rabbi
ASME PCC-02 TRAINING -DESKTOP-NLE5HNP.pptx
Accra-Kumasi Expressway - Prefeasibility Report Volume 1 of 7.11.2018.pdf
Chapter 2 -Technology and Enginerring Materials + Composites.pptx
August 2025 - Top 10 Read Articles in Network Security & Its Applications
tack Data Structure with Array and Linked List Implementation, Push and Pop O...
Cryptography and Network Security-Module-I.pdf
AUTOMOTIVE ENGINE MANAGEMENT (MECHATRONICS).pptx
UEFA_Carbon_Footprint_Calculator_Methology_2.0.pdf
UEFA_Embodied_Carbon_Emissions_Football_Infrastructure.pdf
ai_satellite_crop_management_20250815030350.pptx
First part_B-Image Processing - 1 of 2).pdf
Principal presentation for NAAC (1).pptx
Applications of Equal_Area_Criterion.pdf
Ad

EEE305 Assignment-1.pdf

  • 1. Assignment-1 The Temperature Box: An Introductory Control System Project
  • 2. Objective ● Problem based learning approach ● To design and implementation of a close loop feedback temperature control system ● Analogue and digital circuit implementation ● Compare and differentiate by LM35 and DS18B20
  • 3. COMPONENTS OF THIS PROJECT ● Sensor LM35 and DS18B20 ● Scale and shift circuit ● Relay ● LED ● DC source ● Arduino uno ● Resistor ● potentiometer
  • 5. EQUATIONS AND CONVERSIONS We get, Vs=0.975+0.0125Tf Also, Tf= 70 degree F ; Vs=1.85V Tf=85 degree F ; Vs=2.04V Tf=95 degree F ; Vs=2.16V Tc=70 degree C ; Tf= 21.11 degree F Tc= 85 degree C ; Tf= 29.44 degree F Tc= 95 degree C ; Tf= 35 degree F We will put 0.5V and 4.5V at 85 and 95 degree F in scale and shift equation which is Vt= α+βVs
  • 6. SCALE AND SHIFT CIRCUIT FOR LM35 Voltage output at 29 degree (low) , Vs=29*0.01=0.29 volts Voltage output at 35 degree (high) , Vs = 35*0.01=0.35 volts Vt=0.5V at 29 degree celsius and Vt=4.5V at 35 degree celsius We know, Vt= α+βVs 0.5=α+β0.29 ……..(1) 4.5=α+β0.35 ……..(2) From equation (1) and (2) we get, α= -18.83 and β= 66.67 Let , R=100K R1=R/β=100/66.67=1.5K R2=[-5*(R)]/α=[-5*(100)]/(-18.83)= 26.6K
  • 7. Scale and Shift circuit
  • 8. COMPARISON CIRCUIT ● Scaled and shifted sensor voltage is compared to the predetermined high and low temperatures. ● A decision is made (using digital logic) whether to open or close the relay and, hence, turn the device off or on. ● VH denote the voltage corresponding to the highest desired temperature and VL denote voltage corresponding to the lowest desired temperature. ● The decision is based on three rules 1. The relay is on if VT < VL < VH. 2. The relay is off if VT > VH > VL. 3. The relay state is unchanged if VL < VT < VH.
  • 9. COMPARISON CIRCUIT ● The decision is based on three rules 1. The relay is on if VT < VL < VH. 2. The relay is off if VT > VH > VL. 3. The relay state is unchanged if VL < VT <VH.
  • 10. COMPARISON OF LM35 After scaling, Input voltage at comparison circuit for 29 degree celsius = 0.29 volts Input voltage at comparison circuit for 35 degree celsius = 0.35 volts We know, Vt= α+βVs VL=Vt= (-18.83)+(66.67*0.29)=0.5V VH=Vt= (-18.83)+(66.67*0.35)=4.5V
  • 11. ANALOGUE CONTROLLER (LM35) ● Use to measure precise centigrade temperature. ● It is rated to operate over a -55 degree celsius to 150 degree celsius temperature range. ● Output voltage increases 10mV per degree celsius rise in temperature. ● Input voltage is from 4 volts to 30 volts. ● Consumes about 60 microamperes of current. ● Output voltages are linearly comparative to the celsius temperature.
  • 12. RELAY ● Activated for strong positive voltage. ● Get pulls on the switch and the circuit is completed for LED and then shines. ● Pull goes away when voltage is released. ● Switch remains in original position when a little voltage is given.
  • 13. DIGITAL AND LOGIC IMPLEMENTATION ● Here we need to define two logical functions: A = Vt < Vh, B = Vt >Vl. 1.VT greater than VH Then A = 1 and B = 0 2. VT less than VL Then B = 1 and A = 0 3.VT between VH and VL then A = B
  • 14. DIGITAL LOGIC ● Bulb will be ON if VT≤VL<VH ● Bulb will be OFF if VT ≥VH>VL ● Bulb will be UNCHANGED if VL<VT<VH A A B OUT PUT 0 0 Previous State 0 1 Previous State 1 0 Off 1 1 Not Possible
  • 15. DIGITAL CONTROLLER LM35 ADC Value Calculation For, 29 Degree Celsius (0.29V) Val = (0.29 × 1023) ÷ 5 = 59.33 = 59 (Approximately) For , 35 Degree Celsius (0.35V) Val = (0.35 × 1023) ÷ 5 = 71.61 = 71 (Approximately) 1.The relay is on if Vt ≤ Vl < Vh [on] 2. The relay is off if Vt ≥ Vh > Vl [off] 3. State is unchanged if Vl < Vt < Vh
  • 16. DIGITAL CONTROLLER DS18B20 ADC Value Calculation For, 29 Degree Celsius (0.29V) Val = (0.29 × 1023) ÷ 5 = 59.33 = 59 (Approximately) For , 35 Degree Celsius (0.35V) Val = (0.35 × 1023) ÷ 5 = 71.61 = 71 (Approximately) 1.The relay is on if Vt ≤ Vl < Vh [on] 2. The relay is off if Vt ≥ Vh > Vl [off] 3. State is unchanged if Vl < Vt < Vh
  • 17. Complete circuit with LM35 temperature sensor
  • 18. When temperature is 28°C i.e. VT<VL<VH and Lamp turns On
  • 19. When temperature is 32°C i.e. VL<VT<VH and Lamp should remain like its previous state but it becomes off.
  • 20. When temperature is 36°C i.e. VL<VH<VT and Lamp become off
  • 21. Complete circuit using DS18B20 temperature sensor
  • 22. Temperature increased but no voltage is generating from DS18B20
  • 26. ARDUINO CODE FOR LM35 int sensor = A0, relay = 7, adc_in=0; float temp=0; void setup () { Serial.begin(9600); pinMode(relay, OUTPUT); } void loop() { adc_in=analogRead(sensor); temp= ((adc_in*5000.0)/1023.0)/10.0; Serial.println(temp); } if (temp >=35){ digitalWrite(relay, LOW); Serial.println("Relay off"); } if (temp <=30){ digitalWrite(relay, HIGH); Serial.println("Relay on"); } delay(1000);
  • 28. ARDUINO CODE FOR DS18B20 ARDUINO CODE FOR DS18B20 void loop(void) { sensors.requestTemperatures(); temp=sensors.getTempCByIndex(0); Serial.println(" C "); Serial.println(temp); if (temp >=35){ digitalWrite(relay, LOW); Serial.println("Relay off"); } if (temp <=30){ digitalWrite(relay, HIGH); Serial.println("Relay on"); } delay(1000); }
  • 29. COST ALLOCATION AND COMPARISON DIGITAL CONTROLLER LM35 ● LM35 sensor- 140tk ● Voltage source- 110tk ● Arduino-950tk ● RESISTOR-16tk (8 pisces) ● NPN BJT-4tk ● LED-2tk ● Jumper wire-30tk ● Relay-30tk Total cost : 1282tk DIGITAL CONTROLLER DS18B20 ● DS18B20 sensor-100tk ● Voltage source-110tk ● Arduino-950tk ● NPN BJT-4tk ● LED-2tk ● Relay-30tk ● Jumper wire-30tk Total cost : 1226tk
  • 31. Conclusion From this project we can say that analog circuit system instantly stops while VT> VL and we also say that Digital circuit is costly but more efficient.