config

package
v0.0.6 Latest Latest
Warning

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

Go to latest
Published: Jul 18, 2022 License: GPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AddrConfig

type AddrConfig struct {
	Ra       string `yaml:"ra"`
	Platform string `yaml:"platform"`
}

type Config

type Config struct {
	Mqtt MqttConfig        `yaml:"mqtt"`
	User client.UserConfig `yaml:"user"`
	Addr AddrConfig        `yaml:"addr"`
}

Config holds the configuration

type MqttConfig

type MqttConfig struct {
	ServerAddr        string `yaml:"server_addr"`         // MQTT server URL
	ClientID          string `yaml:"client_id"`           // client id to use when connecting to server
	ClientName        string `yaml:"client_name"`         // client name
	DeviceType        string `yaml:"device_type"`         // device type
	Topic             string `yaml:"topic"`               // topic on which to publish messaged
	Qos               byte   `yaml:"qos"`                 // qos to use when publishing
	Keepalive         uint16 `yaml:"keepalive"`           // seconds between keepalive packets
	ConnectRetryDelay uint16 `yaml:"connect_retry_delay"` // period between connection attempts
	WriteToStdOut     bool   `yaml:"write_to_stdout"`     // If true received messages will be written to stdout
	WriteToDisk       bool   `yaml:"write_to_disk"`       // if true received messages will be written to below file
	OutputFileName    string `yaml:"output_filename"`     // filename to save messages to
	Debug             bool   `yaml:"debug"`               // autopaho and paho debug output requested
}

Jump to

Keyboard shortcuts

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