How to download programs using the STM32 serial port (USB serial port)

Publisher:火箭少年Latest update time:2018-08-13 Source: eefocusKeywords:STM32 Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

1. Steps for STM32 serial port download program 
1) Install "CH340 driver (USB serial port driver)_XP_WIN7 common" 
2) Open the serial port download software "STM32F4 serial port download software (FLYMCU)" 
3) Connect the USB interface of the development board to the USB port of the computer and power the development board 
4) Set the download software as follows; click Search Serial Port, select the correct serial port number, ignore the baud rate, select the HEX file, click Start Programming to download. 
Write the picture description here 
2. Hardware Connection 
The wiring diagram of USB to serial port CH340 is as follows. 
ARM serial port TXD is connected to the RXD pin of CH340G, and RXD is connected to the TXD pin of CH340G; CH340 is 5V powered and can be powered by USB. Boot0 is set to 1 (connected to 3.3V), and boot1 is set to 0 (grounded). 
Write the picture description here 
3. Note: For the encrypted STM32 chip, you can unlock the download program through the serial port download program, and then you can use the emulator to download the program. 
4. Notes on downloading programs with the serial port of STM32: 
The USART of the stm32 microcontroller can only use usart1. Other USARTs are not available. Remember this. Pay attention to this when designing the circuit. 
The last step is to restore the BOOT settings. Set boot0 to 0 and boot1 to 0. Be sure to restore the settings. Otherwise, the program will not run.

Keywords:STM32 Reference address:How to download programs using the STM32 serial port (USB serial port)

Previous article:STM32F407 serial port 2 configuration
Next article:Basic use of STM32F407 serial port

Recommended ReadingLatest update time:2024-11-16 13:03

STM32: ADC data collection example (using DMA mode)
SOC:STM32F103RCT6 Software platform: STM official library V3.5.0 Development tools: Keil 1. Summary   This article will give the code for STM32F103RCT6 to control AT24C02. If you have any questions or errors, please leave a message. 2. Hardware Connection AT24C02 uses I2C for data access, and the board uses ST
[Microcontroller]
Analysis of STM32 Controlling Three-Axis Acceleration Sensor
I bought the stm32F107VC development board with the three-axis acceleration sensor LIS302DL and the sample code included. I studied it for a few days and summarized it as follows.   1. Logical structure Initialize each peripheral (RCC, GPIO, SPI, NVIC, I2C, LCD) - detect MEMS and display the detection status - con
[Microcontroller]
Analysis of STM32 Controlling Three-Axis Acceleration Sensor
STM32 uses serial port interrupts to send and receive data
The chip used here is STM32F103, which uses interrupts to receive and send serial port data. Here we use the method of directly operating the registers. Using the library function is similar to this, except that we just call the corresponding library function instead. Configure serial ports and multiplexed IO ports v
[Microcontroller]
Understanding the startup code of the medium-capacity STM32 processor
Today I want to introduce the startup code of STM32. I am using the medium-capacity STM32f103c8t6 here. The corresponding startup file is startup_stm32f10x_md.s. My startup file version is V3.6.2 Without further ado, here are the source codes I annotated:   /**   ***************************************************
[Microcontroller]
STM32 interrupts and events --- the difference between interrupts and events
  This figure is a schematic diagram of an external interrupt line or external event line. There is a slash on the signal line in the figure, and the annotation marked with the word 19 next to it indicates that there are 19 sets of such lines. The blue dotted arrow in the figure marks the transmission path of the
[Microcontroller]
STM32 interrupts and events --- the difference between interrupts and events
STM32 enters STOP mode and wakes up the experiment summary
The project requires the low power consumption of the device to be realized. Several problems were encountered during the implementation process, and this is recorded and summarized. (stm32f103ret6) Question 1: After executing PWR_EnterSTOPMode(PWR_Regulator_LowPower,PWR_STOPEntry_WFI);, the program continues to exe
[Microcontroller]
STM32 enters STOP mode and wakes up the experiment summary
STM32 learning notes 1: selection and pin description
Selection classification   STM32 naming method How to assign schematic pins How to find the pin function description Pin Function Interpretation
[Microcontroller]
STM32 learning notes 1: selection and pin description
STM32 SPI mode
SPI protocol (Serial Peripheral Interface), also known as serial peripheral interface, is a high-speed full-duplex Communication bus, it was proposed by Motorola, and the latest version is V04.01-2004. There are four SPI modes according to the different configurations of SPI clock polarity (CPOL) and clock phase
[Microcontroller]
Latest Microcontroller Articles
  • Download from the Internet--ARM Getting Started Notes
    A brief introduction: From today on, the ARM notebook of the rookie is open, and it can be regarded as a place to store these notes. Why publish it? Maybe you are interested in it. In fact, the reason for these notes is ...
  • Learn ARM development(22)
    Turning off and on interrupts Interrupts are an efficient dialogue mechanism, but sometimes you don't want to interrupt the program while it is running. For example, when you are printing something, the program suddenly interrupts and another ...
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
  • Learn ARM development(15)
  • Learn ARM development(16)
  • Learn ARM development(17)
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号