Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
I
isr_cobot
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Rodrigo Ventura
isr_cobot
Commits
43c1c146
Commit
43c1c146
authored
Jul 10, 2015
by
yoda
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dynamic vref supported by navigation_by_target
parent
b4a37471
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
0 deletions
+19
-0
rosbuild/scout_navigation/navgoal.py
rosbuild/scout_navigation/navgoal.py
+19
-0
No files found.
rosbuild/scout_navigation/navgoal.py
View file @
43c1c146
...
...
@@ -247,6 +247,8 @@ class NavGoalDynamic(NavGoalBase):
mode
=
None
cached_goal
=
None
last_solve
=
None
vref
=
None
sub_vref
=
None
# -- WIP --
...
...
@@ -391,8 +393,24 @@ class NavGoalDynamic(NavGoalBase):
else
:
raise
Exception
,
"unknown mode %s"
%
(
self
.
mode
)
def
reference_speed
(
self
):
return
self
.
vref
def
disable
(
self
):
if
self
.
sub_vref
is
not
None
:
self
.
sub_vref
.
unregister
()
def
vref_handler
(
self
,
msg
):
self
.
vref
=
msg
.
data
## setup methods
def
setup_topics
(
self
):
"""setup external parameterization toipic handlers"""
if
self
.
sub_vref
is
not
None
:
self
.
sub_vref
.
unregister
()
self
.
sub_vref
=
rospy
.
Subscriber
(
TOPIC_VREF
,
Float64
,
self
.
vref_handler
)
def
set_dynamic_goal
(
self
,
target_frame
,
heading_frame
=
None
,
proximity
=
0
,
follow_target
=
False
):
"""follow frame target_frame with a proximity distance (body) heading to target_frame; success upon reaching if follow_target True"""
self
.
target_frame
=
target_frame
...
...
@@ -412,6 +430,7 @@ class NavGoalDynamic(NavGoalBase):
rospy
.
logerr
(
"set_dynamic_goal(): heading transform '%s' timed out"
%
(
target_frame
))
return
False
self
.
mode
=
'near'
self
.
setup_topics
()
return
True
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment