summaryrefstree
path: root/vendor/etc/sensors/proto/sns_ext_svc.proto
blob: 7e8370ae4c0894385f8cd1e3eb4f09f4578aeb4e (plain)
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
// @file sns_ext_svc.proto
//
// Sensor provides access to external QMI services.
//
// This Sensor will create a connection to the external service upon
// receipt of the first request. Subsequent requests will be sent upon the
// same connection. The connection will be closed after the client closes
// the data stream.
//
// An error event will be sent upon any received error, including upon
// the error callback. It is then the responsibility of the client to close
// the data stream, and re-open a new one if desired.
//
// Copyright (c) 2017, 2020 Qualcomm Technologies, Inc.
// All Rights Reserved.
// Confidential and Proprietary - Qualcomm Technologies, Inc.

syntax = "proto2";
import "nanopb.proto";

enum sns_ext_svc_msgid
{
  option (nanopb_enumopt).long_names = false;

  // Send a request message
  SNS_EXT_SVC_MSGID_SNS_EXT_SVC_REQ = 512;

  // Asynchronously received response message
  SNS_EXT_SVC_MSGID_SNS_EXT_SVC_RESP = 768;

  // Asynchronously received indication message
  SNS_EXT_SVC_MSGID_SNS_EXT_SVC_IND = 1024;
}

message sns_ext_svc_req
{
  required uint32 svc_id = 1;

  // QMI/IDL Message ID
  required int32 msg_id = 2;

  // Client-specified transaction ID, to be returned in sns_ext_svc_resp
  optional int32 transaction_id = 3;

  // Contains the QMI-decoded request message.
  required bytes payload = 4;
}

message sns_ext_svc_resp
{
  // QMI/IDL Message ID
  required int32 msg_id = 1;

  // Transport error, as defined in qmi_client.h; Defaults to QMI_NO_ERR
  required int32 transp_err = 2;

  // Client-specified transaction ID, as provided in sns_ext_svc_req
  optional int32 transaction_id = 3;

  // Contains the QMI-decoded response message
  // May be empty if transport_err != QMI_NO_ERR
  required bytes payload = 4;
}

message sns_ext_svc_ind
{
  // QMI/IDL Message ID
  required int32 msg_id = 1;

  // Contains the QMI-decoded indication message.
  required bytes payload = 2;
}