node

package
v0.0.0-...-71b0d36 Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2020 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 Node

type Node struct {
	Store store.Device
	// contains filtered or unexported fields
}

Node handles communication with nodes over the MQTT

func New

func New(appBroker string, nodeBroker string, st store.Device) (*Node, error)

New creates mqtt client and connect into broker

func (*Node) Log

func (n *Node) Log(_ paho.Client, message paho.Message)

Log provides data gathering endpoint for devices. we call these data that are came from devices log from kaa old days. thing -> log/{deveui}/send -> /device/{deveui}/rx -> app

func (*Node) Notification

func (n *Node) Notification(_ paho.Client, message paho.Message)

Notification provides data sending endpoint for devices. we call these data that are sent to devices notification from kaa old days. app -> device/{deveui}/tx -> /notification/{deveui}/request -> thing

Jump to

Keyboard shortcuts

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