kuavo-humanoid-sdk 1.1.5__py3-none-any.whl → 1.1.6__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of kuavo-humanoid-sdk might be problematic. Click here for more details.

Files changed (50) hide show
  1. kuavo_humanoid_sdk/__init__.py +0 -2
  2. kuavo_humanoid_sdk/interfaces/data_types.py +0 -90
  3. kuavo_humanoid_sdk/kuavo/__init__.py +0 -3
  4. kuavo_humanoid_sdk/kuavo/core/core.py +20 -238
  5. kuavo_humanoid_sdk/kuavo/core/ros/control.py +27 -1087
  6. kuavo_humanoid_sdk/kuavo/core/ros/param.py +4 -142
  7. kuavo_humanoid_sdk/kuavo/core/ros/state.py +19 -556
  8. kuavo_humanoid_sdk/kuavo/core/ros_env.py +1 -229
  9. kuavo_humanoid_sdk/kuavo/dexterous_hand.py +2 -6
  10. kuavo_humanoid_sdk/kuavo/leju_claw.py +2 -6
  11. kuavo_humanoid_sdk/kuavo/robot.py +27 -150
  12. kuavo_humanoid_sdk/kuavo/robot_arm.py +7 -53
  13. kuavo_humanoid_sdk/kuavo/robot_head.py +0 -10
  14. kuavo_humanoid_sdk/kuavo/robot_info.py +2 -7
  15. kuavo_humanoid_sdk/kuavo/robot_state.py +4 -41
  16. kuavo_humanoid_sdk/msg/kuavo_msgs/msg/__init__.py +0 -7
  17. kuavo_humanoid_sdk/msg/kuavo_msgs/srv/__init__.py +0 -5
  18. kuavo_humanoid_sdk/msg/kuavo_msgs/srv/_playmusic.py +20 -26
  19. kuavo_humanoid_sdk/msg/motion_capture_ik/msg/__init__.py +9 -0
  20. kuavo_humanoid_sdk/msg/{kuavo_msgs → motion_capture_ik}/msg/_armHandPose.py +2 -2
  21. kuavo_humanoid_sdk/msg/{kuavo_msgs → motion_capture_ik}/msg/_handPose.py +2 -2
  22. kuavo_humanoid_sdk/msg/motion_capture_ik/msg/_headBodyPose.py +145 -0
  23. kuavo_humanoid_sdk/msg/{kuavo_msgs → motion_capture_ik}/msg/_ikSolveError.py +13 -13
  24. kuavo_humanoid_sdk/msg/{kuavo_msgs → motion_capture_ik}/msg/_ikSolveParam.py +2 -2
  25. kuavo_humanoid_sdk/msg/{kuavo_msgs → motion_capture_ik}/msg/_robotArmQVVD.py +2 -2
  26. kuavo_humanoid_sdk/msg/motion_capture_ik/msg/_robotHandPosition.py +225 -0
  27. kuavo_humanoid_sdk/msg/{kuavo_msgs → motion_capture_ik}/msg/_twoArmHandPose.py +13 -13
  28. kuavo_humanoid_sdk/msg/{kuavo_msgs → motion_capture_ik}/msg/_twoArmHandPoseCmd.py +30 -34
  29. kuavo_humanoid_sdk/msg/motion_capture_ik/srv/__init__.py +4 -0
  30. kuavo_humanoid_sdk/msg/{kuavo_msgs/srv/_setMmCtrlFrame.py → motion_capture_ik/srv/_changeArmCtrlMode.py} +37 -35
  31. kuavo_humanoid_sdk/msg/{kuavo_msgs → motion_capture_ik}/srv/_changeArmCtrlModeKuavo.py +5 -5
  32. kuavo_humanoid_sdk/msg/{kuavo_msgs → motion_capture_ik}/srv/_fkSrv.py +13 -13
  33. kuavo_humanoid_sdk/msg/{kuavo_msgs → motion_capture_ik}/srv/_twoArmHandPoseCmdSrv.py +37 -38
  34. {kuavo_humanoid_sdk-1.1.5.dist-info → kuavo_humanoid_sdk-1.1.6.dist-info}/METADATA +1 -2
  35. {kuavo_humanoid_sdk-1.1.5.dist-info → kuavo_humanoid_sdk-1.1.6.dist-info}/RECORD +37 -46
  36. kuavo_humanoid_sdk/common/global_config.py +0 -16
  37. kuavo_humanoid_sdk/common/websocket_kuavo_sdk.py +0 -23
  38. kuavo_humanoid_sdk/kuavo/core/audio.py +0 -36
  39. kuavo_humanoid_sdk/kuavo/core/ros/audio.py +0 -176
  40. kuavo_humanoid_sdk/kuavo/core/ros/tools.py +0 -158
  41. kuavo_humanoid_sdk/kuavo/core/ros/vision.py +0 -283
  42. kuavo_humanoid_sdk/kuavo/robot_audio.py +0 -39
  43. kuavo_humanoid_sdk/kuavo/robot_tool.py +0 -62
  44. kuavo_humanoid_sdk/kuavo/robot_vision.py +0 -90
  45. kuavo_humanoid_sdk/kuavo_strategy/__init__.py +0 -2
  46. kuavo_humanoid_sdk/kuavo_strategy/grasp_box/grasp_box_strategy.py +0 -418
  47. kuavo_humanoid_sdk/kuavo_strategy/kuavo_strategy.py +0 -63
  48. kuavo_humanoid_sdk/msg/kuavo_msgs/srv/_SpeechSynthesis.py +0 -270
  49. {kuavo_humanoid_sdk-1.1.5.dist-info → kuavo_humanoid_sdk-1.1.6.dist-info}/WHEEL +0 -0
  50. {kuavo_humanoid_sdk-1.1.5.dist-info → kuavo_humanoid_sdk-1.1.6.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,225 @@
1
+ # This Python file uses the following encoding: utf-8
2
+ """autogenerated by genpy from motion_capture_ik/robotHandPosition.msg. Do not edit."""
3
+ import codecs
4
+ import sys
5
+ python3 = True if sys.hexversion > 0x03000000 else False
6
+ import genpy
7
+ import struct
8
+
9
+ import std_msgs.msg
10
+
11
+ class robotHandPosition(genpy.Message):
12
+ _md5sum = "ee45ac8dfb6e0c9a4c7712025fd69d4f"
13
+ _type = "motion_capture_ik/robotHandPosition"
14
+ _has_header = True # flag to mark the presence of a Header object
15
+ _full_text = """Header header
16
+ uint8[] left_hand_position
17
+ uint8[] right_hand_position
18
+ ================================================================================
19
+ MSG: std_msgs/Header
20
+ # Standard metadata for higher-level stamped data types.
21
+ # This is generally used to communicate timestamped data
22
+ # in a particular coordinate frame.
23
+ #
24
+ # sequence ID: consecutively increasing ID
25
+ uint32 seq
26
+ #Two-integer timestamp that is expressed as:
27
+ # * stamp.sec: seconds (stamp_secs) since epoch (in Python the variable is called 'secs')
28
+ # * stamp.nsec: nanoseconds since stamp_secs (in Python the variable is called 'nsecs')
29
+ # time-handling sugar is provided by the client library
30
+ time stamp
31
+ #Frame this data is associated with
32
+ string frame_id
33
+ """
34
+ __slots__ = ['header','left_hand_position','right_hand_position']
35
+ _slot_types = ['std_msgs/Header','uint8[]','uint8[]']
36
+
37
+ def __init__(self, *args, **kwds):
38
+ """
39
+ Constructor. Any message fields that are implicitly/explicitly
40
+ set to None will be assigned a default value. The recommend
41
+ use is keyword arguments as this is more robust to future message
42
+ changes. You cannot mix in-order arguments and keyword arguments.
43
+
44
+ The available fields are:
45
+ header,left_hand_position,right_hand_position
46
+
47
+ :param args: complete set of field values, in .msg order
48
+ :param kwds: use keyword arguments corresponding to message field names
49
+ to set specific fields.
50
+ """
51
+ if args or kwds:
52
+ super(robotHandPosition, self).__init__(*args, **kwds)
53
+ # message fields cannot be None, assign default values for those that are
54
+ if self.header is None:
55
+ self.header = std_msgs.msg.Header()
56
+ if self.left_hand_position is None:
57
+ self.left_hand_position = b''
58
+ if self.right_hand_position is None:
59
+ self.right_hand_position = b''
60
+ else:
61
+ self.header = std_msgs.msg.Header()
62
+ self.left_hand_position = b''
63
+ self.right_hand_position = b''
64
+
65
+ def _get_types(self):
66
+ """
67
+ internal API method
68
+ """
69
+ return self._slot_types
70
+
71
+ def serialize(self, buff):
72
+ """
73
+ serialize message into buffer
74
+ :param buff: buffer, ``StringIO``
75
+ """
76
+ try:
77
+ _x = self
78
+ buff.write(_get_struct_3I().pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs))
79
+ _x = self.header.frame_id
80
+ length = len(_x)
81
+ if python3 or type(_x) == unicode:
82
+ _x = _x.encode('utf-8')
83
+ length = len(_x)
84
+ buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
85
+ _x = self.left_hand_position
86
+ length = len(_x)
87
+ # - if encoded as a list instead, serialize as bytes instead of string
88
+ if type(_x) in [list, tuple]:
89
+ buff.write(struct.Struct('<I%sB'%length).pack(length, *_x))
90
+ else:
91
+ buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
92
+ _x = self.right_hand_position
93
+ length = len(_x)
94
+ # - if encoded as a list instead, serialize as bytes instead of string
95
+ if type(_x) in [list, tuple]:
96
+ buff.write(struct.Struct('<I%sB'%length).pack(length, *_x))
97
+ else:
98
+ buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
99
+ except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
100
+ except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
101
+
102
+ def deserialize(self, str):
103
+ """
104
+ unpack serialized message in str into this message instance
105
+ :param str: byte array of serialized message, ``str``
106
+ """
107
+ if python3:
108
+ codecs.lookup_error("rosmsg").msg_type = self._type
109
+ try:
110
+ if self.header is None:
111
+ self.header = std_msgs.msg.Header()
112
+ end = 0
113
+ _x = self
114
+ start = end
115
+ end += 12
116
+ (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
117
+ start = end
118
+ end += 4
119
+ (length,) = _struct_I.unpack(str[start:end])
120
+ start = end
121
+ end += length
122
+ if python3:
123
+ self.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
124
+ else:
125
+ self.header.frame_id = str[start:end]
126
+ start = end
127
+ end += 4
128
+ (length,) = _struct_I.unpack(str[start:end])
129
+ start = end
130
+ end += length
131
+ self.left_hand_position = str[start:end]
132
+ start = end
133
+ end += 4
134
+ (length,) = _struct_I.unpack(str[start:end])
135
+ start = end
136
+ end += length
137
+ self.right_hand_position = str[start:end]
138
+ return self
139
+ except struct.error as e:
140
+ raise genpy.DeserializationError(e) # most likely buffer underfill
141
+
142
+
143
+ def serialize_numpy(self, buff, numpy):
144
+ """
145
+ serialize message with numpy array types into buffer
146
+ :param buff: buffer, ``StringIO``
147
+ :param numpy: numpy python module
148
+ """
149
+ try:
150
+ _x = self
151
+ buff.write(_get_struct_3I().pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs))
152
+ _x = self.header.frame_id
153
+ length = len(_x)
154
+ if python3 or type(_x) == unicode:
155
+ _x = _x.encode('utf-8')
156
+ length = len(_x)
157
+ buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
158
+ _x = self.left_hand_position
159
+ length = len(_x)
160
+ # - if encoded as a list instead, serialize as bytes instead of string
161
+ if type(_x) in [list, tuple]:
162
+ buff.write(struct.Struct('<I%sB'%length).pack(length, *_x))
163
+ else:
164
+ buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
165
+ _x = self.right_hand_position
166
+ length = len(_x)
167
+ # - if encoded as a list instead, serialize as bytes instead of string
168
+ if type(_x) in [list, tuple]:
169
+ buff.write(struct.Struct('<I%sB'%length).pack(length, *_x))
170
+ else:
171
+ buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
172
+ except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
173
+ except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
174
+
175
+ def deserialize_numpy(self, str, numpy):
176
+ """
177
+ unpack serialized message in str into this message instance using numpy for array types
178
+ :param str: byte array of serialized message, ``str``
179
+ :param numpy: numpy python module
180
+ """
181
+ if python3:
182
+ codecs.lookup_error("rosmsg").msg_type = self._type
183
+ try:
184
+ if self.header is None:
185
+ self.header = std_msgs.msg.Header()
186
+ end = 0
187
+ _x = self
188
+ start = end
189
+ end += 12
190
+ (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
191
+ start = end
192
+ end += 4
193
+ (length,) = _struct_I.unpack(str[start:end])
194
+ start = end
195
+ end += length
196
+ if python3:
197
+ self.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
198
+ else:
199
+ self.header.frame_id = str[start:end]
200
+ start = end
201
+ end += 4
202
+ (length,) = _struct_I.unpack(str[start:end])
203
+ start = end
204
+ end += length
205
+ self.left_hand_position = str[start:end]
206
+ start = end
207
+ end += 4
208
+ (length,) = _struct_I.unpack(str[start:end])
209
+ start = end
210
+ end += length
211
+ self.right_hand_position = str[start:end]
212
+ return self
213
+ except struct.error as e:
214
+ raise genpy.DeserializationError(e) # most likely buffer underfill
215
+
216
+ _struct_I = genpy.struct_I
217
+ def _get_struct_I():
218
+ global _struct_I
219
+ return _struct_I
220
+ _struct_3I = None
221
+ def _get_struct_3I():
222
+ global _struct_3I
223
+ if _struct_3I is None:
224
+ _struct_3I = struct.Struct("<3I")
225
+ return _struct_3I
@@ -1,17 +1,17 @@
1
1
  # This Python file uses the following encoding: utf-8
2
- """autogenerated by genpy from kuavo_msgs/twoArmHandPose.msg. Do not edit."""
2
+ """autogenerated by genpy from motion_capture_ik/twoArmHandPose.msg. Do not edit."""
3
3
  import codecs
4
4
  import sys
5
5
  python3 = True if sys.hexversion > 0x03000000 else False
6
6
  import genpy
7
7
  import struct
8
8
 
9
- import kuavo_msgs.msg
9
+ import motion_capture_ik.msg
10
10
  import std_msgs.msg
11
11
 
12
12
  class twoArmHandPose(genpy.Message):
13
13
  _md5sum = "5bdb1e027f430369b6f88e5e2f5d31ca"
14
- _type = "kuavo_msgs/twoArmHandPose"
14
+ _type = "motion_capture_ik/twoArmHandPose"
15
15
  _has_header = True # flag to mark the presence of a Header object
16
16
  _full_text = """Header header
17
17
  armHandPose left_pose
@@ -33,7 +33,7 @@ time stamp
33
33
  string frame_id
34
34
 
35
35
  ================================================================================
36
- MSG: kuavo_msgs/armHandPose
36
+ MSG: motion_capture_ik/armHandPose
37
37
  float64[3] pos_xyz
38
38
  float64[4] quat_xyzw
39
39
 
@@ -41,7 +41,7 @@ float64[3] elbow_pos_xyz
41
41
 
42
42
  float64[7] joint_angles"""
43
43
  __slots__ = ['header','left_pose','right_pose']
44
- _slot_types = ['std_msgs/Header','kuavo_msgs/armHandPose','kuavo_msgs/armHandPose']
44
+ _slot_types = ['std_msgs/Header','motion_capture_ik/armHandPose','motion_capture_ik/armHandPose']
45
45
 
46
46
  def __init__(self, *args, **kwds):
47
47
  """
@@ -63,13 +63,13 @@ float64[7] joint_angles"""
63
63
  if self.header is None:
64
64
  self.header = std_msgs.msg.Header()
65
65
  if self.left_pose is None:
66
- self.left_pose = kuavo_msgs.msg.armHandPose()
66
+ self.left_pose = motion_capture_ik.msg.armHandPose()
67
67
  if self.right_pose is None:
68
- self.right_pose = kuavo_msgs.msg.armHandPose()
68
+ self.right_pose = motion_capture_ik.msg.armHandPose()
69
69
  else:
70
70
  self.header = std_msgs.msg.Header()
71
- self.left_pose = kuavo_msgs.msg.armHandPose()
72
- self.right_pose = kuavo_msgs.msg.armHandPose()
71
+ self.left_pose = motion_capture_ik.msg.armHandPose()
72
+ self.right_pose = motion_capture_ik.msg.armHandPose()
73
73
 
74
74
  def _get_types(self):
75
75
  """
@@ -113,9 +113,9 @@ float64[7] joint_angles"""
113
113
  if self.header is None:
114
114
  self.header = std_msgs.msg.Header()
115
115
  if self.left_pose is None:
116
- self.left_pose = kuavo_msgs.msg.armHandPose()
116
+ self.left_pose = motion_capture_ik.msg.armHandPose()
117
117
  if self.right_pose is None:
118
- self.right_pose = kuavo_msgs.msg.armHandPose()
118
+ self.right_pose = motion_capture_ik.msg.armHandPose()
119
119
  end = 0
120
120
  _x = self
121
121
  start = end
@@ -197,9 +197,9 @@ float64[7] joint_angles"""
197
197
  if self.header is None:
198
198
  self.header = std_msgs.msg.Header()
199
199
  if self.left_pose is None:
200
- self.left_pose = kuavo_msgs.msg.armHandPose()
200
+ self.left_pose = motion_capture_ik.msg.armHandPose()
201
201
  if self.right_pose is None:
202
- self.right_pose = kuavo_msgs.msg.armHandPose()
202
+ self.right_pose = motion_capture_ik.msg.armHandPose()
203
203
  end = 0
204
204
  _x = self
205
205
  start = end
@@ -1,26 +1,25 @@
1
1
  # This Python file uses the following encoding: utf-8
2
- """autogenerated by genpy from kuavo_msgs/twoArmHandPoseCmd.msg. Do not edit."""
2
+ """autogenerated by genpy from motion_capture_ik/twoArmHandPoseCmd.msg. Do not edit."""
3
3
  import codecs
4
4
  import sys
5
5
  python3 = True if sys.hexversion > 0x03000000 else False
6
6
  import genpy
7
7
  import struct
8
8
 
9
- import kuavo_msgs.msg
9
+ import motion_capture_ik.msg
10
10
  import std_msgs.msg
11
11
 
12
12
  class twoArmHandPoseCmd(genpy.Message):
13
- _md5sum = "cd5f0a3dc4154eb55aff1c874e2dc81e"
14
- _type = "kuavo_msgs/twoArmHandPoseCmd"
13
+ _md5sum = "d4b6792a6f960bea428fd7158220110b"
14
+ _type = "motion_capture_ik/twoArmHandPoseCmd"
15
15
  _has_header = False # flag to mark the presence of a Header object
16
16
  _full_text = """twoArmHandPose hand_poses
17
17
  # params for the IK solver
18
18
  bool use_custom_ik_param
19
19
  bool joint_angles_as_q0
20
20
  ikSolveParam ik_param
21
- int32 frame # 0 keep current frame 1 world frame (based on odom) 2 local frame 3 manipulation world frame
22
21
  ================================================================================
23
- MSG: kuavo_msgs/twoArmHandPose
22
+ MSG: motion_capture_ik/twoArmHandPose
24
23
  Header header
25
24
  armHandPose left_pose
26
25
  armHandPose right_pose
@@ -41,7 +40,7 @@ time stamp
41
40
  string frame_id
42
41
 
43
42
  ================================================================================
44
- MSG: kuavo_msgs/armHandPose
43
+ MSG: motion_capture_ik/armHandPose
45
44
  float64[3] pos_xyz
46
45
  float64[4] quat_xyzw
47
46
 
@@ -49,7 +48,7 @@ float64[3] elbow_pos_xyz
49
48
 
50
49
  float64[7] joint_angles
51
50
  ================================================================================
52
- MSG: kuavo_msgs/ikSolveParam
51
+ MSG: motion_capture_ik/ikSolveParam
53
52
  # snopt params
54
53
  float64 major_optimality_tol
55
54
  float64 major_feasibility_tol
@@ -59,8 +58,8 @@ float64 major_iterations_limit
59
58
  float64 oritation_constraint_tol
60
59
  float64 pos_constraint_tol # work when pos_cost_weight > 0.0
61
60
  float64 pos_cost_weight"""
62
- __slots__ = ['hand_poses','use_custom_ik_param','joint_angles_as_q0','ik_param','frame']
63
- _slot_types = ['kuavo_msgs/twoArmHandPose','bool','bool','kuavo_msgs/ikSolveParam','int32']
61
+ __slots__ = ['hand_poses','use_custom_ik_param','joint_angles_as_q0','ik_param']
62
+ _slot_types = ['motion_capture_ik/twoArmHandPose','bool','bool','motion_capture_ik/ikSolveParam']
64
63
 
65
64
  def __init__(self, *args, **kwds):
66
65
  """
@@ -70,7 +69,7 @@ float64 pos_cost_weight"""
70
69
  changes. You cannot mix in-order arguments and keyword arguments.
71
70
 
72
71
  The available fields are:
73
- hand_poses,use_custom_ik_param,joint_angles_as_q0,ik_param,frame
72
+ hand_poses,use_custom_ik_param,joint_angles_as_q0,ik_param
74
73
 
75
74
  :param args: complete set of field values, in .msg order
76
75
  :param kwds: use keyword arguments corresponding to message field names
@@ -80,21 +79,18 @@ float64 pos_cost_weight"""
80
79
  super(twoArmHandPoseCmd, self).__init__(*args, **kwds)
81
80
  # message fields cannot be None, assign default values for those that are
82
81
  if self.hand_poses is None:
83
- self.hand_poses = kuavo_msgs.msg.twoArmHandPose()
82
+ self.hand_poses = motion_capture_ik.msg.twoArmHandPose()
84
83
  if self.use_custom_ik_param is None:
85
84
  self.use_custom_ik_param = False
86
85
  if self.joint_angles_as_q0 is None:
87
86
  self.joint_angles_as_q0 = False
88
87
  if self.ik_param is None:
89
- self.ik_param = kuavo_msgs.msg.ikSolveParam()
90
- if self.frame is None:
91
- self.frame = 0
88
+ self.ik_param = motion_capture_ik.msg.ikSolveParam()
92
89
  else:
93
- self.hand_poses = kuavo_msgs.msg.twoArmHandPose()
90
+ self.hand_poses = motion_capture_ik.msg.twoArmHandPose()
94
91
  self.use_custom_ik_param = False
95
92
  self.joint_angles_as_q0 = False
96
- self.ik_param = kuavo_msgs.msg.ikSolveParam()
97
- self.frame = 0
93
+ self.ik_param = motion_capture_ik.msg.ikSolveParam()
98
94
 
99
95
  def _get_types(self):
100
96
  """
@@ -125,7 +121,7 @@ float64 pos_cost_weight"""
125
121
  buff.write(_get_struct_3d().pack(*self.hand_poses.right_pose.elbow_pos_xyz))
126
122
  buff.write(_get_struct_7d().pack(*self.hand_poses.right_pose.joint_angles))
127
123
  _x = self
128
- buff.write(_get_struct_2B7di().pack(_x.use_custom_ik_param, _x.joint_angles_as_q0, _x.ik_param.major_optimality_tol, _x.ik_param.major_feasibility_tol, _x.ik_param.minor_feasibility_tol, _x.ik_param.major_iterations_limit, _x.ik_param.oritation_constraint_tol, _x.ik_param.pos_constraint_tol, _x.ik_param.pos_cost_weight, _x.frame))
124
+ buff.write(_get_struct_2B7d().pack(_x.use_custom_ik_param, _x.joint_angles_as_q0, _x.ik_param.major_optimality_tol, _x.ik_param.major_feasibility_tol, _x.ik_param.minor_feasibility_tol, _x.ik_param.major_iterations_limit, _x.ik_param.oritation_constraint_tol, _x.ik_param.pos_constraint_tol, _x.ik_param.pos_cost_weight))
129
125
  except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
130
126
  except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
131
127
 
@@ -138,9 +134,9 @@ float64 pos_cost_weight"""
138
134
  codecs.lookup_error("rosmsg").msg_type = self._type
139
135
  try:
140
136
  if self.hand_poses is None:
141
- self.hand_poses = kuavo_msgs.msg.twoArmHandPose()
137
+ self.hand_poses = motion_capture_ik.msg.twoArmHandPose()
142
138
  if self.ik_param is None:
143
- self.ik_param = kuavo_msgs.msg.ikSolveParam()
139
+ self.ik_param = motion_capture_ik.msg.ikSolveParam()
144
140
  end = 0
145
141
  _x = self
146
142
  start = end
@@ -181,8 +177,8 @@ float64 pos_cost_weight"""
181
177
  self.hand_poses.right_pose.joint_angles = _get_struct_7d().unpack(str[start:end])
182
178
  _x = self
183
179
  start = end
184
- end += 62
185
- (_x.use_custom_ik_param, _x.joint_angles_as_q0, _x.ik_param.major_optimality_tol, _x.ik_param.major_feasibility_tol, _x.ik_param.minor_feasibility_tol, _x.ik_param.major_iterations_limit, _x.ik_param.oritation_constraint_tol, _x.ik_param.pos_constraint_tol, _x.ik_param.pos_cost_weight, _x.frame,) = _get_struct_2B7di().unpack(str[start:end])
180
+ end += 58
181
+ (_x.use_custom_ik_param, _x.joint_angles_as_q0, _x.ik_param.major_optimality_tol, _x.ik_param.major_feasibility_tol, _x.ik_param.minor_feasibility_tol, _x.ik_param.major_iterations_limit, _x.ik_param.oritation_constraint_tol, _x.ik_param.pos_constraint_tol, _x.ik_param.pos_cost_weight,) = _get_struct_2B7d().unpack(str[start:end])
186
182
  self.use_custom_ik_param = bool(self.use_custom_ik_param)
187
183
  self.joint_angles_as_q0 = bool(self.joint_angles_as_q0)
188
184
  return self
@@ -214,7 +210,7 @@ float64 pos_cost_weight"""
214
210
  buff.write(self.hand_poses.right_pose.elbow_pos_xyz.tostring())
215
211
  buff.write(self.hand_poses.right_pose.joint_angles.tostring())
216
212
  _x = self
217
- buff.write(_get_struct_2B7di().pack(_x.use_custom_ik_param, _x.joint_angles_as_q0, _x.ik_param.major_optimality_tol, _x.ik_param.major_feasibility_tol, _x.ik_param.minor_feasibility_tol, _x.ik_param.major_iterations_limit, _x.ik_param.oritation_constraint_tol, _x.ik_param.pos_constraint_tol, _x.ik_param.pos_cost_weight, _x.frame))
213
+ buff.write(_get_struct_2B7d().pack(_x.use_custom_ik_param, _x.joint_angles_as_q0, _x.ik_param.major_optimality_tol, _x.ik_param.major_feasibility_tol, _x.ik_param.minor_feasibility_tol, _x.ik_param.major_iterations_limit, _x.ik_param.oritation_constraint_tol, _x.ik_param.pos_constraint_tol, _x.ik_param.pos_cost_weight))
218
214
  except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
219
215
  except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))
220
216
 
@@ -228,9 +224,9 @@ float64 pos_cost_weight"""
228
224
  codecs.lookup_error("rosmsg").msg_type = self._type
229
225
  try:
230
226
  if self.hand_poses is None:
231
- self.hand_poses = kuavo_msgs.msg.twoArmHandPose()
227
+ self.hand_poses = motion_capture_ik.msg.twoArmHandPose()
232
228
  if self.ik_param is None:
233
- self.ik_param = kuavo_msgs.msg.ikSolveParam()
229
+ self.ik_param = motion_capture_ik.msg.ikSolveParam()
234
230
  end = 0
235
231
  _x = self
236
232
  start = end
@@ -271,8 +267,8 @@ float64 pos_cost_weight"""
271
267
  self.hand_poses.right_pose.joint_angles = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=7)
272
268
  _x = self
273
269
  start = end
274
- end += 62
275
- (_x.use_custom_ik_param, _x.joint_angles_as_q0, _x.ik_param.major_optimality_tol, _x.ik_param.major_feasibility_tol, _x.ik_param.minor_feasibility_tol, _x.ik_param.major_iterations_limit, _x.ik_param.oritation_constraint_tol, _x.ik_param.pos_constraint_tol, _x.ik_param.pos_cost_weight, _x.frame,) = _get_struct_2B7di().unpack(str[start:end])
270
+ end += 58
271
+ (_x.use_custom_ik_param, _x.joint_angles_as_q0, _x.ik_param.major_optimality_tol, _x.ik_param.major_feasibility_tol, _x.ik_param.minor_feasibility_tol, _x.ik_param.major_iterations_limit, _x.ik_param.oritation_constraint_tol, _x.ik_param.pos_constraint_tol, _x.ik_param.pos_cost_weight,) = _get_struct_2B7d().unpack(str[start:end])
276
272
  self.use_custom_ik_param = bool(self.use_custom_ik_param)
277
273
  self.joint_angles_as_q0 = bool(self.joint_angles_as_q0)
278
274
  return self
@@ -283,12 +279,12 @@ _struct_I = genpy.struct_I
283
279
  def _get_struct_I():
284
280
  global _struct_I
285
281
  return _struct_I
286
- _struct_2B7di = None
287
- def _get_struct_2B7di():
288
- global _struct_2B7di
289
- if _struct_2B7di is None:
290
- _struct_2B7di = struct.Struct("<2B7di")
291
- return _struct_2B7di
282
+ _struct_2B7d = None
283
+ def _get_struct_2B7d():
284
+ global _struct_2B7d
285
+ if _struct_2B7d is None:
286
+ _struct_2B7d = struct.Struct("<2B7d")
287
+ return _struct_2B7d
292
288
  _struct_3I = None
293
289
  def _get_struct_3I():
294
290
  global _struct_3I
@@ -0,0 +1,4 @@
1
+ from ._changeArmCtrlMode import *
2
+ from ._changeArmCtrlModeKuavo import *
3
+ from ._fkSrv import *
4
+ from ._twoArmHandPoseCmdSrv import *