toothache

[Training Camp] Based on Hi3861 module—Harmony Puppy

 
Overview

Change log

2022.7.11——
The foot end is expanded in structural design and attached to the timing belt to increase friction with the ground. (Added into STL compressed file)
Foot modification.jpg

2022.8.7——-
Leg structure design changes:

  • Thigh + calf thickening
  • The structure of the foot is expanded and modified, no timing belt is required
  • Add 3×7×3mm bearings to the joints
    Single leg structure- V2.0.png

1 Project Introduction

   本项目中设计了一款基于鸿蒙Hi3861主控的十二自由度桌面级舵狗,选择MG90S型号9g舵机作为关节位控电机,采用PCA9685PW来实现16路舵机的驱动控制,具有MPU6050六轴加速度传感器模块接口。

移动电源为2S-35C航模聚合物锂电池,电机供电部分采用以MP2236型号DC-DC芯片展开的BUCK型DC-DC降压电路,其支持宽电压输入,最高输入电压18V,最高输出电流6A。

B station video:
Harmony Puppy


Twelve degrees of freedom rudder dog.jpg

2 Device selection

2.1 Main control MCU:

  • Hi3861: A system-in-package module based on the HiSilicon Hi3861LV100 chip. It has a compact appearance and supports Hongmeng embedded development and can realize wifi communication.

2.2 Steering gear drive management:

  • PCA9685PW: Based on 12-bit precision of IIC bus communication, 16-channel PWM wave output, and supports the management of up to 16 servos.

2.3 Power supply voltage stabilization part:

  • 3.3V regulated LDO: SCJT1117-3.3.
  • DC-DC BUCK step-down circuit chip: MP2236, maximum input voltage 18V, maximum output current 6A.

Reference teaching video:
Station b: Mr. Sun from the Engineering Department - BUCK type DC-DC step-down switching power supply module design


2.4 Additional interfaces:

  • IIC0 interface;
  • IIC1 interface;
  • MCU serial port interface;
  • GPIO11~14 pins;

2.5 Resources not called:

  • Six-axis acceleration sensor module: MPU6050 (It is planned to transplant the communication code of MPU6050 from STM32, but it is not completed...)
  • RGB lamp beads: WS2812B-Mini;
  • Micro buzzer: DET402G.
