参考文章
pip install esptool
esptool.py --port COM? erase_flash
案例
esptool.py --port COM3 erase_flash
esp mircopython官网
我的固件
格式
esptool.py --chip esp32 --port COM? write_flash -z 0x1000 .bin文件全名
案例
esptool.py --chip esp32 --port COM3 write_flash -z 0x1000 esp32-idf3-20210202-v1.14.bin
Open file on device
Run file on device
: 运行程序Upload to device
: 上传程序#led.py
import time
import machine
led = machine.Pin(2,machine.Pin.OUT)
def run():
for i in range(10):
led.value(1)
time.sleep(1)
led.value(0)
time.sleep(1)
import os
os.listdir() #要Upload to device后才能找到
import led
led.run()