tele_api

package
v0.251008.0 Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2025 License: CC0-1.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Packet

type Packet struct {
	Payload []byte
	VmId    int32
	Kind    PacketKind
}

func (*Packet) CommandResponseUnmarshal

func (p *Packet) CommandResponseUnmarshal() *vender_api.Response

func (*Packet) MessageFromRobotseUnmarshal

func (p *Packet) MessageFromRobotseUnmarshal() *vender_api.FromRoboMessage

func (*Packet) State

func (p *Packet) State() (vender_api.State, error)

func (*Packet) String

func (p *Packet) String() string

func (*Packet) Telemetry

func (p *Packet) Telemetry() (*vender_api.Telemetry, error)

type PacketKind

type PacketKind uint8
const (
	PacketInvalid PacketKind = iota
	PacketConnect
	PacketState
	PacketTelemetry
	PacketCommand
	PacketCommandReply
	PacketCommandAccepted
	FromRoboPacketCommandDone
	FromRobo
)

func (PacketKind) String

func (i PacketKind) String() string

type Teler

type Teler interface {
	Init(context.Context, *log2.Log, tele_config.Config) error
	Close() error
	Addrs() []string
	Chan() <-chan Packet
	CommandTx(vmid int32, c *vender_api.Command)
	SendCommand(vmid int32, c *vender_api.Command)
	SendToRobo(vmid int32, m *vender_api.ToRoboMessage)
}

func NewStub

func NewStub() Teler

Jump to

Keyboard shortcuts

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