File tree Expand file tree Collapse file tree 2 files changed +10
-16
lines changed
challenge_speech_recognition Expand file tree Collapse file tree 2 files changed +10
-16
lines changed Original file line number Diff line number Diff line change 13
13
14
14
<buildtool_depend >catkin</buildtool_depend >
15
15
16
- <build_depend >geometry_msgs</build_depend >
17
- <build_depend >robot_skills</build_depend >
18
- <build_depend >robot_smach_states</build_depend >
19
- <build_depend >rospy</build_depend >
20
- <build_depend >tf</build_depend >
21
-
22
- <exec_depend >geometry_msgs</exec_depend >
23
- <exec_depend >robot_skills</exec_depend >
24
- <exec_depend >robot_smach_states</exec_depend >
25
- <exec_depend >rospy</exec_depend >
26
- <exec_depend >tf</exec_depend >
16
+ <depend >pykdl_ros</depend >
17
+ <depend >robot_skills</depend >
18
+ <depend >robot_smach_states</depend >
19
+ <depend >rospy</depend >
27
20
28
21
</package >
Original file line number Diff line number Diff line change 2
2
3
3
from __future__ import print_function
4
4
5
- import rospy
6
- import smach
7
5
import sys
8
6
import random
9
7
import math
10
8
import time
11
9
10
+ from pykdl_ros import VectorStamped
11
+ import rospy
12
+ import smach
12
13
13
14
import robot_smach_states as states
14
15
@@ -53,7 +54,7 @@ def _turn_to_closest_entity(self):
53
54
operator = None
54
55
while not operator :
55
56
operator = self .robot .ed .get_closest_entity (self , radius = 1.9 ,
56
- center_point = self .robot .base .get_location (). extractVectorStamped ( ))
57
+ center_point = VectorStamped . from_framestamped ( self .robot .base .get_location ()))
57
58
print (operator )
58
59
if not operator :
59
60
vth = 0.5
@@ -66,8 +67,8 @@ def _turn_to_closest_entity(self):
66
67
# Turn towards the operator
67
68
current = self .robot .base .get_location ()
68
69
robot_th = current .frame .M .GetRPY ()[2 ] # Get the Yaw, rotation around Z
69
- desired_th = math .atan2 (operator ._pose .p .y () - current .frame .p .y (),
70
- operator ._pose .p .x () - current .frame .p .x ())
70
+ desired_th = math .atan2 (operator .pose . frame .p .y () - current .frame .p .y (),
71
+ operator .pose . frame .p .x () - current .frame .p .x ())
71
72
72
73
# Calculate params
73
74
th = desired_th - robot_th
You can’t perform that action at this time.
0 commit comments