As per customer requirement designed automatic temperature control system

The temperature of system goes on 32 degree then the motor or cooling fan will operated

ds18b20 temperature sensor :

DS18B20 is one of the popular temperature sensors because it is cheap, easy to use, and also waterproof. It is a very cheap

No:Pin NameDescription
1GroundConnect to the ground of the circuit
2VccPowers the Sensor, can be 3.3V or 5V
3DataThis pin gives output the temperature value which can be read using 1-wire method  

Specification:

  • Operating voltage: 3V to 5V
  • Temperature Range: -55°C to +125°C
  • Accuracy: ±0.5°C
  • Programmable Digital Temperature Sensor
  • Communicates using 1-Wire method

DS18B20 connection:

DS18B20 Microcontroller Circuit Diagram

The sensor works with the method of 1-Wire communication. It requires only the data pin connected to the microcontroller with a pull up resistor and the other two pins are used for power

components required :

  1. Arduino UNO
  2. DS18B20 Temperature sensor
  3. cable
  4. 3 pin switch
  5. 5 V relay module
  6. 1 k resistor
  7. adapter
  8. Flexible Electrical Wire
  9. USB cable

circuit connection

in this picture arrows shoe the display, relay and switch connection with Arduino

circuit connection:

source code /program:

1. Download one wire library

Final working :

As per requirement I have get some trials on AC supply.

temperature grater than 32 degree then switch is ON.