Documentation
¶
Index ¶
- Constants
- Variables
- func GenerateDir(cups bool, path string, suffix string) string
- func GenerateUri(cups bool, tls bool, addr string, port int) string
- type Auth
- type BsAuth
- type BsConfig
- type DebugConf
- type File
- type GatewayConfig
- type GbConfig
- type NoAuth
- type NsConfig
- type PfConfig
- type TlsServerAndClientAuth
- type TlsServerAuth
- type TlsServerAuthAndClientToken
Constants ¶
View Source
const Eu868NsDefault string = `` /* 1247-byte string literal not displayed */
View Source
const Eu868PfDefault = `` /* 3860-byte string literal not displayed */
View Source
const GbDefault = `` /* 1210-byte string literal not displayed */
View Source
const Us915NsDefault = `` /* 925-byte string literal not displayed */
View Source
const Us915PfDefault = `` /* 3903-byte string literal not displayed */
Variables ¶
View Source
var ErrorBsConfigFileNotFound = errors.New("bs config file not found")
Functions ¶
Types ¶
type GatewayConfig ¶
type GatewayConfig struct {
ServerAddress string `json:"server_address" mapstructure:"server_address"`
ServPortUp int32 `json:"serv_port_up" mapstructure:"serv_port_up"`
ServPortDown int32 `json:"serv_port_down" mapstructure:"serv_port_down"`
GatewayID string `json:"gateway_ID"`
KeepaliveInterval int32 `json:"keepalive_interval"`
StatInterval int32 `json:"stat_interval"`
PushTimeoutMs int32 `json:"push_timeout_ms"`
ForwardCrcValid bool `json:"forward_crc_valid"`
ForwardCrcError bool `json:"forward_crc_error"`
ForwardCrcDisabled bool `json:"forward_crc_disabled"`
GPSTTYPath string `json:"gps_tty_path,omitempty"`
RefLatitude float32 `json:"ref_latitude"`
RefLongitude float32 `json:"ref_longitude"`
RefAltitude int32 `json:"ref_altitude"`
AutoquitThreshold int32 `json:"autoquit_threshold,omitempty"`
BeaconPeriod int32 `json:"beacon_period"`
BeaconFreqHZ int32 `json:"beacon_freq_hz"`
BeaconFreqNB int32 `json:"beacon_freq_nb"`
BeaconFreqStep int32 `json:"beacon_freq_step"`
BeaconDatarate int32 `json:"beacon_datarate"`
BeaconBwHZ int32 `json:"beacon_bw_hz"`
BeaconPower int32 `json:"beacon_power"`
BeaconInfodesc int32 `json:"beacon_infodesc,omitempty"`
}
type GbConfig ¶
type GbConfig struct {
Filters struct {
NetIDs []string `mapstructure:"net_ids"`
JoinEUIs [][2]string `mapstructure:"join_euis"`
} `mapstructure:"filters"`
}
func NewGbConfig ¶
type NsConfig ¶
type NsConfig struct {
NetworkServer struct {
NetID string `mapstructure:"net_id"`
Band struct {
Name string `mapstructure:"name"`
} `mapstructure:"band"`
NetworkSettings struct {
InstallationMargin float64 `mapstructure:"installation_margin"`
RX1Delay int `mapstructure:"rx1_delay"`
RX1DROffset int `mapstructure:"rx1_dr_offset"`
RX2DR int `mapstructure:"rx2_dr"`
RX2Frequency int `mapstructure:"rx2_frequency"`
// DownlinkTXPower int `mapstructure:"downlink_tx_power"`
EnabledUplinkChannels []int `mapstructure:"enabled_uplink_channels"`
DisableADR bool `mapstructure:"disable_adr"`
ExtraChannels []band.ExtraChannel `mapstructure:"extra_channels"`
} `mapstructure:"network_settings"`
} `mapstructure:"network_server"`
}
func NewNsConfig ¶
func NewNsConfig(b band.Band, a *api.BuiltInNetworkServer) *NsConfig
type PfConfig ¶
type PfConfig struct {
band.SX130xConfig `json:"SX130x_conf" mapstructure:"SX130x_conf"`
GatewayConfig `json:"gateway_conf" mapstructure:"gateway_conf"`
DebugConf `json:"debug_conf" mapstructure:"debug_conf"`
}
func (*PfConfig) ApiMode ¶
func (c *PfConfig) ApiMode() *api.GateWayMode
type TlsServerAndClientAuth ¶
func (*TlsServerAndClientAuth) ApiMode ¶
func (c *TlsServerAndClientAuth) ApiMode() *api.GateWayMode
func (*TlsServerAndClientAuth) GetAuth ¶
func (c *TlsServerAndClientAuth) GetAuth(dir string) *Auth
type TlsServerAuth ¶
func (*TlsServerAuth) ApiMode ¶
func (c *TlsServerAuth) ApiMode() *api.GateWayMode
func (*TlsServerAuth) GetAuth ¶
func (c *TlsServerAuth) GetAuth(dir string) *Auth
type TlsServerAuthAndClientToken ¶
func (*TlsServerAuthAndClientToken) ApiMode ¶
func (c *TlsServerAuthAndClientToken) ApiMode() *api.GateWayMode
func (*TlsServerAuthAndClientToken) GetAuth ¶
func (c *TlsServerAuthAndClientToken) GetAuth(dir string) *Auth
Click to show internal directories.
Click to hide internal directories.