diff options
Diffstat (limited to 'gd/l2cap/classic/facade.proto')
-rw-r--r-- | gd/l2cap/classic/facade.proto | 61 |
1 files changed, 14 insertions, 47 deletions
diff --git a/gd/l2cap/classic/facade.proto b/gd/l2cap/classic/facade.proto index 73c204fa7..b5faf03df 100644 --- a/gd/l2cap/classic/facade.proto +++ b/gd/l2cap/classic/facade.proto @@ -6,42 +6,23 @@ import "google/protobuf/empty.proto"; import "facade/common.proto"; service L2capClassicModuleFacade { + rpc RegisterChannel(RegisterChannelRequest) returns (google.protobuf.Empty) { + // Testing Android Bluetooth stack only. Optional for other stack. + } rpc FetchConnectionComplete(google.protobuf.Empty) returns (stream ConnectionCompleteEvent) { // Testing Android Bluetooth stack only. Optional for other stack. } rpc FetchConnectionClose(google.protobuf.Empty) returns (stream ConnectionCloseEvent) { // Testing Android Bluetooth stack only. Optional for other stack. } + rpc Connect(facade.BluetoothAddress) returns (google.protobuf.Empty) {} rpc OpenChannel(OpenChannelRequest) returns (google.protobuf.Empty) {} rpc CloseChannel(CloseChannelRequest) returns (google.protobuf.Empty) {} + rpc ConfigureChannel(ConfigureChannelRequest) returns (google.protobuf.Empty) {} + rpc SendL2capPacket(L2capPacket) returns (SendL2capPacketResult) {} rpc FetchL2capData(google.protobuf.Empty) returns (stream L2capPacket) {} rpc SetDynamicChannel(SetEnableDynamicChannelRequest) returns (google.protobuf.Empty) {} rpc SendDynamicChannelPacket(DynamicChannelPacket) returns (google.protobuf.Empty) {} - rpc SetTrafficPaused(SetTrafficPausedRequest) returns (google.protobuf.Empty) {} - rpc GetChannelQueueDepth(google.protobuf.Empty) returns (GetChannelQueueDepthResponse) { - // Get the buffer size of channel queue end for L2CAP user (how many packets we can buffer - // before L2CAP user dequeues. - } - rpc InitiateConnectionForSecurity(facade.BluetoothAddress) returns (google.protobuf.Empty) {} - rpc FetchSecurityConnectionEvents(google.protobuf.Empty) returns (stream LinkSecurityInterfaceCallbackEvent) {} - rpc SecurityLinkEnsureAuthenticated(facade.BluetoothAddress) returns (google.protobuf.Empty) {} - rpc SecurityLinkHold(facade.BluetoothAddress) returns (google.protobuf.Empty) {} - rpc SecurityLinkDisconnect(facade.BluetoothAddress) returns (google.protobuf.Empty) {} - rpc SecurityLinkRelease(facade.BluetoothAddress) returns (google.protobuf.Empty) {} -} - -enum LinkSecurityInterfaceCallbackEventType { - ON_CONNECTED = 0; - ON_DISCONNECTED = 1; - ON_AUTHENTICATION_COMPLETE = 2; - ON_ENCRYPTION_CHANGE = 3; - ON_READ_REMOTE_VERSION_INFO = 4; - ON_READ_REMOTE_EXTENDED_FEATURES = 5; -} - -message LinkSecurityInterfaceCallbackEvent { - facade.BluetoothAddress address = 1; - LinkSecurityInterfaceCallbackEventType event_type = 2; } message RegisterChannelRequest { @@ -59,8 +40,7 @@ message ConnectionCloseEvent { enum RetransmissionFlowControlMode { BASIC = 0; - ERTM = 1; - ERTM_OPTIONAL = 2; + ERTM = 3; } message OpenChannelRequest { @@ -69,6 +49,11 @@ message OpenChannelRequest { RetransmissionFlowControlMode mode = 3; } +message ConfigureChannelRequest { + facade.BluetoothAddress remote = 1; + // Config +} + message CloseChannelRequest { uint32 psm = 1; } @@ -94,10 +79,8 @@ message SendL2capPacketResult { } message L2capPacket { - oneof channel_type { - uint32 psm = 1; - uint32 fixed_cid = 2; - } + facade.BluetoothAddress remote = 1; + uint32 channel = 2; bytes payload = 3; } @@ -112,19 +95,3 @@ message DynamicChannelPacket { uint32 psm = 2; bytes payload = 3; } - -message SetTrafficPausedRequest { - bool paused = 1; - uint32 psm = 2; -} - -message GetChannelQueueDepthResponse { - uint32 size = 1; -} - -enum ClassicSecurityPolicy { - ENCRYPTED_TRANSPORT = 0; - AUTHENTICATED_ENCRYPTED_TRANSPORT = 1; - BEST = 2; - _SDP_ONLY_NO_SECURITY_WHATSOEVER_PLAINTEXT_TRANSPORT_OK = 3; -} |