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

05.MDK-ARM project usage

MDK-ARM project usage and transplantation

MDK-ARM project usage and transplantationProject experienceOpen the projectCompile the projectDownload the programProject migrationCopy fileAdd header files/pathsModify the main.c fileCompile the projectDownload the program

Project experience: Use the project files we provide to experience the corresponding functions of the development board

Project migration: Migrate our underlying driver code files to the project files developed by yourself

Tutorial demonstration case: LED control (GPIO)

Project experience

Use the STM32 Getting Started Tutorial: LED Control (GPIO) to demonstrate how to quickly experience our case functions.

xxxxxxxxxx
Product supporting materials source code path: Attachment → Source code summary → 1.Base_Course → 2.LED

Open the project

After decompressing the corresponding project file, find the file with the .uvprojx suffix and double-click it to open it.

xxxxxxxxxx
The .uvprojx suffix file is located in the USER directory of the project file

image-20240830141611686

Compile the project

Click the Rebuild option on the toolbar to compile the project, and the compilation output bar will prompt the compilation results.

xxxxxxxxxx
Before compiling the project, you need to check the Create HEX File option in the project target. For details, see the [Download the program] tutorial

image-20240821213014404

Download the program

The generated .hex file is located in the OBJ folder of the project file. Use the FlyMCU software to burn the .hex file into the development board.

xxxxxxxxxx
For detailed burning process, see the [Download the program] tutorial

Project migration

Migrate the driver code of the LED project to the template project (Template) file, and use the template (Template) project to control the LED flashing.

xxxxxxxxxx
Secondary development does not provide technical support. Some cases are difficult to transplant and require certain user development capabilities. Users need to solve problems in the transplant process by themselves.

Project files used: 1. Template

xxxxxxxxxx
Product supporting materials source code path: Attachment → Source code summary → 1. Base_Course → 1. Template

Copy file

Copy the contents of the BSP folder of the LED project to the BSP folder of the template project:

xxxxxxxxxx
Our peripheral driver function is written in the BSP folder of the project file. Users can perform secondary development according to their own ideas!

image-20240821220020192

In the same steps, copy the AllHeader.h and myenum.h files in the LED project USER folder to the template project folder:

xxxxxxxxxx
AllHeader.h: contains the header files used
myenum.h: bit band operation file

Add header files/paths

Project management directory

Open the template project file and add the files copied from the LED project to:

image-20240821220020193

After adding successfully:

image-20240821220020194

image-20240821220020197Project target option

Add the previously copied folder path to the project header file path: If you copy a new folder into the project later, you need to add a new folder path

image-20240821220020196

Modify the main.c file

Copy the contents of the main.c file of the LED project to the main.c folder of the template project: Since the template project has no functions, you can completely copy the contents of the main.c file of the LED project. If you want to transplant a certain function later, you cannot directly replace it.

image-20240821220020198

Compile the project

If the compilation is successful and there is no error, it is likely that the transplantation is successful.

image-20240821220020199

Download the program

The generated Template.hex file is located in the OBJ folder of the LED project file. Use the FlyMCU software to burn the Template.hex file into the development board.

For detailed burning process, please refer to the [Download Program] tutorial
Download the program
Program simulation

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/中文