问题描述

报错

A fatal error occurred: Failed to write to target RAM (result was 01070000: Operation timed out)

新买的esp32在下载固件时出现如下错误,原因是串口驱动没有安装好

  1. esptool.py v3.0-dev
  2. Serial port /dev/tty.usbmodem52D20149311
  3. Connecting......
  4. Chip is ESP32-D0WDQ6 (revision 1)
  5. Features: WiFi, BT, Dual Core, VRef calibration in efuse, Coding Scheme None
  6. Crystal is 40MHz
  7. MAC: 24:0a:c4:8b:65:80
  8. Uploading stub...
  9. A fatal error occurred: Failed to write to target RAM (result was 01070000)
  10. 上传项目出错
  11. IntelliSense configuration already up to date. To manually rebuild your IntelliSense configuration run "Cmd+Alt+I"
  12. [Error] Uploading sketch 'esp32_car.ino': Exit with code=1

解决方案

1、查看串口名称

/dev/tty.usbmodemXXXXXXXX

2、下载安装CH9102的Mac版本的驱动(CH9102_Mac_Driver.zip
3、再次查看串口名称

/dev/tty.usbmodemXXXXXXXX /dev/tty.wchusbserialXXXXXXXX

4、多了一个,使用名称中有wchusbserial的串口即可
方案来自于如下
https://github.com/Xinyuan-LilyGO/LilyGo-T-Call-SIM800/issues/139#issuecomment-904390716


参考

CH9102 Serial-To-USB Driver for Mac OS X
Version 1.4 with CH9102F doesn’t work with Mac OS X #139