mirror of
https://github.com/chirpstack/chirpstack.git
synced 2025-05-07 19:38:25 +00:00
Update JS payload codec configuration and templates.
This commit is contained in:
parent
f2e6d77ce4
commit
d69ff895b6
358
api/go/api/device_profile.pb.go
vendored
358
api/go/api/device_profile.pb.go
vendored
@ -97,10 +97,8 @@ type DeviceProfile struct {
|
|||||||
AdrAlgorithmId string `protobuf:"bytes,7,opt,name=adr_algorithm_id,json=adrAlgorithmId,proto3" json:"adr_algorithm_id,omitempty"`
|
AdrAlgorithmId string `protobuf:"bytes,7,opt,name=adr_algorithm_id,json=adrAlgorithmId,proto3" json:"adr_algorithm_id,omitempty"`
|
||||||
// Payload codec runtime.
|
// Payload codec runtime.
|
||||||
PayloadCodecRuntime CodecRuntime `protobuf:"varint,8,opt,name=payload_codec_runtime,json=payloadCodecRuntime,proto3,enum=api.CodecRuntime" json:"payload_codec_runtime,omitempty"`
|
PayloadCodecRuntime CodecRuntime `protobuf:"varint,8,opt,name=payload_codec_runtime,json=payloadCodecRuntime,proto3,enum=api.CodecRuntime" json:"payload_codec_runtime,omitempty"`
|
||||||
// Payload codec encoder config.
|
// Payload codec script.
|
||||||
PayloadEncoderConfig string `protobuf:"bytes,9,opt,name=payload_encoder_config,json=payloadEncoderConfig,proto3" json:"payload_encoder_config,omitempty"`
|
PayloadCodecScript string `protobuf:"bytes,9,opt,name=payload_codec_script,json=payloadCodecScript,proto3" json:"payload_codec_script,omitempty"`
|
||||||
// Payload codec decoder config.
|
|
||||||
PayloadDecoderConfig string `protobuf:"bytes,10,opt,name=payload_decoder_config,json=payloadDecoderConfig,proto3" json:"payload_decoder_config,omitempty"`
|
|
||||||
// Uplink interval (seconds).
|
// Uplink interval (seconds).
|
||||||
// This defines the expected uplink interval which the device uses for
|
// This defines the expected uplink interval which the device uses for
|
||||||
// communication. When the uplink interval has expired and no uplink has
|
// communication. When the uplink interval has expired and no uplink has
|
||||||
@ -228,16 +226,9 @@ func (x *DeviceProfile) GetPayloadCodecRuntime() CodecRuntime {
|
|||||||
return CodecRuntime_NONE
|
return CodecRuntime_NONE
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *DeviceProfile) GetPayloadEncoderConfig() string {
|
func (x *DeviceProfile) GetPayloadCodecScript() string {
|
||||||
if x != nil {
|
if x != nil {
|
||||||
return x.PayloadEncoderConfig
|
return x.PayloadCodecScript
|
||||||
}
|
|
||||||
return ""
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *DeviceProfile) GetPayloadDecoderConfig() string {
|
|
||||||
if x != nil {
|
|
||||||
return x.PayloadDecoderConfig
|
|
||||||
}
|
}
|
||||||
return ""
|
return ""
|
||||||
}
|
}
|
||||||
@ -1038,7 +1029,7 @@ var file_api_device_profile_proto_rawDesc = []byte{
|
|||||||
0x1a, 0x1b, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75,
|
0x1a, 0x1b, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75,
|
||||||
0x66, 0x2f, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x13, 0x63,
|
0x66, 0x2f, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x13, 0x63,
|
||||||
0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f,
|
0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f,
|
||||||
0x74, 0x6f, 0x22, 0x9a, 0x09, 0x0a, 0x0d, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f,
|
0x74, 0x6f, 0x22, 0xe0, 0x08, 0x0a, 0x0d, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f,
|
||||||
0x66, 0x69, 0x6c, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
|
0x66, 0x69, 0x6c, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
|
||||||
0x52, 0x02, 0x69, 0x64, 0x12, 0x1b, 0x0a, 0x09, 0x74, 0x65, 0x6e, 0x61, 0x6e, 0x74, 0x5f, 0x69,
|
0x52, 0x02, 0x69, 0x64, 0x12, 0x1b, 0x0a, 0x09, 0x74, 0x65, 0x6e, 0x61, 0x6e, 0x74, 0x5f, 0x69,
|
||||||
0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x74, 0x65, 0x6e, 0x61, 0x6e, 0x74, 0x49,
|
0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x74, 0x65, 0x6e, 0x61, 0x6e, 0x74, 0x49,
|
||||||
@ -1060,104 +1051,57 @@ var file_api_device_profile_proto_rawDesc = []byte{
|
|||||||
0x61, 0x64, 0x5f, 0x63, 0x6f, 0x64, 0x65, 0x63, 0x5f, 0x72, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65,
|
0x61, 0x64, 0x5f, 0x63, 0x6f, 0x64, 0x65, 0x63, 0x5f, 0x72, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65,
|
||||||
0x18, 0x08, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x11, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x43, 0x6f, 0x64,
|
0x18, 0x08, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x11, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x43, 0x6f, 0x64,
|
||||||
0x65, 0x63, 0x52, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x52, 0x13, 0x70, 0x61, 0x79, 0x6c, 0x6f,
|
0x65, 0x63, 0x52, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x52, 0x13, 0x70, 0x61, 0x79, 0x6c, 0x6f,
|
||||||
0x61, 0x64, 0x43, 0x6f, 0x64, 0x65, 0x63, 0x52, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x34,
|
0x61, 0x64, 0x43, 0x6f, 0x64, 0x65, 0x63, 0x52, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x30,
|
||||||
0x0a, 0x16, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x65, 0x6e, 0x63, 0x6f, 0x64, 0x65,
|
0x0a, 0x14, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x63, 0x6f, 0x64, 0x65, 0x63, 0x5f,
|
||||||
0x72, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14,
|
0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x12, 0x70, 0x61,
|
||||||
0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x45, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x72, 0x43, 0x6f,
|
0x79, 0x6c, 0x6f, 0x61, 0x64, 0x43, 0x6f, 0x64, 0x65, 0x63, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74,
|
||||||
0x6e, 0x66, 0x69, 0x67, 0x12, 0x34, 0x0a, 0x16, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x5f,
|
0x12, 0x27, 0x0a, 0x0f, 0x75, 0x70, 0x6c, 0x69, 0x6e, 0x6b, 0x5f, 0x69, 0x6e, 0x74, 0x65, 0x72,
|
||||||
0x64, 0x65, 0x63, 0x6f, 0x64, 0x65, 0x72, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x0a,
|
0x76, 0x61, 0x6c, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0e, 0x75, 0x70, 0x6c, 0x69, 0x6e,
|
||||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x44, 0x65, 0x63,
|
0x6b, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x76, 0x61, 0x6c, 0x12, 0x3b, 0x0a, 0x1a, 0x64, 0x65, 0x76,
|
||||||
0x6f, 0x64, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x27, 0x0a, 0x0f, 0x75, 0x70,
|
0x69, 0x63, 0x65, 0x5f, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x5f, 0x72, 0x65, 0x71, 0x5f, 0x69,
|
||||||
0x6c, 0x69, 0x6e, 0x6b, 0x5f, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x76, 0x61, 0x6c, 0x18, 0x0b, 0x20,
|
0x6e, 0x74, 0x65, 0x72, 0x76, 0x61, 0x6c, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x17, 0x64,
|
||||||
0x01, 0x28, 0x0d, 0x52, 0x0e, 0x75, 0x70, 0x6c, 0x69, 0x6e, 0x6b, 0x49, 0x6e, 0x74, 0x65, 0x72,
|
0x65, 0x76, 0x69, 0x63, 0x65, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x71, 0x49, 0x6e,
|
||||||
0x76, 0x61, 0x6c, 0x12, 0x3b, 0x0a, 0x1a, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x5f, 0x73, 0x74,
|
0x74, 0x65, 0x72, 0x76, 0x61, 0x6c, 0x12, 0x23, 0x0a, 0x0d, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72,
|
||||||
0x61, 0x74, 0x75, 0x73, 0x5f, 0x72, 0x65, 0x71, 0x5f, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x76, 0x61,
|
0x74, 0x73, 0x5f, 0x6f, 0x74, 0x61, 0x61, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0c, 0x73,
|
||||||
0x6c, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x17, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x53,
|
0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x4f, 0x74, 0x61, 0x61, 0x12, 0x28, 0x0a, 0x10, 0x73,
|
||||||
0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x71, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x76, 0x61, 0x6c,
|
0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x5f, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x5f, 0x62, 0x18,
|
||||||
0x12, 0x23, 0x0a, 0x0d, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x5f, 0x6f, 0x74, 0x61,
|
0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0e, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x43,
|
||||||
0x61, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0c, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74,
|
0x6c, 0x61, 0x73, 0x73, 0x42, 0x12, 0x28, 0x0a, 0x10, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74,
|
||||||
0x73, 0x4f, 0x74, 0x61, 0x61, 0x12, 0x28, 0x0a, 0x10, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74,
|
0x73, 0x5f, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x5f, 0x63, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52,
|
||||||
0x73, 0x5f, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x5f, 0x62, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52,
|
0x0e, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x43, 0x6c, 0x61, 0x73, 0x73, 0x43, 0x12,
|
||||||
0x0e, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x43, 0x6c, 0x61, 0x73, 0x73, 0x42, 0x12,
|
0x26, 0x0a, 0x0f, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x5f, 0x62, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x6f,
|
||||||
0x28, 0x0a, 0x10, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x5f, 0x63, 0x6c, 0x61, 0x73,
|
0x75, 0x74, 0x18, 0x10, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0d, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x42,
|
||||||
0x73, 0x5f, 0x63, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0e, 0x73, 0x75, 0x70, 0x70, 0x6f,
|
0x54, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x12, 0x36, 0x0a, 0x18, 0x63, 0x6c, 0x61, 0x73, 0x73,
|
||||||
0x72, 0x74, 0x73, 0x43, 0x6c, 0x61, 0x73, 0x73, 0x43, 0x12, 0x26, 0x0a, 0x0f, 0x63, 0x6c, 0x61,
|
0x5f, 0x62, 0x5f, 0x70, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x6c, 0x6f, 0x74, 0x5f, 0x70, 0x65, 0x72,
|
||||||
0x73, 0x73, 0x5f, 0x62, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x18, 0x10, 0x20, 0x01,
|
0x69, 0x6f, 0x64, 0x18, 0x11, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x14, 0x63, 0x6c, 0x61, 0x73, 0x73,
|
||||||
0x28, 0x0d, 0x52, 0x0d, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x42, 0x54, 0x69, 0x6d, 0x65, 0x6f, 0x75,
|
0x42, 0x50, 0x69, 0x6e, 0x67, 0x53, 0x6c, 0x6f, 0x74, 0x50, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x12,
|
||||||
0x74, 0x12, 0x36, 0x0a, 0x18, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x5f, 0x62, 0x5f, 0x70, 0x69, 0x6e,
|
0x2e, 0x0a, 0x14, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x5f, 0x62, 0x5f, 0x70, 0x69, 0x6e, 0x67, 0x5f,
|
||||||
0x67, 0x5f, 0x73, 0x6c, 0x6f, 0x74, 0x5f, 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x18, 0x11, 0x20,
|
0x73, 0x6c, 0x6f, 0x74, 0x5f, 0x64, 0x72, 0x18, 0x12, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x10, 0x63,
|
||||||
0x01, 0x28, 0x0d, 0x52, 0x14, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x42, 0x50, 0x69, 0x6e, 0x67, 0x53,
|
0x6c, 0x61, 0x73, 0x73, 0x42, 0x50, 0x69, 0x6e, 0x67, 0x53, 0x6c, 0x6f, 0x74, 0x44, 0x72, 0x12,
|
||||||
0x6c, 0x6f, 0x74, 0x50, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x12, 0x2e, 0x0a, 0x14, 0x63, 0x6c, 0x61,
|
0x32, 0x0a, 0x16, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x5f, 0x62, 0x5f, 0x70, 0x69, 0x6e, 0x67, 0x5f,
|
||||||
0x73, 0x73, 0x5f, 0x62, 0x5f, 0x70, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x6c, 0x6f, 0x74, 0x5f, 0x64,
|
0x73, 0x6c, 0x6f, 0x74, 0x5f, 0x66, 0x72, 0x65, 0x71, 0x18, 0x13, 0x20, 0x01, 0x28, 0x0d, 0x52,
|
||||||
0x72, 0x18, 0x12, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x10, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x42, 0x50,
|
0x12, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x42, 0x50, 0x69, 0x6e, 0x67, 0x53, 0x6c, 0x6f, 0x74, 0x46,
|
||||||
0x69, 0x6e, 0x67, 0x53, 0x6c, 0x6f, 0x74, 0x44, 0x72, 0x12, 0x32, 0x0a, 0x16, 0x63, 0x6c, 0x61,
|
0x72, 0x65, 0x71, 0x12, 0x26, 0x0a, 0x0f, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x5f, 0x63, 0x5f, 0x74,
|
||||||
0x73, 0x73, 0x5f, 0x62, 0x5f, 0x70, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x6c, 0x6f, 0x74, 0x5f, 0x66,
|
0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0d, 0x63, 0x6c,
|
||||||
0x72, 0x65, 0x71, 0x18, 0x13, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x12, 0x63, 0x6c, 0x61, 0x73, 0x73,
|
0x61, 0x73, 0x73, 0x43, 0x54, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x12, 0x22, 0x0a, 0x0d, 0x61,
|
||||||
0x42, 0x50, 0x69, 0x6e, 0x67, 0x53, 0x6c, 0x6f, 0x74, 0x46, 0x72, 0x65, 0x71, 0x12, 0x26, 0x0a,
|
0x62, 0x70, 0x5f, 0x72, 0x78, 0x31, 0x5f, 0x64, 0x65, 0x6c, 0x61, 0x79, 0x18, 0x15, 0x20, 0x01,
|
||||||
0x0f, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x5f, 0x63, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74,
|
0x28, 0x0d, 0x52, 0x0b, 0x61, 0x62, 0x70, 0x52, 0x78, 0x31, 0x44, 0x65, 0x6c, 0x61, 0x79, 0x12,
|
||||||
0x18, 0x14, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0d, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x43, 0x54, 0x69,
|
0x29, 0x0a, 0x11, 0x61, 0x62, 0x70, 0x5f, 0x72, 0x78, 0x31, 0x5f, 0x64, 0x72, 0x5f, 0x6f, 0x66,
|
||||||
0x6d, 0x65, 0x6f, 0x75, 0x74, 0x12, 0x22, 0x0a, 0x0d, 0x61, 0x62, 0x70, 0x5f, 0x72, 0x78, 0x31,
|
0x66, 0x73, 0x65, 0x74, 0x18, 0x16, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0e, 0x61, 0x62, 0x70, 0x52,
|
||||||
0x5f, 0x64, 0x65, 0x6c, 0x61, 0x79, 0x18, 0x15, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0b, 0x61, 0x62,
|
0x78, 0x31, 0x44, 0x72, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x12, 0x1c, 0x0a, 0x0a, 0x61, 0x62,
|
||||||
0x70, 0x52, 0x78, 0x31, 0x44, 0x65, 0x6c, 0x61, 0x79, 0x12, 0x29, 0x0a, 0x11, 0x61, 0x62, 0x70,
|
0x70, 0x5f, 0x72, 0x78, 0x32, 0x5f, 0x64, 0x72, 0x18, 0x17, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x08,
|
||||||
0x5f, 0x72, 0x78, 0x31, 0x5f, 0x64, 0x72, 0x5f, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x16,
|
0x61, 0x62, 0x70, 0x52, 0x78, 0x32, 0x44, 0x72, 0x12, 0x20, 0x0a, 0x0c, 0x61, 0x62, 0x70, 0x5f,
|
||||||
0x20, 0x01, 0x28, 0x0d, 0x52, 0x0e, 0x61, 0x62, 0x70, 0x52, 0x78, 0x31, 0x44, 0x72, 0x4f, 0x66,
|
0x72, 0x78, 0x32, 0x5f, 0x66, 0x72, 0x65, 0x71, 0x18, 0x18, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0a,
|
||||||
0x66, 0x73, 0x65, 0x74, 0x12, 0x1c, 0x0a, 0x0a, 0x61, 0x62, 0x70, 0x5f, 0x72, 0x78, 0x32, 0x5f,
|
0x61, 0x62, 0x70, 0x52, 0x78, 0x32, 0x46, 0x72, 0x65, 0x71, 0x12, 0x30, 0x0a, 0x04, 0x74, 0x61,
|
||||||
0x64, 0x72, 0x18, 0x17, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x08, 0x61, 0x62, 0x70, 0x52, 0x78, 0x32,
|
0x67, 0x73, 0x18, 0x19, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x44,
|
||||||
0x44, 0x72, 0x12, 0x20, 0x0a, 0x0c, 0x61, 0x62, 0x70, 0x5f, 0x72, 0x78, 0x32, 0x5f, 0x66, 0x72,
|
0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x2e, 0x54, 0x61, 0x67,
|
||||||
0x65, 0x71, 0x18, 0x18, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0a, 0x61, 0x62, 0x70, 0x52, 0x78, 0x32,
|
0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x04, 0x74, 0x61, 0x67, 0x73, 0x1a, 0x37, 0x0a, 0x09,
|
||||||
0x46, 0x72, 0x65, 0x71, 0x12, 0x30, 0x0a, 0x04, 0x74, 0x61, 0x67, 0x73, 0x18, 0x19, 0x20, 0x03,
|
0x54, 0x61, 0x67, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79,
|
||||||
0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50,
|
0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76,
|
||||||
0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x2e, 0x54, 0x61, 0x67, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79,
|
0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75,
|
||||||
0x52, 0x04, 0x74, 0x61, 0x67, 0x73, 0x1a, 0x37, 0x0a, 0x09, 0x54, 0x61, 0x67, 0x73, 0x45, 0x6e,
|
0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xd2, 0x03, 0x0a, 0x15, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65,
|
||||||
0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
|
0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x12,
|
||||||
0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02,
|
0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12,
|
||||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22,
|
|
||||||
0xd2, 0x03, 0x0a, 0x15, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c,
|
|
||||||
0x65, 0x4c, 0x69, 0x73, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18,
|
|
||||||
0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x39, 0x0a, 0x0a, 0x63, 0x72, 0x65,
|
|
||||||
0x61, 0x74, 0x65, 0x64, 0x5f, 0x61, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e,
|
|
||||||
0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e,
|
|
||||||
0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x09, 0x63, 0x72, 0x65, 0x61, 0x74,
|
|
||||||
0x65, 0x64, 0x41, 0x74, 0x12, 0x39, 0x0a, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x5f,
|
|
||||||
0x61, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c,
|
|
||||||
0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73,
|
|
||||||
0x74, 0x61, 0x6d, 0x70, 0x52, 0x09, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12,
|
|
||||||
0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e,
|
|
||||||
0x61, 0x6d, 0x65, 0x12, 0x26, 0x0a, 0x06, 0x72, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x18, 0x05, 0x20,
|
|
||||||
0x01, 0x28, 0x0e, 0x32, 0x0e, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x67,
|
|
||||||
0x69, 0x6f, 0x6e, 0x52, 0x06, 0x72, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x12, 0x33, 0x0a, 0x0b, 0x6d,
|
|
||||||
0x61, 0x63, 0x5f, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0e,
|
|
||||||
0x32, 0x12, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x4d, 0x61, 0x63, 0x56, 0x65, 0x72,
|
|
||||||
0x73, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x6d, 0x61, 0x63, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e,
|
|
||||||
0x12, 0x49, 0x0a, 0x13, 0x72, 0x65, 0x67, 0x5f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x5f, 0x72,
|
|
||||||
0x65, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x19, 0x2e,
|
|
||||||
0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73,
|
|
||||||
0x52, 0x65, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x11, 0x72, 0x65, 0x67, 0x50, 0x61, 0x72,
|
|
||||||
0x61, 0x6d, 0x73, 0x52, 0x65, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x23, 0x0a, 0x0d, 0x73,
|
|
||||||
0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x5f, 0x6f, 0x74, 0x61, 0x61, 0x18, 0x08, 0x20, 0x01,
|
|
||||||
0x28, 0x08, 0x52, 0x0c, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x4f, 0x74, 0x61, 0x61,
|
|
||||||
0x12, 0x28, 0x0a, 0x10, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x5f, 0x63, 0x6c, 0x61,
|
|
||||||
0x73, 0x73, 0x5f, 0x62, 0x18, 0x09, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0e, 0x73, 0x75, 0x70, 0x70,
|
|
||||||
0x6f, 0x72, 0x74, 0x73, 0x43, 0x6c, 0x61, 0x73, 0x73, 0x42, 0x12, 0x28, 0x0a, 0x10, 0x73, 0x75,
|
|
||||||
0x70, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x5f, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x5f, 0x63, 0x18, 0x0a,
|
|
||||||
0x20, 0x01, 0x28, 0x08, 0x52, 0x0e, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x43, 0x6c,
|
|
||||||
0x61, 0x73, 0x73, 0x43, 0x22, 0x57, 0x0a, 0x1a, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x65,
|
|
||||||
0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65,
|
|
||||||
0x73, 0x74, 0x12, 0x39, 0x0a, 0x0e, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x5f, 0x70, 0x72, 0x6f,
|
|
||||||
0x66, 0x69, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x61, 0x70, 0x69,
|
|
||||||
0x2e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52, 0x0d,
|
|
||||||
0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x22, 0x2d, 0x0a,
|
|
||||||
0x1b, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f,
|
|
||||||
0x66, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x0e, 0x0a, 0x02,
|
|
||||||
0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x29, 0x0a, 0x17,
|
|
||||||
0x47, 0x65, 0x74, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65,
|
|
||||||
0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20,
|
|
||||||
0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0xcb, 0x01, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x44,
|
|
||||||
0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70,
|
|
||||||
0x6f, 0x6e, 0x73, 0x65, 0x12, 0x39, 0x0a, 0x0e, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x5f, 0x70,
|
|
||||||
0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x61,
|
|
||||||
0x70, 0x69, 0x2e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65,
|
|
||||||
0x52, 0x0d, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x12,
|
|
||||||
0x39, 0x0a, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x61, 0x74, 0x18, 0x02, 0x20,
|
0x39, 0x0a, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x61, 0x74, 0x18, 0x02, 0x20,
|
||||||
0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f,
|
0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f,
|
||||||
0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52,
|
0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52,
|
||||||
@ -1165,81 +1109,125 @@ var file_api_device_profile_proto_rawDesc = []byte{
|
|||||||
0x64, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x61, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a,
|
0x64, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x61, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a,
|
||||||
0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66,
|
0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66,
|
||||||
0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x09, 0x75, 0x70, 0x64, 0x61,
|
0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x09, 0x75, 0x70, 0x64, 0x61,
|
||||||
0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x57, 0x0a, 0x1a, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x44,
|
0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x04, 0x20,
|
||||||
0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75,
|
0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x26, 0x0a, 0x06, 0x72, 0x65, 0x67,
|
||||||
0x65, 0x73, 0x74, 0x12, 0x39, 0x0a, 0x0e, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x5f, 0x70, 0x72,
|
0x69, 0x6f, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x0e, 0x2e, 0x63, 0x6f, 0x6d, 0x6d,
|
||||||
0x6f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x61, 0x70,
|
0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x52, 0x06, 0x72, 0x65, 0x67, 0x69, 0x6f,
|
||||||
0x69, 0x2e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52,
|
0x6e, 0x12, 0x33, 0x0a, 0x0b, 0x6d, 0x61, 0x63, 0x5f, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e,
|
||||||
0x0d, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x22, 0x2c,
|
0x18, 0x06, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x12, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e,
|
||||||
0x0a, 0x1a, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72,
|
0x4d, 0x61, 0x63, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x6d, 0x61, 0x63, 0x56,
|
||||||
0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02,
|
0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x49, 0x0a, 0x13, 0x72, 0x65, 0x67, 0x5f, 0x70, 0x61,
|
||||||
0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x7e, 0x0a, 0x19,
|
0x72, 0x61, 0x6d, 0x73, 0x5f, 0x72, 0x65, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20,
|
||||||
0x4c, 0x69, 0x73, 0x74, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c,
|
0x01, 0x28, 0x0e, 0x32, 0x19, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x67,
|
||||||
0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x69, 0x6d,
|
0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x11,
|
||||||
0x69, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x12,
|
0x72, 0x65, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x76, 0x69, 0x73, 0x69, 0x6f,
|
||||||
0x16, 0x0a, 0x06, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0d, 0x52,
|
0x6e, 0x12, 0x23, 0x0a, 0x0d, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x5f, 0x6f, 0x74,
|
||||||
0x06, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x65, 0x61, 0x72, 0x63,
|
0x61, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0c, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72,
|
||||||
0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x73, 0x65, 0x61, 0x72, 0x63, 0x68, 0x12,
|
0x74, 0x73, 0x4f, 0x74, 0x61, 0x61, 0x12, 0x28, 0x0a, 0x10, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72,
|
||||||
0x1b, 0x0a, 0x09, 0x74, 0x65, 0x6e, 0x61, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01,
|
0x74, 0x73, 0x5f, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x5f, 0x62, 0x18, 0x09, 0x20, 0x01, 0x28, 0x08,
|
||||||
0x28, 0x09, 0x52, 0x08, 0x74, 0x65, 0x6e, 0x61, 0x6e, 0x74, 0x49, 0x64, 0x22, 0x71, 0x0a, 0x1a,
|
0x52, 0x0e, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x43, 0x6c, 0x61, 0x73, 0x73, 0x42,
|
||||||
0x4c, 0x69, 0x73, 0x74, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c,
|
0x12, 0x28, 0x0a, 0x10, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x5f, 0x63, 0x6c, 0x61,
|
||||||
0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x74, 0x6f,
|
0x73, 0x73, 0x5f, 0x63, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0e, 0x73, 0x75, 0x70, 0x70,
|
||||||
0x74, 0x61, 0x6c, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52,
|
0x6f, 0x72, 0x74, 0x73, 0x43, 0x6c, 0x61, 0x73, 0x73, 0x43, 0x22, 0x57, 0x0a, 0x1a, 0x43, 0x72,
|
||||||
0x0a, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x32, 0x0a, 0x06, 0x72,
|
0x65, 0x61, 0x74, 0x65, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c,
|
||||||
0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x61, 0x70,
|
0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x39, 0x0a, 0x0e, 0x64, 0x65, 0x76, 0x69,
|
||||||
0x69, 0x2e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x4c,
|
0x63, 0x65, 0x5f, 0x70, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b,
|
||||||
0x69, 0x73, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22,
|
0x32, 0x12, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f,
|
||||||
0x7c, 0x0a, 0x26, 0x4c, 0x69, 0x73, 0x74, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f,
|
0x66, 0x69, 0x6c, 0x65, 0x52, 0x0d, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66,
|
||||||
0x66, 0x69, 0x6c, 0x65, 0x41, 0x64, 0x72, 0x41, 0x6c, 0x67, 0x6f, 0x72, 0x69, 0x74, 0x68, 0x6d,
|
0x69, 0x6c, 0x65, 0x22, 0x2d, 0x0a, 0x1b, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x65, 0x76,
|
||||||
0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x74, 0x6f, 0x74,
|
|
||||||
0x61, 0x6c, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0a,
|
|
||||||
0x74, 0x6f, 0x74, 0x61, 0x6c, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x31, 0x0a, 0x06, 0x72, 0x65,
|
|
||||||
0x73, 0x75, 0x6c, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x61, 0x70, 0x69,
|
|
||||||
0x2e, 0x41, 0x64, 0x72, 0x41, 0x6c, 0x67, 0x6f, 0x72, 0x69, 0x74, 0x68, 0x6d, 0x4c, 0x69, 0x73,
|
|
||||||
0x74, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x3a, 0x0a,
|
|
||||||
0x14, 0x41, 0x64, 0x72, 0x41, 0x6c, 0x67, 0x6f, 0x72, 0x69, 0x74, 0x68, 0x6d, 0x4c, 0x69, 0x73,
|
|
||||||
0x74, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28,
|
|
||||||
0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20,
|
|
||||||
0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x2a, 0x31, 0x0a, 0x0c, 0x43, 0x6f, 0x64,
|
|
||||||
0x65, 0x63, 0x52, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x08, 0x0a, 0x04, 0x4e, 0x4f, 0x4e,
|
|
||||||
0x45, 0x10, 0x00, 0x12, 0x0f, 0x0a, 0x0b, 0x43, 0x41, 0x59, 0x45, 0x4e, 0x4e, 0x45, 0x5f, 0x4c,
|
|
||||||
0x50, 0x50, 0x10, 0x01, 0x12, 0x06, 0x0a, 0x02, 0x4a, 0x53, 0x10, 0x02, 0x32, 0xdc, 0x03, 0x0a,
|
|
||||||
0x14, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x53, 0x65,
|
|
||||||
0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x4d, 0x0a, 0x06, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x12,
|
|
||||||
0x1f, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x65, 0x76, 0x69,
|
|
||||||
0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
|
|
||||||
0x1a, 0x20, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x65, 0x76,
|
|
||||||
0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e,
|
0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e,
|
||||||
0x73, 0x65, 0x22, 0x00, 0x12, 0x44, 0x0a, 0x03, 0x47, 0x65, 0x74, 0x12, 0x1c, 0x2e, 0x61, 0x70,
|
0x73, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02,
|
||||||
0x69, 0x2e, 0x47, 0x65, 0x74, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69,
|
0x69, 0x64, 0x22, 0x29, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50,
|
||||||
0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x61, 0x70, 0x69, 0x2e,
|
0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a,
|
||||||
0x47, 0x65, 0x74, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65,
|
0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0xcb, 0x01,
|
||||||
0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x43, 0x0a, 0x06, 0x55, 0x70,
|
0x0a, 0x18, 0x47, 0x65, 0x74, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69,
|
||||||
0x64, 0x61, 0x74, 0x65, 0x12, 0x1f, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74,
|
0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x39, 0x0a, 0x0e, 0x64, 0x65,
|
||||||
0x65, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52, 0x65,
|
0x76, 0x69, 0x63, 0x65, 0x5f, 0x70, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01,
|
||||||
0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70,
|
0x28, 0x0b, 0x32, 0x12, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50,
|
||||||
0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12,
|
0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52, 0x0d, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72,
|
||||||
0x43, 0x0a, 0x06, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x12, 0x1f, 0x2e, 0x61, 0x70, 0x69, 0x2e,
|
0x6f, 0x66, 0x69, 0x6c, 0x65, 0x12, 0x39, 0x0a, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64,
|
||||||
0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66,
|
0x5f, 0x61, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67,
|
||||||
0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x67, 0x6f, 0x6f,
|
0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65,
|
||||||
|
0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x09, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74,
|
||||||
|
0x12, 0x39, 0x0a, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x61, 0x74, 0x18, 0x03,
|
||||||
|
0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72,
|
||||||
|
0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70,
|
||||||
|
0x52, 0x09, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x57, 0x0a, 0x1a, 0x55,
|
||||||
|
0x70, 0x64, 0x61, 0x74, 0x65, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69,
|
||||||
|
0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x39, 0x0a, 0x0e, 0x64, 0x65, 0x76,
|
||||||
|
0x69, 0x63, 0x65, 0x5f, 0x70, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28,
|
||||||
|
0x0b, 0x32, 0x12, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72,
|
||||||
|
0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52, 0x0d, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f,
|
||||||
|
0x66, 0x69, 0x6c, 0x65, 0x22, 0x2c, 0x0a, 0x1a, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x44, 0x65,
|
||||||
|
0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65,
|
||||||
|
0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02,
|
||||||
|
0x69, 0x64, 0x22, 0x7e, 0x0a, 0x19, 0x4c, 0x69, 0x73, 0x74, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65,
|
||||||
|
0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12,
|
||||||
|
0x14, 0x0a, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05,
|
||||||
|
0x6c, 0x69, 0x6d, 0x69, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18,
|
||||||
|
0x02, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x06, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x12, 0x16, 0x0a,
|
||||||
|
0x06, 0x73, 0x65, 0x61, 0x72, 0x63, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x73,
|
||||||
|
0x65, 0x61, 0x72, 0x63, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x74, 0x65, 0x6e, 0x61, 0x6e, 0x74, 0x5f,
|
||||||
|
0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x74, 0x65, 0x6e, 0x61, 0x6e, 0x74,
|
||||||
|
0x49, 0x64, 0x22, 0x71, 0x0a, 0x1a, 0x4c, 0x69, 0x73, 0x74, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65,
|
||||||
|
0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65,
|
||||||
|
0x12, 0x1f, 0x0a, 0x0b, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18,
|
||||||
|
0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0a, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x43, 0x6f, 0x75, 0x6e,
|
||||||
|
0x74, 0x12, 0x32, 0x0a, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28,
|
||||||
|
0x0b, 0x32, 0x1a, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72,
|
||||||
|
0x6f, 0x66, 0x69, 0x6c, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x06, 0x72,
|
||||||
|
0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x7c, 0x0a, 0x26, 0x4c, 0x69, 0x73, 0x74, 0x44, 0x65, 0x76,
|
||||||
|
0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x41, 0x64, 0x72, 0x41, 0x6c, 0x67,
|
||||||
|
0x6f, 0x72, 0x69, 0x74, 0x68, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12,
|
||||||
|
0x1f, 0x0a, 0x0b, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01,
|
||||||
|
0x20, 0x01, 0x28, 0x0d, 0x52, 0x0a, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x43, 0x6f, 0x75, 0x6e, 0x74,
|
||||||
|
0x12, 0x31, 0x0a, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b,
|
||||||
|
0x32, 0x19, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x41, 0x64, 0x72, 0x41, 0x6c, 0x67, 0x6f, 0x72, 0x69,
|
||||||
|
0x74, 0x68, 0x6d, 0x4c, 0x69, 0x73, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x06, 0x72, 0x65, 0x73,
|
||||||
|
0x75, 0x6c, 0x74, 0x22, 0x3a, 0x0a, 0x14, 0x41, 0x64, 0x72, 0x41, 0x6c, 0x67, 0x6f, 0x72, 0x69,
|
||||||
|
0x74, 0x68, 0x6d, 0x4c, 0x69, 0x73, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x69,
|
||||||
|
0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e,
|
||||||
|
0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x2a,
|
||||||
|
0x31, 0x0a, 0x0c, 0x43, 0x6f, 0x64, 0x65, 0x63, 0x52, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x12,
|
||||||
|
0x08, 0x0a, 0x04, 0x4e, 0x4f, 0x4e, 0x45, 0x10, 0x00, 0x12, 0x0f, 0x0a, 0x0b, 0x43, 0x41, 0x59,
|
||||||
|
0x45, 0x4e, 0x4e, 0x45, 0x5f, 0x4c, 0x50, 0x50, 0x10, 0x01, 0x12, 0x06, 0x0a, 0x02, 0x4a, 0x53,
|
||||||
|
0x10, 0x02, 0x32, 0xdc, 0x03, 0x0a, 0x14, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f,
|
||||||
|
0x66, 0x69, 0x6c, 0x65, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x4d, 0x0a, 0x06, 0x43,
|
||||||
|
0x72, 0x65, 0x61, 0x74, 0x65, 0x12, 0x1f, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x43, 0x72, 0x65, 0x61,
|
||||||
|
0x74, 0x65, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52,
|
||||||
|
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x43, 0x72, 0x65,
|
||||||
|
0x61, 0x74, 0x65, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65,
|
||||||
|
0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x44, 0x0a, 0x03, 0x47, 0x65,
|
||||||
|
0x74, 0x12, 0x1c, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x47, 0x65, 0x74, 0x44, 0x65, 0x76, 0x69, 0x63,
|
||||||
|
0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a,
|
||||||
|
0x1d, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x47, 0x65, 0x74, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50,
|
||||||
|
0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00,
|
||||||
|
0x12, 0x43, 0x0a, 0x06, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x12, 0x1f, 0x2e, 0x61, 0x70, 0x69,
|
||||||
|
0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f,
|
||||||
|
0x66, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x67, 0x6f,
|
||||||
|
0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d,
|
||||||
|
0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x43, 0x0a, 0x06, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x12,
|
||||||
|
0x1f, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x44, 0x65, 0x76, 0x69,
|
||||||
|
0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
|
||||||
|
0x1a, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62,
|
||||||
|
0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x49, 0x0a, 0x04, 0x4c, 0x69,
|
||||||
|
0x73, 0x74, 0x12, 0x1e, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x44, 0x65, 0x76,
|
||||||
|
0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65,
|
||||||
|
0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x44, 0x65, 0x76,
|
||||||
|
0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f,
|
||||||
|
0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x5a, 0x0a, 0x11, 0x4c, 0x69, 0x73, 0x74, 0x41, 0x64, 0x72,
|
||||||
|
0x41, 0x6c, 0x67, 0x6f, 0x72, 0x69, 0x74, 0x68, 0x6d, 0x73, 0x12, 0x16, 0x2e, 0x67, 0x6f, 0x6f,
|
||||||
0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70,
|
0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70,
|
||||||
0x74, 0x79, 0x22, 0x00, 0x12, 0x49, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x1e, 0x2e, 0x61,
|
0x74, 0x79, 0x1a, 0x2b, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x44, 0x65, 0x76,
|
||||||
0x70, 0x69, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f,
|
0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x41, 0x64, 0x72, 0x41, 0x6c, 0x67,
|
||||||
0x66, 0x69, 0x6c, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x61,
|
0x6f, 0x72, 0x69, 0x74, 0x68, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22,
|
||||||
0x70, 0x69, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f,
|
0x00, 0x42, 0x59, 0x0a, 0x11, 0x69, 0x6f, 0x2e, 0x63, 0x68, 0x69, 0x72, 0x70, 0x73, 0x74, 0x61,
|
||||||
0x66, 0x69, 0x6c, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12,
|
0x63, 0x6b, 0x2e, 0x61, 0x70, 0x69, 0x42, 0x12, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72,
|
||||||
0x5a, 0x0a, 0x11, 0x4c, 0x69, 0x73, 0x74, 0x41, 0x64, 0x72, 0x41, 0x6c, 0x67, 0x6f, 0x72, 0x69,
|
0x6f, 0x66, 0x69, 0x6c, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x2e, 0x67, 0x69,
|
||||||
0x74, 0x68, 0x6d, 0x73, 0x12, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72,
|
0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x63, 0x68, 0x69, 0x72, 0x70, 0x73, 0x74,
|
||||||
0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x2b, 0x2e, 0x61,
|
0x61, 0x63, 0x6b, 0x2f, 0x63, 0x68, 0x69, 0x72, 0x70, 0x73, 0x74, 0x61, 0x63, 0x6b, 0x2f, 0x61,
|
||||||
0x70, 0x69, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f,
|
0x70, 0x69, 0x2f, 0x67, 0x6f, 0x2f, 0x76, 0x34, 0x2f, 0x61, 0x70, 0x69, 0x62, 0x06, 0x70, 0x72,
|
||||||
0x66, 0x69, 0x6c, 0x65, 0x41, 0x64, 0x72, 0x41, 0x6c, 0x67, 0x6f, 0x72, 0x69, 0x74, 0x68, 0x6d,
|
0x6f, 0x74, 0x6f, 0x33,
|
||||||
0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x59, 0x0a, 0x11, 0x69,
|
|
||||||
0x6f, 0x2e, 0x63, 0x68, 0x69, 0x72, 0x70, 0x73, 0x74, 0x61, 0x63, 0x6b, 0x2e, 0x61, 0x70, 0x69,
|
|
||||||
0x42, 0x12, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x50,
|
|
||||||
0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x2e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63,
|
|
||||||
0x6f, 0x6d, 0x2f, 0x63, 0x68, 0x69, 0x72, 0x70, 0x73, 0x74, 0x61, 0x63, 0x6b, 0x2f, 0x63, 0x68,
|
|
||||||
0x69, 0x72, 0x70, 0x73, 0x74, 0x61, 0x63, 0x6b, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x67, 0x6f, 0x2f,
|
|
||||||
0x76, 0x34, 0x2f, 0x61, 0x70, 0x69, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
|
||||||
}
|
}
|
||||||
|
|
||||||
var (
|
var (
|
||||||
|
10
api/grpc-web/api/device_profile_pb.d.ts
vendored
10
api/grpc-web/api/device_profile_pb.d.ts
vendored
@ -30,11 +30,8 @@ export class DeviceProfile extends jspb.Message {
|
|||||||
getPayloadCodecRuntime(): CodecRuntime;
|
getPayloadCodecRuntime(): CodecRuntime;
|
||||||
setPayloadCodecRuntime(value: CodecRuntime): DeviceProfile;
|
setPayloadCodecRuntime(value: CodecRuntime): DeviceProfile;
|
||||||
|
|
||||||
getPayloadEncoderConfig(): string;
|
getPayloadCodecScript(): string;
|
||||||
setPayloadEncoderConfig(value: string): DeviceProfile;
|
setPayloadCodecScript(value: string): DeviceProfile;
|
||||||
|
|
||||||
getPayloadDecoderConfig(): string;
|
|
||||||
setPayloadDecoderConfig(value: string): DeviceProfile;
|
|
||||||
|
|
||||||
getUplinkInterval(): number;
|
getUplinkInterval(): number;
|
||||||
setUplinkInterval(value: number): DeviceProfile;
|
setUplinkInterval(value: number): DeviceProfile;
|
||||||
@ -99,8 +96,7 @@ export namespace DeviceProfile {
|
|||||||
regParamsRevision: common_common_pb.RegParamsRevision,
|
regParamsRevision: common_common_pb.RegParamsRevision,
|
||||||
adrAlgorithmId: string,
|
adrAlgorithmId: string,
|
||||||
payloadCodecRuntime: CodecRuntime,
|
payloadCodecRuntime: CodecRuntime,
|
||||||
payloadEncoderConfig: string,
|
payloadCodecScript: string,
|
||||||
payloadDecoderConfig: string,
|
|
||||||
uplinkInterval: number,
|
uplinkInterval: number,
|
||||||
deviceStatusReqInterval: number,
|
deviceStatusReqInterval: number,
|
||||||
supportsOtaa: boolean,
|
supportsOtaa: boolean,
|
||||||
|
42
api/grpc-web/api/device_profile_pb.js
vendored
42
api/grpc-web/api/device_profile_pb.js
vendored
@ -326,8 +326,7 @@ proto.api.DeviceProfile.toObject = function(includeInstance, msg) {
|
|||||||
regParamsRevision: jspb.Message.getFieldWithDefault(msg, 6, 0),
|
regParamsRevision: jspb.Message.getFieldWithDefault(msg, 6, 0),
|
||||||
adrAlgorithmId: jspb.Message.getFieldWithDefault(msg, 7, ""),
|
adrAlgorithmId: jspb.Message.getFieldWithDefault(msg, 7, ""),
|
||||||
payloadCodecRuntime: jspb.Message.getFieldWithDefault(msg, 8, 0),
|
payloadCodecRuntime: jspb.Message.getFieldWithDefault(msg, 8, 0),
|
||||||
payloadEncoderConfig: jspb.Message.getFieldWithDefault(msg, 9, ""),
|
payloadCodecScript: jspb.Message.getFieldWithDefault(msg, 9, ""),
|
||||||
payloadDecoderConfig: jspb.Message.getFieldWithDefault(msg, 10, ""),
|
|
||||||
uplinkInterval: jspb.Message.getFieldWithDefault(msg, 11, 0),
|
uplinkInterval: jspb.Message.getFieldWithDefault(msg, 11, 0),
|
||||||
deviceStatusReqInterval: jspb.Message.getFieldWithDefault(msg, 12, 0),
|
deviceStatusReqInterval: jspb.Message.getFieldWithDefault(msg, 12, 0),
|
||||||
supportsOtaa: jspb.Message.getBooleanFieldWithDefault(msg, 13, false),
|
supportsOtaa: jspb.Message.getBooleanFieldWithDefault(msg, 13, false),
|
||||||
@ -413,11 +412,7 @@ proto.api.DeviceProfile.deserializeBinaryFromReader = function(msg, reader) {
|
|||||||
break;
|
break;
|
||||||
case 9:
|
case 9:
|
||||||
var value = /** @type {string} */ (reader.readString());
|
var value = /** @type {string} */ (reader.readString());
|
||||||
msg.setPayloadEncoderConfig(value);
|
msg.setPayloadCodecScript(value);
|
||||||
break;
|
|
||||||
case 10:
|
|
||||||
var value = /** @type {string} */ (reader.readString());
|
|
||||||
msg.setPayloadDecoderConfig(value);
|
|
||||||
break;
|
break;
|
||||||
case 11:
|
case 11:
|
||||||
var value = /** @type {number} */ (reader.readUint32());
|
var value = /** @type {number} */ (reader.readUint32());
|
||||||
@ -566,20 +561,13 @@ proto.api.DeviceProfile.serializeBinaryToWriter = function(message, writer) {
|
|||||||
f
|
f
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
f = message.getPayloadEncoderConfig();
|
f = message.getPayloadCodecScript();
|
||||||
if (f.length > 0) {
|
if (f.length > 0) {
|
||||||
writer.writeString(
|
writer.writeString(
|
||||||
9,
|
9,
|
||||||
f
|
f
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
f = message.getPayloadDecoderConfig();
|
|
||||||
if (f.length > 0) {
|
|
||||||
writer.writeString(
|
|
||||||
10,
|
|
||||||
f
|
|
||||||
);
|
|
||||||
}
|
|
||||||
f = message.getUplinkInterval();
|
f = message.getUplinkInterval();
|
||||||
if (f !== 0) {
|
if (f !== 0) {
|
||||||
writer.writeUint32(
|
writer.writeUint32(
|
||||||
@ -830,10 +818,10 @@ proto.api.DeviceProfile.prototype.setPayloadCodecRuntime = function(value) {
|
|||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* optional string payload_encoder_config = 9;
|
* optional string payload_codec_script = 9;
|
||||||
* @return {string}
|
* @return {string}
|
||||||
*/
|
*/
|
||||||
proto.api.DeviceProfile.prototype.getPayloadEncoderConfig = function() {
|
proto.api.DeviceProfile.prototype.getPayloadCodecScript = function() {
|
||||||
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 9, ""));
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 9, ""));
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -842,29 +830,11 @@ proto.api.DeviceProfile.prototype.getPayloadEncoderConfig = function() {
|
|||||||
* @param {string} value
|
* @param {string} value
|
||||||
* @return {!proto.api.DeviceProfile} returns this
|
* @return {!proto.api.DeviceProfile} returns this
|
||||||
*/
|
*/
|
||||||
proto.api.DeviceProfile.prototype.setPayloadEncoderConfig = function(value) {
|
proto.api.DeviceProfile.prototype.setPayloadCodecScript = function(value) {
|
||||||
return jspb.Message.setProto3StringField(this, 9, value);
|
return jspb.Message.setProto3StringField(this, 9, value);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* optional string payload_decoder_config = 10;
|
|
||||||
* @return {string}
|
|
||||||
*/
|
|
||||||
proto.api.DeviceProfile.prototype.getPayloadDecoderConfig = function() {
|
|
||||||
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 10, ""));
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param {string} value
|
|
||||||
* @return {!proto.api.DeviceProfile} returns this
|
|
||||||
*/
|
|
||||||
proto.api.DeviceProfile.prototype.setPayloadDecoderConfig = function(value) {
|
|
||||||
return jspb.Message.setProto3StringField(this, 10, value);
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* optional uint32 uplink_interval = 11;
|
* optional uint32 uplink_interval = 11;
|
||||||
* @return {number}
|
* @return {number}
|
||||||
|
10
api/js/api/device_profile_pb.d.ts
vendored
10
api/js/api/device_profile_pb.d.ts
vendored
@ -31,11 +31,8 @@ export class DeviceProfile extends jspb.Message {
|
|||||||
getPayloadCodecRuntime(): CodecRuntimeMap[keyof CodecRuntimeMap];
|
getPayloadCodecRuntime(): CodecRuntimeMap[keyof CodecRuntimeMap];
|
||||||
setPayloadCodecRuntime(value: CodecRuntimeMap[keyof CodecRuntimeMap]): void;
|
setPayloadCodecRuntime(value: CodecRuntimeMap[keyof CodecRuntimeMap]): void;
|
||||||
|
|
||||||
getPayloadEncoderConfig(): string;
|
getPayloadCodecScript(): string;
|
||||||
setPayloadEncoderConfig(value: string): void;
|
setPayloadCodecScript(value: string): void;
|
||||||
|
|
||||||
getPayloadDecoderConfig(): string;
|
|
||||||
setPayloadDecoderConfig(value: string): void;
|
|
||||||
|
|
||||||
getUplinkInterval(): number;
|
getUplinkInterval(): number;
|
||||||
setUplinkInterval(value: number): void;
|
setUplinkInterval(value: number): void;
|
||||||
@ -101,8 +98,7 @@ export namespace DeviceProfile {
|
|||||||
regParamsRevision: common_common_pb.RegParamsRevisionMap[keyof common_common_pb.RegParamsRevisionMap],
|
regParamsRevision: common_common_pb.RegParamsRevisionMap[keyof common_common_pb.RegParamsRevisionMap],
|
||||||
adrAlgorithmId: string,
|
adrAlgorithmId: string,
|
||||||
payloadCodecRuntime: CodecRuntimeMap[keyof CodecRuntimeMap],
|
payloadCodecRuntime: CodecRuntimeMap[keyof CodecRuntimeMap],
|
||||||
payloadEncoderConfig: string,
|
payloadCodecScript: string,
|
||||||
payloadDecoderConfig: string,
|
|
||||||
uplinkInterval: number,
|
uplinkInterval: number,
|
||||||
deviceStatusReqInterval: number,
|
deviceStatusReqInterval: number,
|
||||||
supportsOtaa: boolean,
|
supportsOtaa: boolean,
|
||||||
|
39
api/js/api/device_profile_pb.js
vendored
39
api/js/api/device_profile_pb.js
vendored
@ -79,8 +79,7 @@ proto.api.DeviceProfile.toObject = function(includeInstance, msg) {
|
|||||||
regParamsRevision: msg.getRegParamsRevision(),
|
regParamsRevision: msg.getRegParamsRevision(),
|
||||||
adrAlgorithmId: msg.getAdrAlgorithmId(),
|
adrAlgorithmId: msg.getAdrAlgorithmId(),
|
||||||
payloadCodecRuntime: msg.getPayloadCodecRuntime(),
|
payloadCodecRuntime: msg.getPayloadCodecRuntime(),
|
||||||
payloadEncoderConfig: msg.getPayloadEncoderConfig(),
|
payloadCodecScript: msg.getPayloadCodecScript(),
|
||||||
payloadDecoderConfig: msg.getPayloadDecoderConfig(),
|
|
||||||
uplinkInterval: msg.getUplinkInterval(),
|
uplinkInterval: msg.getUplinkInterval(),
|
||||||
deviceStatusReqInterval: msg.getDeviceStatusReqInterval(),
|
deviceStatusReqInterval: msg.getDeviceStatusReqInterval(),
|
||||||
supportsOtaa: msg.getSupportsOtaa(),
|
supportsOtaa: msg.getSupportsOtaa(),
|
||||||
@ -166,11 +165,7 @@ proto.api.DeviceProfile.deserializeBinaryFromReader = function(msg, reader) {
|
|||||||
break;
|
break;
|
||||||
case 9:
|
case 9:
|
||||||
var value = /** @type {string} */ (reader.readString());
|
var value = /** @type {string} */ (reader.readString());
|
||||||
msg.setPayloadEncoderConfig(value);
|
msg.setPayloadCodecScript(value);
|
||||||
break;
|
|
||||||
case 10:
|
|
||||||
var value = /** @type {string} */ (reader.readString());
|
|
||||||
msg.setPayloadDecoderConfig(value);
|
|
||||||
break;
|
break;
|
||||||
case 11:
|
case 11:
|
||||||
var value = /** @type {number} */ (reader.readUint32());
|
var value = /** @type {number} */ (reader.readUint32());
|
||||||
@ -328,20 +323,13 @@ proto.api.DeviceProfile.prototype.serializeBinaryToWriter = function (writer) {
|
|||||||
f
|
f
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
f = this.getPayloadEncoderConfig();
|
f = this.getPayloadCodecScript();
|
||||||
if (f.length > 0) {
|
if (f.length > 0) {
|
||||||
writer.writeString(
|
writer.writeString(
|
||||||
9,
|
9,
|
||||||
f
|
f
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
f = this.getPayloadDecoderConfig();
|
|
||||||
if (f.length > 0) {
|
|
||||||
writer.writeString(
|
|
||||||
10,
|
|
||||||
f
|
|
||||||
);
|
|
||||||
}
|
|
||||||
f = this.getUplinkInterval();
|
f = this.getUplinkInterval();
|
||||||
if (f !== 0) {
|
if (f !== 0) {
|
||||||
writer.writeUint32(
|
writer.writeUint32(
|
||||||
@ -577,35 +565,20 @@ proto.api.DeviceProfile.prototype.setPayloadCodecRuntime = function(value) {
|
|||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* optional string payload_encoder_config = 9;
|
* optional string payload_codec_script = 9;
|
||||||
* @return {string}
|
* @return {string}
|
||||||
*/
|
*/
|
||||||
proto.api.DeviceProfile.prototype.getPayloadEncoderConfig = function() {
|
proto.api.DeviceProfile.prototype.getPayloadCodecScript = function() {
|
||||||
return /** @type {string} */ (jspb.Message.getFieldProto3(this, 9, ""));
|
return /** @type {string} */ (jspb.Message.getFieldProto3(this, 9, ""));
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/** @param {string} value */
|
/** @param {string} value */
|
||||||
proto.api.DeviceProfile.prototype.setPayloadEncoderConfig = function(value) {
|
proto.api.DeviceProfile.prototype.setPayloadCodecScript = function(value) {
|
||||||
jspb.Message.setField(this, 9, value);
|
jspb.Message.setField(this, 9, value);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* optional string payload_decoder_config = 10;
|
|
||||||
* @return {string}
|
|
||||||
*/
|
|
||||||
proto.api.DeviceProfile.prototype.getPayloadDecoderConfig = function() {
|
|
||||||
return /** @type {string} */ (jspb.Message.getFieldProto3(this, 10, ""));
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
/** @param {string} value */
|
|
||||||
proto.api.DeviceProfile.prototype.setPayloadDecoderConfig = function(value) {
|
|
||||||
jspb.Message.setField(this, 10, value);
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* optional uint32 uplink_interval = 11;
|
* optional uint32 uplink_interval = 11;
|
||||||
* @return {number}
|
* @return {number}
|
||||||
|
2
api/js/package.json
vendored
2
api/js/package.json
vendored
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@chirpstack/chirpstack-api",
|
"name": "@chirpstack/chirpstack-api",
|
||||||
"version": "4.0.0-test.1",
|
"version": "4.0.0",
|
||||||
"description": "Chirpstack JS and TS API",
|
"description": "Chirpstack JS and TS API",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
7
api/proto/api/device_profile.proto
vendored
7
api/proto/api/device_profile.proto
vendored
@ -69,11 +69,8 @@ message DeviceProfile {
|
|||||||
// Payload codec runtime.
|
// Payload codec runtime.
|
||||||
CodecRuntime payload_codec_runtime = 8;
|
CodecRuntime payload_codec_runtime = 8;
|
||||||
|
|
||||||
// Payload codec encoder config.
|
// Payload codec script.
|
||||||
string payload_encoder_config = 9;
|
string payload_codec_script = 9;
|
||||||
|
|
||||||
// Payload codec decoder config.
|
|
||||||
string payload_decoder_config = 10;
|
|
||||||
|
|
||||||
// Uplink interval (seconds).
|
// Uplink interval (seconds).
|
||||||
// This defines the expected uplink interval which the device uses for
|
// This defines the expected uplink interval which the device uses for
|
||||||
|
@ -69,11 +69,8 @@ message DeviceProfile {
|
|||||||
// Payload codec runtime.
|
// Payload codec runtime.
|
||||||
CodecRuntime payload_codec_runtime = 8;
|
CodecRuntime payload_codec_runtime = 8;
|
||||||
|
|
||||||
// Payload codec encoder config.
|
// Payload codec script.
|
||||||
string payload_encoder_config = 9;
|
string payload_codec_script = 9;
|
||||||
|
|
||||||
// Payload codec decoder config.
|
|
||||||
string payload_decoder_config = 10;
|
|
||||||
|
|
||||||
// Uplink interval (seconds).
|
// Uplink interval (seconds).
|
||||||
// This defines the expected uplink interval which the device uses for
|
// This defines the expected uplink interval which the device uses for
|
||||||
|
@ -0,0 +1,8 @@
|
|||||||
|
alter table device_profile
|
||||||
|
drop column payload_codec_script,
|
||||||
|
add column payload_decoder_config text not null default '',
|
||||||
|
add column payload_encoder_config text not null default '';
|
||||||
|
|
||||||
|
alter table device_profile
|
||||||
|
alter column payload_decoder_config drop default,
|
||||||
|
alter column payload_decoder_config drop default;
|
@ -0,0 +1,7 @@
|
|||||||
|
alter table device_profile
|
||||||
|
drop column payload_decoder_config,
|
||||||
|
drop column payload_encoder_config,
|
||||||
|
add column payload_codec_script text not null default '';
|
||||||
|
|
||||||
|
alter table device_profile
|
||||||
|
alter column payload_codec_script drop default;
|
@ -684,7 +684,7 @@ impl DeviceService for Device {
|
|||||||
dp.payload_codec_runtime,
|
dp.payload_codec_runtime,
|
||||||
req_qi.f_port as u8,
|
req_qi.f_port as u8,
|
||||||
&dev.variables,
|
&dev.variables,
|
||||||
&dp.payload_encoder_config,
|
&dp.payload_codec_script,
|
||||||
obj,
|
obj,
|
||||||
)
|
)
|
||||||
.await
|
.await
|
||||||
|
@ -52,8 +52,7 @@ impl DeviceProfileService for DeviceProfile {
|
|||||||
reg_params_revision: req_dp.reg_params_revision().from_proto(),
|
reg_params_revision: req_dp.reg_params_revision().from_proto(),
|
||||||
adr_algorithm_id: req_dp.adr_algorithm_id.clone(),
|
adr_algorithm_id: req_dp.adr_algorithm_id.clone(),
|
||||||
payload_codec_runtime: req_dp.payload_codec_runtime().from_proto(),
|
payload_codec_runtime: req_dp.payload_codec_runtime().from_proto(),
|
||||||
payload_decoder_config: req_dp.payload_encoder_config.clone(),
|
payload_codec_script: req_dp.payload_codec_script.clone(),
|
||||||
payload_encoder_config: req_dp.payload_decoder_config.clone(),
|
|
||||||
uplink_interval: req_dp.uplink_interval as i32,
|
uplink_interval: req_dp.uplink_interval as i32,
|
||||||
device_status_req_interval: req_dp.device_status_req_interval as i32,
|
device_status_req_interval: req_dp.device_status_req_interval as i32,
|
||||||
supports_otaa: req_dp.supports_otaa,
|
supports_otaa: req_dp.supports_otaa,
|
||||||
@ -105,8 +104,7 @@ impl DeviceProfileService for DeviceProfile {
|
|||||||
reg_params_revision: dp.reg_params_revision.to_proto().into(),
|
reg_params_revision: dp.reg_params_revision.to_proto().into(),
|
||||||
adr_algorithm_id: dp.adr_algorithm_id,
|
adr_algorithm_id: dp.adr_algorithm_id,
|
||||||
payload_codec_runtime: dp.payload_codec_runtime.to_proto().into(),
|
payload_codec_runtime: dp.payload_codec_runtime.to_proto().into(),
|
||||||
payload_decoder_config: dp.payload_decoder_config,
|
payload_codec_script: dp.payload_codec_script,
|
||||||
payload_encoder_config: dp.payload_encoder_config,
|
|
||||||
uplink_interval: dp.uplink_interval as u32,
|
uplink_interval: dp.uplink_interval as u32,
|
||||||
device_status_req_interval: dp.device_status_req_interval as u32,
|
device_status_req_interval: dp.device_status_req_interval as u32,
|
||||||
supports_otaa: dp.supports_otaa,
|
supports_otaa: dp.supports_otaa,
|
||||||
@ -156,8 +154,7 @@ impl DeviceProfileService for DeviceProfile {
|
|||||||
reg_params_revision: req_dp.reg_params_revision().from_proto(),
|
reg_params_revision: req_dp.reg_params_revision().from_proto(),
|
||||||
adr_algorithm_id: req_dp.adr_algorithm_id.clone(),
|
adr_algorithm_id: req_dp.adr_algorithm_id.clone(),
|
||||||
payload_codec_runtime: req_dp.payload_codec_runtime().from_proto(),
|
payload_codec_runtime: req_dp.payload_codec_runtime().from_proto(),
|
||||||
payload_decoder_config: req_dp.payload_encoder_config.clone(),
|
payload_codec_script: req_dp.payload_codec_script.clone(),
|
||||||
payload_encoder_config: req_dp.payload_decoder_config.clone(),
|
|
||||||
uplink_interval: req_dp.uplink_interval as i32,
|
uplink_interval: req_dp.uplink_interval as i32,
|
||||||
device_status_req_interval: req_dp.device_status_req_interval as i32,
|
device_status_req_interval: req_dp.device_status_req_interval as i32,
|
||||||
supports_otaa: req_dp.supports_otaa,
|
supports_otaa: req_dp.supports_otaa,
|
||||||
|
@ -16,28 +16,40 @@ pub async fn decode(
|
|||||||
let conf = config::get();
|
let conf = config::get();
|
||||||
let max_run_ts = SystemTime::now() + conf.codec.js.max_execution_time;
|
let max_run_ts = SystemTime::now() + conf.codec.js.max_execution_time;
|
||||||
|
|
||||||
let rt = rquickjs::Runtime::new().unwrap();
|
let rt = rquickjs::Runtime::new()?;
|
||||||
rt.set_interrupt_handler(Some(Box::new(move || SystemTime::now() > max_run_ts)));
|
rt.set_interrupt_handler(Some(Box::new(move || SystemTime::now() > max_run_ts)));
|
||||||
|
|
||||||
let ctx = rquickjs::Context::full(&rt).unwrap();
|
let ctx = rquickjs::Context::full(&rt)?;
|
||||||
|
|
||||||
let script = decode_config.to_string();
|
let script = format!(
|
||||||
|
r#"
|
||||||
|
{}
|
||||||
|
|
||||||
|
export {{ decodeUplink }};
|
||||||
|
"#,
|
||||||
|
decode_config
|
||||||
|
);
|
||||||
let b = b.to_vec();
|
let b = b.to_vec();
|
||||||
|
|
||||||
ctx.with(|ctx| {
|
let out = ctx.with(|ctx| -> Result<pbjson_types::Struct> {
|
||||||
let m = ctx.compile("script", script).unwrap();
|
let m = ctx.compile("script", script)?;
|
||||||
let func: rquickjs::Function = m.get("Decode").unwrap();
|
let func: rquickjs::Function = m.get("decodeUplink")?;
|
||||||
|
|
||||||
let input = rquickjs::Object::new(ctx).unwrap();
|
let input = rquickjs::Object::new(ctx)?;
|
||||||
input.set("f_port", f_port.into_js(ctx).unwrap()).unwrap();
|
input.set("fPort", f_port.into_js(ctx)?)?;
|
||||||
input
|
input.set("variables", variables.into_js(ctx)?)?;
|
||||||
.set("variables", variables.into_js(ctx).unwrap())
|
input.set("bytes", b.into_js(ctx)?)?;
|
||||||
.unwrap();
|
|
||||||
input.set("data", b.into_js(ctx).unwrap()).unwrap();
|
|
||||||
|
|
||||||
let res: rquickjs::Object = func.call((input,))?;
|
let res: rquickjs::Object = func.call((input,))?;
|
||||||
Ok(convert::rquickjs_to_struct(&res))
|
Ok(convert::rquickjs_to_struct(&res))
|
||||||
})
|
})?;
|
||||||
|
|
||||||
|
let obj = out.fields.get("object").cloned().unwrap_or_default();
|
||||||
|
if let Some(pbjson_types::value::Kind::StructValue(v)) = obj.kind {
|
||||||
|
return Ok(v);
|
||||||
|
}
|
||||||
|
|
||||||
|
Err(anyhow!("decodeUplink did not return 'object'"))
|
||||||
}
|
}
|
||||||
|
|
||||||
pub async fn encode(
|
pub async fn encode(
|
||||||
@ -49,28 +61,31 @@ pub async fn encode(
|
|||||||
let conf = config::get();
|
let conf = config::get();
|
||||||
let max_run_ts = SystemTime::now() + conf.codec.js.max_execution_time;
|
let max_run_ts = SystemTime::now() + conf.codec.js.max_execution_time;
|
||||||
|
|
||||||
let rt = rquickjs::Runtime::new().unwrap();
|
let rt = rquickjs::Runtime::new()?;
|
||||||
rt.set_interrupt_handler(Some(Box::new(move || SystemTime::now() > max_run_ts)));
|
rt.set_interrupt_handler(Some(Box::new(move || SystemTime::now() > max_run_ts)));
|
||||||
|
|
||||||
let ctx = rquickjs::Context::full(&rt).unwrap();
|
let ctx = rquickjs::Context::full(&rt)?;
|
||||||
|
|
||||||
let script = encode_config.to_string();
|
let script = format!(
|
||||||
|
r#"
|
||||||
|
{}
|
||||||
|
export {{ encodeDownlink }};
|
||||||
|
"#,
|
||||||
|
encode_config,
|
||||||
|
);
|
||||||
|
|
||||||
ctx.with(|ctx| {
|
ctx.with(|ctx| {
|
||||||
let m = ctx.compile("script", script).unwrap();
|
let m = ctx.compile("script", script)?;
|
||||||
let func: rquickjs::Function = m.get("Encode").unwrap();
|
let func: rquickjs::Function = m.get("encodeDownlink")?;
|
||||||
|
|
||||||
let input = rquickjs::Object::new(ctx).unwrap();
|
let input = rquickjs::Object::new(ctx)?;
|
||||||
input.set("f_port", f_port.into_js(ctx).unwrap()).unwrap();
|
input.set("fPort", f_port.into_js(ctx)?)?;
|
||||||
input
|
input.set("variables", variables.into_js(ctx)?)?;
|
||||||
.set("variables", variables.into_js(ctx).unwrap())
|
input.set("data", convert::struct_to_rquickjs(ctx, s))?;
|
||||||
.unwrap();
|
|
||||||
input
|
|
||||||
.set("object", convert::struct_to_rquickjs(ctx, s))
|
|
||||||
.unwrap();
|
|
||||||
|
|
||||||
let res: Vec<u8> = func.call((input,))?;
|
let res: rquickjs::Object = func.call((input,))?;
|
||||||
Ok(res)
|
let v: Vec<u8> = res.get("bytes")?;
|
||||||
|
Ok(v)
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -81,7 +96,7 @@ pub mod test {
|
|||||||
#[tokio::test]
|
#[tokio::test]
|
||||||
pub async fn test_decode_timeout() {
|
pub async fn test_decode_timeout() {
|
||||||
let decoder = r#"
|
let decoder = r#"
|
||||||
export function Decode(input) {
|
function decodeUplink(input) {
|
||||||
while (true) {
|
while (true) {
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -97,11 +112,13 @@ pub mod test {
|
|||||||
#[tokio::test]
|
#[tokio::test]
|
||||||
pub async fn test_decode() {
|
pub async fn test_decode() {
|
||||||
let decoder = r#"
|
let decoder = r#"
|
||||||
export function Decode(input) {
|
function decodeUplink(input) {
|
||||||
return {
|
return {
|
||||||
f_port: input.f_port,
|
object: {
|
||||||
|
f_port: input.fPort,
|
||||||
variables: input.variables,
|
variables: input.variables,
|
||||||
data: input.data
|
data: input.bytes
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
"#
|
"#
|
||||||
@ -174,7 +191,7 @@ pub mod test {
|
|||||||
#[tokio::test]
|
#[tokio::test]
|
||||||
pub async fn test_encode_timeout() {
|
pub async fn test_encode_timeout() {
|
||||||
let encoder = r#"
|
let encoder = r#"
|
||||||
export function Encode(input) {
|
function encodeDownlink(input) {
|
||||||
while (true) {
|
while (true) {
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -195,11 +212,15 @@ pub mod test {
|
|||||||
#[tokio::test]
|
#[tokio::test]
|
||||||
pub async fn test_encode() {
|
pub async fn test_encode() {
|
||||||
let encoder = r#"
|
let encoder = r#"
|
||||||
export function Encode(input) {
|
function encodeDownlink(input) {
|
||||||
if (input.object.enabled) {
|
if (input.data.enabled) {
|
||||||
return [input.f_port, 0x01];
|
return {
|
||||||
|
bytes: [0x01]
|
||||||
|
};
|
||||||
} else {
|
} else {
|
||||||
return [input.f_port, 0x00];
|
return {
|
||||||
|
bytes: [0x02]
|
||||||
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
"#
|
"#
|
||||||
@ -208,19 +229,15 @@ pub mod test {
|
|||||||
let mut vars: HashMap<String, String> = HashMap::new();
|
let mut vars: HashMap<String, String> = HashMap::new();
|
||||||
vars.insert("foo".into(), "bar".into());
|
vars.insert("foo".into(), "bar".into());
|
||||||
|
|
||||||
let input = prost_types::Struct {
|
let mut input = prost_types::Struct::default();
|
||||||
fields: [(
|
input.fields.insert(
|
||||||
"enabled".to_string(),
|
"enabled".to_string(),
|
||||||
prost_types::Value {
|
prost_types::Value {
|
||||||
kind: Some(prost_types::value::Kind::BoolValue(true)),
|
kind: Some(prost_types::value::Kind::BoolValue(true)),
|
||||||
},
|
},
|
||||||
)]
|
);
|
||||||
.iter()
|
|
||||||
.cloned()
|
|
||||||
.collect(),
|
|
||||||
};
|
|
||||||
|
|
||||||
let out = encode(10, &vars, &encoder, &input).await.unwrap();
|
let out = encode(10, &vars, &encoder, &input).await.unwrap();
|
||||||
assert_eq!(vec![10, 1], out);
|
assert_eq!(vec![1], out);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -29,8 +29,6 @@ pub struct DeviceProfile {
|
|||||||
pub reg_params_revision: Revision,
|
pub reg_params_revision: Revision,
|
||||||
pub adr_algorithm_id: String,
|
pub adr_algorithm_id: String,
|
||||||
pub payload_codec_runtime: Codec,
|
pub payload_codec_runtime: Codec,
|
||||||
pub payload_decoder_config: String,
|
|
||||||
pub payload_encoder_config: String,
|
|
||||||
pub uplink_interval: i32,
|
pub uplink_interval: i32,
|
||||||
pub device_status_req_interval: i32,
|
pub device_status_req_interval: i32,
|
||||||
pub supports_otaa: bool,
|
pub supports_otaa: bool,
|
||||||
@ -46,6 +44,7 @@ pub struct DeviceProfile {
|
|||||||
pub abp_rx2_dr: i16,
|
pub abp_rx2_dr: i16,
|
||||||
pub abp_rx2_freq: i64,
|
pub abp_rx2_freq: i64,
|
||||||
pub tags: fields::KeyValue,
|
pub tags: fields::KeyValue,
|
||||||
|
pub payload_codec_script: String,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl DeviceProfile {
|
impl DeviceProfile {
|
||||||
@ -72,8 +71,7 @@ impl Default for DeviceProfile {
|
|||||||
reg_params_revision: Revision::A,
|
reg_params_revision: Revision::A,
|
||||||
adr_algorithm_id: "".into(),
|
adr_algorithm_id: "".into(),
|
||||||
payload_codec_runtime: Codec::NONE,
|
payload_codec_runtime: Codec::NONE,
|
||||||
payload_decoder_config: "".into(),
|
payload_codec_script: "".into(),
|
||||||
payload_encoder_config: "".into(),
|
|
||||||
uplink_interval: 0,
|
uplink_interval: 0,
|
||||||
device_status_req_interval: 0,
|
device_status_req_interval: 0,
|
||||||
supports_otaa: false,
|
supports_otaa: false,
|
||||||
@ -184,8 +182,7 @@ pub async fn update(dp: DeviceProfile) -> Result<DeviceProfile, Error> {
|
|||||||
device_profile::reg_params_revision.eq(&dp.reg_params_revision),
|
device_profile::reg_params_revision.eq(&dp.reg_params_revision),
|
||||||
device_profile::adr_algorithm_id.eq(&dp.adr_algorithm_id),
|
device_profile::adr_algorithm_id.eq(&dp.adr_algorithm_id),
|
||||||
device_profile::payload_codec_runtime.eq(&dp.payload_codec_runtime),
|
device_profile::payload_codec_runtime.eq(&dp.payload_codec_runtime),
|
||||||
device_profile::payload_decoder_config.eq(&dp.payload_decoder_config),
|
device_profile::payload_codec_script.eq(&dp.payload_codec_script),
|
||||||
device_profile::payload_encoder_config.eq(&dp.payload_encoder_config),
|
|
||||||
device_profile::uplink_interval.eq(&dp.uplink_interval),
|
device_profile::uplink_interval.eq(&dp.uplink_interval),
|
||||||
device_profile::device_status_req_interval.eq(&dp.device_status_req_interval),
|
device_profile::device_status_req_interval.eq(&dp.device_status_req_interval),
|
||||||
device_profile::supports_otaa.eq(&dp.supports_otaa),
|
device_profile::supports_otaa.eq(&dp.supports_otaa),
|
||||||
|
@ -81,8 +81,6 @@ table! {
|
|||||||
reg_params_revision -> Varchar,
|
reg_params_revision -> Varchar,
|
||||||
adr_algorithm_id -> Varchar,
|
adr_algorithm_id -> Varchar,
|
||||||
payload_codec_runtime -> Varchar,
|
payload_codec_runtime -> Varchar,
|
||||||
payload_encoder_config -> Text,
|
|
||||||
payload_decoder_config -> Text,
|
|
||||||
uplink_interval -> Int4,
|
uplink_interval -> Int4,
|
||||||
device_status_req_interval -> Int4,
|
device_status_req_interval -> Int4,
|
||||||
supports_otaa -> Bool,
|
supports_otaa -> Bool,
|
||||||
@ -98,6 +96,7 @@ table! {
|
|||||||
abp_rx2_dr -> Int2,
|
abp_rx2_dr -> Int2,
|
||||||
abp_rx2_freq -> Int8,
|
abp_rx2_freq -> Int8,
|
||||||
tags -> Jsonb,
|
tags -> Jsonb,
|
||||||
|
payload_codec_script -> Text,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -574,7 +574,7 @@ impl Data {
|
|||||||
dp.payload_codec_runtime,
|
dp.payload_codec_runtime,
|
||||||
mac.f_port.unwrap_or(0),
|
mac.f_port.unwrap_or(0),
|
||||||
&dev.variables,
|
&dev.variables,
|
||||||
&dp.payload_decoder_config,
|
&dp.payload_codec_script,
|
||||||
&pl.data,
|
&pl.data,
|
||||||
)
|
)
|
||||||
.await
|
.await
|
||||||
|
@ -106,3 +106,7 @@ pre {
|
|||||||
.search-dropdown .ant-select-dropdown-menu {
|
.search-dropdown .ant-select-dropdown-menu {
|
||||||
max-height: 600px;
|
max-height: 600px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.CodeMirror {
|
||||||
|
height: 600px;
|
||||||
|
}
|
||||||
|
@ -28,33 +28,40 @@ class CreateDeviceProfile extends Component<IProps> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
const encodeScript = `// Encode encodes the given object into an array of bytes.
|
const codecScript = `// Decode uplink function.
|
||||||
//
|
//
|
||||||
// Input is an object with the following fields:
|
// Input is an object with the following fields:
|
||||||
// - f_port = LoRaWAN fPort
|
// - bytes = Byte array containing the uplink payload, e.g. [255, 230, 255, 0]
|
||||||
// - variables = Device variables
|
// - fPort = Uplink fPort.
|
||||||
// - object = Input object, e.g. {"temperature": 22.5}
|
// - variables = Object containing the configured device variables.
|
||||||
//
|
//
|
||||||
// This function must return an array of bytes, e.g. [225, 230, 255, 0]
|
// Output must be an object with the following fields:
|
||||||
export function Encode(input) {
|
// - data = Object representing the decoded payload.
|
||||||
return [];
|
function decodeUplink(input) {
|
||||||
}`;
|
return {
|
||||||
|
object: {
|
||||||
|
temp: 22.5
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
const decodeScript = `// Decode decodes an array of bytes into an object.
|
// Encode downlink function.
|
||||||
//
|
//
|
||||||
// Input is an object with the following fields:
|
// Input is an object with the following fields:
|
||||||
// - f_port = LoRaWAN fPort
|
// - data = Object representing the payload that must be encoded.
|
||||||
// - variables = Device variables
|
// - variables = Object containing the configured device variables.
|
||||||
// - data = Input byte array, e.g. [225, 230, 255, 0]
|
|
||||||
//
|
//
|
||||||
// This function must return an object, e.g. {"temperature": 22.5}
|
// Output must be an object with the following fields:
|
||||||
export function Decode(input) {
|
// - bytes = Byte array containing the downlink payload.
|
||||||
return {};
|
function encodeDownlink(input) {
|
||||||
}`;
|
return {
|
||||||
|
data: [225, 230, 255, 0]
|
||||||
|
};
|
||||||
|
}
|
||||||
|
`;
|
||||||
|
|
||||||
let deviceProfile = new DeviceProfile();
|
let deviceProfile = new DeviceProfile();
|
||||||
deviceProfile.setPayloadEncoderConfig(encodeScript);
|
deviceProfile.setPayloadCodecScript(codecScript);
|
||||||
deviceProfile.setPayloadDecoderConfig(decodeScript);
|
|
||||||
|
|
||||||
return(
|
return(
|
||||||
<Space direction="vertical" style={{width: "100%"}} size="large">
|
<Space direction="vertical" style={{width: "100%"}} size="large">
|
||||||
|
@ -92,8 +92,7 @@ class DeviceProfileForm extends Component<IProps, IState> {
|
|||||||
|
|
||||||
// codec
|
// codec
|
||||||
dp.setPayloadCodecRuntime(v.payloadCodecRuntime);
|
dp.setPayloadCodecRuntime(v.payloadCodecRuntime);
|
||||||
dp.setPayloadEncoderConfig(v.payloadEncoderConfig);
|
dp.setPayloadCodecScript(v.payloadCodecScript);
|
||||||
dp.setPayloadDecoderConfig(v.payloadDecoderConfig);
|
|
||||||
|
|
||||||
// tags
|
// tags
|
||||||
for (const elm of v.tagsMap) {
|
for (const elm of v.tagsMap) {
|
||||||
@ -322,17 +321,9 @@ class DeviceProfileForm extends Component<IProps, IState> {
|
|||||||
</Select>
|
</Select>
|
||||||
</Form.Item>
|
</Form.Item>
|
||||||
{this.state.payloadCodecRuntime === CodecRuntime.JS && <CodeEditor
|
{this.state.payloadCodecRuntime === CodecRuntime.JS && <CodeEditor
|
||||||
label="Decode function"
|
label="Codec functions"
|
||||||
tooltip="The function must have the signature function Decode(fPort, bytes) and must return an object. ChirpStack Application Server will convert this object to JSON."
|
name="payloadCodecScript"
|
||||||
name="payloadDecoderConfig"
|
value={this.props.initialValues.getPayloadCodecScript()}
|
||||||
value={this.props.initialValues.getPayloadDecoderConfig()}
|
|
||||||
formRef={this.formRef} disabled={this.props.disabled}
|
|
||||||
/>}
|
|
||||||
{this.state.payloadCodecRuntime === CodecRuntime.JS && <CodeEditor
|
|
||||||
label="Encode function"
|
|
||||||
tooltip="The function must have the signature function Encode(fPort, obj) and must return an array of bytes."
|
|
||||||
name="payloadEncoderConfig"
|
|
||||||
value={this.props.initialValues.getPayloadEncoderConfig()}
|
|
||||||
formRef={this.formRef} disabled={this.props.disabled}
|
formRef={this.formRef} disabled={this.props.disabled}
|
||||||
/>}
|
/>}
|
||||||
</Tabs.TabPane>
|
</Tabs.TabPane>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user