yahboom
HomeLearn
Solution
Blog
Online Store
About Us
EN/中文
520 Motor📖
1.About motor
  • About motor
2.ROS robot control board drive
  • 2.1 Control motor
  • 2.2 Timer captures encoder data
  • 2.3 PID control robot car
  • 2.4 Kinematic Analysis-Mecanum wheel structure
  • 2.5 Kinematic Analysis-Ackerman structure
  • 2.6 Kinematic Analysis-4WD structure
3.STM32 Self-balancing car tutorials
Get started quickly
  • 03.P, PI, PD controller theory
  • 01.Balancing car assembly
  • 02.Get started quicklyy
  • 03.Balance car interface description
  • 04.Common Problem Analysis
  • 05.Balance Car V2 Library Function Development Manual
Environment construction and development
  • 01.MDK-ARM installation
  • 02.STM32CubeIDE installation
  • 03.Common driver installation
  • 04.Download the program
  • 05.MDK-ARM project usage
  • 06.Program simulation
Robot car PID control course
  • 01.PID basic concept
  • 02.PID example analysis
  • 04.Position PID
  • 05.Incremental PID
  • 06.Cascade PID
  • 07.Balance principle of car
  • 08.Car upright control (PD)
  • 09.Car speed ​​control (PI)
  • 10.Car steering control (PD)
  • 11.Got angle and angular velocity (DMP algorithm)
  • 12.Got angle and angular velocity (Kalman filter algorithm)
  • 13.Got angle and angular velocity(Complementary filter algorithm)
Robot car basic course
  • 01.Car parameter adjustment
  • 02.Ultrasonic obstacle avoidance
  • 03.Ultrasonic follow
  • 04.Bluetooth remote control
  • 05.Load balance
Robot car LQR control
  • Robot car LQR control
Circuit design
  • 01.Overall circuit design
  • 02.STM32 minimum system
  • 03.Serial port circuit design
  • 04.Power circuit design
  • 05.MPU6050 Circuit Design
  • 06.Motor drive circuit design
Mathematical model
  • Balance car mathematical model
4.4-channel motor drive module
Introduction and Debug
  • 1.Introduction to 4-channel motor drive board
  • 2.Control command
  • 3.Motor introduction and usage
  • 4.PC host
IIC communication
  • For Arduino
  • For ESP32
  • For Jetson NANO
  • For MSPM0G3507
  • For MSPM0G3519new
  • For PICO2
  • For RDK X5
  • For RPi5
  • For STM32
USART communication
  • For Arduino
  • For ESP32
  • For Jetson NANO
  • For MSPM0G3507
  • For MSPM0G3519new
  • For PICO2
  • For RDK X5
  • For RPi5
  • For STM32
5.2-channel motor drive module
For MSPM0G3507
  • 1.AT8236 drive tutorials
  • 2.TB6612 drive tutorials
For MSPM0G3519
  • 1.AT8236 drive tutorialsnew
  • 2.TB6612 drive tutorialsnew
Download
  • Model File
  • Annex_ROS_robot_board
  • Annex_STM32_balancing_car
  • Annex_4channel_motor_drive
  • Annex_2channel_motor_drive
Download ZIP

Welcome to 520 Motor repository

02.STM32CubeIDE installation

STM32CubeIDE installation

STM32CubeIDE installation1. Software Download1、Software download2. Select the platform3. Fill in the information2. Software installation1. Open the installation package2. Installation process-settings3. Software Configuration1. Open the application2. Register-Login account3. Install the firmware package4. Software Usage1. Create a new project2. Chip selection3. Project settings4. Pin layout and configuration SYS - RCC 5. Clock configuration6. Project management7. Generate initialization code8. Write code9. Compile code10. Create a new project again5. Common ProblemsEncoding format problem

STM32CubeIDE is a free software, the tutorial demonstrates the installation and use of the software!

The [Attachment → Software Tools] in the document provides an installation package, you can skip the download step and install it directly

1. Software Download

1、Software download

ST office website:https://www.st.com/content/st_com/en/stm32cubeide.html

image-20240830120606898

2. Select the platform

  • Platform: Windows

image-20240830120624603

3. Fill in the information

  • Agree to the agreement

image-20240830120653420

  • Fill in the information

image-20240830120708472

xxxxxxxxxx
The email address needs to be filled in accurately, and the software download link will be sent to you via email
  • Submission completed

image-20240830120725782

  • Download the installation package via email

image-20230921173555796

