Closed apuder closed 9 months ago
:+1: I have the same problem with a board that uses CP2102n chip. Works flawlessly in Windows 10, but isn't detected in WSL.
Hi, i am also facing the same issue. Can connect using putty from windows to esp32 but from wsl it gives IO error.
varun@DESKTOP-SRI1M21:/dev$ sudo cu -l /dev/ttyS6 -s 115200
cu: open (/dev/ttyS6): Input/output error
cu: /dev/ttyS6: Line in use
Hi Silicon Labs Virtual COM Port (VCP) Universal Driver for Windows 10 version 10.1.4 does not work. But Silicon Labs Virtual COM Port (VCP) driver for Windows version: 6.7.6 works on windows 10.
Same issue, its could not open the port ... its shows that the port is always busy !
i tried flashing the code on the same port using Visual GDB instead of WSL and it worked pretty fine though ;)
Serial port /dev/ttyS11
Traceback (most recent call last):
File "/mnt/c/temp/IDFS/IDF-3.2/esp-idf/components/esptool_py/esptool/esptool.py", line 2959, in
_main() File "/mnt/c/temp/IDFS/IDF-3.2/esp-idf/components/esptool_py/esptool/esptool.py", line 2952, in _main
main() File "/mnt/c/temp/IDFS/IDF-3.2/esp-idf/components/esptool_py/esptool/esptool.py", line 2652, in main esp = chip_class(each_port, initial_baud, args.trace)
File "/mnt/c/temp/IDFS/IDF-3.2/esp-idf/components/esptool_py/esptool/esptool.py", line 222, in init self._port = serial.serial_for_url(port)
File "/usr/lib/python2.7/dist-packages/serial/init.py", line 85, in serial_for_url
instance.open()
File "/usr/lib/python2.7/dist-packages/serial/serialposix.py", line 294, in open
raise SerialException(msg.errno, "could not open port %s: %s" % (self._port, msg))
serial.serialutil.SerialException: [Errno 5] could not open port /dev/ttyS11: [Errno 5] Input/output error: '/dev/ttyS11'/mnt/c/temp/IDFS/IDF-3.2/esp-idf/components/esptool_py/Makefile.projbuild:62: recipe for target 'flash' failed make: *** [flash] Error 1
I think it's a problem of cp210x driver. Please refer https://www.silabs.com/community/interface/forum.topic.html/cp210x_registry_entr-11Kf. or use pololu's CP2102 USB-to-Serial Bridge Driver
Solution with my ESP32 dev board: The older Windows 7/8/8.1 drivers from Silabs work. I can cat /dev/ttyS5 now and see the messages on RxD.
Problem with cu: How can I tell cu to leave RTS and CTS alone? These pins are connected to the RST and BOOT buttons and are used to initiate flashing the device. As soon as I start cu, the ESP32 LED stops, when I exit cu, the LED resumes blinking (a demo program that outputs a hello message and flashes the LED every second).
CONFIRMED: CP210x Driver issue, rollback to v6.7.6 resolves the issue.
Also - for good measure sudo chmod 0666 /dev/ttyS11
or your port number
great work thanks! older driver version works perfectly for me. In case you get something like:
$ idf.py -p /dev/ttyS11 flash
...
[100%] Built target app
esptool.py --chip esp32 -p /dev/ttyS11 -b 460800 --before=default_reset --after=hard_reset write_flash --flash_mode dio --flash_freq 40m --flash_size 2MB 0x8000 partition_table/partition-table.bin 0x1000 bootloader/bootloader.bin 0x10000 hello-world.bin
esptool.py v3.0-dev
Serial port /dev/ttyS11
Connecting....
Chip is ESP32D0WDQ5 (revision 1)
Features: WiFi, BT, Dual Core, 240MHz, VRef calibration in efuse, Coding Scheme None
Crystal is 40MHz
MAC: c4:4f:33:17:0b:39
Uploading stub...
Running stub...
Stub running...
Changing baud rate to 460800
Changed.
Configuring flash size...
A fatal error occurred: Timed out waiting for packet header
CMake Error at run_cmd.cmake:14 (message):
esptool.py failed
Call Stack (most recent call first):
run_esptool.cmake:21 (include)
make[3]: *** [CMakeFiles/flash.dir/build.make:57: CMakeFiles/flash] Error 1
make[2]: *** [CMakeFiles/Makefile2:1892: CMakeFiles/flash.dir/all] Error 2
make[1]: *** [CMakeFiles/Makefile2:1899: CMakeFiles/flash.dir/rule] Error 2
make: *** [Makefile:190: flash] Error 2
make failed with exit code 2
like I did - try to reduce the baudrate:
$ idf.py -p /dev/ttyS11 -b 115200 flash
Referencing unresolved topic https://github.com/espressif/esp-idf/issues/4936
RS-232 on WSL2 is LZ #4322
I've got the same problem using CH340 drivers
This issue has been automatically closed since it has not had any activity for the past year. If you're still experiencing this issue please re-file this as a new issue or feature request.
Thank you!
In the past I was able to access an ESP32 from WSL. I haven't done it in a while but now I'm having issues flashing. I'm using Window 10 pro, version 1809, OS build 17763.253. I have Silicon Labs CP210x USB to UART Bridge installed (driver version 10.1.4.2290). Windows reports the device to be working on COM11. I have an ESP32 connected and I can use putty to successfully connect to it via COM11. However, I cannot access it from WSL:
Any suggestions?