Command Line

Command-line utility code for interacting with robot services.

class bosdyn.client.command_line.Command(subparsers, command_dict)[source]

Bases: object

Command-line command.

Parameters:
  • subparsers – List of argument parsers.

  • command_dict – Dictionary of command names which take parsed options.

NAME = None
NEED_AUTHENTICATION = True
run(robot, options)[source]

Invoke the command.

Parameters:
  • robot – Robot object on which to run the command.

  • options – Parsed command-line arguments.

class bosdyn.client.command_line.Subcommands(subparsers, command_dict, subcommands)[source]

Bases: Command

Run subcommands.

Parameters:
  • subparsers – List of argument parsers.

  • command_dict – Dictionary of command names which take parsed options.

  • subcommands – List of subcommands to run.

class bosdyn.client.command_line.DirectoryCommands(subparsers, command_dict)[source]

Bases: Subcommands

Commands related to the directory service.

NAME = 'dir'
class bosdyn.client.command_line.DirectoryListCommand(subparsers, command_dict)[source]

Bases: Command

List all services in the directory.

NAME = 'list'
class bosdyn.client.command_line.DirectoryGetCommand(subparsers, command_dict)[source]

Bases: Command

Get entry for a given service in the directory.

NAME = 'get'
class bosdyn.client.command_line.DirectoryRegisterCommand(subparsers, command_dict)[source]

Bases: Command

Register entry for a service in the directory.

NAME = 'register'
class bosdyn.client.command_line.DirectoryUnregisterCommand(subparsers, command_dict)[source]

Bases: Command

Unregister entry for a service in the directory.

NAME = 'unregister'
class bosdyn.client.command_line.PayloadCommands(subparsers, command_dict)[source]

Bases: Subcommands

Commands related to the payload and payload registration services.

NAME = 'payload'
class bosdyn.client.command_line.PayloadListCommand(subparsers, command_dict)[source]

Bases: Command

List all payloads registered with the robot.

NAME = 'list'
class bosdyn.client.command_line.PayloadRegisterCommand(subparsers, command_dict)[source]

Bases: Command

Register a payload with the robot.

NAME = 'register'
class bosdyn.client.command_line.FaultCommands(subparsers, command_dict)[source]

Bases: Subcommands

Commands related to the fault service and robot state service (for fault reading).

NAME = 'fault'
class bosdyn.client.command_line.FaultShowCommand(subparsers, command_dict)[source]

Bases: Command

Show all faults currently active in robot state.

NAME = 'show'
class bosdyn.client.command_line.FaultWatchCommand(subparsers, command_dict)[source]

Bases: Command

Watch all faults in robot state and print them out.

NAME = 'watch'
class bosdyn.client.command_line.LogStatusCommands(subparsers, command_dict)[source]

Bases: Subcommands

Start, update and terminate experiment logs, start and terminate retro logs and check status of active logs for robot.

NAME = 'log-status'
NEED_AUTHENTICATION = True
class bosdyn.client.command_line.GetLogCommand(subparsers, command_dict)[source]

Bases: Command

Get log status but log id.

NAME = 'get'
class bosdyn.client.command_line.GetActiveLogStatusesCommand(subparsers, command_dict)[source]

Bases: Command

Get active log bundles for robot.

NAME = 'active'
class bosdyn.client.command_line.ExperimentLogCommand(subparsers, command_dict)[source]

Bases: Subcommands

Give experiment log commands to robot.

NAME = 'experiment'
class bosdyn.client.command_line.StartTimedExperimentLogCommand(subparsers, command_dict)[source]

Bases: Command

Start a timed experiment log.

NAME = 'timed'
class bosdyn.client.command_line.StartContinuousExperimentLogCommand(subparsers, command_dict)[source]

Bases: Command

Start a continuous experiment log.

NAME = 'continuous'
static handle_keyboard_interruption(client, log_id)[source]
class bosdyn.client.command_line.StartRetroLogCommand(subparsers, command_dict)[source]

Bases: Command

Start a retro log.

NAME = 'retro'
class bosdyn.client.command_line.TerminateLogCommand(subparsers, command_dict)[source]

Bases: Command

Terminate log gathering process.

NAME = 'terminate'
class bosdyn.client.command_line.RobotIdCommand(subparsers, command_dict)[source]

Bases: Command

Show robot-id.

NAME = 'id'
NEED_AUTHENTICATION = False
class bosdyn.client.command_line.DataBufferCommands(subparsers, command_dict)[source]

Bases: Subcommands

Commands related to the data-buffer service.

NAME = 'log'
class bosdyn.client.command_line.TextMsgCommand(subparsers, command_dict)[source]

Bases: Command

Send a text-message to the data buffer to be logged.

NAME = 'textmsg'
class bosdyn.client.command_line.OperatorCommentCommand(subparsers, command_dict)[source]

Bases: Command

Send an operator comment to the robot to be logged.

NAME = 'comment'
class bosdyn.client.command_line.DataServiceCommands(subparsers, command_dict)[source]

Bases: Subcommands

Commands for querying the data-service.

NAME = 'data'
class bosdyn.client.command_line.GetDataBufferEventsCommentsCommand(subparsers, command_dict)[source]

Bases: Command

Parent class for commands grabbing operator comment and events.

abstract pretty_print(values)[source]

Print output of request in a human-friendly way.

