esp-rs / espflash

Serial flasher utility for Espressif SoCs and modules based on esptool.py
Apache License 2.0
471 stars 115 forks source link

Fix handling of serial ports on BSD systems #415

Closed jessebraham closed 1 year ago

jessebraham commented 1 year ago

@tingox would you mind verifying this fixes the issue for you, please?

Closes #409

tingox commented 1 year ago

I do not mind at all:

tingo@kg-core1:~/personal/projects/2023/rust/embedded/esp/espflash $ target/release/espflash board-info
[2023-05-30T20:16:56Z INFO ] Detected 2 serial ports
[2023-05-30T20:16:56Z INFO ] Ports which match a known common dev board are highlighted
[2023-05-30T20:16:56Z INFO ] Please select a port
[2023-05-30T20:17:00Z INFO ] Serial port: '/dev/cuaU0'
[2023-05-30T20:17:00Z INFO ] Connecting...
[2023-05-30T20:17:04Z INFO ] Unable to connect, retrying with extra delay...
[2023-05-30T20:17:05Z INFO ] Using flash stub
Chip type:         esp32c3 (revision v0.3)
Crystal frequency: 40MHz
Flash size:        4MB
Features:          WiFi, BLE
MAC address:       58:cf:79:05:5c:e8
tingo@kg-core1:~/personal/projects/2023/rust/embedded/esp/espflash $ target/release/espflash board-info --port /dev/cuaU0
[2023-05-30T20:17:21Z INFO ] Serial port: '/dev/cuaU0'
[2023-05-30T20:17:21Z INFO ] Connecting...
[2023-05-30T20:17:25Z INFO ] Unable to connect, retrying with extra delay...
[2023-05-30T20:17:25Z INFO ] Using flash stub
Chip type:         esp32c3 (revision v0.3)
Crystal frequency: 40MHz
Flash size:        4MB
Features:          WiFi, BLE
MAC address:       58:cf:79:05:5c:e8

yes, this fixes the issue.