ros_sensor_publisher

package
v0.0.0-...-65acc58 Latest Latest
Warning

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

Go to latest
Published: Feb 20, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Model = resource.NewModel(utils.Namespace, "ros", "sensor-publisher")

Functions

func NewRosSensorPublisher

func NewRosSensorPublisher(ctx context.Context, deps resource.Dependencies, conf resource.Config, logger logging.Logger) (resource.Resource, error)

Types

type RosBridgeConfig

type RosBridgeConfig struct {
	PrimaryUri string          `json:"primary_uri"`
	Host       string          `json:"host"`
	Sensors    []*SensorConfig `json:"sensors"`
}

func (*RosBridgeConfig) Validate

func (cfg *RosBridgeConfig) Validate(path string) ([]string, error)

type RosReader

type RosReader struct {
	// contains filtered or unexported fields
}

type RosSensorPublisher

type RosSensorPublisher struct {
	resource.Named
	// contains filtered or unexported fields
}

func (*RosSensorPublisher) Close

func (r *RosSensorPublisher) Close(ctx context.Context) error

Close implements resource.Resource.

func (*RosSensorPublisher) DoCommand

func (*RosSensorPublisher) DoCommand(ctx context.Context, cmd map[string]interface{}) (map[string]interface{}, error)

DoCommand implements resource.Resource.

func (*RosSensorPublisher) Reconfigure

func (r *RosSensorPublisher) Reconfigure(ctx context.Context, deps resource.Dependencies, conf resource.Config) error

Reconfigure implements resource.Resource.

type SensorConfig

type SensorConfig struct {
	Topic      string  `json:"topic"`
	Type       string  `json:"message_type"`
	Name       string  `json:"sensor_name"`
	SampleRate float64 `json:"sample_rate"`
}

Jump to

Keyboard shortcuts

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