class bosdyn.client.command_line.GetDataBufferCommentsCommand(subparsers, command_dict)[source]

Bases: GetDataBufferEventsCommentsCommand

Get operator comments from the robot.

NAME = 'comments'
pretty_print(values)[source]

Print output of request in a human-friendly way.

class bosdyn.client.command_line.GetDataBufferEventsCommand(subparsers, command_dict)[source]

Bases: GetDataBufferEventsCommentsCommand

Get events from the robot.

NAME = 'events'
pretty_print(values)[source]

Print output of request in a human-friendly way.

class bosdyn.client.command_line.GetDataBufferStatusCommand(subparsers, command_dict)[source]

Bases: Command

Get status of data-buffer on robot.

NAME = 'status'
class bosdyn.client.command_line.RobotStateCommands(subparsers, command_dict)[source]

Bases: Subcommands

Commands for querying robot state.

NAME = 'state'
class bosdyn.client.command_line.FullStateCommand(subparsers, command_dict)[source]

Bases: Command

Show robot state.

NAME = 'full'
class bosdyn.client.command_line.HardwareConfigurationCommand(subparsers, command_dict)[source]

Bases: Command

Show robot hardware configuration.

NAME = 'hardware'
class bosdyn.client.command_line.RobotModel(subparsers, command_dict)[source]

Bases: Command

Write robot URDF and mesh to local files.

NAME = 'model'
NEED_AUTHENTICATION = False
class bosdyn.client.command_line.MetricsCommand(subparsers, command_dict)[source]

Bases: Command

Show metrics (runtime, etc…).

NAME = 'metrics'
class bosdyn.client.command_line.TimeSyncCommand(subparsers, command_dict)[source]

Bases: Command

Find clock difference between this and the robot clock.

NAME = 'time-sync'
class bosdyn.client.command_line.LicenseCommand(subparsers, command_dict)[source]

Bases: Command

Show installed license.

NAME = 'license'
class bosdyn.client.command_line.LeaseCommands(subparsers, command_dict)[source]

Bases: Subcommands

Commands related to the lease service.

NAME = 'lease'
class bosdyn.client.command_line.LeaseListCommand(subparsers, command_dict)[source]

Bases: Command

List all leases.

NAME = 'list'
class bosdyn.client.command_line.BecomeEstopCommand(subparsers, command_dict)[source]

Bases: Command

Grab and hold estop until Ctl-C.

NAME = 'become-estop'
class bosdyn.client.command_line.ImageCommands(subparsers, command_dict)[source]

Bases: Subcommands

Commands for querying images.

NAME = 'image'
class bosdyn.client.command_line.ListImageSourcesCommand(subparsers, command_dict)[source]

Bases: Command

List image sources.

NAME = 'list-sources'
class bosdyn.client.command_line.GetImageCommand(subparsers, command_dict)[source]

Bases: Command

Get an image from the robot and write it to an image file.

NAME = 'get-image'
class bosdyn.client.command_line.LocalGridCommands(subparsers, command_dict)[source]

Bases: Subcommands

Commands for querying local grid maps.

NAME = 'local_grid'
class bosdyn.client.command_line.ListLocalGridTypesCommand(subparsers, command_dict)[source]

Bases: Command

List local grid sources.

NAME = 'types'
class bosdyn.client.command_line.GetLocalGridsCommand(subparsers, command_dict)[source]

Bases: Command

Get local grids from the robot.

NAME = 'get'
class bosdyn.client.command_line.DataAcquisitionCommand(subparsers, command_dict)[source]

Bases: Subcommands

Acquire data from the robot and add it in the data buffer with the metadata, or request status.

NAME = 'acquire'
class bosdyn.client.command_line.DataAcquisitionRequestCommand(subparsers, command_dict)[source]

Bases: Command

Capture and save images or metadata specified in the command line arguments.

NAME = 'request'
class bosdyn.client.command_line.DataAcquisitionServiceCommand(subparsers, command_dict)[source]

Bases: Command

Get list of different data acquisition capabilities.

NAME = 'info'
class bosdyn.client.command_line.DataAcquisitionStatusCommand(subparsers, command_dict)[source]

Bases: Command

Get status of an acquisition request based on the request id.

NAME = 'status'
class bosdyn.client.command_line.DataAcquisitionGetLiveDataCommand(subparsers, command_dict)[source]

Bases: Command

Call GetLiveData based on service name.

NAME = 'live'
class bosdyn.client.command_line.HostComputerIPCommand(subparsers, command_dict)[source]

Bases: Command

Determine a computer’s IP address.

NAME = 'self-ip'
NEED_AUTHENTICATION = False
class bosdyn.client.command_line.PowerCommand(subparsers, command_dict)[source]

Bases: Subcommands

Send power commands to the robot.

NAME = 'power'
class bosdyn.client.command_line.PowerRobotCommand(subparsers, command_dict)[source]

Bases: Command

Control the power of the entire robot.

NAME = 'robot'
class bosdyn.client.command_line.PowerPayloadsCommand(subparsers, command_dict)[source]

Bases: Command

Control the power of robot payloads.

NAME = 'payload'
class bosdyn.client.command_line.PowerWifiRadioCommand(subparsers, command_dict)[source]

Bases: Command

Control the power of robot wifi radio.

NAME = 'wifi'
bosdyn.client.command_line.main(args=None)[source]

Command-line interface for interacting with robot services.