From a8515fe713e8b16b93296cdedf2eae26faac1508 Mon Sep 17 00:00:00 2001 From: Morten Lind Date: Tue, 12 Feb 2019 18:17:36 +0100 Subject: [PATCH] Conditional pose 'p' prefix in movexs. --- urx/urrobot.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/urx/urrobot.py b/urx/urrobot.py index d4d441f..cf7beb5 100644 --- a/urx/urrobot.py +++ b/urx/urrobot.py @@ -401,10 +401,13 @@ class URRobot(object): raise RobotException( 'movexs: "radius" must be a number or a list ' + 'of numbers the same length as "pose_list"!') + prefix = '' + if command in ['movel', 'movec']: + prefix = 'p' for idx, pose in enumerate(pose_list): prog += self._format_move(command, pose, acc, vel[idx], radius[idx], - prefix="p") + "\n" + prefix=prefix) + "\n" prog += end self.send_program(prog) if wait: