English: Trying to connect to MCU/single-chip computer by handshake...
Failed to open the serial port!
English: The serial port has been opened by other programs or does not exist.
Solution:
1. Check whether the connection of the USB download module is normal. The green and red LED lights on the module are both on, indicating that the connection is normal. If the green LED light is off, it means that there is a problem with the USB driver. You can unplug the USB module and plug it again. If the red LED light is off, it means that the module is not powered, or there is a short circuit at the power output terminal (3.3V, +5V, GND) behind the USB module.
2. Find "Port" in the control panel---》system---》hardware manager---》CP2101 serial port and understand the COM number in the brackets. If COM4 is displayed in the brackets, you must select COM4 in the STC-ISP software.
STC-ISP software:
3. Sometimes the serial port cannot be found due to the instability of the STC-ISP software. Restart the software, plug the USB module again and try again.
4. If the driver of the USB module is not installed properly, or it conflicts with other port drivers, the serial port cannot be found. Reinstall and restart the computer and try again.
Failure phenomenon:
English: Trying to connect to MCU/single-chip computer by handshake...
(The following display will appear after 3 seconds)
English: Connection failed, please try the following operations:
1. When the single-chip computer is powered off, click the download button, and then power on the single-chip computer.
2. Stop downloading, reselect the RS-232 serial port, and connect the cable
. 3. You may need to short P1.0/P1.1 to ground first
. 4. The external clock may not be connected
. 5. The clock does not oscillate due to the long lead of the PLCC and PQFP conversion socket. Please
adjust the parameters
. 6. You may need to upgrade the STC-ISP.exe software on the computer.
7. If it still fails, there may be no ISP system boot code in the MCU/single-chip computer,
or it may need to be returned for upgrade, or the MCU is damaged
. 8. If you use a USB to RS-232 serial port cable to download, you may encounter incompatibility
issues. You can let us help you purchase a compatible USB to RS-232
serial port cable
. Still connecting, please power on the MCU...
Solution:
1. This situation first proves that the connection of the USB module and the USB driver are working properly. It is a normal download prompt. At this time, you can start downloading by re-powering the microcontroller. If the download progress bar still does not appear after re-powering, the possible problems are concentrated on the back end of the USB module, that is, the microcontroller circuit.
2. First, you need to check whether the hardware circuit connection of the USB download circuit is correct. The correct circuit connection is as shown in the figure below:
3. Check whether the microcontroller is connected to an external crystal oscillator. Although some microcontrollers were previously set to an internal RC clock, that is, they can download without an external crystal oscillator, but if you accidentally use the default external crystal of the STC-ISP software at a certain time, and the microcontroller does not have a crystal oscillator connected to the outside, the download will fail. Please add a crystal oscillator between 1~35M and a 30P capacitor () to the outside of the microcontroller, and then try to download again.
4. There is a download protection setting in the STC-ISP software, that is, the two IO interfaces P1.0 and P1.1 need to be connected to GND at the same time to download the program. The general type of STC microcontroller does not use this protection by default, but microcontrollers such as STC12C5406 have protection turned on by default. If the above method fails, please try to short the P1.0 and P1.1 interfaces to GND and then download. And in the future, pay attention to turn off this protection function when downloading, unless you need protection.
5. The 5 pins at the back of the USB module do not have a directional device, so sometimes they are plugged in the wrong way, or the power supply of the 5V microcontroller is mistakenly connected to 3.3V, which will also cause download failure.
Failure phenomenon:
Chinese: Trying to connect with MCU/single-chip computer by handshake...
MCU Type is: STC12C5A60S2
MCU Firmware Version: 6.2I
Chinese: MCU firmware version number: 6.2I
After the next cold start, use an external crystal or clock
RESET pin is still RESET.
No additional reset delay is added for power-on reset
Oscillator gain: High gain
P1.0/P1.1 is irrelevant to the download when downloading next time
The data Flash area will be erased when the user application is downloaded next time: NO
P4.6/RESET2 is used as P4.6.
After starting the internal watchdog, it is forbidden to change the watchdog frequency division number NO.
The internal watchdog is automatically started with relevant parameters
when powered on next time. NO. The internal watchdog stops counting in the idle state. YES.
After cold start, the internal watchdog pre-division number (not started): 256
MCU Clock: 24.045688MHz./Clock frequency: 24.045688M.
Chinese: Reconnecting...
(displayed after a few seconds)
Connection failed. / Handshake failure (End: 21:00:39)
Solution:
1. This problem often occurs on the STC12C5A60S2 microcontroller. At a higher baud rate, it is easy to have a handshake failure when downloading. The general solution is to select the highest baud rate of the serial port in step 3 to 1200, which can ensure downloading, but the download speed is slow.
2. Another solution is to select the same value for the highest and lowest baud rates (such as setting them to 9600), and use different baud rates in the drop-down list to download and find the value with the highest success rate. That is your lucky value.
-----------------------------
If the above solution still cannot solve your problem, please leave a message here to let me know.
1 January 23, 2010 23:34
There is another question, which is the "[Must-read instructions]" in your "Must-read instructions"
* Please refer to the corresponding circuit schematic diagram on this site to make
* Copy the STC11Fxx.H file to C:/Keil/C51/INC (if the header file has been installed, it can be omitted).
* When using the STC-ISP software to download, you need to select the "RST as P4.7 Use" item
* When using the STC-ISP software to download, you need to select the "Use external crystal or clock" item
* When using the STC-ISP software to download, you need to select the lower right option "Reset voltage 3.7V" item" "
Item 5" * When using the STC-ISP software to download, you need to select the lower right option "Reset voltage 3.7V" item" "This "Reset voltage 3.7V" item" was not found"
Previous article:What are internal clock mode and external clock mode?
Next article:Introduction to the types and differences of STC microcontrollers
- Learn ARM development(16)
- Learn ARM development(17)
- Learn ARM development(18)
- Embedded system debugging simulation tool
- A small question that has been bothering me recently has finally been solved~~
- Learn ARM development (1)
- Learn ARM development (2)
- Learn ARM development (4)
- Learn ARM development (6)
Professor at Beihang University, dedicated to promoting microcontrollers and embedded systems for over 20 years.
- LED chemical incompatibility test to see which chemicals LEDs can be used with
- Application of ARM9 hardware coprocessor on WinCE embedded motherboard
- What are the key points for selecting rotor flowmeter?
- LM317 high power charger circuit
- A brief analysis of Embest's application and development of embedded medical devices
- Single-phase RC protection circuit
- stm32 PVD programmable voltage monitor
- Introduction and measurement of edge trigger and level trigger of 51 single chip microcomputer
- Improved design of Linux system software shell protection technology
- What to do if the ABB robot protection device stops
- Wi-Fi 8 specification is on the way: 2.4/5/6GHz triple-band operation
- Wi-Fi 8 specification is on the way: 2.4/5/6GHz triple-band operation
- Vietnam's chip packaging and testing business is growing, and supply-side fragmentation is splitting the market
- Vietnam's chip packaging and testing business is growing, and supply-side fragmentation is splitting the market
- Three steps to govern hybrid multicloud environments
- Three steps to govern hybrid multicloud environments
- Microchip Accelerates Real-Time Edge AI Deployment with NVIDIA Holoscan Platform
- Microchip Accelerates Real-Time Edge AI Deployment with NVIDIA Holoscan Platform
- Melexis launches ultra-low power automotive contactless micro-power switch chip
- Melexis launches ultra-low power automotive contactless micro-power switch chip
- Design of intelligent remote control based on MSP430F413
- GT911 touch screen chip datasheet
- MCU reset types and faults
- Here's a wave of benefits for everyone. Pay 10 yuan for postage and get a brand new power meter that can measure the power consumption of home appliances. While stocks last.
- Qorvo's customizable PMIC simplifies power management system design
- Can the digital tube screen be driven by the same driving method as the segment code LCD screen?
- Creative digital electronic clock using ESP8266
- Hardware Engineer (Shanghai)
- Three Clouds
- MSP430FR5969 Development Data