bambulab

package
v0.0.0-...-dac0dfe Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2024 License: GPL-3.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 Client

type Client struct {
	Device     DeviceInfo
	Host       string
	Port       int
	LocalMQTT  bool
	Username   string
	AuthToken  string
	AccessCode string
	UsageHours float64
	Client     mqtt.Client
	Connected  bool
	Tracer     trace.Tracer
}

func (*Client) Connect

func (c *Client) Connect(ctx context.Context)

func (*Client) Disconnect

func (c *Client) Disconnect(ctx context.Context)

func (*Client) Publish

func (c *Client) Publish(ctx context.Context, topic string, payload interface{})

func (*Client) Subscribe

func (c *Client) Subscribe(ctx context.Context, topic string)

type DeviceInfo

type DeviceInfo struct {
	DeviceType string
	ID         string
}

Jump to

Keyboard shortcuts

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