yahboom
HomeLearn
Solution
Blog
Online Store
About Us
EN/中文
ROSMASTER M3📖
00.Configuration and Operation Guide
  • 1.Quick start handle to control the car
  • 2.Log in to the car and view the code
  • 3.Enter the Docker (For RPI5)
  • 4.Camera and Radar Configuration (Must Read)
  • 5.Assembly video
  • 6.Modify Control Board Firmware Parameters
01.Chassis Control Course
  • 01.ROS control
  • 02.Handle control
  • 03.Keyboard control
  • 04.Robot state estimation
  • 05.Data remote visualization
  • 06.Line velocity calibration
  • 07.Angular velocity calibration
  • 08.Robot URDF model
  • 09.Line patrol automatic driving
  • 10.Patrol
02.Lidar Course
  • 01.Lidar introduction and use
  • 02.Lidar point cloud fusion and filtering
  • 03.Lidar obstacle avoidance
  • 04.Lidar tracking
  • 05.Lidar guard
  • 06.Gmapping-SLAM mapping
  • 07.Cartographer-SLAM mapping
  • 08.slam_toolbox mapping
  • 09.Lifelong mapping
  • 10.Navigation2 single-point navigation avoid
  • 11.Navigation2 multi-point navigation avoid
  • 12.Cartographer relocalization navigation
  • 13.slam_toolbox localization and navigation
  • 14.Synchronous mapping and navigation
  • 15.RTAB-Map mapping
  • 16.RTAB-Map navigation
  • 17.APP mapping and navigation
03.AI Model Basics
  • 1.AI large model types and principles
  • 2.RAG retrieval enhancement and model training samples
  • 3.Embodied intelligent robot system architecture
  • 4.Embodied intelligent functions core source code
04.AI Model Development
  • 01.Register a model service provider account
  • 02.Configuring API-KEY
  • 03.Introduction to Dify
  • 04.Basic Dify Features
  • 05.AI Large Model Development - chatbot
  • 06.Deploy the RAG knowledge base
  • 07.RAG knowledge base + chatbot
  • 08.AI agent workflow
  • 09.Custom wake-up response
  • 10.Core module testing tools
05.AI Model - Voice Version
  • 1.Semantic understand and command follow
  • 2.Multimodal visual understanding
  • 3.Multimodal visual understanding+SLAM navigation
  • 4.Intention estimation
06.AI Model - Text Version
  • 1.Semantic understand and command follow
  • 2.Multimodal visual understanding
  • 3.Multimodal visual understanding+SLAM navigation
  • 4.Intention estimation
07.Road Network Planning and Navigation
  • 1.Introduction and Quick Start
  • 2.Constructing a Pose Map
  • 3.Road Network Labelling
  • 4.Inter-Road Network Planning and Navigation
  • 5.Free-Pose Road Network Navigation
  • 6.Path Replanning
08.Autonomous Driving expand(Need purchase track map)
  • 01.Environment Setup & Precautions
  • 02.YOLO Environment Configuration
  • 03.Data Collection
  • 04.Data Annotation
  • 05.YOLOv11 Model Training
  • 06.Model Format Conversion
  • 07.Vehicle Centerline Calibration
  • 08.Lane Detection
  • 09.Lane-Keeping Autonomous Driving
  • 10.Traffic Sign Recognition
  • 11.Comprehensive Autonomous Driving Applications
  • 12.Autonomous Driving Debugging Module
  • 13.Road Network Planning with Track Map
  • 14.Road Network Planning with Traffic Sign Recognition
  • 15.AI Model with Road Network Planning
  • 16.AI Model with Track Map and SLAM Navigation
  • 17.AI Model with Road Network Planning and Autonomous Driving
09.Depth Camera Course
  • 01.Dabai_DCW2 Camera Introduction
  • 02.Nuwa-HP60C Camera Introduction
  • 03.Depth Pseudo-Color Image
  • 04.Depth Camera Distance Measurement
  • 05.Wood Block Volume Measurement
  • 06.Edge Detection
  • 07.YOLOv11 Object Detection
  • 08.YOLOv11 Object Tracking
  • 09.Color Following
  • 10.Face Following
  • 11.QR Code Following
  • 12.Machine Code Following
  • 13.KCF Object Tracking
  • 14.QR Code Motion Control
  • 15.AR Vision
