This paper presents the design and implementation of a real-time system for the temperature monitoring and control in an infant incubator using a microcontroller. The implementation of a set of controlapproaches on the microcontroller is investigated: direct on-off control, proportional (P-control), proportional-integral (PI-control), proportional-integral-derivative (PID-control) and fuzzy logic control. The temperature is measured using reusable skin/surface probe sensor. The controller output determines the amount of power supplied to the heater by employing pulse width modulation and a IGBT-triggered circuit. The performance of the applied control approaches is evaluated and compared. It was concluded that the fuzzy logic controller resulted in the most accurate response with the least settling time and standard deviation compared with the other approaches.
CIRCUIT
PROGRAM
#include <LiquidCrystal.h>
LiquidCrystal lcd(3, 4, A0, 6, 7, 8);//LCD RS-3,En-4,D4-5,D5- 6,D6-7,D7-8
int a=0,b=0,x=0,y=0;
void setup()
{
Serial.begin(9600);
delay(100);
lcdstart();
}
void loop()
{
a=analogRead(A5)/6;
delay(10);
Serial.print(a);
lcd.setCursor(0, 0);
lcd.print(“Temperature:”);
lcd.setCursor(12, 0);
lcd.print(a);
if((0<a)&&(a<20))
{
analogWrite(9,255);
delay(500);
x=1;
}
if((21<a)&&(a<35))
{
analogWrite(9,250);
delay(500);
}
if((36<a)&&(a<50))
{
analogWrite(9,200);
delay(500);
}
if((51<a)&&(a<65))
{
analogWrite(9,150);
delay(500);
}
if((67<a)&&(a<70))
{
analogWrite(9,100);
delay(500);
}
if(a>71)
{
analogWrite(9,0);
lcd.setCursor(4, 1);
lcd.print(“emergency”);
delay(500);
x=2;
}
if (((x==1)||(x==2))&&(y==0))
{
message();
x=0;
y=1;
lcd.setCursor(15, 1);
lcd.print(“1”);
delay(500);
}
lcd.clear();
}
void lcdstart(void)
{
lcd.begin(16, 2);// set up the LCD’s number of columns and rows:
lcd.setCursor(4, 0);
lcd.print(“WELCOME!”);// Print a message to the LCD.
delay(500);
lcd.clear();
}
void message(void)
{
Serial.print(“AT+CMGF=1”);//TEXT MODE
Serial.write(0xd);//ENTER
delay(1000);
Serial.print(“AT+CMGS=”);
Serial.write(0X22);
Serial.print(“90489”);
Serial.print(“47373”);
Serial.write(0X22);
Serial.write(0xd);
delay(1000);
Serial.print(“Emergency”);
Serial.write(0x1a);
}