当前位置:网站首页>Arduino flame sensor (with code)
Arduino flame sensor (with code)
2022-06-23 05:10:00 【Loading_ create】
Flame sensor wiring
Flame module modules and numbers 13 The interface comes with LED Build a simple circuit , Make a flame light . Use numbers 13 The interface comes with LED, Connect the flame sensor to the digital 3 Interface , When the flame sensor senses a key signal ,LED bright , On the contrary, it will extinguish ..
Here's the picture :
Routine source code :
int Led=13;// Definition LED Interface
int buttonpin=3; // Define the flame sensor interface int val;// Define digital variables val
void setup()
{
pinMode(Led,OUTPUT);// Definition LED Is the output interface
pinMode(buttonpin,INPUT);// Define the flame sensor as the output interface
}
void loop()
{
val=digitalRead(buttonpin);// Connect the digital interface 3 Read the value assigned to val
if(val==HIGH){
// When the flame sensor detects a signal ,LED flashing
digitalWrite(Led,HIGH);
}
else{
digitalWrite(Led,LOW);
}
}
If help , Please praise the collection , In case of problems , Please send a private message directly .
边栏推荐
- 代码片段管理器SnippetsLab
- 396. mine site construction
- Notepad++ find replace group replace retain
- rtklib新版本2.4.3 b34测试对比
- Separate use of alertmanager alarms and use of Prometheus configuration alarm rules
- Direct insertion sort - [common sort method (1/8)]
- Seven year manong Road
- ICER skills 03design compile
- Apache atlas quick start
- Thinkphp6 solving jump problems
猜你喜欢
随机推荐
How can mushrooms survive a five-year loss of 4.2 billion yuan?
The solution to prompt "this list creation could be rewritten as a list literal" when adding elements to the list using the append() method in pychart
Do280openshift command and troubleshooting -- common troubleshooting and chapter experiments
Cloud native database is in full swing, and the future can be expected
dolphinscheduler海豚调度升级代码改造-UpgradeDolphinScheduler
物体结构图,快速图解物体内部结构
Dolphin scheduler 2.0.5 task test (spark task) reported an error: container exited with a non zero exit code 1
Banner banner
HCIP第五次作业
ICER skills 03design compile
Arduino火焰传感器(含代码)
Go learning record II (window)
dolphinscheduler 1.2.1 数据迁移到 dolphinscheduler 2.0.5方法及迁移后数据测试记录
HCIP 重发布实验
新晋职场人的 技术进击?之旅
Object structure diagram, which can quickly illustrate the internal structure of an object
vmware网络连接出错Unit network.service not found
Meituan's good article: understand swift, Objective-C and the mixing mechanism from the perspective of precompiling
apache atlas 快速入门
微信小程序:土味情话恋爱话术