10.Mediapipe Visual Course
  • 01.Hand Detection
  • 02.Posture Detection
  • 03.Overall Detection
  • 04.Facial Landmark Detection
  • 05.3D Object Recognition
  • 06.Face Detection
  • 07.Gesture Recognition
  • 08.Face Special Effects
  • 09.Brush
  • 10.Finger Control
  • 11.Palm Target Positioning
  • 12.Fingertip Trajectory Recognition
  • 13.Gesture Following
  • 14.Posture Following
  • 15.Gesture Motion Control
11.Multi-vehicle Course
  • 1.Multi-vehicle Control
  • 2.Multi-vehicle Navigation
  • 3.Multi-vehicle Platoon
12.AI Large Model Basic Course
Offline large model (Text Interaction)
  • 0. AI Large Model Mirroring Explanation
  • 1. Deployment of large-scale AI models
  • 2. Installation of the large model dialogue platform
  • 3. Meta AI Llama 3.2 model
  • 4. Alibaba Cloud Qwen3 Model
  • 5. DeepSeek DeepSeek-R1 model
  • 6. Microsoft Phi-4 mini model
  • 7. Alibaba Cloud Qwen2.5vl Visual Multimodal Large Model
  • 8. Google Gemma3 Visual Multimodal Large Model
  • 9. Llava Visual Multimodal Large Model
  • 10. Multimodal Visual Understanding Applications
  • 11.MiniCPM-V Visual Multimodal Large Model
  • 12. Multimodal Text-Based Image Application
  • 13. Multimodal Video Analysis Application
  • 14. Multimodal table scanning application
  • 15. Multimodal visual positioning applications
  • 16. Multimodal Autonomous Agent Application
Offline large model (Voice Interaction)
  • 0. Voice Interaction Hardware Connection (Must Read)
  • 1. Offline speech-to-text (ASR)
  • 2. Offline Text-to-Speech (TTS)
  • 3. AI large model voice interaction
  • 4. Multimodal visual understanding and voice interaction
  • 5. Multimodal Text-Based Image Application
  • 6. Multimodal Video Analysis Application
  • 7. Multimodal visual positioning applications
  • 8. Multimodal table scanning application
  • 9. Multimodal Autonomous Agent Applications
  • 10. AI large model offline voice assistant
Online large model (Text Interaction)
  • 1. OpenRouter Large Model API Aggregation Platform
  • 2. Multimodal visual understanding applications
  • 3. Multimodal visual positioning applications
  • 4. Multimodal table scanning application
  • 5. Multimodal Autonomous Agent Applications
Online large model (Voice Interaction)
  • 0. Voice Interaction Hardware Connection (Must Read)
  • 1. Online speech-to-text (ASR)
  • 2. Online Text-to-Speech (TTS)
  • 3. AI large model voice interaction
  • 4. Multimodal visual and voice interaction
  • 5. Multimodal visual positioning applications
  • 6. Multimodal table scanning application
  • 7. Multimodal Autonomous Agent Applications
  • 8. AI large model online voice assistant
13.Control Board Course
1.Development environment setup
  • 1.Introduction to the Control Board
  • 2.Set up the STM32CUBEIDE development environment
  • 3.Burning STM32 firmware using SWD
  • 4.Burning STM32 firmware using serial port
  • 5.Compile the microros driver library
  • 6.Install and start the microros agent
  • 7.Import Project
2.Control board STM32 basic routine
  • 1.Turn on the LED light
  • 2.Button functions
  • 3.Drive the buzzer
  • 4.Serial communication
  • 5.Battery voltage detection
  • 6.Driving PWM Servo
  • 7.Drive motor
  • 8.Read motor encoder data
  • 9.PID control of motor speed
  • 10.Robot kinematics analysis theory
  • 11.Read IMU data
  • 12.Read Lidar data
  • 13.Flash access data
  • 14.Driving OLED Displays
  • 15.Driving RGB light strip
  • 16.SBUS model aircraft remote control
  • 17.USB controller remote control
  • 18.CAN bus communication
3.Control board micro_ros basic routine
  • 1.Post a topic
  • 2.Subscribe to a topic
  • 3.Multi-topic subscription and publishing
  • 4.Subscribe to the buzzer topic
  • 5.Subscribe to the bus servo topic
  • 6.Subscribe to the rate control topic
  • 7.Release Speed Topic
  • 8.Publish IMU data topic
  • 9.Publish radar data topic
