The Flame Sensor is an electronic component designed to detect the presence of flames or high temperatures. It is commonly used in fire detection and safety systems to provide early warnings of potential fire hazards. The sensor is sensitive to infrared light emitted by flames, making it an essential component in various safety and automation applications.
Parameter | Value |
---|---|
Operating Voltage | 3.3V to 5V |
Current Consumption | 20mA (typical) |
Detection Range | Up to 100 cm (depending on flame size) |
Spectral Range | 760 nm to 1100 nm |
Output Type | Digital and Analog |
Response Time | < 15 ms |
Operating Temperature | -25°C to 85°C |
Pin Number | Pin Name | Description |
---|---|---|
1 | VCC | Power supply (3.3V to 5V) |
2 | GND | Ground |
3 | A0 | Analog output (proportional to flame intensity) |
4 | D0 | Digital output (HIGH when flame is detected) |
// Flame Sensor Example Code for Arduino UNO
const int flameSensorAnalogPin = A0; // Analog pin connected to A0
const int flameSensorDigitalPin = 2; // Digital pin connected to D0
const int ledPin = 13; // LED pin for indication
void setup() {
pinMode(flameSensorDigitalPin, INPUT); // Set digital pin as input
pinMode(ledPin, OUTPUT); // Set LED pin as output
Serial.begin(9600); // Initialize serial communication
}
void loop() {
int flameAnalogValue = analogRead(flameSensorAnalogPin); // Read analog value
int flameDigitalValue = digitalRead(flameSensorDigitalPin); // Read digital value
Serial.print("Analog Value: ");
Serial.println(flameAnalogValue); // Print analog value to serial monitor
if (flameDigitalValue == HIGH) {
digitalWrite(ledPin, HIGH); // Turn on LED if flame is detected
Serial.println("Flame detected!");
} else {
digitalWrite(ledPin, LOW); // Turn off LED if no flame is detected
Serial.println("No flame detected.");
}
delay(500); // Wait for 500 milliseconds before next reading
}
False Positives: The sensor may detect flames when there are none.
No Detection: The sensor does not detect flames even when they are present.
Inconsistent Readings: The sensor provides fluctuating or inconsistent readings.
By following this documentation, users can effectively integrate the Flame Sensor into their projects, ensuring reliable flame detection and enhancing safety measures.