​x
Click the link to jump to the official website, and the website will automatically pop up a pop-up window for downloading the software compressed package

2. Software installation

1. Open the installation package

  • Administrator

Open the installation package as an administrator

image-20240821172641461

xxxxxxxxxx
If you open the software installation package and see "NSIS ERROR: error "Launching installer" error message:
Please put the installation package in a path without Chinese characters

2. Installation process-settings

  • Next

image-20230921174734406

  • Agree to the agreement → I agree

image-20230921174827723

  • Installation location → Next → Install

xxxxxxxxxx
It is recommended to use the default installation location of the software and the path should not contain Chinese characters

image-20230921175019951

image-20230921175121934

xxxxxxxxxx
Check the option to install ST-Link and J-Link drivers
  • Install driver

image-20230921175245637

  • Installation waiting → Next

image-20230921175518924

  • Finish

image-20230921175801203

3. Software Configuration

Be familiar with the software-related options and functions.

1. Open the application

  • Left mouse button: Double-click the desktop application

image-20230921175945830

  • Select workspace

image-20240821173105251

xxxxxxxxxx
You can create a new folder yourself, and the folder path cannot contain Chinese characters

image-20240821173159091

2. Register-Login account

The new version of STM32CubeIDE requires a registered account to log in before downloading the firmware package and using the software normally:

image-20230921180902783

3. Install the firmware package

  • Help → Manage embedded software packages

image-20230921181435546

  • Install the latest firmware package of the STM32F1 series

image-20230921181947516

xxxxxxxxxx
1. The chip firmware package cannot be installed without logging in
2. To install or uninstall, select the box in front of the chip firmware package. Clicking this option will not have installation and uninstall options
  • Waiting for download

image-20230921182157454

  • Close the interface

image-20230921182233264

4. Software Usage

STM32CubeIDE integrates the STM32CubeMX function, which can be used for pin configuration, as well as direct code writing and debugging.

1. Create a new project

image-20230921183202024

2. Chip selection

  • Chip selection and interface

Search for STM32F103RCT6

image-20240821174213278

3. Project settings

image-20240821174336509

xxxxxxxxxx
Default configuration is sufficient, and the project file name can be customized

image-20240821174411429

image-20240821174433911

image-20240821174459660

4. Pin layout and configuration

image-20240821174550492 SYS image-20240821174645467 - RCC image-20240821174727982 5. Clock configuration

image-20240821174908961

xxxxxxxxxx
Refer to the options involved in the red line

6. Project management

  • Project: Project

image-20240821175051963

xxxxxxxxxx
Using STM32CubeIDE, IDE projects cannot be exported (such as exporting MDK-ARM project files). If you need to export other IDE projects, switch to STM32CubeMX operation!
  • Code Generator: Code Generation

image-20240821175127807

  • Advance Settings: Advanced Settings

image-20240821175211984

xxxxxxxxxx
Select the library used for the initialization code: HAL library is demonstrated here

7. Generate initialization code

Click the code generation or save button to generate initialization code

image-20240821175257208

xxxxxxxxxx
Using the Ctrl+S shortcut key to save will also generate initialization code

image-20240821175400772

8. Write code

User code must be located between USER CODE BEGIN and USER CODE END, otherwise the next time you use the STM32CubeMX peripheral configuration function, the code outside this position will be deleted.

xxxxxxxxxx
Other positions also need to be written in the area between *** BEGIN and *** END!

image-20240821175655872

9. Compile code

image-20240821180145746

10. Create a new project again

Demonstrates how to create a new project in a project file. This method is often used in actual development to create a new project

image-20240821175924311

For the following operations, please refer to the previous steps.

xxxxxxxxxx
The newly added project will be displayed in the workspace on the left

5. Common Problems

Encoding format problem

Tip: Project '***' has no explicit encoding set

Solution: Right-click the project name → Modify file encoding format → UTF-8

image-20240821180224199

image-20240821180307633

MDK-ARM installation
Common driver installation

COMPANY

  • About us
  • Team Style
  • Blog

LEARNING & EXPLORATION

  • Tutorials
  • Edge AI hardware
  • Educational robots
  • Embedded intelligent hardware

WHERE TO BUY

  • Yahboom Online Store
  • Amazon
  • Alibaba
  • AliExpress
  • Mercado

TECHNOLOGY SUPPORT

  • Email: support@yahboom.com

BE A DISTRIBUTOR

  • Email: sales@yahboom.com
QR Code

Copyright © 2017-2026 Yahboom. All Rights Reserved.

EN/中文