mirror of
https://github.com/elephantrobotics/mycobot_ros.git
synced 2026-07-03 02:27:04 +00:00
my系列ROS代码适配新版pymycobot库2
This commit is contained in:
parent
399a27f405
commit
f4c666ae9b
62 changed files with 251 additions and 189 deletions
|
|
@ -11,11 +11,12 @@ from visualization_msgs.msg import Marker
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MechArm270
|
||||
|
|
|
|||
|
|
@ -17,11 +17,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MechArm270
|
||||
|
|
|
|||
|
|
@ -9,11 +9,12 @@ from mecharm_communication.srv import *
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MechArm270
|
||||
|
|
|
|||
|
|
@ -20,14 +20,15 @@ from mycobot_communication.msg import (
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.5.3'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot.mycobot import MyCobot
|
||||
from pymycobot import MechArm270
|
||||
|
||||
|
||||
class Watcher:
|
||||
|
|
@ -85,7 +86,7 @@ class MycobotTopics(object):
|
|||
port = rospy.get_param("~port", os.popen("ls /dev/ttyACM*").readline()[:-1])
|
||||
baud = rospy.get_param("~baud", 115200)
|
||||
rospy.loginfo("%s,%s" % (port, baud))
|
||||
self.mc = MyCobot(port, baud)
|
||||
self.mc = MechArm270(port, baud)
|
||||
self.lock = threading.Lock()
|
||||
|
||||
def start(self):
|
||||
|
|
|
|||
|
|
@ -20,11 +20,12 @@ from mecharm_communication.msg import (
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MechArm270
|
||||
|
|
|
|||
|
|
@ -8,11 +8,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MechArm270
|
||||
|
|
|
|||
|
|
@ -11,11 +11,12 @@ from visualization_msgs.msg import Marker
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MechArm270
|
||||
|
|
|
|||
|
|
@ -17,11 +17,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MechArm270
|
||||
|
|
|
|||
|
|
@ -7,11 +7,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MechArm270
|
||||
|
|
|
|||
|
|
@ -9,11 +9,12 @@ from visualization_msgs.msg import Marker
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -10,11 +10,12 @@ from visualization_msgs.msg import Marker
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -15,11 +15,12 @@ from rospy import ServiceException
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -16,11 +16,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -15,11 +15,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -6,11 +6,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -7,11 +7,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -9,11 +9,12 @@ from visualization_msgs.msg import Marker
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -16,11 +16,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -2,11 +2,12 @@ import time
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -7,11 +7,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -9,11 +9,12 @@ from visualization_msgs.msg import Marker
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -16,11 +16,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -16,11 +16,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -16,11 +16,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -3,11 +3,12 @@ import time
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot.mycobot280socket import MyCobot280Socket
|
||||
|
|
|
|||
|
|
@ -16,11 +16,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -7,11 +7,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -10,11 +10,12 @@ from visualization_msgs.msg import Marker
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -17,11 +17,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -8,11 +8,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -13,11 +13,12 @@ from moving_utils import Movement
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MechArm270
|
||||
|
|
|
|||
|
|
@ -23,11 +23,12 @@ from moving_utils import Movement
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MechArm270
|
||||
|
|
|
|||
|
|
@ -13,11 +13,12 @@ from moving_utils import Movement
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -25,11 +25,12 @@ from moving_utils import Movement
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -13,11 +13,12 @@ from moving_utils import Movement
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyPalletizer260
|
||||
|
|
|
|||
|
|
@ -23,11 +23,12 @@ from moving_utils import Movement
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyPalletizer260
|
||||
|
|
|
|||
|
|
@ -9,11 +9,12 @@ from moving_utils import Movement
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -10,11 +10,12 @@ import RPi.GPIO as GPIO
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -10,11 +10,12 @@ from moving_utils import Movement
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -9,11 +9,12 @@ from moving_utils import Movement
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -9,11 +9,12 @@ from moving_utils import Movement
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot320
|
||||
|
|
@ -218,7 +219,7 @@ class Object_detect(Movement):
|
|||
# init mycobot320
|
||||
def run(self):
|
||||
if "dev" in self.robot_raspi:
|
||||
self.mc = MyCobot280(self.robot_raspi, 115200)
|
||||
self.mc = MyCobot320(self.robot_raspi, 115200)
|
||||
self.pump_off()
|
||||
self.mc.send_angles([0.61, 45.87, -92.37, -41.3, 89.56, 9.58], 20)
|
||||
time.sleep(2.5)
|
||||
|
|
|
|||
|
|
@ -9,11 +9,12 @@ from moving_utils import Movement
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot320
|
||||
|
|
|
|||
|
|
@ -9,11 +9,12 @@ from moving_utils import Movement
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot320
|
||||
|
|
|
|||
|
|
@ -10,11 +10,12 @@ from moving_utils import Movement
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot320
|
||||
|
|
|
|||
|
|
@ -10,11 +10,12 @@ from moving_utils import Movement
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot320
|
||||
|
|
|
|||
|
|
@ -10,11 +10,12 @@ from moving_utils import Movement
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot320
|
||||
|
|
|
|||
|
|
@ -9,11 +9,12 @@ from moving_utils import Movement
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot320
|
||||
|
|
|
|||
|
|
@ -9,11 +9,12 @@ from mycobot_communication.srv import *
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -23,11 +23,12 @@ from std_msgs.msg import UInt8
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -20,11 +20,12 @@ from mycobot_communication.msg import (
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
# from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -20,11 +20,12 @@ from mycobot_communication.msg import (
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -21,11 +21,12 @@ from mycobot_communication.msg import (
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyCobot280
|
||||
|
|
|
|||
|
|
@ -11,11 +11,12 @@ from visualization_msgs.msg import Marker
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyPalletizer260
|
||||
|
|
|
|||
|
|
@ -17,11 +17,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyPalletizer260
|
||||
|
|
|
|||
|
|
@ -7,11 +7,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyPalletizer260
|
||||
|
|
|
|||
|
|
@ -10,11 +10,12 @@ from visualization_msgs.msg import Marker
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyPalletizer260
|
||||
|
|
|
|||
|
|
@ -17,11 +17,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyPalletizer260
|
||||
|
|
|
|||
|
|
@ -8,11 +8,12 @@ from sensor_msgs.msg import JointState
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyPalletizer260
|
||||
|
|
|
|||
|
|
@ -8,11 +8,12 @@ from mypalletizer_communication.srv import *
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot import MyPalletizer260
|
||||
|
|
|
|||
|
|
@ -17,11 +17,12 @@ from mypalletizer_communication.msg import(
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot.mypalletizer260 import MyPalletizer260
|
||||
|
|
|
|||
|
|
@ -17,11 +17,12 @@ from mypalletizer_communication.msg import(
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot.mypalletizer260 import MyPalletizer260
|
||||
|
|
|
|||
|
|
@ -19,11 +19,12 @@ from mypalletizer_communication import (
|
|||
import pymycobot
|
||||
from packaging import version
|
||||
# min low version require
|
||||
MAX_REQUIRE_VERSION = '3.6.1'
|
||||
MIN_REQUIRE_VERSION = '3.6.1'
|
||||
|
||||
current_verison = pymycobot.__version__
|
||||
print('current pymycobot library version: {}'.format(current_verison))
|
||||
if version.parse(current_verison) > version.parse(MAX_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be less than {} . The current version is {}. Please downgrade the library version.'.format(MAX_REQUIRE_VERSION, current_verison))
|
||||
if version.parse(current_verison) < version.parse(MIN_REQUIRE_VERSION):
|
||||
raise RuntimeError('The version of pymycobot library must be greater than {} or higher. The current version is {}. Please upgrade the library version.'.format(MIN_REQUIRE_VERSION, current_verison))
|
||||
else:
|
||||
print('pymycobot library version meets the requirements!')
|
||||
from pymycobot.mypalletizer260 import MyPalletizer260
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue