yahboom
HomeLearn
Solution
Blog
Online Store
About Us
EN/中文
AI Voice Interaction Module📖
1. Module information
  • 0. Get started quickly
  • 1. Introduction to Voice Interaction Module
  • 2. Modify the wake-up word and command word
  • 3. Customized protocol entry creation
2. Firmware burning
  • Module firmware burning method
3. Multi-master communication
IIC communication
  • For STM32
  • For Arduino
  • For MSPM0G3507
  • For MSPM0G3519new
  • For ESP32
  • For PICO
  • For RPi5
  • For Jetson
  • For RDK X5
USART communication
  • For STM32
  • For Arduino
  • For MSPM0G3507
  • For MSPM0G3519new
  • For ESP32
  • For PICO2
  • For RPi5
  • For Jetson
  • For RDK X5
4. PC serial port communication
  • PC serial port communication
5. ROS voice interaction
ROS1
  • 1. Environment Construction
  • 2. Voice control car movement
  • 3. Voice control Autopilot
  • 4. Voice control color tracking
  • 5. Voice control multi-point navigation
ROS2
  • 1. Environment Construction
  • 2. Voice control car movement
  • 3. Voice control Autopilot
  • 4. Voice control color tracking
  • 5. Voice control multi-point navigation
Download
  • Code
  • Python driver library
  • Firmware
  • Communication Protocol
  • Software Tools
  • Voice chip datasheet
  • 3D Model File
Download ZIP

Welcome to AI Voice Interaction Module repository

5. Voice control multi-point navigation

5. Voice-controlled multi-point navigation

This course requires the combination of Rosmaster-X3 car hardware, and only code analysis is done here. First, let's look at the built-in voice commands,

image-20230530193828276

1. Program startup

1.1. Calibrate the target point

Terminal input,

xxxxxxxxxx
ros2 launch yahboomcar_nav laser_bringup_launch.py
ros2 launch yahboomcar_nav display_nav_launch.py
ros2 launch yahboomcar_nav navigation_teb_launch.py

Click [2D Pose in the rviz interface of the virtual machine Estimate】, and then compare the car's position and mark an initial position on the map;

The display after marking is as follows:

image-20230530194210728

Compare the overlap of the radar scanning point and the obstacle, you can set the initial position of the car multiple times until the radar scanning point and the obstacle roughly overlap;

Terminal input,

xxxxxxxxxx
ros2 topic echo /goal_pose

Click [2D Goal Pose], set the first navigation target point, then the car starts navigating, and the terminal will print out the topic data:

image-20230530194301408

1.2、Write the target point position program

Edit the voice_Ctrl_send_mark.py file, which is located at: ~/driver_ws/src/yahboomcar_voice_ctrl/yahboomcar_voice_ctrl/voice_Ctrl_send_mark.py

Modify the pose of the first navigation point to the one printed in the terminal:

xxxxxxxxxx
pose.pose.position.x = 2.15381097794
pose.pose.position.y = -5.02386903763
pose.pose.orientation.z = 0.726492681307
pose.pose.orientation.w = 0.687174202082

The marking results of the other points are also marked in rviz according to the above steps, and the coordinates of the pose points are recorded. Then modify to the corresponding position.

1.3, Voice Navigation

Terminal input,

xxxxxxxxxx
ros2 launch yahboomcar_nav laser_bringup_launch.py
ros2 launch yahboomcar_nav display_nav_launch.py
ros2 launch yahboomcar_nav navigation_teb_launch.py

At this time, click [2D Pose Estimate] in the rviz interface of the virtual machine, and then compare the position of the car to mark an initial position of the car on the map;

The display after marking is as follows:

image-20230530195115317

Compare the overlap of the radar scanning point and the obstacle, you can set the initial position of the car multiple times until the radar scanning point and the obstacle roughly overlap;

Terminal input,

xxxxxxxxxx
ros2 run yahboomcar_voice_ctrl voice_Ctrl_send_mark

Say "Hi Yahboom" to the voice module on the car to wake up the voice module. After hearing the voice module's feedback "Yes", continue to say "Navigate to position 1"; the voice module will feedback "OK, going to position 1", and the car will start navigating to position 1. Navigation at other locations can be used in the same way.

2. Code analysis

xxxxxxxxxx
#导入语音库 Importing Voice Library
from Speech_Lib import Speech
#创建目标点话题发布者 Create a target topic publisher
self.pub_goal = self.create_publisher(PoseStamped, "/goal_pose", 1)
def voice_pub_goal(self):
    self.pose.header.frame_id = 'map'
    #获取语音指令 Get voice commands
    speech_r = self.spe.speech_read() 
    # print("-------speech_r = ",speech_r)
    if speech_r == 19:
        print("goal to one")
        self.spe.void_write(speech_r)
        self.pose.header.stamp = Clock().now().to_msg()
        self.pose.pose.position.x = -7.1171722412109375
        self.pose.pose.position.y = -3.8613715171813965
        self.pose.pose.orientation.z = -0.6484729569092691
        self.pose.pose.orientation.w = 0.7612376922862854
        #发布目标点话题数据 Publish target point topic data
        self.pub_goal.publish(self.pose)
    elif speech_r == 20:
        print("goal to two")
        self.spe.void_write(speech_r)
        self.pose.header.stamp = Clock().now().to_msg()
        self.pose.pose.position.x = -5.434411525726318
        self.pose.pose.position.y = -3.575838088989258
        self.pose.pose.orientation.z = 0.041131907433507836
        self.pose.pose.orientation.w = 0.9991537250047569
        self.pub_goal.publish(self.pose)

 

Voice control color tracking

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