Skip to content

Commit 615ae97

Browse files
author
Your Name
committed
New remove collision object service now used
1 parent 43a0d68 commit 615ae97

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

armer/robots/ROSRobot.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -558,7 +558,7 @@ def __init__(self,
558558

559559
rospy.Service(
560560
'{}/remove_collision_object'.format(self.name.lower()),
561-
AddCollisionObject,
561+
RemoveCollisionObject,
562562
self.remove_collision_obj_cb
563563
)
564564

@@ -1973,7 +1973,7 @@ def add_collision_obj_cb(self, req: AddCollisionObjectRequest) -> AddCollisionOb
19731973

19741974
return AddCollisionObjectResponse(success=True)
19751975

1976-
def remove_collision_obj_cb(self, req: AddCollisionObjectRequest) -> AddCollisionObjectResponse:
1976+
def remove_collision_obj_cb(self, req: RemoveCollisionObjectRequest) -> RemoveCollisionObjectResponse:
19771977
"""
19781978
This will take a given key and (if it exists) and removes said key object as a collision shape
19791979
NOTE: currently expects the following
@@ -1982,7 +1982,7 @@ def remove_collision_obj_cb(self, req: AddCollisionObjectRequest) -> AddCollisio
19821982
# Handle early termination on input error for name and type
19831983
if req.name == None or req.name == '':
19841984
rospy.logerr(f"[REMOVE COLLISION OBJ CB] -> Remove collision object service input error: name [{req.name}] | type [{req.type}]")
1985-
return AddCollisionObjectResponse(success=False)
1985+
return RemoveCollisionObjectResponse(success=False)
19861986

19871987
if req.name in self.collision_dict.keys():
19881988
# Stage Backend to Remove Object
@@ -2000,7 +2000,7 @@ def remove_collision_obj_cb(self, req: AddCollisionObjectRequest) -> AddCollisio
20002000
self.interactive_marker_server.erase(name=req.name)
20012001
self.interactive_marker_server.applyChanges()
20022002

2003-
return AddCollisionObjectResponse(success=True)
2003+
return RemoveCollisionObjectResponse(success=True)
20042004
else:
20052005
rospy.logerr(f"[REMOVE COLLISION OBJ CB] -> Unknown name [{req.name}] requested; not in collision dictionary")
20062006

0 commit comments

Comments
 (0)