点亮一个esp32 的led

最近入了一个ESP32 兄弟们,这玩意还可以,买来肯定是给它点亮啊对吧 我就是点灯侠🎇

😭千万不要不接天线啊,不然你会一直找不到你的wifi

1.点灯第一步你得有IDE == Arduino

就是这个绿东西

可是怎么下载安装呢?自己百度吧,当然你要是懒这边也给您附加了连接

Arduino 安装 ---这里作者认为你看连接并且你安装好了

esp32 sdk 安装 ---这里也作者认为你看连接并且你安装好了

2023/5/2 值得注意的是 这个sdk你需要以管理员的身份去运行

ok 现在进入第二步

2.编写点灯程序

cpp 复制代码
const int LED = 2;
void setup() {
    // initialize digital pin LED_BUILTIN as an output.
    pinMode(LED, OUTPUT);
}

// the loop function runs over and over again forever
void loop() {
    digitalWrite(LED, HIGH);   // turn the LED on (HIGH is the voltage level)
    delay(1000);                       // wait for a second
    digitalWrite(LED, LOW);    // turn the LED off by making the voltage LOW
    delay(1000);                       // wait for a second
}

烧录

一定要选串口

上传

cpp 复制代码
项目使用了 219045 字节,占用了 (16%) 程序存储空间。最大为 1310720 字节。
全局变量使用了16088字节,(4%)的动态内存,余留311592字节局部变量。最大为327680字节。
esptool.py v3.3
Serial port COM4
Connecting......
Chip is ESP32-D0WD-V3 (revision 3)
Features: WiFi, BT, Dual Core, 240MHz, VRef calibration in efuse, Coding Scheme None
Crystal is 40MHz
MAC: e8:31:cd:74:1c:84
Uploading stub...
Running stub...
Stub running...
Changing baud rate to 921600
Changed.
Configuring flash size...
Flash will be erased from 0x00001000 to 0x00005fff...
Flash will be erased from 0x00008000 to 0x00008fff...
Flash will be erased from 0x0000e000 to 0x0000ffff...
Flash will be erased from 0x00010000 to 0x00045fff...
Flash params set to 0x022f
Compressed 18880 bytes to 12992...
Writing at 0x00001000... (100 %)
Wrote 18880 bytes (12992 compressed) at 0x00001000 in 0.5 seconds (effective 279.9 kbit/s)...
Hash of data verified.
Compressed 3072 bytes to 128...
Writing at 0x00008000... (100 %)
Wrote 3072 bytes (128 compressed) at 0x00008000 in 0.1 seconds (effective 350.9 kbit/s)...
Hash of data verified.
Compressed 8192 bytes to 47...
Writing at 0x0000e000... (100 %)
Wrote 8192 bytes (47 compressed) at 0x0000e000 in 0.1 seconds (effective 490.3 kbit/s)...
Hash of data verified.
Compressed 219440 bytes to 120828...
Writing at 0x00010000... (12 %)
Writing at 0x0001d956... (25 %)
Writing at 0x00022fd3... (37 %)
Writing at 0x00028288... (50 %)
Writing at 0x0002d6ef... (62 %)
Writing at 0x00035f5d... (75 %)
Writing at 0x0003e042... (87 %)
Writing at 0x000438e3... (100 %)
Wrote 219440 bytes (120828 compressed) at 0x00010000 in 2.4 seconds (effective 722.3 kbit/s)...
Hash of data verified
相关推荐
深圳启明云端科技4 小时前
设备智能化无线交互,ESP32-C3芯片方案,物联网WiFi蓝牙控制通信
物联网·人机交互·智能家居·乐鑫·esp32-c3
一只搬砖的猹4 小时前
PCA9685舵机控制板使用
stm32·单片机·嵌入式硬件·mcu·pwm·舵机·舵机驱动
猫猫的小茶馆10 小时前
【进程与线程】如何编写一个守护进程
linux·运维·c语言·git·单片机·mcu
Amarantine、沐风倩✨12 小时前
区块链技术未来发展趋势(人工智能和物联网领域)
人工智能·物联网·区块链
智联物联21 小时前
工业 4G 路由器助力消防领域,守卫生命安全防线
物联网·远程监控·4g·工业路由器·智联物联·数据传输·无线路由器
Try1harder1 天前
联德胜w801开发板(六)手机蓝牙设置wifi名称和密码
单片机·物联网·蓝牙·w801
神一样的老师2 天前
战场物联网中的移动雾人工智能
物联网
好奇的菜鸟2 天前
物联网的三层架构:感知层、网络层与应用层
物联网·架构
大有数据可视化2 天前
如今物联网的快速发展对hmi的更新有哪些积极影响
物联网·车载hmi·hmi界面
深圳启明云端科技2 天前
ESP32-C6通过Thread 1.4认证,设备无线交互联动,物联网通信方案
物联网·乐鑫·esp32-c6·无线方案·无线组网