Lmproved Software:mycobot 280 In 2023 With More Features
About the project
Get your myCobot 280 upgraded,ROS2 support, improved communication speed and self-interference collision and handle control
Project info
Difficulty: Easy
Platforms: ROS, Elephant Robotics
Estimated time: 1 hour
License: GNU General Public License, version 3 or later (GPL3+)
Items used in this project
Software apps and online services
Story
A robotic arm is a programmable, automated robotic system that can mimic human movements to perform a variety of tasks, such as assembly, painting, packaging, handling, welding, grinding, and more. Due to its high flexibility and versatility, robotic arms have been widely used in modern society.
The myCobot 280 M5Stack 2023 is a high-performance desktop robotic arm that is an ideal choice for education, scientific research, and light manufacturing due to its powerful features and various new capabilities. This robotic arm not only has precise motion control and efficient work capabilities, but also supports new features such as ROS2 environment adaptation, PS2 joystick control, and self-interference collision prevention, making it more intelligent, flexible, and safe. This article will provide a detailed introduction to the new features and application scenarios of myCobot 280 2023, helping readers to gain a deeper understanding of the characteristics and advantages of this robotic arm and exploring how to unleash its potential in education, scientific research, and manufacturing fields.
myCobot 280 2023 introductionThe myCobot 280 is a lightweight desktop robotic arm, weighing 800g, with a repeat positioning accuracy controlled within 0.5 mm, a load capacity of 250g, and a working radius of 280mm. The robotic arm has rich interfaces, supporting mainstream programming languages and environments such as Python, C++, ROS1/2, making it very suitable for use in education, scientific research, and other fields.
New functionsmyCobot 280 2023 has the following new features:
(If you are currently using the first generation of myCobot 280, you can upgrade the firmware to access the new features.)
● Improved communication speed and ROS2 support
● Self-interference collision and handle control
● Compound robot and logistics automation research
Improved communication speed and ROS2 support● The communication speed of myCobot 280 2023 has been improved by five times compared to the previous version and can now achieve 20ms. This improvement can increase the responsiveness of the robotic arm and make control more sensitive, reducing accidents caused by communication. The robot's movement is also faster, reducing the occurrence of accidents.
● myCobot 280 2023 now supports the ROS2 environment, which has two differences from ROS1. First, ROS2 has improved real-time performance, allowing for more precise control of the robot's motion path and speed. This is suitable for applications that require high real-time performance. Second, ROS2 uses the Data Distribution Service (DDS) protocol, which improves network communication performance compared to ROS1, making it more efficient at processing robotic control commands and improving the robot's response speed. However, ROS1 is already widely used in the robotics field and has a relatively complete control library and development environment, making it easy to develop and apply robotics-related software. ROS2 is relatively new and has fewer applications in the market. Therefore, when choosing a control development environment, users need to consider their specific needs and actual situations and choose the most suitable one.
Self-interference collision and handle control● myCobot 280 2023 has added a self-interference collision function, which immediately stops the robot's motion when joint collision occurs, preventing damage caused by abnormal situations during robot operation and improving the robot's safety and reliability. This technology is based on user feedback and research expectations, and it has solved a problem in the past where the entire machine would execute power-off protection when forcing the robot joint to collide, causing trouble for many users. Currently, this technology is not open-source, so the algorithm and principles cannot be disclosed too much.
● There is also a Gamepad control function, which allows users to control the robot's motion and operation with a PS2 game controller and also adds control for suction cups and grippers. This function simplifies the programming process and improves the user experience. The handle control function is based on a set of Python programs and introduces the Pygame library to set the controller's keys (equivalent to customizing the handle). It is a relatively simple project, and those interested can further develop it based on it. The project is open-source and shared on GitHub.
def main():
global action
pygame.init()
pygame.joystick.init()
try:
joystick = pygame.joystick.Joystick(0)
except:
print("Please connect the handle first.")
return
joystick.init()
done = False
start_time = 0
while not done:
for event_ in pygame.event.get():
if event_.type == pygame.QUIT:
done = True
# key down or up event
elif (
event_.type == pygame.JOYBUTTONDOWN or event_.type == pygame.JOYBUTTONUP
):
buttons = joystick.get_numbuttons()
# Get all key state information
for i in range(buttons):
button = joystick.get_button(i)
if i == 7:
if button == 1:
action = 7
break
else:
action = 0
if i == 1:
if button == 1:
action = 11
break
if i == 0:
if button == 1:
action = 10
break
if i == 3:
if button == 1:
action = 9
break
if action == 9 and button == 0:
action = 0
break
if i == 2:
if button == 1:
action = 8
break
if action == 8 and button == 0:
action = 0
break
if i == 4:
if button == 1:
action = 18
start_time = time.time()
break
if start_time != 0 and button == 0:
if time.time() - start_time > 2:
start_time = 0
break
else:
start_time = 0
action = 0
if i == 5:
if button == 1:
action = 21
start_time = time.time()
break
if start_time != 0 and button == 0:
if time.time() - start_time > 2:
start_time = 0
break
else:
start_time = 0
action = 0
# print("button " + str(i) + ": " + str(button))
# pivot event
elif event_.type == pygame.JOYAXISMOTION:
axes = joystick.get_numaxes()
# get all angles data
# while True:
for i in range(axes):
axis = joystick.get_axis(i)
# res[i] = axis
if i == 1:
if axis < -3.0517578125e-05:
action = 1
break
elif axis > -3.0517578125e-05:
action = 2
break
else:
action = 0
if i == 0:
if axis < 0:
action = 3
break
elif axis > 0:
action = 4
break
else:
action = 0
if i == 2:
if axis < 0:
action = 17
break
elif axis > 0:
action = 16
break
else:
action = 0
if i == 3:
if axis < -3.0517578125e-05:
action = 5
break
elif axis > -3.0517578125e-05:
action = 6
break
else:
action = 0
if i == 4:
if axis > 0.9:
action = 19
start_time = time.time()
break
if start_time != 0 and axis == -1.0:
if time.time() - start_time > 2:
start_time = 0
break
else:
start_time = 0
action = 0
if i == 5:
if axis > 0.9:
action = 20
start_time = time.time()
break
if start_time != 0 and axis == -1.0:
if time.time() - start_time > 2:
start_time = 0
break
else:
start_time = 0
action = 0
# print("axis " + str(i) + ": " + str(axis))
# Arrow keys change
elif event_.type == pygame.JOYHATMOTION:
# hats = joystick.get_numhats()
# get all data
# for i in range(hats):
hat = joystick.get_hat(0)
# print("hat " + str(i) +": " + str(hat))
if hat == (0, 1):
action = 12
elif hat == (0, -1):
action = 13
elif hat == (-1, 0):
action = 14
elif hat == (1, 0):
action = 15
elif hat == (0, 0):
action = 0
pygame.quit()
Compound robot and logistics automation research● myCobot 280 2023 can also combine with myAGV, a SLAM radar vehicle controlled by a Raspberry Pi 4B, to form a compound robot that can learn and research logistics automation, navigation, and other functions. This function makes the robot more flexible and versatile in dealing with different scenarios and tasks, improving its comprehensive application ability.
● myAGV: Regarding the vehicle, there are many introduction articles on the hackster site, and some developers use myAGV and myCobot 280 to realize some projects.
SummaryIn general, myCobot 280 2023 is a robotic arm with multiple new features and improvements, greatly enhancing its performance and application range. In addition to improving communication speed, supporting ROS2, and self-interference collision avoidance, we have also introduced the AI Kit 2023, combining machine vision with robotic arms to achieve industrial-like automation scenarios, making the application of robotic arms more extensive and diversified.
Moreover, myCobot 280 2023 has many other features waiting for you to explore, such as drawing, AI sorting and grabbing, etc., which will further expand the application range and innovation of robotic arms. If you have better projects and ideas, please feel free to share them with us. We are very happy to listen to your suggestions and provide you with better service.
If you have any other questions or concerns, please feel free to contact us. We will be happy to assist you.
Credits
Elephant Robotics
Elephant Robotics is a technology firm specializing in the design and production of robotics, development and applications of operating system and intelligent manufacturing services in industry, commerce, education, scientific research, home and etc.
Leave your feedback...