当前位置:网站首页>ESP32CAM 1838接收红外遥控器信号
ESP32CAM 1838接收红外遥控器信号
2022-07-30 10:15:00 【qq179395714】
Arduino 1.8.20
IRremote 3.7.1
1838T红外接收头
安装IRremote
Arduino-工具-管理库-搜索IRremote-安装IRremote
ESP32 CAM引脚与1838T引脚接线
ESP32 CAM | 1838T |
5V | VCC |
GND | GND |
IO14 | D0 |
1838T模块
#include <IRremote.hpp>
#define IR_RECEIVE_PIN 14 // IO14
void setup() {
// put your setup code here, to run once:
Serial.begin(115200); //串口初始化
//启动接收器
IrReceiver.begin(IR_RECEIVE_PIN, ENABLE_LED_FEEDBACK);
Serial.print(F("准备接收协议的红外信号: "));
printActiveIRProtocols(&Serial);
Serial.println(F("Enabling IRin..."));
}
void loop() {
// put your main code here, to run repeatedly:
if(IrReceiver.decode())
{
IrReceiver.printIRResultShort(&Serial);
IrReceiver.resume();
}
}
上传后打开串口监视器
Arduino-工具-串口监视器
用红外遥控器测试
边栏推荐
猜你喜欢
WARN: Establishing SSL connection without server's identity verification is not recommended when connecting to mysql
Paper reading: SegFormer: Simple and Efficient Design for Semantic Segmentation with Transformers
【云原生】-Docker安装部署分布式数据库 OceanBase
Day113. Shangyitong: WeChat login QR code, login callback interface
New in GNOME: Warn users when Secure Boot is disabled
再有人问你分布式事务,把这篇扔给他
spark udf 接受并处理 null值.
The configuration process and related syntax of writing markdown format notes in vscode
死锁的理解
Multi-threading scheme to ensure that a single thread opens a transaction and takes effect
随机推荐
Some commands of kubernetes
OC - Manual Reference Counting Memory Management
电压跟随器不要随便加
Re20:读论文 What About the Precedent: An Information-Theoretic Analysis of Common Law
The method of parameter passing
360 released a future-oriented EDR to protect the security of government and enterprise user terminals in an all-round way
paging
(C language) file operation
idea2021+Activiti【最完整笔记一(基础使用)】
GNOME 新功能:安全启动被禁用时警告用户
JCL 学习
【HMS core】【FAQ】HMS Toolkit典型问题合集1
[Deep Learning] (Problem Record)
- Linear Regression - Small Batch Stochastic Gradient Descent BERT pre-training model series summary
数据库脏读、不可重复读、幻读以及对应的隔离级别
梅科尔工作室-看鸿蒙设备开发实战笔记四——内核开发
By building a sequence table - teach you to calculate time complexity and space complexity (including recursion)
神秘的APT攻击
(***Key points***) Flink common memory problems and tuning guide (1)
Meikle Studio - see the actual combat notes of Hongmeng device development 4 - kernel development