openwch / arduino_core_ch32

Core library for CH32duino
252 stars 42 forks source link

Serial not working on CH32v003j4m6 #143

Open mindonne opened 2 weeks ago

mindonne commented 2 weeks ago

hi every one I have a problem: after trying to use Serial.begin(300) for board CH32v003j4m6, my COM port 5 always shows an error: ''Port monitor error: command 'open' failed: Serial port busy. Could not connect to COM5 serial port ''. I tried Serial.begin(9600) on Uno R3, nano and the Serial port still works fine. Then I tried using Serial.begin(9600) with CH32v003j4m6 but still got the error I reinstalled the driver but Serial still reported the error: ''Port monitor error: command 'open' failed: Serial port busy. Could not connect to COM5 serial port '' Now I can still load the code but cannot use the Serial for Ch32v003j4m6 " Port monitor error: command 'open' failed: Invalid serial port. Could not connect to COM5 serial port "

maxint-rd commented 1 week ago

None of your writings ring a bell. Perhaps you need to restart your IDE, power-cycle the chip and check all your pinouts and connections. Make sure TX/RX pins are not conflicting with other functions.

NOTE: The CH32V003J4M6 is a SOP8 chip that maps multiple peripherals to single pins. After using serial on the SOP8 chip, you can flash it only once and then you will need to use the WCH-LinkUtility on the LinkE to Clear all code flash - by power off