14.Main Control Course
Jetson Orin Nano_NX
  • 1.Jetson Orin board introduction
  • 2.Restore the factory image system
  • 3.Backup SSD system
  • 4.SSD expansion
  • 5.Network configuration
  • 6.SSH remote login
  • 7.VNC remote control
  • 8.Remote file transfer
  • 9.Jtop tool
  • 10.Exchange space expansion
Raspberry Pi
  • 1. Introduction to Raspberry PI 5
  • 2. Raspberry PI system installation and backup
  • 3. Powering the Raspberry PI 5
  • 4. Startup of Raspberry PI 5
  • 5. Update and upgrade operating system
  • 6. Introduction to raspi-config tool
  • 7. config.txt file description
  • 8. Network Configuration
  • 9. remote access
  • 10. Transfer files remotely
  • 11. Set display resolution and rotation
  • 12. Set screen to sleep
  • 13. Play audio and video
  • 14. Using USB camera
  • 15. Using MIPI camera
  • 16. Get real-time temperature of Raspberry Pi
RDKX5
  • 1.Introduction to RDK X5 board
  • 2.Write system file
  • 3.Hardware interface description
  • 4.Install case and other accessories
  • 5.Network configuration
  • 6.Remote login
  • 7.Update system
  • 8.srpi-config user guide
  • 9.config. txt configuration file
  • 10.Self-startup setting
  • 11.RDK exclusive command usage
  • 12.Linux command usage
  • 13.GPIO readwrite operation
  • 14.Image classification algorithm
  • 15.Use USB camera
  • 16.Use MIPI camera
  • 17.Binocular camera depth algorithm
15.YOLOv11 Development (ORIN)
  • 1.YOLO environment construction
  • 2.CLI use
  • 3.Object detection
  • 4.Instance segmentation
  • 5.Pose estimation
  • 6.Image classification
  • 7.Oriented object detection
  • 8.Model conversion
  • 9.Dataset annotation
  • 10.Model Training_Conversion
  • 11.Model prediction
16.YOLOv11 Development(RDKX5)
  • 1.YOLO environment construction
  • 2.CLI use
  • 3.Object detection
  • 4.Instance segmentation
  • 5.Pose estimation
  • 6.Image classification
  • 7.Oriented object detection
  • 8.Model prediction
  • 9.Model Quantization
17.YOLOv11 Development (RPI)
  • 1.YOLO environment construction
  • 2.CLI use
  • 3.Object detection
  • 4.Instance segmentation
  • 5.Pose estimation
  • 6.Image classification
  • 7.Oriented object detection
  • 8.Model conversion
  • 9.Model prediction
18.Linux Operating System
  • 1.Introduction to Linux system
  • 2.Ubuntu file system
  • 3.Ubuntu common commands
  • 4.Ubuntu common editors
  • 5.Ubuntu software operation commands
  • 6.Virtual machine installation
  • 7.SSH remote control
  • 8.VNC remote control
  • 9.Transfer files remotely
  • 10.Driver library and communication
  • 11.Static IP and hotspot mode
  • 12.Bind device ID
  • 13.Capacity expansion and resource allocation
  • 14.Update system software sources
  • 15.Set root user password
  • 16.sudo free password
  • 17.Connect to WiFi network
  • 18.View system version
  • 19.Customized service management
  • 20.Back up system image
19.ROS2 Basic Course
  • 1.Introduction to ROS2
  • 2.ROS2 install Humble
  • 3.ROS2 development environment
  • 4.ROS2 workspace
  • 5.ROS2 function package
  • 6.ROS2 node
  • 7.ROS2 topic communication
  • 8.ROS2 service communication
  • 9.ROS2 action communication
  • 10.ROS2 custom interface message
  • 11.ROS2 parameter service case
  • 12.ROS2 meta-function package
  • 13.ROS2 distributed communication
  • 14.ROS2 DDS
  • 15.ROS2 time related API
  • 16.ROS2 common command tools
  • 17.ROS2 rviz2 use
  • 18.ROS2 rqt toolbox
  • 19.ROS2 Launch startup file configuration
  • 20.ROS2 recording and playback tool
  • 21.ROS2 URDF model
  • 22.ROS2 Gazebo simulation platform
  • 23.ROS2 TF2 coordinate transformation
