Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SelectDownlinkGateway ¶
func SelectDownlinkGateway(minSNRMargin float64, rxDR int, rxInfo []storage.DeviceGatewayRXInfo) (storage.DeviceGatewayRXInfo, error)
SelectDownlinkGateway returns, given a slice of DeviceGatewayRXInfo elements the gateway (as a DeviceGatewayRXInfo) to use for downlink. In the current implementation it will sort the given slice based on SNR / RSSI, and return:
- A random item from the elements with an SNR > minSNR
- The first item of the sorted slice (failing the above)
Types ¶
Click to show internal directories.
Click to hide internal directories.