Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

espflash fails to automatically set the port #649

Open
HaoboGu opened this issue Jun 24, 2024 · 6 comments
Open

espflash fails to automatically set the port #649

HaoboGu opened this issue Jun 24, 2024 · 6 comments
Labels
port detection Issues related with ports detection

Comments

@HaoboGu
Copy link

HaoboGu commented Jun 24, 2024

Hello! I'm using macOS with a custom esp32s3 board. When I connected the usb cable to the serial JTAG, it shows correctly:

image

However, I cannot use espflash to access the board without specifying --port:

$ espflash board-info                 
Error: espflash::connection_failed

  × Error while connecting to device
  ╰─▶ Serial port not found
  help: Ensure that the device is connected and your host recognizes the serial adapter

$ ls -l /dev/cu*
crw-rw-rw-  1 root  wheel  0x9000005  6 24 22:47 /dev/cu.usbmodem1101

$ espflash board-info --port /dev/cu.usbmodem1101
[2024-06-24T14:50:56Z INFO ] Serial port: '/dev/cu.usbmodem1101'
[2024-06-24T14:50:56Z INFO ] Connecting...
[2024-06-24T14:50:56Z INFO ] Using flash stub
Chip type:         esp32s3 (revision v0.2)
Crystal frequency: 40 MHz
Flash size:        16MB
Features:          WiFi, BLE
MAC address:       24:58:7c:e2:cc:90

The issue occurs on both latest release and git version.

$ espflash -V                                    
espflash 3.1.0
@SergioGasquez
Copy link
Member

Is your port listed if you use --list-all-ports flag?

@SergioGasquez
Copy link
Member

By the way, I dont have any issues recognizing a ESP32-S3-DevKitC-1 v1.0 connected via USB Serial JTAG port.

$ espflash -V
espflash 3.1.0
$ espflash board-info
[2024-06-25T09:58:21Z INFO ] Detected 2 serial ports
[2024-06-25T09:58:21Z INFO ] Ports which match a known common dev board are highlighted
[2024-06-25T09:58:21Z INFO ] Please select a port
[2024-06-25T09:58:21Z INFO ] Serial port: '/dev/cu.usbmodem11101'
[2024-06-25T09:58:21Z INFO ] Connecting...
[2024-06-25T09:58:22Z INFO ] Using flash stub
[2024-06-25T09:58:22Z WARN ] Setting baud rate higher than 115,200 can cause issues
Chip type:         esp32s3 (revision v0.1)
Crystal frequency: 40 MHz
Flash size:        8MB
Features:          WiFi, BLE
MAC address:       60:55:f9:f5:20:d4

@HaoboGu
Copy link
Author

HaoboGu commented Jun 25, 2024

Is your port listed if you use --list-all-ports flag?

No, still

$ espflash board-info --list-all-ports

Error: espflash::connection_failed

  × Error while connecting to device
  ╰─▶ Serial port not found
  help: Ensure that the device is connected and your host recognizes the serial adapter

@SergioGasquez SergioGasquez added the port detection Issues related with ports detection label Jul 18, 2024
@SergioGasquez
Copy link
Member

Have you tried with other flashing tools like esptool?

@HaoboGu
Copy link
Author

HaoboGu commented Jul 19, 2024

Have you tried with other flashing tools like esptool?

I just tried esptool:

pip install esptool
esptool.py flash_id

It recognizes the chip

$ esptool.py flash_id
esptool.py v4.7.0
Found 4 serial ports
Serial port /dev/cu.usbmodem211401
Connecting...
Detecting chip type... ESP32-C3
Chip is ESP32-C3 (QFN32) (revision v0.4)
Features: WiFi, BLE
Crystal is 40MHz
MAC: ec:da:3b:d1:87:c4
Uploading stub...
Running stub...
Stub running...
Manufacturer: 85
Device: 2016
Detected flash size: 4MB
Hard resetting via RTS pin...

@dumski
Copy link

dumski commented Jul 31, 2024

Same here with Seeed Xiao ESP32-XX boards...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
port detection Issues related with ports detection
Projects
Status: Todo
Development

No branches or pull requests

3 participants