20.Docker Course
  • 1、Docker overview and docker installation
  • 2、Common commands for docker image containers
  • 3、Docker images deeply understand and publish images
  • 4、Docker hardware interaction and data processing
  • 5、Enter the bot's docker container
  • 6、Robot development environment construction in Docker
21.Image Processing Basics Course
  • 1. Introduction to Open Source CV
  • 2. Image reading and display
  • 3. Image writing
  • 4. Image quality
  • 5. Pixel Operation
  • 6. Image zoom
  • 7. Image cutting
  • 8. Image translation
  • 9. Image Mirroring
  • 10. Affine Transformation
  • 11. Image Rotation
  • 12. Perspective Transformation
  • 13. Grayscale processing
  • 14. Image Binarization
  • 15. Edge Detection
  • 16. Line drawing
  • 17. Rectangle and circle drawing
  • 18. Drawing text and pictures
Download
  • Mapping_APP(iOS_Android)
  • MainBoard_AI_Pure_System
  • Robot_Image_System_File
  • Code-Firmware
  • Instruction_Manual
  • VM_File
  • Software_Tools
  • Firmware_DriverFile
  • 3D_Model_File
  • ROS2_Basic_VM
  • Other_Annex
Download ZIP

Welcome to ROSMASTER M3 repository

12.Autonomous Driving Debugging Module

Autonomous Driving Debugging Special Topic

Autonomous Driving Debugging Special Topic1. Course Content2. YOLOv11 Inference Parameter Debugging (Not applicable to RDK)2.1 Traffic Sign Recognition Debugging2.2 Parameter Adjustment Guide2.3 Lane Line Detection Debugging2.4 Parameter Adjustment Guide3. Lane Left-Right Keeping—Zero Offset Error Calibration4. Lane Keeping Left-Right Keeping—PID Debugging4.1 Parameter Adjustment Guide:5. Lane Straight Keeping—PID Debugging5.1 Parameter Adjustment Guide:6. Curve Turning Effect Debugging6.1 Parameter Adjustment Guide:7. Right Turn Sign Debugging8. Parking Sign Debugging

1. Course Content

  • Master the role and debugging methods of autonomous driving YOLO inference recognition, lane centering keeping, and traffic sign recognition response parameters to optimize autonomous driving effects.

 

2. YOLOv11 Inference Parameter Debugging (Not applicable to RDK)

[!CAUTION]

RDK mainboard users cannot debug inference parameters because the inference model is a quantized model. Use factory preset parameters!!

  • YOLOv11 parameter file location:
~/yahboomM3_ws/user_ws/src/m3_bringup/config/auto_drive/yolo_param.yaml
  • Parameter content is as follows, where

    • The sign_detection field contains inference parameters for the traffic sign recognition model
    • The line_detection field contains inference parameters for the lane line detection model
​x
#Road sign detection inference parameters
sign_detection:
  model_path: '/home/jetson/MODELS/auto_drive/sign_model.engine'
  conf: 0.92                                                                            
  #Sets the minimum confidence threshold for detection. Objects detected with a confidence level below this threshold will be ignored. Adjusting this value can help reduce false positives.
  iou: 0.7                                                                              
  #An overlap threshold is used for non-maximum suppression (NMS). Lower values reduce detections by eliminating overlapping bounding boxes.
  rect: True                                                                            
  #If enabled, the shorter side of the image is minimally padded until it is divisible by the step size to improve inference speed.
  half: True                                                                            
  #If enabled, half-precision inference is used, which can speed up model inference on supported GPUs with minimal impact on accuracy.
  device: "cuda:0"                                                                                           #Reasoning device
  batch : 50                                                                                        
  #Batch size: Larger batch sizes can provide higher throughput, thereby reducing the total time required for inference.
  max_det : 2                                                                                    
  #Maximum number of objects detected
  augment : False                                                                                
  #Enabling Test-Time Enhancement (TTA) for prediction may improve the robustness of detection, but it will reduce inference speed.
  verbose : False                                                                                
  #Whether to output detailed inference information to the terminal.
  classes : [0, 1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 13]
