builtin

package
v0.2.16 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 13, 2023 License: AGPL-3.0 Imports: 18 Imported by: 0

Documentation

Overview

Package builtin implements a remote control for a arm.

Index

Constants

View Source
const (
	SubtypeName = resource.SubtypeName("arm_remote_control") // resource name
)

constants, joints are constants till we can can get joint name from model.

Variables

This section is empty.

Functions

func NewBuiltIn

func NewBuiltIn(
	ctx context.Context,
	deps registry.Dependencies,
	config config.Service,
	logger golog.Logger,
) (armremotecontrol.Service, error)

NewDefault returns a new remote control service for the given robot.

Types

type ControllerMode

type ControllerMode struct {
	ModeName       mode                     `json:"mode_name"`
	ControlMapping map[string]input.Control `json:"control_mapping"`
}

ControllerMode supports mapping in joint or endpoint configuration.

type ServiceConfig

type ServiceConfig struct {
	ArmName               string  `json:"arm"`
	InputControllerName   string  `json:"input_controller"`
	JointStep             float64 `json:"joint_step,omitempty"`   // scale Joint movement in degrees (defaults to 10)
	DegreeStep            float64 `json:"step_degs,omitempty"`    // scale roll, pitch, yaw default 0.1
	MMStep                float64 `json:"step_mm,omitempty"`      // scale x, y, z in millimeters (deafaults to 5)
	ControllerSensitivity float64 `json:"controller_sensitivity"` // joystick sensitivity
	// only respond to events where: abs(+-1) - sensitivity > 0
	ControllerModes []ControllerMode `json:"controller_modes"` // modes of operation for arm (joint or endpoint/pose control)
}

ServiceConfig describes how to configure the service.

func (*ServiceConfig) Validate

func (config *ServiceConfig) Validate(path string) ([]string, error)

Validate ensures configuration is valid.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL