The tutorial explains about the control system of a 4 DoF Robotic Arm
- Teensy 4.1
- Rhino 60rpm 40kgcm 12v Dc Planetary Geared Quad Encoder Servo Motor - 1
- Rhino 30rpm 70kgcm 12v Dc Planetary Geared Quad Encoder Servo Motor - 1
- MG995 Metal Gear Servo Motor - 1
- 12V 100MM Stroke Length Linear Actuator 7mm/S 1500N
- 57HS76-2804 NEMA23 18.9 kg-cm Stepper Motor – Round Type Shaft
- TB6600 Stepper Motor Driver -1
- Cytron DC Motor Driver MD10C -3
- 12 V DC Power supply
- BreadBoard
- Jumper Wires
- Ubuntu 20.04 with ROS Noetic
- VS Code with PlatformIO
-
Name the project, Select Board teensey 4.1
-
Create src/main.cpp, paste the code present in src folder. Change the CPR Value for adjusting the angle of rotation of motor.
-
Go to Include folder and make a file named PositionControl.h and paste the given code.
-
Go to libraries section and search for ros. Download the Rosserial Arduino Library by Michael Ferguson. Select the project name and add project dependency.
-
Add one more library named 'AutoPID' using same method.
-
Compile the Code and upload to teensey.
-
Run the below commands in separate terminals:-
-
Terminal 1:
roscore
- Terminal 2:
rosrun rosserial_arduino serial_node.py /dev/ttyACM0 _baud:=115200
- Terminal 3:
rostopic pub /joint_states sensor_msgs/JointState "header:
seq: 0
stamp: {secs: 0, nsecs: 0}
frame_id: ''
name: ['']
position: [10,10,5,5,5]
velocity: [0]
effort: [0]"-1