![]() |
SecurBot
0.1
A cutting edge robotic security platform
|
Classes | |
class | Status |
Functions | |
def | waypointToPixelPoseStamped (waypointObject) |
Format Waypoint to Pixel PoseStamped. More... | |
def | pixelPoseStampedToRealPoseStamped (pixelPoseStamped) |
Publish Pixel PoseStamped to map_image_generator to format it into Real PoseStamped. More... | |
def | realPoseStampedReceiverCallback (realPoseStamped) |
Callback funtion receiving processed waypoint from map_image. More... | |
def | startPatrolNavigation () |
This function starts sending the different waypoint that were converted in the list. More... | |
def | waypointsListReceiverCallback (waypointsJsonStr) |
Callback funtion that handles the reception of new patrol plans. More... | |
def | interruptReceiverCallback (interruptJsonStr) |
Interprets interruption requests. More... | |
def | getStatusString (uInt8Status) |
Returns status as a string, used primarly for debugging purposes. More... | |
def | publishPatrolFeedBack (patrolId, status, acheivedWaypointCount, plannedWaypointCount) |
Publishes the advancement of a patrol. More... | |
def | sendGoalDoneCallback (terminalState, result) |
Callback function called when an action sent to move_base is done. More... | |
def | patrolExecutive () |
Main function starting the Patrol Executive Node. More... | |
Variables | |
int | PIXEL_POSESTAMPED_INDEX = 1 |
int | REAL_POSESTAMPED_INDEX = 2 |
actionClient = actionlib.SimpleActionClient('move_base', MoveBaseAction) | |
list | waypointsPatrolList = [] |
int | currentWaypointIndex = 0 |
bool | isLooped = False |
string | patrolId = "" |
toMapImageGenerator = rospy.Publisher("toMapImageGenerator", PoseStamped, queue_size=20) | |
toElectron = rospy.Publisher("toElectron", String, queue_size=20) | |
def patrolExecutive.getStatusString | ( | uInt8Status | ) |
Returns status as a string, used primarly for debugging purposes.
uInt8Status | move_base status code |
def patrolExecutive.interruptReceiverCallback | ( | interruptJsonStr | ) |
Interprets interruption requests.
Will stop patrol and send confirmation if patrol plan is stopped.
interruptJsonStr | The ROS message containing the JSON string with the interrupt message. |
def patrolExecutive.patrolExecutive | ( | ) |
Main function starting the Patrol Executive Node.
Subcription to three topics are made : fromMapimageGenerator, fromElectronWaypoints, fromElectronInterrupt.
def patrolExecutive.pixelPoseStampedToRealPoseStamped | ( | pixelPoseStamped | ) |
Publish Pixel PoseStamped to map_image_generator to format it into Real PoseStamped.
pixelPoseStamped | The waypoint relative to the screen input |
def patrolExecutive.publishPatrolFeedBack | ( | patrolId, | |
status, | |||
acheivedWaypointCount, | |||
plannedWaypointCount | |||
) |
Publishes the advancement of a patrol.
patrolId | The unique id of the patrol in string representation |
status | String representation of the event to report |
acheivedWaypointCount | Number of waypoints that have succesfully been reached |
plannedWaypointCount | Number of waypoints in the current patrol |
def patrolExecutive.realPoseStampedReceiverCallback | ( | realPoseStamped | ) |
Callback funtion receiving processed waypoint from map_image.
realPoseStamped | The processed waypoint in dimesions relative to RTAB-MAP |
def patrolExecutive.sendGoalDoneCallback | ( | terminalState, | |
result | |||
) |
Callback function called when an action sent to move_base is done.
terminalState | The state of the action (ie: SUCCEEDED / ABORTED) |
result |
def patrolExecutive.startPatrolNavigation | ( | ) |
This function starts sending the different waypoint that were converted in the list.
def patrolExecutive.waypointsListReceiverCallback | ( | waypointsJsonStr | ) |
Callback funtion that handles the reception of new patrol plans.
This function will decode incoming JSON message and convert the waypoints for them to be sent to move_base sequentially.
waypointsJsonStr | The patrol plan in JSON representation |
def patrolExecutive.waypointToPixelPoseStamped | ( | waypointObject | ) |
Format Waypoint to Pixel PoseStamped.
waypointObject | The waypoint in dictionnary form from the JSON object |
patrolExecutive.actionClient = actionlib.SimpleActionClient('move_base', MoveBaseAction) |
int patrolExecutive.currentWaypointIndex = 0 |
bool patrolExecutive.isLooped = False |
string patrolExecutive.patrolId = "" |
int patrolExecutive.PIXEL_POSESTAMPED_INDEX = 1 |
int patrolExecutive.REAL_POSESTAMPED_INDEX = 2 |
patrolExecutive.toElectron = rospy.Publisher("toElectron", String, queue_size=20) |
patrolExecutive.toMapImageGenerator = rospy.Publisher("toMapImageGenerator", PoseStamped, queue_size=20) |
list patrolExecutive.waypointsPatrolList = [] |