yahboom
HomeLearn
Solution
Blog
Online Store
About Us
EN/中文
Game Handle📖
1.Introduction to the Handle
  • Introduction to the Handle
2.Python Driver Tutorial
  • Python Driver Tutorial
3.ROS Driver Tutorial
  • ROS1 Handle Driver
  • ROS2 Handle Driver
4.Car Control Tutorial
  • ROSMASTER M3 Pro Car Control Tutorial
  • ROSMASTER X3PLUS Car Control Tutorial
5.ROS Car Upgrade Controller Adaptation Tutorial
  • ROS Car Upgrade Controller Adaptation Tutorial
Download
  • Code
  • VM_File
  • Instruction Manual
  • WindowsSoftware
Download ZIP

Welcome to Game Handle repository

ROSMASTER M3 Pro Car Control Tutorial

Controller control of M3Pro

I. Experimental Environment

  • Three-mode handle

  • M3pro(Mandatory)

Ii. Experimental Procedures

Note

This tutorial needs to be used in conjunction with a X3PLUS . It cannot run without a M3Pro

This tutorial's test environment takes 2.4G as an example!

The handle supports continuous transmission function. If you find it shaking when pressing the button, please turn off the corresponding button's continuous transmission function as per the manual

Before testing, ensure that the handle receiver is connected to the motherboard or PC, and switch the handle to DINPUT (Long press FN+SELECT for 3 seconds) 

The indicator light showing a constant green color indicates that the handle has been successfully paired

Before the experiment starts, it is necessary to ensure that the car and the computer are under the same local area network. The DOMAIN_ID must be kept consistent with that of the car The factory default is 30

  1. Start the car agent on the M3pro end/Start the large program at startup

image-20251211171804414

2.First, insert the USB receiver of the wireless gamepad into the main controller (Jetson, Raspberry Pi). Open the terminal and enter the following command(s). If js0 is displayed, this refers to the wireless gamepad.

In special cases, you can also check the changes in the device list by comparing the two states: with the wireless gamepad USB receiver connected and disconnected. If there is a change, the altered entry is the target device; otherwise, the connection has failed or the device cannot be recognized.

Note: If a mouse or keyboard is connected, they may also be recognized as js devices. However, the program only identifies js0. Therefore, if multiple js devices appear, connect the gamepad receiver first, then connect other devices.

When the gamepad is successfully connected, its indicator light remains solid lit; a flashing light indicates the connection is disconnected.

ls /dev/input/js0

image-20250616173027144

As shown in the figure, it indicates that the handle receiver has been recognized.

Open the terminal and run the handle node:

Raspberry PI and Jetson Nano versions need to enter Docker in advance

xxxxxxxxxx
ros2 launch yahboomcar_ctrl yahboomcar_joy_launch.py

Open another terminal and run the robot handle control node

xxxxxxxxxx
ros2 run yahboomcar_ctrl yahboom_joy_M3Pro

image-20250616161419493

Iii. Button Control Instructions

Gamepad ActionFunction
Left Joystick Up/DownRobot Car Moves Forward/Backward Straight
Left Joystick Left/RightRobot Car Moves Left/Right Straight
Right Joystick Left/RightRobot Car Rotates Left/Right
START ButtonExit Sleep Mode
Left Stick PressAdjust X/Y Axis Linear Velocity
Right Stick PressAdjust Angular Velocity
D-pad UpNo.4 Servo Moves Upward
D-pad DownNo.4 Servo Moves Downward
D-pad LeftNo.3 Servo Moves Downward
D-pad RightNo.3 Servo Moves Upward
Button XNo.1 Servo Moves Left
Button BNo.1 Servo Moves Right
Button YNo.2 Servo Moves Upward
Button ANo.2 Servo Moves Downward
L1|LB ButtonNo.6 Servo Gripper (Tighten) / No.5 Servo Rotate Right
L2|LT ButtonNo.6 Servo Gripper (Loosen) / No.5 Servo Rotate Left
R1|RB ButtonSwitch Light Effects
R2|RT ButtonControl Unlock
SELECT ButtonSwitch Control Between No.6 / No.5 Servo

Iv. Source Code Analysis

Source code path

jetson orin nano, jetson orin NX mainframe:

xxxxxxxxxx
/home/jetson/yahboomcar_ws/src/yahboomcar_ctrl/yahboomcar_ctrl/yahboom_joy_M3Pro.py

jetson nano, Raspberry PI mainframe:

You need to enter docker first

xxxxxxxxxx
root/yahboomcar_ws/src/yahboomcar_ctrl/yahboomcar_ctrl/yahboom_joy_M3Pro.py

 

ROS2 Handle Driver
ROSMASTER X3PLUS Car Control Tutorial

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
QR Code

Copyright © 2017-2026 Yahboom. All Rights Reserved.

EN/中文