-
Notifications
You must be signed in to change notification settings - Fork 302
/
end_device.pb.go
6287 lines (5715 loc) · 305 KB
/
end_device.pb.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// Copyright © 2019 The Things Network Foundation, The Things Industries B.V.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.30.0
// protoc v4.22.2
// source: lorawan-stack/api/end_device.proto
package ttnpb
import (
_ "github.com/TheThingsIndustries/protoc-gen-go-flags/annotations"
_ "github.com/TheThingsIndustries/protoc-gen-go-json/annotations"
_ "github.com/envoyproxy/protoc-gen-validate/validate"
_ "github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2/options"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
durationpb "google.golang.org/protobuf/types/known/durationpb"
fieldmaskpb "google.golang.org/protobuf/types/known/fieldmaskpb"
structpb "google.golang.org/protobuf/types/known/structpb"
timestamppb "google.golang.org/protobuf/types/known/timestamppb"
wrapperspb "google.golang.org/protobuf/types/known/wrapperspb"
reflect "reflect"
sync "sync"
)
const (
// Verify that this generated code is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
// Verify that runtime/protoimpl is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
// Power state of the device.
type PowerState int32
const (
PowerState_POWER_UNKNOWN PowerState = 0
PowerState_POWER_BATTERY PowerState = 1
PowerState_POWER_EXTERNAL PowerState = 2
)
// Enum value maps for PowerState.
var (
PowerState_name = map[int32]string{
0: "POWER_UNKNOWN",
1: "POWER_BATTERY",
2: "POWER_EXTERNAL",
}
PowerState_value = map[string]int32{
"POWER_UNKNOWN": 0,
"POWER_BATTERY": 1,
"POWER_EXTERNAL": 2,
}
)
func (x PowerState) Enum() *PowerState {
p := new(PowerState)
*p = x
return p
}
func (x PowerState) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (PowerState) Descriptor() protoreflect.EnumDescriptor {
return file_lorawan_stack_api_end_device_proto_enumTypes[0].Descriptor()
}
func (PowerState) Type() protoreflect.EnumType {
return &file_lorawan_stack_api_end_device_proto_enumTypes[0]
}
func (x PowerState) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use PowerState.Descriptor instead.
func (PowerState) EnumDescriptor() ([]byte, []int) {
return file_lorawan_stack_api_end_device_proto_rawDescGZIP(), []int{0}
}
type Session struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Device Address, issued by the Network Server or chosen by device manufacturer in case of testing range (beginning with 00-03).
// Known by Network Server, Application Server and Join Server. Owned by Network Server.
DevAddr []byte `protobuf:"bytes,2,opt,name=dev_addr,json=devAddr,proto3" json:"dev_addr,omitempty"`
Keys *SessionKeys `protobuf:"bytes,3,opt,name=keys,proto3" json:"keys,omitempty"`
// Last uplink frame counter value used. Network Server only. Application Server assumes the Network Server checked it.
LastFCntUp uint32 `protobuf:"varint,4,opt,name=last_f_cnt_up,json=lastFCntUp,proto3" json:"last_f_cnt_up,omitempty"`
// Last network downlink frame counter value used. Network Server only.
LastNFCntDown uint32 `protobuf:"varint,5,opt,name=last_n_f_cnt_down,json=lastNFCntDown,proto3" json:"last_n_f_cnt_down,omitempty"`
// Last application downlink frame counter value used. Application Server only.
LastAFCntDown uint32 `protobuf:"varint,6,opt,name=last_a_f_cnt_down,json=lastAFCntDown,proto3" json:"last_a_f_cnt_down,omitempty"`
// Frame counter of the last confirmed downlink message sent. Network Server only.
LastConfFCntDown uint32 `protobuf:"varint,7,opt,name=last_conf_f_cnt_down,json=lastConfFCntDown,proto3" json:"last_conf_f_cnt_down,omitempty"`
// Time when the session started. Network Server only.
StartedAt *timestamppb.Timestamp `protobuf:"bytes,8,opt,name=started_at,json=startedAt,proto3" json:"started_at,omitempty"`
// Queued Application downlink messages. Stored in Application Server and Network Server.
QueuedApplicationDownlinks []*ApplicationDownlink `protobuf:"bytes,9,rep,name=queued_application_downlinks,json=queuedApplicationDownlinks,proto3" json:"queued_application_downlinks,omitempty"`
}
func (x *Session) Reset() {
*x = Session{}
if protoimpl.UnsafeEnabled {
mi := &file_lorawan_stack_api_end_device_proto_msgTypes[0]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *Session) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*Session) ProtoMessage() {}
func (x *Session) ProtoReflect() protoreflect.Message {
mi := &file_lorawan_stack_api_end_device_proto_msgTypes[0]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use Session.ProtoReflect.Descriptor instead.
func (*Session) Descriptor() ([]byte, []int) {
return file_lorawan_stack_api_end_device_proto_rawDescGZIP(), []int{0}
}
func (x *Session) GetDevAddr() []byte {
if x != nil {
return x.DevAddr
}
return nil
}
func (x *Session) GetKeys() *SessionKeys {
if x != nil {
return x.Keys
}
return nil
}
func (x *Session) GetLastFCntUp() uint32 {
if x != nil {
return x.LastFCntUp
}
return 0
}
func (x *Session) GetLastNFCntDown() uint32 {
if x != nil {
return x.LastNFCntDown
}
return 0
}
func (x *Session) GetLastAFCntDown() uint32 {
if x != nil {
return x.LastAFCntDown
}
return 0
}
func (x *Session) GetLastConfFCntDown() uint32 {
if x != nil {
return x.LastConfFCntDown
}
return 0
}
func (x *Session) GetStartedAt() *timestamppb.Timestamp {
if x != nil {
return x.StartedAt
}
return nil
}
func (x *Session) GetQueuedApplicationDownlinks() []*ApplicationDownlink {
if x != nil {
return x.QueuedApplicationDownlinks
}
return nil
}
type BoolValue struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Value bool `protobuf:"varint,1,opt,name=value,proto3" json:"value,omitempty"`
}
func (x *BoolValue) Reset() {
*x = BoolValue{}
if protoimpl.UnsafeEnabled {
mi := &file_lorawan_stack_api_end_device_proto_msgTypes[1]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *BoolValue) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*BoolValue) ProtoMessage() {}
func (x *BoolValue) ProtoReflect() protoreflect.Message {
mi := &file_lorawan_stack_api_end_device_proto_msgTypes[1]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use BoolValue.ProtoReflect.Descriptor instead.
func (*BoolValue) Descriptor() ([]byte, []int) {
return file_lorawan_stack_api_end_device_proto_rawDescGZIP(), []int{1}
}
func (x *BoolValue) GetValue() bool {
if x != nil {
return x.Value
}
return false
}
// MACParameters represent the parameters of the device's MAC layer (active or desired).
// This is used internally by the Network Server.
type MACParameters struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Maximum EIRP (dBm).
MaxEirp float32 `protobuf:"fixed32,1,opt,name=max_eirp,json=maxEirp,proto3" json:"max_eirp,omitempty"`
// ADR: data rate index to use.
AdrDataRateIndex DataRateIndex `protobuf:"varint,4,opt,name=adr_data_rate_index,json=adrDataRateIndex,proto3,enum=ttn.lorawan.v3.DataRateIndex" json:"adr_data_rate_index,omitempty"`
// ADR: transmission power index to use.
AdrTxPowerIndex uint32 `protobuf:"varint,5,opt,name=adr_tx_power_index,json=adrTxPowerIndex,proto3" json:"adr_tx_power_index,omitempty"`
// ADR: number of retransmissions.
AdrNbTrans uint32 `protobuf:"varint,6,opt,name=adr_nb_trans,json=adrNbTrans,proto3" json:"adr_nb_trans,omitempty"`
// ADR: number of messages to wait before setting ADRAckReq.
// This field is deprecated, use adr_ack_limit_exponent instead.
//
// Deprecated: Marked as deprecated in lorawan-stack/api/end_device.proto.
AdrAckLimit uint32 `protobuf:"varint,7,opt,name=adr_ack_limit,json=adrAckLimit,proto3" json:"adr_ack_limit,omitempty"`
// ADR: number of messages to wait after setting ADRAckReq and before changing TxPower or DataRate.
// This field is deprecated, use adr_ack_delay_exponent instead.
//
// Deprecated: Marked as deprecated in lorawan-stack/api/end_device.proto.
AdrAckDelay uint32 `protobuf:"varint,8,opt,name=adr_ack_delay,json=adrAckDelay,proto3" json:"adr_ack_delay,omitempty"`
// Rx1 delay (Rx2 delay is Rx1 delay + 1 second).
Rx1Delay RxDelay `protobuf:"varint,9,opt,name=rx1_delay,json=rx1Delay,proto3,enum=ttn.lorawan.v3.RxDelay" json:"rx1_delay,omitempty"`
// Data rate offset for Rx1.
Rx1DataRateOffset DataRateOffset `protobuf:"varint,10,opt,name=rx1_data_rate_offset,json=rx1DataRateOffset,proto3,enum=ttn.lorawan.v3.DataRateOffset" json:"rx1_data_rate_offset,omitempty"`
// Data rate index for Rx2.
Rx2DataRateIndex DataRateIndex `protobuf:"varint,11,opt,name=rx2_data_rate_index,json=rx2DataRateIndex,proto3,enum=ttn.lorawan.v3.DataRateIndex" json:"rx2_data_rate_index,omitempty"`
// Frequency for Rx2 (Hz).
Rx2Frequency uint64 `protobuf:"varint,12,opt,name=rx2_frequency,json=rx2Frequency,proto3" json:"rx2_frequency,omitempty"`
// Maximum uplink duty cycle (of all channels).
MaxDutyCycle AggregatedDutyCycle `protobuf:"varint,13,opt,name=max_duty_cycle,json=maxDutyCycle,proto3,enum=ttn.lorawan.v3.AggregatedDutyCycle" json:"max_duty_cycle,omitempty"`
// Time within which a rejoin-request must be sent.
RejoinTimePeriodicity RejoinTimeExponent `protobuf:"varint,14,opt,name=rejoin_time_periodicity,json=rejoinTimePeriodicity,proto3,enum=ttn.lorawan.v3.RejoinTimeExponent" json:"rejoin_time_periodicity,omitempty"`
// Message count within which a rejoin-request must be sent.
RejoinCountPeriodicity RejoinCountExponent `protobuf:"varint,15,opt,name=rejoin_count_periodicity,json=rejoinCountPeriodicity,proto3,enum=ttn.lorawan.v3.RejoinCountExponent" json:"rejoin_count_periodicity,omitempty"`
// Frequency of the class B ping slot (Hz).
PingSlotFrequency uint64 `protobuf:"varint,16,opt,name=ping_slot_frequency,json=pingSlotFrequency,proto3" json:"ping_slot_frequency,omitempty"`
// Data rate index of the class B ping slot.
// This field is deprecated, use ping_slot_data_rate_index_value instead.
//
// Deprecated: Marked as deprecated in lorawan-stack/api/end_device.proto.
PingSlotDataRateIndex DataRateIndex `protobuf:"varint,17,opt,name=ping_slot_data_rate_index,json=pingSlotDataRateIndex,proto3,enum=ttn.lorawan.v3.DataRateIndex" json:"ping_slot_data_rate_index,omitempty"`
// Frequency of the class B beacon (Hz).
BeaconFrequency uint64 `protobuf:"varint,18,opt,name=beacon_frequency,json=beaconFrequency,proto3" json:"beacon_frequency,omitempty"`
// Configured uplink channels and optionally Rx1 frequency.
Channels []*MACParameters_Channel `protobuf:"bytes,19,rep,name=channels,proto3" json:"channels,omitempty"`
// Whether uplink dwell time is set (400ms).
// If this field is not set, then the value is either unknown or irrelevant(Network Server cannot modify it).
UplinkDwellTime *BoolValue `protobuf:"bytes,20,opt,name=uplink_dwell_time,json=uplinkDwellTime,proto3" json:"uplink_dwell_time,omitempty"`
// Whether downlink dwell time is set (400ms).
// If this field is not set, then the value is either unknown or irrelevant(Network Server cannot modify it).
DownlinkDwellTime *BoolValue `protobuf:"bytes,21,opt,name=downlink_dwell_time,json=downlinkDwellTime,proto3" json:"downlink_dwell_time,omitempty"`
// ADR: number of messages to wait before setting ADRAckReq.
AdrAckLimitExponent *ADRAckLimitExponentValue `protobuf:"bytes,22,opt,name=adr_ack_limit_exponent,json=adrAckLimitExponent,proto3" json:"adr_ack_limit_exponent,omitempty"`
// ADR: number of messages to wait after setting ADRAckReq and before changing TxPower or DataRate.
AdrAckDelayExponent *ADRAckDelayExponentValue `protobuf:"bytes,23,opt,name=adr_ack_delay_exponent,json=adrAckDelayExponent,proto3" json:"adr_ack_delay_exponent,omitempty"`
// Data rate index of the class B ping slot.
PingSlotDataRateIndexValue *DataRateIndexValue `protobuf:"bytes,24,opt,name=ping_slot_data_rate_index_value,json=pingSlotDataRateIndexValue,proto3" json:"ping_slot_data_rate_index_value,omitempty"`
}
func (x *MACParameters) Reset() {
*x = MACParameters{}
if protoimpl.UnsafeEnabled {
mi := &file_lorawan_stack_api_end_device_proto_msgTypes[2]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *MACParameters) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*MACParameters) ProtoMessage() {}
func (x *MACParameters) ProtoReflect() protoreflect.Message {
mi := &file_lorawan_stack_api_end_device_proto_msgTypes[2]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use MACParameters.ProtoReflect.Descriptor instead.
func (*MACParameters) Descriptor() ([]byte, []int) {
return file_lorawan_stack_api_end_device_proto_rawDescGZIP(), []int{2}
}
func (x *MACParameters) GetMaxEirp() float32 {
if x != nil {
return x.MaxEirp
}
return 0
}
func (x *MACParameters) GetAdrDataRateIndex() DataRateIndex {
if x != nil {
return x.AdrDataRateIndex
}
return DataRateIndex_DATA_RATE_0
}
func (x *MACParameters) GetAdrTxPowerIndex() uint32 {
if x != nil {
return x.AdrTxPowerIndex
}
return 0
}
func (x *MACParameters) GetAdrNbTrans() uint32 {
if x != nil {
return x.AdrNbTrans
}
return 0
}
// Deprecated: Marked as deprecated in lorawan-stack/api/end_device.proto.
func (x *MACParameters) GetAdrAckLimit() uint32 {
if x != nil {
return x.AdrAckLimit
}
return 0
}
// Deprecated: Marked as deprecated in lorawan-stack/api/end_device.proto.
func (x *MACParameters) GetAdrAckDelay() uint32 {
if x != nil {
return x.AdrAckDelay
}
return 0
}
func (x *MACParameters) GetRx1Delay() RxDelay {
if x != nil {
return x.Rx1Delay
}
return RxDelay_RX_DELAY_0
}
func (x *MACParameters) GetRx1DataRateOffset() DataRateOffset {
if x != nil {
return x.Rx1DataRateOffset
}
return DataRateOffset_DATA_RATE_OFFSET_0
}
func (x *MACParameters) GetRx2DataRateIndex() DataRateIndex {
if x != nil {
return x.Rx2DataRateIndex
}
return DataRateIndex_DATA_RATE_0
}
func (x *MACParameters) GetRx2Frequency() uint64 {
if x != nil {
return x.Rx2Frequency
}
return 0
}
func (x *MACParameters) GetMaxDutyCycle() AggregatedDutyCycle {
if x != nil {
return x.MaxDutyCycle
}
return AggregatedDutyCycle_DUTY_CYCLE_1
}
func (x *MACParameters) GetRejoinTimePeriodicity() RejoinTimeExponent {
if x != nil {
return x.RejoinTimePeriodicity
}
return RejoinTimeExponent_REJOIN_TIME_0
}
func (x *MACParameters) GetRejoinCountPeriodicity() RejoinCountExponent {
if x != nil {
return x.RejoinCountPeriodicity
}
return RejoinCountExponent_REJOIN_COUNT_16
}
func (x *MACParameters) GetPingSlotFrequency() uint64 {
if x != nil {
return x.PingSlotFrequency
}
return 0
}
// Deprecated: Marked as deprecated in lorawan-stack/api/end_device.proto.
func (x *MACParameters) GetPingSlotDataRateIndex() DataRateIndex {
if x != nil {
return x.PingSlotDataRateIndex
}
return DataRateIndex_DATA_RATE_0
}
func (x *MACParameters) GetBeaconFrequency() uint64 {
if x != nil {
return x.BeaconFrequency
}
return 0
}
func (x *MACParameters) GetChannels() []*MACParameters_Channel {
if x != nil {
return x.Channels
}
return nil
}
func (x *MACParameters) GetUplinkDwellTime() *BoolValue {
if x != nil {
return x.UplinkDwellTime
}
return nil
}
func (x *MACParameters) GetDownlinkDwellTime() *BoolValue {
if x != nil {
return x.DownlinkDwellTime
}
return nil
}
func (x *MACParameters) GetAdrAckLimitExponent() *ADRAckLimitExponentValue {
if x != nil {
return x.AdrAckLimitExponent
}
return nil
}
func (x *MACParameters) GetAdrAckDelayExponent() *ADRAckDelayExponentValue {
if x != nil {
return x.AdrAckDelayExponent
}
return nil
}
func (x *MACParameters) GetPingSlotDataRateIndexValue() *DataRateIndexValue {
if x != nil {
return x.PingSlotDataRateIndexValue
}
return nil
}
// Template for creating end devices.
type EndDeviceVersion struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Version identifiers.
Ids *EndDeviceVersionIdentifiers `protobuf:"bytes,1,opt,name=ids,proto3" json:"ids,omitempty"`
// LoRaWAN MAC version.
LorawanVersion MACVersion `protobuf:"varint,2,opt,name=lorawan_version,json=lorawanVersion,proto3,enum=ttn.lorawan.v3.MACVersion" json:"lorawan_version,omitempty"`
// LoRaWAN PHY version.
LorawanPhyVersion PHYVersion `protobuf:"varint,3,opt,name=lorawan_phy_version,json=lorawanPhyVersion,proto3,enum=ttn.lorawan.v3.PHYVersion" json:"lorawan_phy_version,omitempty"`
// ID of the frequency plan used by this device.
FrequencyPlanId string `protobuf:"bytes,4,opt,name=frequency_plan_id,json=frequencyPlanId,proto3" json:"frequency_plan_id,omitempty"`
// Photos contains file names of device photos.
Photos []string `protobuf:"bytes,5,rep,name=photos,proto3" json:"photos,omitempty"`
// Whether the device supports class B.
SupportsClassB bool `protobuf:"varint,6,opt,name=supports_class_b,json=supportsClassB,proto3" json:"supports_class_b,omitempty"`
// Whether the device supports class C.
SupportsClassC bool `protobuf:"varint,7,opt,name=supports_class_c,json=supportsClassC,proto3" json:"supports_class_c,omitempty"`
// Default MAC layer settings of the device.
DefaultMacSettings *MACSettings `protobuf:"bytes,8,opt,name=default_mac_settings,json=defaultMacSettings,proto3" json:"default_mac_settings,omitempty"`
// Minimum frequency the device is capable of using (Hz).
MinFrequency uint64 `protobuf:"varint,9,opt,name=min_frequency,json=minFrequency,proto3" json:"min_frequency,omitempty"`
// Maximum frequency the device is capable of using (Hz).
MaxFrequency uint64 `protobuf:"varint,10,opt,name=max_frequency,json=maxFrequency,proto3" json:"max_frequency,omitempty"`
// The device supports join (it's OTAA).
SupportsJoin bool `protobuf:"varint,11,opt,name=supports_join,json=supportsJoin,proto3" json:"supports_join,omitempty"`
// Whether the device resets the join and dev nonces (not LoRaWAN compliant).
ResetsJoinNonces bool `protobuf:"varint,12,opt,name=resets_join_nonces,json=resetsJoinNonces,proto3" json:"resets_join_nonces,omitempty"`
// Default formatters defining the payload formats for this end device.
DefaultFormatters *MessagePayloadFormatters `protobuf:"bytes,13,opt,name=default_formatters,json=defaultFormatters,proto3" json:"default_formatters,omitempty"`
}
func (x *EndDeviceVersion) Reset() {
*x = EndDeviceVersion{}
if protoimpl.UnsafeEnabled {
mi := &file_lorawan_stack_api_end_device_proto_msgTypes[3]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *EndDeviceVersion) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*EndDeviceVersion) ProtoMessage() {}
func (x *EndDeviceVersion) ProtoReflect() protoreflect.Message {
mi := &file_lorawan_stack_api_end_device_proto_msgTypes[3]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use EndDeviceVersion.ProtoReflect.Descriptor instead.
func (*EndDeviceVersion) Descriptor() ([]byte, []int) {
return file_lorawan_stack_api_end_device_proto_rawDescGZIP(), []int{3}
}
func (x *EndDeviceVersion) GetIds() *EndDeviceVersionIdentifiers {
if x != nil {
return x.Ids
}
return nil
}
func (x *EndDeviceVersion) GetLorawanVersion() MACVersion {
if x != nil {
return x.LorawanVersion
}
return MACVersion_MAC_UNKNOWN
}
func (x *EndDeviceVersion) GetLorawanPhyVersion() PHYVersion {
if x != nil {
return x.LorawanPhyVersion
}
return PHYVersion_PHY_UNKNOWN
}
func (x *EndDeviceVersion) GetFrequencyPlanId() string {
if x != nil {
return x.FrequencyPlanId
}
return ""
}
func (x *EndDeviceVersion) GetPhotos() []string {
if x != nil {
return x.Photos
}
return nil
}
func (x *EndDeviceVersion) GetSupportsClassB() bool {
if x != nil {
return x.SupportsClassB
}
return false
}
func (x *EndDeviceVersion) GetSupportsClassC() bool {
if x != nil {
return x.SupportsClassC
}
return false
}
func (x *EndDeviceVersion) GetDefaultMacSettings() *MACSettings {
if x != nil {
return x.DefaultMacSettings
}
return nil
}
func (x *EndDeviceVersion) GetMinFrequency() uint64 {
if x != nil {
return x.MinFrequency
}
return 0
}
func (x *EndDeviceVersion) GetMaxFrequency() uint64 {
if x != nil {
return x.MaxFrequency
}
return 0
}
func (x *EndDeviceVersion) GetSupportsJoin() bool {
if x != nil {
return x.SupportsJoin
}
return false
}
func (x *EndDeviceVersion) GetResetsJoinNonces() bool {
if x != nil {
return x.ResetsJoinNonces
}
return false
}
func (x *EndDeviceVersion) GetDefaultFormatters() *MessagePayloadFormatters {
if x != nil {
return x.DefaultFormatters
}
return nil
}
// Adaptive Data Rate settings.
type ADRSettings struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Types that are assignable to Mode:
// *ADRSettings_Static
// *ADRSettings_Dynamic
// *ADRSettings_Disabled
Mode isADRSettings_Mode `protobuf_oneof:"mode"`
}
func (x *ADRSettings) Reset() {
*x = ADRSettings{}
if protoimpl.UnsafeEnabled {
mi := &file_lorawan_stack_api_end_device_proto_msgTypes[4]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *ADRSettings) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*ADRSettings) ProtoMessage() {}
func (x *ADRSettings) ProtoReflect() protoreflect.Message {
mi := &file_lorawan_stack_api_end_device_proto_msgTypes[4]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use ADRSettings.ProtoReflect.Descriptor instead.
func (*ADRSettings) Descriptor() ([]byte, []int) {
return file_lorawan_stack_api_end_device_proto_rawDescGZIP(), []int{4}
}
func (m *ADRSettings) GetMode() isADRSettings_Mode {
if m != nil {
return m.Mode
}
return nil
}
func (x *ADRSettings) GetStatic() *ADRSettings_StaticMode {
if x, ok := x.GetMode().(*ADRSettings_Static); ok {
return x.Static
}
return nil
}
func (x *ADRSettings) GetDynamic() *ADRSettings_DynamicMode {
if x, ok := x.GetMode().(*ADRSettings_Dynamic); ok {
return x.Dynamic
}
return nil
}
func (x *ADRSettings) GetDisabled() *ADRSettings_DisabledMode {
if x, ok := x.GetMode().(*ADRSettings_Disabled); ok {
return x.Disabled
}
return nil
}
type isADRSettings_Mode interface {
isADRSettings_Mode()
}
type ADRSettings_Static struct {
Static *ADRSettings_StaticMode `protobuf:"bytes,1,opt,name=static,proto3,oneof"`
}
type ADRSettings_Dynamic struct {
Dynamic *ADRSettings_DynamicMode `protobuf:"bytes,2,opt,name=dynamic,proto3,oneof"`
}
type ADRSettings_Disabled struct {
Disabled *ADRSettings_DisabledMode `protobuf:"bytes,3,opt,name=disabled,proto3,oneof"`
}
func (*ADRSettings_Static) isADRSettings_Mode() {}
func (*ADRSettings_Dynamic) isADRSettings_Mode() {}
func (*ADRSettings_Disabled) isADRSettings_Mode() {}
type MACSettings struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Maximum delay for the device to answer a MAC request or a confirmed downlink frame.
// If unset, the default value from Network Server configuration will be used.
ClassBTimeout *durationpb.Duration `protobuf:"bytes,1,opt,name=class_b_timeout,json=classBTimeout,proto3" json:"class_b_timeout,omitempty"`
// Periodicity of the class B ping slot.
// If unset, the default value from Network Server configuration will be used.
PingSlotPeriodicity *PingSlotPeriodValue `protobuf:"bytes,2,opt,name=ping_slot_periodicity,json=pingSlotPeriodicity,proto3" json:"ping_slot_periodicity,omitempty"`
// Data rate index of the class B ping slot.
// If unset, the default value from Network Server configuration will be used.
PingSlotDataRateIndex *DataRateIndexValue `protobuf:"bytes,3,opt,name=ping_slot_data_rate_index,json=pingSlotDataRateIndex,proto3" json:"ping_slot_data_rate_index,omitempty"`
// Frequency of the class B ping slot (Hz).
// If unset, the default value from Network Server configuration will be used.
PingSlotFrequency *ZeroableFrequencyValue `protobuf:"bytes,4,opt,name=ping_slot_frequency,json=pingSlotFrequency,proto3" json:"ping_slot_frequency,omitempty"`
// Frequency of the class B beacon (Hz).
// If unset, the default value from Network Server configuration will be used.
BeaconFrequency *ZeroableFrequencyValue `protobuf:"bytes,25,opt,name=beacon_frequency,json=beaconFrequency,proto3" json:"beacon_frequency,omitempty"`
// Maximum delay for the device to answer a MAC request or a confirmed downlink frame.
// If unset, the default value from Network Server configuration will be used.
ClassCTimeout *durationpb.Duration `protobuf:"bytes,5,opt,name=class_c_timeout,json=classCTimeout,proto3" json:"class_c_timeout,omitempty"`
// Class A Rx1 delay.
// If unset, the default value from Network Server configuration or regional parameters specification will be used.
Rx1Delay *RxDelayValue `protobuf:"bytes,6,opt,name=rx1_delay,json=rx1Delay,proto3" json:"rx1_delay,omitempty"`
// Rx1 data rate offset.
// If unset, the default value from Network Server configuration will be used.
Rx1DataRateOffset *DataRateOffsetValue `protobuf:"bytes,7,opt,name=rx1_data_rate_offset,json=rx1DataRateOffset,proto3" json:"rx1_data_rate_offset,omitempty"`
// Data rate index for Rx2.
// If unset, the default value from Network Server configuration or regional parameters specification will be used.
Rx2DataRateIndex *DataRateIndexValue `protobuf:"bytes,8,opt,name=rx2_data_rate_index,json=rx2DataRateIndex,proto3" json:"rx2_data_rate_index,omitempty"`
// Frequency for Rx2 (Hz).
// If unset, the default value from Network Server configuration or regional parameters specification will be used.
Rx2Frequency *FrequencyValue `protobuf:"bytes,9,opt,name=rx2_frequency,json=rx2Frequency,proto3" json:"rx2_frequency,omitempty"`
// List of factory-preset frequencies.
// If unset, the default value from Network Server configuration or regional parameters specification will be used.
FactoryPresetFrequencies []uint64 `protobuf:"varint,10,rep,packed,name=factory_preset_frequencies,json=factoryPresetFrequencies,proto3" json:"factory_preset_frequencies,omitempty"`
// Maximum uplink duty cycle (of all channels).
MaxDutyCycle *AggregatedDutyCycleValue `protobuf:"bytes,11,opt,name=max_duty_cycle,json=maxDutyCycle,proto3" json:"max_duty_cycle,omitempty"`
// Whether the device supports 32-bit frame counters.
// If unset, the default value from Network Server configuration will be used.
Supports_32BitFCnt *BoolValue `protobuf:"bytes,12,opt,name=supports_32_bit_f_cnt,json=supports32BitFCnt,proto3" json:"supports_32_bit_f_cnt,omitempty"`
// Whether the Network Server should use ADR for the device.
// This field is deprecated, use adr_settings instead.
//
// Deprecated: Marked as deprecated in lorawan-stack/api/end_device.proto.
UseAdr *BoolValue `protobuf:"bytes,13,opt,name=use_adr,json=useAdr,proto3" json:"use_adr,omitempty"`
// The ADR margin (dB) tells the network server how much margin it should add in ADR requests.
// A bigger margin is less efficient, but gives a better chance of successful reception.
// This field is deprecated, use adr_settings.dynamic.margin instead.
//
// Deprecated: Marked as deprecated in lorawan-stack/api/end_device.proto.
AdrMargin *wrapperspb.FloatValue `protobuf:"bytes,14,opt,name=adr_margin,json=adrMargin,proto3" json:"adr_margin,omitempty"`
// Whether the device resets the frame counters (not LoRaWAN compliant).
// If unset, the default value from Network Server configuration will be used.
ResetsFCnt *BoolValue `protobuf:"bytes,15,opt,name=resets_f_cnt,json=resetsFCnt,proto3" json:"resets_f_cnt,omitempty"`
// The interval after which a DevStatusReq MACCommand shall be sent.
// If unset, the default value from Network Server configuration will be used.
StatusTimePeriodicity *durationpb.Duration `protobuf:"bytes,16,opt,name=status_time_periodicity,json=statusTimePeriodicity,proto3" json:"status_time_periodicity,omitempty"`
// Number of uplink messages after which a DevStatusReq MACCommand shall be sent.
// If unset, the default value from Network Server configuration will be used.
StatusCountPeriodicity *wrapperspb.UInt32Value `protobuf:"bytes,17,opt,name=status_count_periodicity,json=statusCountPeriodicity,proto3" json:"status_count_periodicity,omitempty"`
// The Rx1 delay Network Server should configure device to use via MAC commands or Join-Accept.
// If unset, the default value from Network Server configuration or regional parameters specification will be used.
DesiredRx1Delay *RxDelayValue `protobuf:"bytes,18,opt,name=desired_rx1_delay,json=desiredRx1Delay,proto3" json:"desired_rx1_delay,omitempty"`
// The Rx1 data rate offset Network Server should configure device to use via MAC commands or Join-Accept.
// If unset, the default value from Network Server configuration will be used.
DesiredRx1DataRateOffset *DataRateOffsetValue `protobuf:"bytes,19,opt,name=desired_rx1_data_rate_offset,json=desiredRx1DataRateOffset,proto3" json:"desired_rx1_data_rate_offset,omitempty"`
// The Rx2 data rate index Network Server should configure device to use via MAC commands or Join-Accept.
// If unset, the default value from frequency plan, Network Server configuration or regional parameters specification will be used.
DesiredRx2DataRateIndex *DataRateIndexValue `protobuf:"bytes,20,opt,name=desired_rx2_data_rate_index,json=desiredRx2DataRateIndex,proto3" json:"desired_rx2_data_rate_index,omitempty"`
// The Rx2 frequency index Network Server should configure device to use via MAC commands.
// If unset, the default value from frequency plan, Network Server configuration or regional parameters specification will be used.
DesiredRx2Frequency *FrequencyValue `protobuf:"bytes,21,opt,name=desired_rx2_frequency,json=desiredRx2Frequency,proto3" json:"desired_rx2_frequency,omitempty"`
// The maximum uplink duty cycle (of all channels) Network Server should configure device to use via MAC commands.
// If unset, the default value from Network Server configuration will be used.
DesiredMaxDutyCycle *AggregatedDutyCycleValue `protobuf:"bytes,22,opt,name=desired_max_duty_cycle,json=desiredMaxDutyCycle,proto3" json:"desired_max_duty_cycle,omitempty"`
// The ADR ACK limit Network Server should configure device to use via MAC commands.
// If unset, the default value from Network Server configuration or regional parameters specification will be used.
DesiredAdrAckLimitExponent *ADRAckLimitExponentValue `protobuf:"bytes,23,opt,name=desired_adr_ack_limit_exponent,json=desiredAdrAckLimitExponent,proto3" json:"desired_adr_ack_limit_exponent,omitempty"`
// The ADR ACK delay Network Server should configure device to use via MAC commands.
// If unset, the default value from Network Server configuration or regional parameters specification will be used.
DesiredAdrAckDelayExponent *ADRAckDelayExponentValue `protobuf:"bytes,24,opt,name=desired_adr_ack_delay_exponent,json=desiredAdrAckDelayExponent,proto3" json:"desired_adr_ack_delay_exponent,omitempty"`
// The data rate index of the class B ping slot Network Server should configure device to use via MAC commands.
// If unset, the default value from Network Server configuration will be used.
DesiredPingSlotDataRateIndex *DataRateIndexValue `protobuf:"bytes,27,opt,name=desired_ping_slot_data_rate_index,json=desiredPingSlotDataRateIndex,proto3" json:"desired_ping_slot_data_rate_index,omitempty"`
// The frequency of the class B ping slot (Hz) Network Server should configure device to use via MAC commands.
// If unset, the default value from Network Server configuration or regional parameters specification will be used.
DesiredPingSlotFrequency *ZeroableFrequencyValue `protobuf:"bytes,28,opt,name=desired_ping_slot_frequency,json=desiredPingSlotFrequency,proto3" json:"desired_ping_slot_frequency,omitempty"`
// The frequency of the class B beacon (Hz) Network Server should configure device to use via MAC commands.
// If unset, the default value from Network Server configuration will be used.
DesiredBeaconFrequency *ZeroableFrequencyValue `protobuf:"bytes,29,opt,name=desired_beacon_frequency,json=desiredBeaconFrequency,proto3" json:"desired_beacon_frequency,omitempty"`
// Maximum EIRP (dBm).
// If unset, the default value from regional parameters specification will be used.
DesiredMaxEirp *DeviceEIRPValue `protobuf:"bytes,30,opt,name=desired_max_eirp,json=desiredMaxEirp,proto3" json:"desired_max_eirp,omitempty"`
// The minimum duration passed before a network-initiated(e.g. Class B or C) downlink following an arbitrary downlink.
ClassBCDownlinkInterval *durationpb.Duration `protobuf:"bytes,31,opt,name=class_b_c_downlink_interval,json=classBCDownlinkInterval,proto3" json:"class_b_c_downlink_interval,omitempty"`
// Whether uplink dwell time is set (400ms).
// If unset, the default value from Network Server configuration or regional parameters specification will be used.
UplinkDwellTime *BoolValue `protobuf:"bytes,32,opt,name=uplink_dwell_time,json=uplinkDwellTime,proto3" json:"uplink_dwell_time,omitempty"`
// Whether downlink dwell time is set (400ms).
// If unset, the default value from Network Server configuration or regional parameters specification will be used.
DownlinkDwellTime *BoolValue `protobuf:"bytes,33,opt,name=downlink_dwell_time,json=downlinkDwellTime,proto3" json:"downlink_dwell_time,omitempty"`
// Adaptive Data Rate settings.
// If unset, the default value from Network Server configuration or regional parameters specification will be used.
Adr *ADRSettings `protobuf:"bytes,34,opt,name=adr,proto3" json:"adr,omitempty"`
// Whether or not downlink messages should be scheduled.
// This option can be used in order to disable any downlink interaction with the end device. It will affect all types
// of downlink messages: data and MAC downlinks, and join accepts.
ScheduleDownlinks *BoolValue `protobuf:"bytes,35,opt,name=schedule_downlinks,json=scheduleDownlinks,proto3" json:"schedule_downlinks,omitempty"`
}
func (x *MACSettings) Reset() {
*x = MACSettings{}
if protoimpl.UnsafeEnabled {
mi := &file_lorawan_stack_api_end_device_proto_msgTypes[5]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *MACSettings) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*MACSettings) ProtoMessage() {}
func (x *MACSettings) ProtoReflect() protoreflect.Message {
mi := &file_lorawan_stack_api_end_device_proto_msgTypes[5]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use MACSettings.ProtoReflect.Descriptor instead.
func (*MACSettings) Descriptor() ([]byte, []int) {
return file_lorawan_stack_api_end_device_proto_rawDescGZIP(), []int{5}
}
func (x *MACSettings) GetClassBTimeout() *durationpb.Duration {
if x != nil {
return x.ClassBTimeout
}
return nil
}
func (x *MACSettings) GetPingSlotPeriodicity() *PingSlotPeriodValue {
if x != nil {
return x.PingSlotPeriodicity
}
return nil
}
func (x *MACSettings) GetPingSlotDataRateIndex() *DataRateIndexValue {
if x != nil {
return x.PingSlotDataRateIndex
}
return nil
}
func (x *MACSettings) GetPingSlotFrequency() *ZeroableFrequencyValue {
if x != nil {
return x.PingSlotFrequency
}
return nil
}
func (x *MACSettings) GetBeaconFrequency() *ZeroableFrequencyValue {
if x != nil {
return x.BeaconFrequency
}
return nil
}
func (x *MACSettings) GetClassCTimeout() *durationpb.Duration {
if x != nil {
return x.ClassCTimeout
}
return nil
}
func (x *MACSettings) GetRx1Delay() *RxDelayValue {
if x != nil {
return x.Rx1Delay
}
return nil
}
func (x *MACSettings) GetRx1DataRateOffset() *DataRateOffsetValue {
if x != nil {
return x.Rx1DataRateOffset
}
return nil
}
func (x *MACSettings) GetRx2DataRateIndex() *DataRateIndexValue {
if x != nil {
return x.Rx2DataRateIndex
}
return nil
}
func (x *MACSettings) GetRx2Frequency() *FrequencyValue {
if x != nil {
return x.Rx2Frequency
}
return nil
}
func (x *MACSettings) GetFactoryPresetFrequencies() []uint64 {
if x != nil {
return x.FactoryPresetFrequencies
}
return nil
}
func (x *MACSettings) GetMaxDutyCycle() *AggregatedDutyCycleValue {
if x != nil {
return x.MaxDutyCycle
}
return nil
}
func (x *MACSettings) GetSupports_32BitFCnt() *BoolValue {
if x != nil {
return x.Supports_32BitFCnt
}
return nil
}
// Deprecated: Marked as deprecated in lorawan-stack/api/end_device.proto.
func (x *MACSettings) GetUseAdr() *BoolValue {
if x != nil {
return x.UseAdr
}
return nil