​
line_detection:
#Lane detection inference parameters
  model_path: '/home/jetson/MODELS/auto_drive/lane_V6_int8.engine'
  conf: 0.4                                                                            
  iou: 0.7                                                                              
  rect: True                                                                            
  half: False                                                                            
  device: "cuda:0"                                                                                          
  batch : 50                                                                                       
  max_det : 5                                                                                    
  augment : False                                                                                
  verbose : False   

 

2.1 Traffic Sign Recognition Debugging

  • Start traffic sign recognition program
xxxxxxxxxx
ros2 launch m3_bringup auto_drive.launch.py unkeeplane:=True

image-20251204165353051

[!TIP]

  • Different types of targets are distinguished by different detection boxes. The detection box will display the target type name and confidence level. The target type name here is determined by the data annotation and training stages.

2.2 Parameter Adjustment Guide

  • If target recognition is not sensitive, for example, the STOP sign is not easily recognized from a side view, refer to the following methods:

    • You can reduce the conf minimum confidence threshold in the sign_detection field
    • Set augment : True in the sign_detection field to enable enhancement (TTA) for prediction (not recommended).
    • Retrain the model, increase training samples under various angles, lighting, and backgrounds. The more diverse the training samples, the better the model recognition accuracy.

image-20251204170229526

 

  • How to ignore targets during object detection?

If you don't want to detect certain categories of targets, you can adjust the classes list in the sign_detection field. The numbers in the classes list are the targets that need to be detected. If you don't need to detect a certain target, simply remove the corresponding serial number.

xxxxxxxxxx
classes : [0, 1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 13]
  • Target categories and corresponding serial numbers are shown in the following table
xxxxxxxxxx
###########################################################
#         Traffic sign inspection
###########################################################
# 0: greenlight                 绿灯
# 1: honking                    鸣笛
# 2: parkA                      停车场A
# 3: parkB                      停车场B
# 4: redlight                   红灯
# 5: school                     学校
# 6: sidewalk                   人行道 
# 7: sidewalk_ground            地面人行道
# 8: speedlimit                 限速
# 9: stop                       停止
# 10: straight                  直行
# 11: turnright                 右转    
# 12: turnright_ground          地面右转
# 13: yellowlight               黄灯
###########################################################
#              Lane detection
# 0: lane
###########################################################

 

2.3 Lane Line Detection Debugging

  • Start autonomous driving program
xxxxxxxxxx
ros2 launch m3_bringup auto_drive.launch.py unsign:=True

image-20251204173154382

  • Start dynamic parameter configuration panel
xxxxxxxxxx
ros2 run rqt_reconfigure rqt_reconfigure
  • Click AutoDrive to enter the parameter control panel. If there is no AutoDrive on the left side when you first open it, click Refresh below

image-20251203094713276

  • Click to check DEBUG_MODE to display the YOLO detection boxes for lane lines

image-20251204173506395

2.4 Parameter Adjustment Guide

[!TIP]

  • If lane line recognition is not sensitive, refer to traffic sign recognition debugging and reduce the conf minimum confidence threshold in the line_detection field
  • If it is too sensitive and incorrectly shows detection boxes for unrelated lines, increase this detection threshold

 

  • How to close the display of reference lane lines and vehicle body centerline?
  • Temporary closure: In the visualization parameter panel, uncheck DEBUG_MODE_4 to close the display

image-20251204174253908

 

  • Long-term closure: Open the configuration parameter file of the auto_drive node:
xxxxxxxxxx
~/yahboomM3_ws/user_ws/src/m3_bringup/config/auto_drive/auto_drive_node.yaml
  • Adjust the DEBUG_MODE_4 parameter to False and save the file

[!NOTE]

The m3_bringup package uses symbolic link compilation. Parameter modifications will take effect immediately after saving.