Note: After this part is soldered, the MCU will output garbled characters after pressing the EN key, making it impossible to burn the firmware. [The reason has not been found yet, so it has not been called. 】

3 Mechanical structure design

设计软件:SolidWorks 2020

所述十二自由度四足舵狗总重量:570g



单腿采用并联腿结构,电机安装部分结构及单腿结构设计紧凑,以尽量减轻腿部重量与节省空间。



主要结构件部分均采用了FDM式3D打印,材质为PLA,大部分均可无支撑打印。

Structural reference video:
DIY your own mechanical dog, hardware drawing open source
Wei Xue 12 degrees of freedom WAVEGO quadruped

3.1 Design features:

  • Three degrees of freedom parallel leg structure
  • Overall 12 degrees of freedom
  • 3D printed structure
  • A 2.4G antenna module can be installed on the tail (such as a small pepper straight head)
  • The power display module can be installed on the PP side
Note: The foot needs to be anti-slip

p5.jpg
SW preview.png
p4.jpg

4 Analysis of forward and inverse solutions of single leg kinematics

此部分可参考b站up主:灯哥开源 的十二自由度正解、逆解几何法、足端摆线轨迹生成讲解视频。

4.1 Derivation of correct solution:

Reference teaching video:
Station B: Deng Ge Open Source - Correct Solution to Robot Dog 12 Degrees of Freedom


4.2 Inverse solution derivation:

Reference teaching video:
Station B: Deng Ge Open Source - Inverse Solution of Robot Dog 12 Degrees of Freedom


4.3 Schematic diagram of single upper and lower leg mechanism:

Simple diagram of single leg mechanism.jpg


4.4 Cycloid trajectory generation at the end of the foot

在数学中,摆线(Cycloid)定义:一个圆沿一条直线运动时,圆边界上一定点所形成的轨迹。

Station b: Deng Ge’s open source - foot end cycloid trajectory generation and MATLAB drawing

Foot end cycloid formula.png
Cycloid image.png


4.5 Trot trot gait planning

    Trot步态是一种动态步态,适用于中低速跑动,并且具有比较大的运动速度范围,另一个重要特征是在中等速度下的Trot步态具有最高的能量效率。这些优点使得Trot步态成为最常用的四足步态。

Reference teaching videos + articles:
Station B: Dengge Open Source - Trot Trot Gait Program
CSDN: Yileda - Foot Trajectory Planning and Gait Planning of a Quadruped Robot


Trot gait cycle diagram:

Trot.png

5 Software algorithm design

Reference teaching website:
Environment configuration (Python or C/C++)

Python development environment: Pycharm
C/C++ development: Linux (Ubuntu) ---> SSH <--- (windows 10) Clion / VScode

5.1 Low-level driver content:

  • PWM servo driver: pca9685.c, pca9685.h;
  • WiFi communication configuration: STA mode + UDP communication (FreeRTOS network thread);

5.2 Motion control content:

5.2.1 Forward and inverse solutions of single-leg kinematics:
  • Single-leg forward solution Forward Kinematics: FKIK.c, FKIK.h ——— void FK function
  • Single-leg inverse solution Inverse Kinematics: FKIK.c, FKIK.h ——— void IK function
5.2.2 Attitude inverse solution control:
  • Inverse solution of posture: Robot.c ——— void PosToPoint function
  • Inverse solution of roll angle Roll: Robot.c ——— void PosToRoll function
  • Inverse solution of pitch angle Pitch: Robot.c ——— void PosToPitch function
  • Inverse solution of yaw angle Yaw: Robot.c ——— void PosToYaw function
5.2.3 Movement gait control:
  • End cycloidal trajectory: in Trot function...
  • Trot front and back gait mode: Robot.c ——— void Trot function
  • Trot left and right gait mode: Robot.c ——— void TrotRL function
  • Trot turning gait mode: Robot.c ——— void TrotTurn function

6 PC App design

开发软件:Android Studio - 2021.1.1
基于Android端开发的App,其UI设计调用了Material与CircleMenu库,简约风设计。
目前菜单功共包含五部分:
    * WiFi信息检测;
    * Robot控制界面浏览;
    * UDP协议通信控制;
    * TCP协议通信控制(未开发完毕);
    * 设置Setting(未开发完毕)。

Reference teaching video:
Station b: WakeUp - circular animation button design

Note: Positioning and notification permissions need to be turned on, otherwise the App cannot call Wifi related functions.

rosdemo.png
tcp+udp.png

Control interface:

a0.jpg

7. Physical pictures

p2.jpg
p6.jpg
p0.jpg
p3.jpg

Existing Problems

1. In this project, the quadruped robot's hind legs are weak when it stands while lying down, and when the Trot moves forward and backward. It is speculated that it is due to insufficient torque of the MG90S and quality batch issues.
(Replacing [a better steering gear] is expected to solve the problem);
2. The deviation of each single leg of the robot needs to be calibrated before moving, which is cumbersome and time-consuming, that is, the steering gear control accuracy problem.
(Replacing [a better servo] may solve the problem);
3. During the movement of the robot, the height of the left and right legs is not equal, which is also a debugging problem involving the accuracy of the servo.
(Replacing [a better servo] is expected to solve the problem);
4. Some of the servos in the robot are shaking wildly after performing actions, which means there is a quality problem with the servos or a power supply problem (there should be no problem with insufficient power supply on this board).
(Replacing a [better steering gear] may solve the problem);
5. The bolt connections of the robot's single-leg mechanism are prone to being too tight or loose, causing the single-leg mechanism to become loose or difficult to move. The current optimization plan is to repeatedly move the hand-pull mechanism to destroy the internal threads of the printed parts and ensure smooth relative movement between parts.
(Adding [miniature bearings] to each joint of the single leg is expected to solve the problem) √

参考设计图片
×
 
 
Search Datasheet?

Supported by EEWorld Datasheet

Forum More
Update:2025-06-24 07:22:48

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
community

Robot
development
community

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号