王达业

Microcontroller learning board based on STM32F103R8T6

 
Overview

1. Introduction

This design is an STM32 minimum system board based on STM32F103RBT6 as the core. I recently participated in the summer school training camp of Lichuang EDA. I want to use Lichuang EDA to draw an STM32 minimum system board. In the past, when learning STM32, I always had to connect an external emulator, which was quite troublesome, so I was wondering if I could use the debugging function. Integrated directly into the minimal system board, so this works.

2. Function description

最小系统板部分:Paired with three-color RGB lights and touch switches, the simplest code debugging can be performed. At the same time, two rows of IO ports are introduced, allowing the core board to achieve more functions. Next to the core board are two rows of power interfaces to facilitate joint development and debugging of external modules.

本设计最大的特点:A debugging module circuit based on STM32F103C8T6 is integrated and designed next to the core board. When this minimum system board is connected to the computer through the USB interface, a virtual DAPLINK disk will be generated on the computer. This can be used as both an emulator and a downloader. As long as you drag the compiled hex file into the automatically generated disk, it can be automatically downloaded to STM32. At the same time, it also retains the function of serial communication, truly achieving one interface for multiple purposes.

3. Selection of some components

1. The debugging board part uses STM32F103C8T6 as the control chip. This chip is a commonly used chip, has high acceptance by people, has more supporting information, and has relatively stable performance.

2. The main control part uses STM32F103RBT6 as the control chip. Compared with C8T6, it has more pins and richer internal resources, making it easier for people to use.

3. The external port uses a typical MicroB interface, which is one of the most common interfaces on the market and is convenient for users to use.

4. Schematic description

1. Power supply part

The power supply of the entire system is divided into two parts, namely the power supply circuit of the debugging part and the power supply circuit of the main control part. Two separate power supplies facilitate the reduction of power supply noise interference and load pressure. Among them, for the external power supply, I chose to use USB power supply normally, and reserved a line interface so that the 5V voltage of any port can be shared between the two power supplies. For the main control part, an external power supply port is reserved to facilitate the use of external power supply to power the core board independently. TIM screenshot 20200813102952.pngFor the 5V to 3.3V conversion part, I chose the common AMS1117 chip and left a path for LED lights to conveniently indicate the system power supply.TIM screenshot 20200813103202.png

2. Peripheral part

To facilitate user debugging, I added a three-color RGB light to the circuit. Users can use the RGB light to confirm whether the system is in normal working condition. The method of use is also very simple. Just connect the jumper cap. That's it. If you don't connect the jumper cap, it will be used directly as an ordinary port. TIM screenshot 20200813103509.pngIn addition, I have also reserved two external buttons to lead to the OLED connection port and two ports to make it more convenient for users to use and debug in general.

3. Main control board and debugging board part

Regarding the main control board and the debugging board, I tried to separate them as clearly as possible during the circuit design process, and connected them using jumper caps and pin headers. When we want to use its debugging function, we You can connect all the corresponding jumper caps together, and you can directly download the program for debugging. After removing the jumper cap, we can also directly connect the debugging part to other microcontrollers through jumpers, which is more convenient. to use. In fact, I designed it this way to facilitate people who are interested in re-dividing the debugging circuit and using it as a separate module.TIM screenshot 20200813104222.png

5. Layout settings

Looking at the whole, the overall layout is divided into the debugging circuit part on the left and the main control part on the right. In order to facilitate debugging, the pins of the system are distributed around the board as much as possible, with a jumper port for debugging communication between the two boards in the middle. At the same time, in order to make the STM32 main control part work in different working modes, I reserved the boot pin for easy adjustment during use. Through learning at the summer training camp, there is no copper laid under the crystal oscillator, and the power input must pass through filter capacitors, etc.

6. Progress update

July 29th - July 30th: Design the schematic diagram to separate the debugging circuit from the minimum system board circuit as much as possible to facilitate decoupling when only some of the functions are needed.

July 31st - August 1st: Draw PCB

August 2: Add USB pull-up resistor

August 10th: The components, boards, etc. arrived, and we started welding. During welding, we noticed that the Micro B interface of the UF-M5DD-Y-1 model was not very easy to weld, so we need to pay attention to it.

August 12: jlink arrived, software debugging was carried out, and the debugging was successful.

7. Physical display

TIM picture 20200813134942.jpgTIM picture 20200813134937.jpgTIM picture 20200813134930.jpg

8. Debugging method

materials needed

The welded core board, the debugger that supports swd download, and the data cable

Operation process

1. Download the two files stm32f103xb_bl and stm32f103xb_stm32f103rb_if

2. Open the stm32f103xb_bl project, compile the project, and download it to the debugging board through the swd interface.

3. Re-insert and unplug the data cable of the debugging board. At this time, a maintaince virtual disk will pop up on the computer.

4. Open the stm32f103xb_stm32f103rb_if folder, find the files inside TIM screenshot 20200813101337.png, and drag them into the generated virtual disk.

5. After the download is completed, re-plug and unplug the data cable. At this time, a new virtual disk will be generated in the computer TIM screenshot 20200813101131.png. This virtual disk is where the direct code download function is supported. Connect the jumper between the debugging board and the core board. Get up, drag the project into this virtual disk, and it will be automatically downloaded to the microcontroller.

6. The above is the debugging method. The data cable connected to the debugging board also supports serial communication, code burning, swd debugging and other functions. It is very easy to use. I hope you like it.

9. Experience

Lichuang EDA's summer training camp is a very good activity. Not only are the lecturers patiently teaching, students can also have full exchanges and discussions with each other. I feel that this period of time has been very fulfilling, and I hope that Lichuang EDA will get better and better.

参考设计图片
×
 
 
Search Datasheet?

Supported by EEWorld Datasheet

Forum More
Update:2025-05-21 09:07:32

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
community

Robot
development
community

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号