Ks0116 keyestudio EASY plug Flame Sensor Module: Difference between revisions

From Keyestudio Wiki
Jump to navigation Jump to search
No edit summary
Line 22: Line 22:
<br>
<br>
==Connect It Up==
==Connect It Up==
Connect the EASY Plug flame sensor to control board using an RJ11 cable. Then connect the control board to your PC with a USB cable.
Connect the EASY Plug Flame Sensor and LED module to control board using RJ11 cables. Then connect the control board to your PC with a USB cable.
<br>[[File:ks0116.jpg|500px|frameless|thumb]]<br>
<br>[[File:火焰灯.jpg|500px|frameless|thumb]]<br>


<br>
<br>
==Upload the Code==
==Upload the Code==
Copy and paste below code to [http://wiki.keyestudio.com/index.php/How_to_Download_Arduino_IDE Arduino IDE] and upload.
Below is an example code. Open or drag below code to [https://wiki.keyestudio.com/Getting_Started_with_Mixly  Mixly Blocks] and upload. <br>
<pre>
<br>[[File:ks0398 8.1.png|500px|frameless|thumb]]<br>
const int flamePin = 2;// flame pin
 
const int ledPin = 13;// LED pin
<br>
// variables will change:
==What You Should See==
int State = 0; // variable for reading status
Done uploading the code, put a lighter close to the flame sensor. Once the sensor detects the flame, the led lights up. <br>
void setup() {
If isn’t, you are able to adjust the sensitivity by a potentiometer.
// initialize the LED pin as output:
<br>[[File:ks0398 8-1.png|500px|frameless|thumb]]<br>
pinMode(ledPin, OUTPUT);
 
// initialize the push button pin as input:
<br>
pinMode(flamePin, INPUT);
<span style="color: red">''' Little Knowledge:'''</span> <br>
}
* You are able to adjust the sensitivity by a blue potentiometer on the sensor.
void loop(){
[[image:ks0116图.jpg|thumb|600px|right|EASY plug Flame Sensor Module]] 
// read the state of the value:
<br>
State = digitalRead(flamePin);
 
if (State == HIGH) {
==Simulating Fire Extinguisher ==
// turn LED on:   
digitalWrite(ledPin, HIGH);
}
else {
// turn LED off:
digitalWrite(ledPin, LOW);
}
}
</pre>
<br>
<br>
Let’s go into an interesting project. When detecting the flame by flame sensor, the fan motor will rotate to blow out the fire.
<br>
'''Hookup Guide'''<br>
<br>[[File:火焰电机.jpg|500px|frameless|thumb]]<br>


==What You Should See==
<br>
Done uploading the code, put a lighter close to the flame sensor. Once the sensor detects the flame, you should see the led light up. If isn’t, you are able to adjust the sensitivity by a potentiometer.
'''Test Code'''<br>
<br>[[File:ks0116 Result.png|500px|frameless|thumb]]<br>
<br>[[File:ks0398 8.2.png|500px|frameless|thumb]]<br>
 
<br>
'''What You Should See'''<br>
Done uploading the code, put a lighter close to the flame sensor. Once the sensor detects the flame, you should see the fan motor run.  
<br>[[File:ks0398 8-2.png|500px|frameless|thumb]]<br>
 
<br>


<br>
<br>
==Resources ==
==Resources ==
'''Download the PDF:'''<br>
'''Download the Arduino Code and PDF:'''<br>
https://drive.google.com/open?id=1aGobmBGdVwTBZ99YIRtuCf7Kg8FZYUTN
https://drive.google.com/open?id=1H6Ndu3bFg1rYiiXJYq8CA2mn7Iam3P7W


'''Download the Code:'''<br>
'''Download the Mixly Code and Datasheet:'''<br>
https://drive.google.com/open?id=1chK-3R_bGSTEImeCHwg_hrKj9iHHvWgd
https://drive.google.com/open?id=15G-2R7egqePV9Oy7MR7FakVHL-EqstB5




<br>
<br>
==Buy from ==
==Buy from ==
*'''Official Website:'''  http://www.keyestudio.com/ks0116.html
*[https://www.keyestudio.com/new-keyestudio-rj11-easy-plug-flame-sensor-module-for-arduino-steam-p0090-p0090.html '''Official Website'''  ]


*[https://www.aliexpress.com/store/product/New-Keyestudio-EASY-plug-Flame-Sensor-module-for-Arduino/1452162_32643691546.html?spm=2114.12010612.8148356.58.2dc64ba7CLVAOv    Shop on aliexpress ]
*[https://www.aliexpress.com/store/product/New-Keyestudio-EASY-plug-Flame-Sensor-module-for-Arduino/1452162_32643691546.html?spm=2114.12010612.8148356.58.2dc64ba7CLVAOv    Shop on aliexpress ]

Revision as of 09:50, 7 May 2019

EASY plug Flame Sensor Module

Introduction

The flame sensor can be used to detect fire or other wavelength at 760nm ~1100nm light.
In the fire-fighting robot game, the flame plays an important role in the probe, which can be used as the robot's eyes to find fire source.
The potentiometer on the flame sensor can be used to adjust the sensitivity.
Note: this module should be used together with EASY plug control board.

Specification

  • Connector: Easy plug
  • Supply Voltage: 3.3V to 5V
  • Detection range: 500px (4.8V) ~ 2500px (1V)
  • Spectral Bandwidth Range: 760nm ~ 1100nm
  • Operating temperature: -25℃ to 85℃
  • Sensor type: digital


Technical Details

  • Dimensions: 48mm*17mm*18mm
  • Weight: 4.6g


Connect It Up

Connect the EASY Plug Flame Sensor and LED module to control board using RJ11 cables. Then connect the control board to your PC with a USB cable.
thumb


Upload the Code

Below is an example code. Open or drag below code to Mixly Blocks and upload.

thumb


What You Should See

Done uploading the code, put a lighter close to the flame sensor. Once the sensor detects the flame, the led lights up.
If isn’t, you are able to adjust the sensitivity by a potentiometer.
thumb


Little Knowledge:

  • You are able to adjust the sensitivity by a blue potentiometer on the sensor.
EASY plug Flame Sensor Module


Simulating Fire Extinguisher


Let’s go into an interesting project. When detecting the flame by flame sensor, the fan motor will rotate to blow out the fire.
Hookup Guide

thumb


Test Code

thumb


What You Should See
Done uploading the code, put a lighter close to the flame sensor. Once the sensor detects the flame, you should see the fan motor run.
thumb



Resources

Download the Arduino Code and PDF:
https://drive.google.com/open?id=1H6Ndu3bFg1rYiiXJYq8CA2mn7Iam3P7W

Download the Mixly Code and Datasheet:
https://drive.google.com/open?id=15G-2R7egqePV9Oy7MR7FakVHL-EqstB5



Buy from