yahboom
HomeLearn
Solution
Blog
Online Store
About Us
EN/中文
Muto S2 Robot📖
1.Introduction to Muto Robot
  • 1.Introduction to Muto Robot
  • 2.Accessories introduction
  • 3.Precautions for battery
  • 4.FAQ
2.Assembly and write system
  • 1.Raspberry Pi write system
  • 2.Jetson Nano write sytem
  • 3. Robot assembly tutorial
  • 4. Installation Video Part1-Part5
  • 4. Installation Video Part6-Part10
3.Remote control course
  • 1.Close APP control process
  • 2.Mobile APP remote control tutorial
  • 3.USB wireless handle remote control
4.Linux basic course
  • 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
5.JupyterLab course
  • 1.ReadMe before operate
  • 2.Environment setup
  • 3.Basic usage tutorial
  • 4.Widgets configuration
  • 5.Widgets controls use
6.Jetson NANO course
  • 1.About JetsonNano system
  • 2.Network configuration and Jtop
  • 3.swap space increased
  • 4.API usage of GPIO library
  • 5.Hardware library configuration
  • 6.Pin reading function
  • 7.Pin level output control
  • 8.Control LED
  • 9.Jetson Nano communicates with external device serial ports
  • 10.jetson nano I2C communication
7.Raspberry Pi course
  • 1.Python usage
  • 2.Use APT to install Python packages
  • 3.Python virtual environment
  • 4.GPIO Zero
  • 5.Pin output high and low levels
  • 6.Pin reads high and low levels
  • 7.Pin output PWM
  • 8.Serial communication
  • 9.I2C communication
8.Robot basic course
  • 1.Control buzzer
  • 2.Control PWM servo
  • 3.Control bus servo
  • 4.Robot forward and backward
  • 5.Robot move left and right
  • 6.Robot rotate left and right
  • 7.Control height
  • 8.Control head
  • 9.Action group performance
  • 10.Read data
  • 11.Host computer control
  • 12.Camera driver
9.Open Source CV course
  • 1.Introduction to Open Source CV
  • 2.Image reading and display
  • 3.Picture writing
  • 4.Image Quality
  • 5.Pixel operations
  • 6.Image zoom
  • 7.Picture cut
  • 8.Picture pan
  • 9.Picture mirroring
  • 10.Affine transformation
  • 11.Picture rotation
  • 12.perspective transformation
  • 13.Grayscale processing
  • 14.Binary image
  • 15.Edge green detection
  • 16.Line segment drawing
  • 17.Rectangular circle drawing
  • 18.Text and picture drawing
7.AI vision course
  • 0.Color HSV value calibration
  • 1.Color recognition
  • 2.Color tracking
  • 3.Color following
  • 4.Color recognition action group
  • 5.Face detection
  • 6.Face tracking
  • 7.Greet people
  • 8.QR code recognition
  • 9.QR code instructions
  • 10.visual line following
  • 11.Motion learning
  • 12.Teach pendant synchronized action
8.Machine deep learning
  • 1.KNN
  • 2.TensorFlow basic tutorial
  • 3.Basic use of PyTorch
  • 4.Yolov5 detects objects in real time
  • 5.Jetson-inference environment construction(selective viewing)
  • 6.Object detection and action
  • 7.Body movement control robot
  • 8.Gesture controlled robot
Remote login control
  • 1. VNC and SSH remote login
  • 2. Jupyter lab login and case code running
9.FAQnew
  • Using your own Jetson board, Muto S2 cannot start normally
Download
  • APP(iOS/Android)
  • SystemFile_For_RPi5
  • System_for_RPi4
  • System_for_JetsonNANO
  • Hardware and protocol
  • Instruction manual
  • Jetson_Boot_USB.tar.gz
Download ZIP

Welcome to Muto S2 Robot repository

8.Serial communication

Serial communication

From the relevant information of Raspberry Pi, we can see that the physical pins 8 and 10 of Raspberry Pi can be mapped to two serial ports, one of which is the hardware serial port (/dev/ttyAMA0) and the other is the mini serial port (/dev/ttyS0). The hardware serial port has a separate baud rate clock source, which has good performance and strong stability; The mini serial port has simple functions and poor stability. The baud rate is provided by the CPU kernel clock and is affected by the kernel clock.

Raspberry Pi (3rd/4th generation) onboard Bluetooth module, the default hardware serial port is assigned to the Bluetooth module, while the poor performance mini serial port is assigned to the GPIO serial ports TXD0 and RXD0.

image.png

Run the following command to view the default serial port allocation method:

ls /dev -al

image.png

 

Due to the hardware serial port being assigned to onboard Bluetooth, we need to release it and set the hardware serial port to be assigned to GPIO serial port.

1.After SSH logs into the Raspberry Pi system

xxxxxxxxxx
sudo raspi-config

Enter the Raspberry Pi system configuration interface and select Interfacing Options:

image.png

Choose P6 Serial

image.png

Select to turn off the serial port login function and turn on the hardware serial port debugging function.

image.png

image.png

After completion, prompt the following interface and press OK

image.png

Exit raspi config settings and follow the prompts to restart Raspberry Pi.

 

2.Set the hardware serial port to GPIO serial port

Edit the config.txt file in the/boot directory

xxxxxxxxxx
sudo nano /boot/config.txt

Add the following two lines to the end:

​x
dtoverlay=pi3-miniuart-bt

force_turbo=1

The modified image is shown below.

image.png

Save: Ctrl+O,Exit: Ctrl+X。

Reboot Raspberry Pi.

xxxxxxxxxx
sudo reboot

After restarting the Raspberry Pi, enter ls/dev - al again, and you can see that the two serial ports have switched positions with each other:

image.png

 

  1. Minicom serial port assistant testing

    Installing Minicom

xxxxxxxxxx
sudo apt-get install minicom

Start Minicom after installation is complete

xxxxxxxxxx
minicom -D /dev/ttyAMA0 -b 9600

Among them, - D represents selecting serial port/dev/ttyAMA0, and - b sets the baud rate to 9600. This parameter can be set without any need, with a default of 115200.

image.png

Open the serial port to transfer data through the USB to TTL module.

The operation of exiting Minicom is quite complicated. According to the prompt, you need to first press Ctrl+A, then press Z to pop up the following menu.

image.png

Next, press X, and finally select YES and press Enter to confirm.

4.C language test code

Print hello world

The code is as follows:

xxxxxxxxxx
#include <stdio.h>
#include <wiringPi.h>
#include <wiringSerial.h>

int main()
{
  int fd;
  if(wiringPiSetup() < 0)return 1;
  if((fd = serialOpen("/dev/ttyAMA0",9600)) < 0)return 1;
  printf("serial test start ...n");
  serialPrintf(fd,"Hello World!!!n");
  while(1)
  {
    serialPutchar(fd,serialGetchar(fd));
  }
  serialClose(fd);
  return 0;
}

image.png

Create a new testCom. c file and copy the above code into it

xxxxxxxxxx
nano testCom.c

Save: Ctrl+O, exit Ctrl+X

Use the gcc compiler to compile programs:

xxxxxxxxxx
gcc testCom.c -o test -lwiringPi

Run a program

xxxxxxxxxx
./test

image.png

You can also send data to Raspberry Pi through the serial port, and Raspberry Pi will directly return it to the serial port for display.

Note: If there is a display of garbled code, please check the baud rate and set it to 9600, which corresponds to the above code.

Pin output PWM
I2C communication

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