laitimes

STC microcontroller automatic download module

author:APPLE频道

Loading...

I. Preface

  In the past two days, it was found that the original STC microcontroller downloader could not be used. The following uses the PL2303 chip at hand to remake an STC microcontroller automatic download module for the development and debugging of today's circuits.

STC microcontroller automatic download module

2. Circuit design

  Design Downloader. USB TypeC port for USB to UART conversion with PL2303GL. Use STM32F030 to detect serial ports. If there is a continuous 0x7E . The control relay powers off and on the target board. Especially when the power is off, the voltage of the target board is directly pulled down to 0, so as to avoid the situation that the single-chip microcomputer cannot be truly reset by relying on serial port power supply. Design the PCB below. Single-sided PCB implementation, suitable for one-minute plate making. After a minute, the board is obtained. The board is perfectly made.

STC microcontroller automatic download module
AD\STC\Tools\Download\PL2303Download.PcbDoc
STC microcontroller automatic download module

▲ Figure 1.2.1 Schematic diagram of the downloader

STC microcontroller automatic download module

▲ Figure 1.2.2 Downloader PCB

3. Circuit debugging

  Soldering circuit boards. Programming the F030 microcontroller. Set its serial port mode to AUTO Baudrate mode, which can automatically detect the 0x7f signal sent by the STC ISP software. This way, it can be detected regardless of the baud rate. Once detected, the target board is powered off for 0.5 seconds, and then the ISP software downloads the software.

STC microcontroller automatic download module

  This is the code at 2400 baud rate detection. Re-paddle download version into USB once, using 9600 baud rate detection to download user code. It can be seen that the downloaders are all relatively easy to adapt.

STC microcontroller automatic download module

※Summary※

  In this paper, a PL2303GL-based STC microcontroller download module is designed. Using the adaptive baud rate function of the F030 microcontroller, the ISP software download command of the STC microcontroller can be detected to complete the automatic power supply of the target board. It facilitates the development of single-chip microcomputer.

STC microcontroller automatic download module