thingsboard

package
v1.0.0-dep Latest Latest
Warning

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

Go to latest
Published: Apr 5, 2020 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Server string `json:"server"`
}

Config holds the Thingsboard integration configuration.

func (Config) Validate

func (c Config) Validate() error

Validate validates the Config.

type Integration

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

Integration implements the Thingsboard integration.

func New

func New(conf Config) (*Integration, error)

New creates a new Thingsboard integration.

func (*Integration) Close

func (i *Integration) Close() error

Close returns nil.

func (*Integration) DataDownChan

func (i *Integration) DataDownChan() chan integration.DataDownPayload

DataDownChan returns nil.

func (*Integration) SendACKNotification

func (i *Integration) SendACKNotification(ctx context.Context, vars map[string]string, pl pb.AckEvent) error

SendACKNotification returns nil.

func (*Integration) SendDataUp

func (i *Integration) SendDataUp(ctx context.Context, vars map[string]string, pl pb.UplinkEvent) error

SendDataUp sends the (decoded) uplink payload to the Thingsboard endpoint.

func (*Integration) SendErrorNotification

func (i *Integration) SendErrorNotification(ctx context.Context, vars map[string]string, pl pb.ErrorEvent) error

SendErrorNotification returns nil.

func (*Integration) SendJoinNotification

func (i *Integration) SendJoinNotification(ctx context.Context, vars map[string]string, pl pb.JoinEvent) error

SendJoinNotification returns nil.

func (*Integration) SendLocationNotification

func (i *Integration) SendLocationNotification(ctx context.Context, vars map[string]string, pl pb.LocationEvent) error

SendLocationNotification sends the device location to the Thingsboard endpoint.

func (*Integration) SendStatusNotification

func (i *Integration) SendStatusNotification(ctx context.Context, vars map[string]string, pl pb.StatusEvent) error

SendStatusNotification sends the device-status fields to the Thingsboard endpoint.

func (*Integration) SendTxAckNotification

func (i *Integration) SendTxAckNotification(ctx context.Context, vars map[string]string, pl pb.TxAckEvent) error

SendTxAckNotification is not not implemented.

Jump to

Keyboard shortcuts

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