xxxxxxxxxx
AutoDrive:                        
  ros__parameters:
    turn_radius: 0.4            # Turning radius
    drive_speed: 0.15           # Driving speed
    angular_speed: -0.5         # Angular speed
    duration: 3.0               # Turning time
    cooldown_time: 15.0          # Road sign recognition event response time interval (seconds)
    DEBUG_MODE: False           #Display the yolo recognition box
    DEBUG_MODE_2: False         #Video debugging mode
    DEBUG_MODE_4: False          #Display the reference lines for the left and right lanes
    START_AutoDrive: False
    unkeeplane: False           #Close lane keep driving
    #Linear_PID parameters
    Kp: -0.5
    Ki: 0.0
    Kd: 0.0
    #Lane_PID parameters
    Kp_1: -0.3
    Ki_1: 0.0
    Kd_1: 0.0
    min_error_angular: 0.03      #Maintain the minimum Angle adjustment threshold of the straight line
    max_integral: 1000.0         #Integral limit
    image_size: [640, 480]
    conbine_nav: False
    roadnet_file: ""
    initial_error: 2.55         #Zero-offset error 
    turn_angle: -96.0           # Turning angle
    turn_distance: 0.85         # Turning distance
    park_distance_1: 0.35       # Parking distance
    park_distance_2: 0.4        # Parking distance

 

3. Lane Left-Right Keeping—Zero Offset Error Calibration

  • In the [07.Vehicle Centerline Calibration] course of this chapter, we learned to calibrate the left and right lane reference lines in the camera perspective
  • However, when the camera position changes mechanically, or due to small jumps in the YOLO recognition lane line bounding box itself, even if the vehicle body is placed in the left-right center position of the lane, the left-right error may not be zero at this time. This is the zero offset error error0. When performing PID operation, this zero offset error needs to be subtracted to obtain the true error value

image-20251204180009656

 

  • First place the vehicle body in the center of the lane, click to check DEBUG_MODE_3, then it will automatically sample the current left-right deviation error 100 times and calculate the average value as the zero offset error

image-20251204180139674

  • The terminal will print out the zero offset error value

image-20251204180739266

 

  • How to add zero offset error value to optimize lane left-right centering effect
  • Temporary adjustment: Fill in the zero offset error value in init_error in the rqt_reconfigure panel, then press Enter, and the terminal will prompt that the parameter has been updated

image-20251204180958252

 

  • Long-term effect:

Open the configuration parameter file of the auto_drive node, modify initial_error, and then save.

xxxxxxxxxx
AutoDrive:                        
  ros__parameters:
  ......................
    initial_error: 1.43         #Zero-offset error 
    ...............

 

4. Lane Keeping Left-Right Keeping—PID Debugging

  • The vehicle body's left-right keeping in the lane is controlled by PID on the left-right deviation. The control parameters are KP_1, Ki_1, Kd_1. We can temporarily adjust and observe the actual effect in rat_reonfigure

[!WARNING]

Note: Lane left-right keeping is not always performed. It is only when the deviation angle between the vehicle body centerline and the lane centerline is less than the min_error_angular threshold that left-right adjustment will be performed.

 

4.1 Parameter Adjustment Guide:

[!TIP]

  • If the left-right translation centering effect is not obvious or sluggish, increase the absolute value of Kp_1, with a negative sign
  • If left-right translation is frequent and normal Kp_1 shows overshoot oscillation, you can reduce Kp_1 or introduce Kd_1 differential term to increase damping.
  • Ki is used to control steady-state error. Here, in the small-scale scenario of the sandbox map, fast response is needed, so the integral term is not introduced.

image-20251204182017497

 

  • After parameter debugging is completed, if you need long-term effective parameters, open the configuration parameter file of the auto_drive node, modify the corresponding parameters, and then save.
xxxxxxxxxx
AutoDrive:                        
  ros__parameters:
    #Lane_PID parameters
    Kp_1: -0.3
    Ki_1: 0.0
    Kd_1: 0.0
    max_integral: 1000.0         #Integral limit
​

 

5. Lane Straight Keeping—PID Debugging

  • When the angle (deviation angle) between the vehicle body centerline and the actual left-right lane intersection point and the vehicle body centerline starting point exceeds the min_error_angular threshold, vehicle head direction adjustment will be triggered, thereby keeping the vehicle body driving straight.

[!WARNING]

  • Can be understood as:
  • Deviation angle < min_error_angular threshold: Perform lane left-right centering keeping
  • Deviation angle > min_error_angular threshold: Perform lane straight keeping
  • Therefore, min_error_angular should not be set too large, otherwise it may cause premature entry into left-right translation state, and the vehicle may drift diagonally in the lane.
  • The angle-dev in the upper left corner of the image below shows the real-time deviation angle

