-
Notifications
You must be signed in to change notification settings - Fork 60
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Add api for robot charging tasks #283
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Luca Della Vedova <lucadv@intrinsic.ai>
{ | ||
"$schema": "https://json-schema.org/draft/2020-12/schema", | ||
"$id": "https://raw.githubusercontent.com/open-rmf/rmf_ros2/main/rmf_fleet_adapter/schemas/event_description__charge.json", | ||
"title": "Charge Event", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I recommend we add "Battery" everywhere to make this more explicit, e.g. "Charge Battery Event", event_description__charge_battery.json
, "Charge the battery of a robot".
If anyone develops a bull robot for a rodeo they might want "charge" to mean something else.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Signed-off-by: Luca Della Vedova <lucadv@intrinsic.ai>
Signed-off-by: Luca Della Vedova <lucadv@intrinsic.ai>
In d87b87b an |
@@ -0,0 +1,9 @@ | |||
{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we necessarily need this event_description
schema since we don't support any ChargeBattery
events in rmf_task
.
With this description, users can theoretically submit a composable task with a ChargeBattery event injected between other activities but the fleet adapter will not find the right builder from rmf_task_sequence
to generate the Model
and Description
for this event.
Not a blocker imo but it would be good to test what happens when such a compose task is submitted to make sure any errors are gracefully handled.
"title": "Charge Battery Event", | ||
"description": "Charge a robot's battery", | ||
"type": "object", | ||
"properties": { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think right now the battery level to which the robot charges up to is statically defined in the fleet config. In the future it would be good to specify this % in the properties
here and have the TaskPlanner
accept this value in the Options
it receives before it plans. Not a blocker.
New feature implementation
Implemented feature
Closes #261.
Implementation description
This PR adds support for submitting robot charging requests through a
charge
task.This task should only be used in direct task requests, since dispatching it to the robot that can charge the fastest doesn't really make a lot of sense.addressed in d87b87bIt can be tested with this rmf_demos branch that adds a
dispatch_charge
task, with mandatoryfleet
androbot
parameters to make sure it is a direct assignment.