store

package
v3.25.0 Latest Latest
Warning

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

Go to latest
Published: Apr 5, 2023 License: Apache-2.0 Imports: 5 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 {
	Store Store `name:"-"`
}

Config is configuration for the Device Repository store.

type EndDeviceProfile added in v3.19.0

type EndDeviceProfile struct {
	VendorProfileID uint32 `yaml:"vendorProfileID" json:"vendor_profile_id"`
	SupportsClassB  bool   `yaml:"supportsClassB" json:"supports_class_b"`
	ClassBTimeout   uint32 `yaml:"classBTimeout" json:"class_b_timeout"`
	PingSlotPeriod  uint32 `yaml:"pingSlotPeriod" json:"ping_slot_period"`

	PingSlotDataRateIndex     *ttnpb.DataRateIndex  `yaml:"pingSlotDataRateIndex" json:"ping_slot_data_rate_index"`
	PingSlotFrequency         float64               `yaml:"pingSlotFrequency" json:"ping_slot_frequency"`
	SupportsClassC            bool                  `yaml:"supportsClassC" json:"supports_class_c"`
	ClassCTimeout             uint32                `yaml:"classCTimeout" json:"class_c_timeout"`
	MACVersion                ttnpb.MACVersion      `yaml:"macVersion" json:"mac_version"`
	RegionalParametersVersion string                `yaml:"regionalParametersVersion" json:"regional_parameters_version"`
	SupportsJoin              bool                  `yaml:"supportsJoin" json:"supports_join"`
	Rx1Delay                  *ttnpb.RxDelay        `yaml:"rx1Delay" json:"rx1_delay"`
	Rx1DataRateOffset         *ttnpb.DataRateOffset `yaml:"rx1DataRateOffset" json:"rx1_data_rate_offset"`
	Rx2DataRateIndex          *ttnpb.DataRateIndex  `yaml:"rx2DataRateIndex" json:"rx2_data_rate_index"`
	Rx2Frequency              float64               `yaml:"rx2Frequency" json:"rx2_frequency"`
	FactoryPresetFrequencies  []float64             `yaml:"factoryPresetFrequencies" json:"factory_preset_frequencies"`
	MaxEIRP                   float32               `yaml:"maxEIRP" json:"max_eirp"`
	MaxDutyCycle              float64               `yaml:"maxDutyCycle" json:"max_duty_cycle"`
	Supports32BitFCnt         bool                  `yaml:"supports32bitFCnt" json:"supports_32_bit_f_cnt"`
}

EndDeviceProfile is the profile of a LoRaWAN end device as defined in the LoRaWAN backend interfaces.

func (EndDeviceProfile) ToTemplatePB added in v3.19.0

ToTemplatePB returns a ttnpb.EndDeviceTemplate from an end device profile.

type GetBrandsRequest

type GetBrandsRequest struct {
	BrandID string
	Limit,
	Page uint32
	OrderBy string
	Paths   []string
	Search  string
}

GetBrandsRequest is a request to list available end device vendors, with pagination and sorting.

type GetBrandsResponse

type GetBrandsResponse struct {
	Count,
	Offset,
	Total uint32
	Brands []*ttnpb.EndDeviceBrand
}

GetBrandsResponse is a list of brands, along with pagination information.

type GetCodecRequest added in v3.12.2

type GetCodecRequest interface {
	GetVersionIds() *ttnpb.EndDeviceVersionIdentifiers
	GetFieldMask() *fieldmaskpb.FieldMask
}

GetCodecRequest is a request to retrieve the codec of

type GetEndDeviceProfilesRequest added in v3.19.0

type GetEndDeviceProfilesRequest struct {
	BrandID,
	ModelID string
	Limit,
	Page uint32
	OrderBy string
	Paths   []string
	Search  string
}

GetEndDeviceProfilesRequest is a request to list available LoRaWAN end device profile definitions.

type GetEndDeviceProfilesResponse added in v3.19.0

type GetEndDeviceProfilesResponse struct {
	Count,
	Offset,
	Total uint32
	Profiles []*EndDeviceProfile
}

GetEndDeviceProfilesResponse returns available LoRaWAN end device profile definitions.

type GetModelsRequest

type GetModelsRequest struct {
	BrandID,
	ModelID string
	Limit,
	Page uint32
	OrderBy string
	Paths   []string
	Search  string
}

GetModelsRequest is a request to list available end device model definitions.

type GetModelsResponse

type GetModelsResponse struct {
	Count,
	Offset,
	Total uint32
	Models []*ttnpb.EndDeviceModel
}

GetModelsResponse is a list of models, along with model information

type Store

type Store interface {
	// GetBrands lists available end device vendors.
	GetBrands(GetBrandsRequest) (*GetBrandsResponse, error)
	// GetModels lists available end device definitions.
	GetModels(GetModelsRequest) (*GetModelsResponse, error)
	// GetEndDeviceProfiles lists available LoRaWAN end device profile definitions.
	GetEndDeviceProfiles(GetEndDeviceProfilesRequest) (*GetEndDeviceProfilesResponse, error)
	// GetTemplate retrieves an end device template for an end device definition.
	GetTemplate(*ttnpb.GetTemplateRequest, *EndDeviceProfile) (*ttnpb.EndDeviceTemplate, error)
	// GetUplinkDecoder retrieves the codec for decoding uplink messages.
	GetUplinkDecoder(GetCodecRequest) (*ttnpb.MessagePayloadDecoder, error)
	// GetDownlinkDecoder retrieves the codec for decoding downlink messages.
	GetDownlinkDecoder(GetCodecRequest) (*ttnpb.MessagePayloadDecoder, error)
	// GetDownlinkEncoder retrieves the codec for encoding downlink messages.
	GetDownlinkEncoder(GetCodecRequest) (*ttnpb.MessagePayloadEncoder, error)
	// Close closes the store.
	Close() error
}

Store contains end device definitions.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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