@@ -140,6 +140,7 @@ func getUplinkFrame(gatewayID lorawan.EUI64, rxpk RXPK, FakeRxInfoTime bool) (*g
140
140
Channel : uint32 (rxpk .Chan ),
141
141
Board : uint32 (rxpk .Brd ),
142
142
Context : make ([]byte , 4 ),
143
+ Metadata : rxpk .Meta ,
143
144
},
144
145
}
145
146
@@ -344,25 +345,26 @@ type Stat struct {
344
345
345
346
// RXPK contain a RF packet and associated metadata.
346
347
type RXPK struct {
347
- Time * CompactTime `json:"time"` // UTC time of pkt RX, us precision, ISO 8601 'compact' format (e.g. 2013-03-31T16:21:17.528002Z)
348
- Tmms * int64 `json:"tmms"` // GPS time of pkt RX, number of milliseconds since 06.Jan.1980
349
- Tmst uint32 `json:"tmst"` // Internal timestamp of "RX finished" event (32b unsigned)
350
- FTime * uint32 `json:"ftime"` // Fine timestamp, number of nanoseconds since last PPS [0..999999999] (Optional)
351
- AESK uint8 `json:"aesk"` // AES key index used for encrypting fine timestamps
352
- Chan uint8 `json:"chan"` // Concentrator "IF" channel used for RX (unsigned integer)
353
- RFCh uint8 `json:"rfch"` // Concentrator "RF chain" used for RX (unsigned integer)
354
- Stat int8 `json:"stat"` // CRC status: 1 = OK, -1 = fail, 0 = no CRC
355
- Freq float64 `json:"freq"` // RX central frequency in MHz (unsigned float, Hz precision)
356
- Brd uint32 `json:"brd"` // Concentrator board used for RX (unsigned integer)
357
- RSSI int16 `json:"rssi"` // RSSI in dBm (signed integer, 1 dB precision)
358
- Size uint16 `json:"size"` // RF packet payload size in bytes (unsigned integer)
359
- DatR DatR `json:"datr"` // LoRa datarate identifier (eg. SF12BW500) || FSK datarate (unsigned, in bits per second)
360
- Modu string `json:"modu"` // Modulation identifier "LORA" or "FSK"
361
- CodR string `json:"codr"` // LoRa ECC coding rate identifier
362
- LSNR float64 `json:"lsnr"` // Lora SNR ratio in dB (signed float, 0.1 dB precision)
363
- HPW uint8 `json:"hpw"` // LR-FHSS hopping grid number of steps.
364
- Data []byte `json:"data"` // Base64 encoded RF packet payload, padded
365
- RSig []RSig `json:"rsig"` // Received signal information, per antenna (Optional)
348
+ Time * CompactTime `json:"time"` // UTC time of pkt RX, us precision, ISO 8601 'compact' format (e.g. 2013-03-31T16:21:17.528002Z)
349
+ Tmms * int64 `json:"tmms"` // GPS time of pkt RX, number of milliseconds since 06.Jan.1980
350
+ Tmst uint32 `json:"tmst"` // Internal timestamp of "RX finished" event (32b unsigned)
351
+ FTime * uint32 `json:"ftime"` // Fine timestamp, number of nanoseconds since last PPS [0..999999999] (Optional)
352
+ AESK uint8 `json:"aesk"` // AES key index used for encrypting fine timestamps
353
+ Chan uint8 `json:"chan"` // Concentrator "IF" channel used for RX (unsigned integer)
354
+ RFCh uint8 `json:"rfch"` // Concentrator "RF chain" used for RX (unsigned integer)
355
+ Stat int8 `json:"stat"` // CRC status: 1 = OK, -1 = fail, 0 = no CRC
356
+ Freq float64 `json:"freq"` // RX central frequency in MHz (unsigned float, Hz precision)
357
+ Brd uint32 `json:"brd"` // Concentrator board used for RX (unsigned integer)
358
+ RSSI int16 `json:"rssi"` // RSSI in dBm (signed integer, 1 dB precision)
359
+ Size uint16 `json:"size"` // RF packet payload size in bytes (unsigned integer)
360
+ DatR DatR `json:"datr"` // LoRa datarate identifier (eg. SF12BW500) || FSK datarate (unsigned, in bits per second)
361
+ Modu string `json:"modu"` // Modulation identifier "LORA" or "FSK"
362
+ CodR string `json:"codr"` // LoRa ECC coding rate identifier
363
+ LSNR float64 `json:"lsnr"` // Lora SNR ratio in dB (signed float, 0.1 dB precision)
364
+ HPW uint8 `json:"hpw"` // LR-FHSS hopping grid number of steps.
365
+ Data []byte `json:"data"` // Base64 encoded RF packet payload, padded
366
+ RSig []RSig `json:"rsig"` // Received signal information, per antenna (Optional)
367
+ Meta map [string ]string `json:"meta"` // Custom meta-data (Optional, not part of PROTOCOL.TXT)
366
368
}
367
369
368
370
// RSig contains the received signal information per antenna.
0 commit comments