Spent over 30 yuan to make a core board, which is a domestic chip replacement solution for the STM32 blue board.
Chip description, hardware description,circuit principle, material inventory, design + welding + debugging precautions, advantages and characteristics, circuit source code download
First, the domestic chip that replaces STM32 is called – HK32F103C8T6.
The reason for using it is that it has a high-performance ARM Cortex-M3 core, rich peripheral configuration, low price, and low power consumption.
The core board consists of 6 parts as described below, and the disassembly diagram will be more intuitive.

The circuit design of the core board is relatively simple. In this chapter, I will break the circuit into 5 parts and explain the principles respectively.

The power circuit mainly consists of TYPE-C power supply circuit and LDO-5V to 3.3V circuit, using a 2Pin TYPE-C interface, simple and convenient, easy to solder.

Among them, the LDO-5V to 3.3V step-down circuit outputs 3.3V from the 5V input of the TYPE-C power supply circuit to power the main control chip.
The capacitor is for filtering to make the output voltage signal more stable.

The pins of HK32F103C8T6 can be roughly divided into 4 categories: power, clock, control and I/O pins;
Figure 4-4 shows the pin definition diagram of HK32F103C8T6, and the following text explains the definition reuse of each pin.

As shown in Figure 4-5, connecting all the pins of HK32F103C8T6 will facilitate project development.
Here, the capacitor is for filtering, and should be placed as close to the chip pins as possible, the connection method of the main control circuit pins is shown in the figure below.

The role of the crystal oscillator is to provide clock signals for the minimum system, and the capacitors next to the crystal oscillator ensure that the output oscillation frequency is more stable.
The 32.768kHz crystal oscillator provides clock signals for the RTC, while the 8MHz crystal oscillator circuit provides clock signals for the microcontroller; if the RTC function is not needed, then the RTC crystal oscillator can be left unconnected.


Resetting is also called rebooting, pressing the SW1 button pulls down the main control NRST pin, generating an external reset pulse to reset the system; releasing the SW1 button restores normal working status, and the reset pin is at a high level.

① When powered on, the power indicator (red) lights up, indicating that the minimum system power supply part is working normally.
The status display light (blue) is used for testing the microcontroller PC13 pin, achieving the on/off of the test light through programming.

② SWD download interface, using the SWD programming method, reserving a 1x4Pin bent plug header interface for downloading debugging simulation programs.
The capacitor is for filtering, making the downloading performance more stable.

③ Boot selection mode, before downloading the program, the boot mode of the microcontroller must be controlled by the high and low levels of the BOOT0 and BOOT1 pins to successfully download the program, detailed configuration is shown in Table 1-1.


-
When using SWD programming, BOOT0 and BOOT1 need to be grounded.
-
When using serial ISP programming, BOOT0 needs to be connected to power, BOOT1 grounded.
④ The function of the external I/O port is to facilitate project expansion and various function verification.
It requires 2 1x20Pin 2.54mm headers to connect the microcontroller’s I/O pins, compatible with other mainstream microcontroller core board pin arrangements.

Finally, let me explain the precautions for schematic design, PCB routing, soldering, and debugging, a total of 4 parts.
① Draw according to module circuit division, indicating the circuit function;
② Unused pins should have non-connection symbols, for professional standards;
③ Fill in project name and other information on the drawing properties;
① The main control chip should be placed at 45 degrees, facilitating the routing of external header pins;
② Pay attention to the current direction of the filtering capacitor, try to keep it close to the filtering components;
③ The crystal oscillator should be as close to the chip as possible, and avoid routing underneath to prevent signal crosstalk;
④ Routing should prioritize straight lines, and for turns, use obtuse angles or arcs;
⑤ After adjusting the PCB layout, add teardrops to make the board more aesthetically pleasing and stable;
⑥ Add silkscreen markings to annotate the function of interfaces;
⑦ JLCJLCJLCJLC designated silkscreen can be hidden under components for a more attractive board;


① When soldering, you can click on the soldering helper tool in JLC’s EDA toolbar for real-time interaction to facilitate soldering;
② When soldering the top layer, it is recommended to solder the main control chip first to avoid interference from other components;
③ When soldering the header pins, use a spare board or perforated board to hold them in place to prevent slanting during soldering;
④ The soldering sequence should follow the principle of low to high to avoid affecting the soldering of small components;



① Before powering on for debugging, check if there are any cold soldering or short circuit issues; only power on for testing after confirming there are no issues;
② When using SWD programming, the BOOT0 and BOOT1 pins need to be grounded with a shorting cap;
③ Download and install the HK32F103 support package in advance.

Finally, let me briefly explain the advantages and characteristics of the core board.

① The board is compact, measuring only (53.3mm*22.9mm(2100mil*900mil));
② Compatible with STM32F103C8T6 and other mainstream F103 core board pin arrangements.
③ Low price, ultra-low power consumption, rich functional pins, high cost performance;
④ Uses high-quality PCB and genuine components from JLC to ensure product quality;
If you also want to DIY a core board for making a small car or robot… you can click “Read Original” > “Open in Editor” … to view the circuit source file.
Open Source Code: “Read Original” > “Click Attachment Download Option” > “Click Download” > “After downloading, unzip and open with Keil”


