Skip to content

Commit 724dcb1

Browse files
committed
270 add get_modify_version()、clear_queue() API
1 parent 99dc903 commit 724dcb1

File tree

3 files changed

+23
-1
lines changed

3 files changed

+23
-1
lines changed

pymycobot/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@
9999
"MyBuddyEmoticon"
100100
]
101101

102-
__version__ = "3.9.9"
102+
__version__ = "3.9.9b0"
103103
__author__ = "Elephantrobotics"
104104
__email__ = "[email protected]"
105105
__git_url__ = "https://github.com/elephantrobotics/pymycobot"

pymycobot/mecharm270.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -766,6 +766,17 @@ def get_coords_plan(self):
766766
"""
767767
return self._mesg(ProtocolCode.GET_COORDS_PLAN, has_reply=True)
768768

769+
def get_modify_version(self):
770+
"""get modify version
771+
772+
Return: int
773+
"""
774+
return self._mesg(ProtocolCode.MODIFY_VERSION, has_reply=True)
775+
776+
def clear_queue(self):
777+
"""Clear Queue Data"""
778+
return self._mesg(ProtocolCode.CLEAR_COMMAND_QUEUE, has_reply=True)
779+
769780
# Other
770781
def wait(self, t):
771782
time.sleep(t)

pymycobot/mecharmsocket.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -781,6 +781,17 @@ def get_coords_plan(self):
781781
"""
782782
return self._mesg(ProtocolCode.GET_COORDS_PLAN, has_reply=True)
783783

784+
def get_modify_version(self):
785+
"""get modify version
786+
787+
Return: int
788+
"""
789+
return self._mesg(ProtocolCode.MODIFY_VERSION, has_reply=True)
790+
791+
def clear_queue(self):
792+
"""Clear Queue Data"""
793+
return self._mesg(ProtocolCode.CLEAR_COMMAND_QUEUE, has_reply=True)
794+
784795
# Other
785796
def wait(self, t):
786797
time.sleep(t)

0 commit comments

Comments
 (0)