image-20251204183615422

 

  • The vehicle body's left-right keeping in the lane is controlled by PID on the left-right deviation. The control parameters are KP, Ki, Kd. We can temporarily adjust and observe the actual effect in rat_reonfigure

image-20251204184240302

5.1 Parameter Adjustment Guide:

[!TIP]

  • If the vehicle head adjustment angle is not obvious or sluggish, increase the absolute value of Kp, with a negative sign
  • If the vehicle head adjustment angle swings frequently and normal Kp shows overshoot oscillation, you can reduce Kp or introduce Kd differential term to increase damping.
  • Ki is used to control steady-state error. Here, in the small-scale scenario of the sandbox map, fast response is needed, so the integral term is not introduced.

 

  • After parameter debugging is completed, if you need long-term effective parameters, open the configuration parameter file of the auto_drive node, modify the corresponding parameters, and then save.
xxxxxxxxxx
AutoDrive:                        
  ros__parameters:
    #Linear_PID parameters
    Kp: -0.5
    Ki: 0.0
    Kd: 0.0
    min_error_angular: 0.03      #Maintain the minimum Angle adjustment threshold of the straight line
    max_integral: 1000.0         #Integral limit
​

 

6. Curve Turning Effect Debugging

  • The length of the vehicle body centerline determines the timing of the vehicle entering the curve for turning. When the vehicle body centerline intersects with the left lane line, turning begins.

image-20251203120734260

 

  • When there is no intersection between the vehicle body centerline and the left lane line, the turn is completed and returns to straight keeping mode, correcting direction through the deviation angle.

image-20251204190619847

 

6.1 Parameter Adjustment Guide:

[!TIP]

  • If the turning timing is too early, turning before entering the curve indicates that the centerline is too long or the camera perspective is too high. You can appropriately shorten the centerline length or adjust the camera perspective slightly downward.
  • Similarly, if the turning timing is too late, turning before entering the curve indicates that the centerline is too short or the camera perspective is too low. You can appropriately extend the centerline length or adjust the camera perspective slightly upward.
  • If you adjusted the camera angle, the camera perspective will change, and you need to recalibrate the zero offset error value for lane left-right keeping.

 

  • As mentioned in 07-Centerline Calibration, all parameters related to centerline calibration are saved in the midline_points.yaml parameter file of the m3_bringup package. The file path is:
xxxxxxxxxx
~/yahboomM3_ws/user_ws/src/m3_bringup/config/auto_drive/midline_points.yaml
  • Among them, midline_length is the vehicle body centerline length. It takes effect after modification and saving.
xxxxxxxxxx
midline_points:
---------------
  midline_length: 115

 

7. Right Turn Sign Debugging

  • After seeing the right turn sign, the vehicle will drive a certain distance to reach the intersection and then turn right by the specified angle

image-20251204192339334

 

  • Open the rqt_reconfigure parameter configuration panel, where:

    • turn_distance is the distance to continue driving after seeing the right turn sign, adjusted according to the actual effect
    • turn_angle is the angle to turn at the intersection, adjusted according to the actual effect

image-20251204192613812

 

  • After parameter debugging is completed, you can fill the parameters into the configuration parameter file of the auto_drive node, modify the corresponding parameters, and then save.
xxxxxxxxxx
AutoDrive:                        
  ros__parameters:
  ----------------
    turn_angle: -96.0           # Turning angle
    turn_distance: 0.85         # Turning distance
----------------

 

8. Parking Sign Debugging

  • Autonomous parking means that after seeing the parking sign, the vehicle drives forward a certain distance and then translates into the garage

image-20251204193657813

Open the rqt_reconfigure parameter configuration panel, where:

  • park_distance_1 is the distance to continue driving after seeing the parking sign, adjusted according to the actual effect
  • park_distance_2 is the distance to translate right into the garage after continuing driving and stopping, adjusted according to the actual effect

image-20251204193954342

 

  • After parameter debugging is completed, you can fill the parameters into the configuration parameter file of the auto_drive node, modify the corresponding parameters, and then save.
xxxxxxxxxx
AutoDrive:                        
  ros__parameters:
  ----------------
    park_distance_1: 0.35       # Parking distance
    park_distance_2: 0.4        # Parking distance
----------------

 

 

 

Comprehensive Autonomous Driving Applications
Road Network Planning with Track Map

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