Documentation ¶
Index ¶
- Variables
- type AES128Key
- func (key AES128Key) Bytes() []byte
- func (key AES128Key) GoString() string
- func (key AES128Key) IsEmpty() bool
- func (key AES128Key) Marshal() ([]byte, error)
- func (key AES128Key) MarshalBinary() ([]byte, error)
- func (key AES128Key) MarshalText() ([]byte, error)
- func (key AES128Key) String() string
- func (key *AES128Key) Unmarshal(data []byte) error
- func (key *AES128Key) UnmarshalBinary(data []byte) error
- func (key *AES128Key) UnmarshalText(data []byte) error
- type AppEUI
- func (eui AppEUI) Bytes() []byte
- func (eui AppEUI) GoString() string
- func (eui AppEUI) IsEmpty() bool
- func (eui AppEUI) Marshal() ([]byte, error)
- func (eui AppEUI) MarshalBinary() ([]byte, error)
- func (eui AppEUI) MarshalText() ([]byte, error)
- func (eui AppEUI) String() string
- func (eui *AppEUI) Unmarshal(data []byte) error
- func (eui *AppEUI) UnmarshalBinary(data []byte) error
- func (eui *AppEUI) UnmarshalText(data []byte) error
- type AppKey
- func (key AppKey) Bytes() []byte
- func (key AppKey) GoString() string
- func (key AppKey) IsEmpty() bool
- func (key AppKey) Marshal() ([]byte, error)
- func (key AppKey) MarshalBinary() ([]byte, error)
- func (key AppKey) MarshalText() ([]byte, error)
- func (key AppKey) String() string
- func (key *AppKey) Unmarshal(data []byte) error
- func (key *AppKey) UnmarshalBinary(data []byte) error
- func (key *AppKey) UnmarshalText(data []byte) error
- type AppSKey
- func (key AppSKey) Bytes() []byte
- func (key AppSKey) GoString() string
- func (key AppSKey) IsEmpty() bool
- func (key AppSKey) Marshal() ([]byte, error)
- func (key AppSKey) MarshalBinary() ([]byte, error)
- func (key AppSKey) MarshalText() ([]byte, error)
- func (key AppSKey) String() string
- func (key *AppSKey) Unmarshal(data []byte) error
- func (key *AppSKey) UnmarshalBinary(data []byte) error
- func (key *AppSKey) UnmarshalText(data []byte) error
- type DevAddr
- func (addr DevAddr) Bytes() []byte
- func (addr DevAddr) GoString() string
- func (addr DevAddr) IsEmpty() bool
- func (addr DevAddr) Marshal() ([]byte, error)
- func (addr DevAddr) MarshalBinary() ([]byte, error)
- func (addr DevAddr) MarshalText() ([]byte, error)
- func (addr DevAddr) String() string
- func (addr DevAddr) ToEUI() DevEUI
- func (addr *DevAddr) Unmarshal(data []byte) error
- func (addr *DevAddr) UnmarshalBinary(data []byte) error
- func (addr *DevAddr) UnmarshalText(data []byte) error
- type DevEUI
- func (eui DevEUI) Bytes() []byte
- func (eui DevEUI) GoString() string
- func (eui DevEUI) IsEmpty() bool
- func (eui DevEUI) Marshal() ([]byte, error)
- func (eui DevEUI) MarshalBinary() ([]byte, error)
- func (eui DevEUI) MarshalText() ([]byte, error)
- func (eui DevEUI) String() string
- func (eui *DevEUI) Unmarshal(data []byte) error
- func (eui *DevEUI) UnmarshalBinary(data []byte) error
- func (eui *DevEUI) UnmarshalText(data []byte) error
- type DeviceType
- func (devType DeviceType) GoString() string
- func (devType DeviceType) Marshal() ([]byte, error)
- func (devType DeviceType) MarshalBinary() ([]byte, error)
- func (devType DeviceType) MarshalText() ([]byte, error)
- func (devType DeviceType) String() string
- func (devType *DeviceType) Unmarshal(data []byte) error
- func (devType *DeviceType) UnmarshalBinary(data []byte) error
- func (devType *DeviceType) UnmarshalText(data []byte) error
- type EUI64
- func (eui EUI64) Bytes() []byte
- func (eui EUI64) GoString() string
- func (eui EUI64) IsEmpty() bool
- func (eui EUI64) Marshal() ([]byte, error)
- func (eui EUI64) MarshalBinary() ([]byte, error)
- func (eui EUI64) MarshalText() ([]byte, error)
- func (eui EUI64) String() string
- func (eui *EUI64) Unmarshal(data []byte) error
- func (eui *EUI64) UnmarshalBinary(data []byte) error
- func (eui *EUI64) UnmarshalText(data []byte) error
- type GatewayEUI
- func (eui GatewayEUI) Bytes() []byte
- func (eui GatewayEUI) GoString() string
- func (eui GatewayEUI) IsEmpty() bool
- func (eui GatewayEUI) Marshal() ([]byte, error)
- func (eui GatewayEUI) MarshalBinary() ([]byte, error)
- func (eui GatewayEUI) MarshalText() ([]byte, error)
- func (eui GatewayEUI) String() string
- func (eui *GatewayEUI) Unmarshal(data []byte) error
- func (eui *GatewayEUI) UnmarshalBinary(data []byte) error
- func (eui *GatewayEUI) UnmarshalText(data []byte) error
- type NwkSKey
- func (key NwkSKey) Bytes() []byte
- func (key NwkSKey) GoString() string
- func (key NwkSKey) IsEmpty() bool
- func (key NwkSKey) Marshal() ([]byte, error)
- func (key NwkSKey) MarshalBinary() ([]byte, error)
- func (key NwkSKey) MarshalText() ([]byte, error)
- func (key NwkSKey) String() string
- func (key *NwkSKey) Unmarshal(data []byte) error
- func (key *NwkSKey) UnmarshalBinary(data []byte) error
- func (key *NwkSKey) UnmarshalText(data []byte) error
Constants ¶
This section is empty.
Variables ¶
var ABPEUIPrefix = []byte{0, 0, 0, 0}
ABPEUIPrefix is the prefix denoting a prefixed dev address
Functions ¶
This section is empty.
Types ¶
type AES128Key ¶
type AES128Key [16]byte
AES128Key is an 128 bit AES key.
func ParseAES128Key ¶
ParseAES128Key parses a 128-bit hex-encoded string to an AES128Key
func (AES128Key) MarshalBinary ¶
MarshalBinary implements the BinaryMarshaler interface.
func (AES128Key) MarshalText ¶
MarshalText implements the TextMarshaler interface.
func (*AES128Key) UnmarshalBinary ¶
UnmarshalBinary implements the BinaryUnmarshaler interface.
func (*AES128Key) UnmarshalText ¶
UnmarshalText implements the TextUnmarshaler interface.
type AppEUI ¶
type AppEUI EUI64
AppEUI is a unique identifier for applications.
func ParseAppEUI ¶
ParseAppEUI parses a 64-bit hex-encoded string to an AppEUI
func (AppEUI) MarshalBinary ¶
MarshalBinary implements the BinaryMarshaler interface.
func (AppEUI) MarshalText ¶
MarshalText implements the TextMarshaler interface.
func (*AppEUI) UnmarshalBinary ¶
UnmarshalBinary implements the BinaryUnmarshaler interface.
func (*AppEUI) UnmarshalText ¶
UnmarshalText implements the TextUnmarshaler interface.
type AppKey ¶
type AppKey AES128Key
AppKey (Application Key) is used for LoRaWAN OTAA.
func ParseAppKey ¶
ParseAppKey parses a 64-bit hex-encoded string to an AppKey
func (AppKey) MarshalBinary ¶
MarshalBinary implements the BinaryMarshaler interface.
func (AppKey) MarshalText ¶
MarshalText implements the TextMarshaler interface.
func (*AppKey) UnmarshalBinary ¶
UnmarshalBinary implements the BinaryUnmarshaler interface.
func (*AppKey) UnmarshalText ¶
UnmarshalText implements the TextUnmarshaler interface.
type AppSKey ¶
type AppSKey AES128Key
AppSKey (Application Session Key) is used for LoRaWAN payload encryption.
func ParseAppSKey ¶
ParseAppSKey parses a 64-bit hex-encoded string to an AppSKey
func (AppSKey) MarshalBinary ¶
MarshalBinary implements the BinaryMarshaler interface.
func (AppSKey) MarshalText ¶
MarshalText implements the TextMarshaler interface.
func (*AppSKey) UnmarshalBinary ¶
UnmarshalBinary implements the BinaryUnmarshaler interface.
func (*AppSKey) UnmarshalText ¶
UnmarshalText implements the TextUnmarshaler interface.
type DevAddr ¶
type DevAddr [4]byte
DevAddr is a non-unique address for LoRaWAN devices.
func ParseDevAddr ¶
ParseDevAddr parses a 32-bit hex-encoded string to a DevAddr
func (DevAddr) MarshalBinary ¶
MarshalBinary implements the BinaryMarshaler interface.
func (DevAddr) MarshalText ¶
MarshalText implements the TextMarshaler interface.
func (*DevAddr) UnmarshalBinary ¶
UnmarshalBinary implements the BinaryUnmarshaler interface.
func (*DevAddr) UnmarshalText ¶
UnmarshalText implements the TextUnmarshaler interface.
type DevEUI ¶
type DevEUI EUI64
DevEUI is a unique identifier for devices.
func ParseDevEUI ¶
ParseDevEUI parses a 64-bit hex-encoded string to an DevEUI
func (DevEUI) MarshalBinary ¶
MarshalBinary implements the BinaryMarshaler interface.
func (DevEUI) MarshalText ¶
MarshalText implements the TextMarshaler interface.
func (*DevEUI) UnmarshalBinary ¶
UnmarshalBinary implements the BinaryUnmarshaler interface.
func (*DevEUI) UnmarshalText ¶
UnmarshalText implements the TextUnmarshaler interface.
type DeviceType ¶
type DeviceType byte
DeviceType is the type of a LoRaWAN device.
const ( // ABP is a LoRaWAN device that is activated by personalization. ABP DeviceType = iota // OTAA is an over-the-air activated LoRaWAN device. OTAA )
func ParseDeviceType ¶
func ParseDeviceType(input string) (devType DeviceType, err error)
ParseDeviceType parses a string to a DeviceType.
func (DeviceType) GoString ¶
func (devType DeviceType) GoString() string
GoString implements the GoStringer interface.
func (DeviceType) Marshal ¶
func (devType DeviceType) Marshal() ([]byte, error)
Marshal implements the Marshaler interface.
func (DeviceType) MarshalBinary ¶
func (devType DeviceType) MarshalBinary() ([]byte, error)
MarshalBinary implements the BinaryMarshaler interface.
func (DeviceType) MarshalText ¶
func (devType DeviceType) MarshalText() ([]byte, error)
MarshalText implements the TextMarshaler interface.
func (DeviceType) String ¶
func (devType DeviceType) String() string
String implements the Stringer interface.
func (*DeviceType) Unmarshal ¶
func (devType *DeviceType) Unmarshal(data []byte) error
Unmarshal implements the Unmarshaler interface.
func (*DeviceType) UnmarshalBinary ¶
func (devType *DeviceType) UnmarshalBinary(data []byte) error
UnmarshalBinary implements the BinaryUnmarshaler interface.
func (*DeviceType) UnmarshalText ¶
func (devType *DeviceType) UnmarshalText(data []byte) error
UnmarshalText implements the TextUnmarshaler interface.
type EUI64 ¶
type EUI64 [8]byte
EUI64 is used for AppEUIs and DevEUIs.
func ParseEUI64 ¶
ParseEUI64 parses a 64-bit hex-encoded string to an EUI64.
func (EUI64) MarshalBinary ¶
MarshalBinary implements the BinaryMarshaler interface.
func (EUI64) MarshalText ¶
MarshalText implements the TextMarshaler interface.
func (*EUI64) UnmarshalBinary ¶
UnmarshalBinary implements the BinaryUnmarshaler interface.
func (*EUI64) UnmarshalText ¶
UnmarshalText implements the TextUnmarshaler interface.
type GatewayEUI ¶
type GatewayEUI EUI64
GatewayEUI is a unique identifier for devices.
func ParseGatewayEUI ¶
func ParseGatewayEUI(input string) (eui GatewayEUI, err error)
ParseGatewayEUI parses a 64-bit hex-encoded string to an GatewayEUI
func (GatewayEUI) Bytes ¶
func (eui GatewayEUI) Bytes() []byte
Bytes returns the GatewayEUI as a byte slice
func (GatewayEUI) GoString ¶
func (eui GatewayEUI) GoString() string
GoString implements the GoStringer interface.
func (GatewayEUI) IsEmpty ¶
func (eui GatewayEUI) IsEmpty() bool
func (GatewayEUI) Marshal ¶
func (eui GatewayEUI) Marshal() ([]byte, error)
Marshal implements the Marshaler interface.
func (GatewayEUI) MarshalBinary ¶
func (eui GatewayEUI) MarshalBinary() ([]byte, error)
MarshalBinary implements the BinaryMarshaler interface.
func (GatewayEUI) MarshalText ¶
func (eui GatewayEUI) MarshalText() ([]byte, error)
MarshalText implements the TextMarshaler interface.
func (GatewayEUI) String ¶
func (eui GatewayEUI) String() string
String implements the Stringer interface.
func (*GatewayEUI) Unmarshal ¶
func (eui *GatewayEUI) Unmarshal(data []byte) error
Unmarshal implements the Unmarshaler interface.
func (*GatewayEUI) UnmarshalBinary ¶
func (eui *GatewayEUI) UnmarshalBinary(data []byte) error
UnmarshalBinary implements the BinaryUnmarshaler interface.
func (*GatewayEUI) UnmarshalText ¶
func (eui *GatewayEUI) UnmarshalText(data []byte) error
UnmarshalText implements the TextUnmarshaler interface.
type NwkSKey ¶
type NwkSKey AES128Key
NwkSKey (Network Session Key) is used for LoRaWAN MIC calculation.
func ParseNwkSKey ¶
ParseNwkSKey parses a 64-bit hex-encoded string to an NwkSKey
func (NwkSKey) MarshalBinary ¶
MarshalBinary implements the BinaryMarshaler interface.
func (NwkSKey) MarshalText ¶
MarshalText implements the TextMarshaler interface.
func (*NwkSKey) UnmarshalBinary ¶
UnmarshalBinary implements the BinaryUnmarshaler interface.
func (*NwkSKey) UnmarshalText ¶
UnmarshalText implements the TextUnmarshaler interface.