Loading cmds/statsd/src/atoms.proto +31 −0 Original line number Diff line number Diff line Loading @@ -161,6 +161,7 @@ message Atom { BluetoothBondStateChanged bluetooth_bond_state_changed = 165; BluetoothClassicPairingEventReported bluetooth_classic_pairing_event_reported = 166; BluetoothSmpPairingEventReported bluetooth_smp_pairing_event_reported = 167; BluetoothSocketConnectionStateChanged bluetooth_socket_connection_state_changed = 171; } // Pulled events will start at field 10000. Loading Loading @@ -1718,6 +1719,36 @@ message BluetoothSmpPairingEventReported { optional android.bluetooth.smp.PairingFailReasonEnum smp_fail_reason = 4; } /** * Logs when a Bluetooth socket’s connection state changed * * Logged from: * system/bt */ message BluetoothSocketConnectionStateChanged { // An identifier that can be used to match events for this device. // Currently, this is a salted hash of the MAC address of this Bluetooth device. // Salt: Randomly generated 256 bit value // Hash algorithm: HMAC-SHA256 // Size: 32 byte // Default: null or empty if the device identifier is not known optional bytes obfuscated_id = 1 [(android.os.statsd.log_mode) = MODE_BYTES]; // Port of this socket // Default 0 when unknown or don't care optional int32 port = 2; // Socket type as mentioned in // frameworks/base/core/java/android/bluetooth/BluetoothSocket.java // Default: SOCKET_TYPE_UNKNOWN optional android.bluetooth.SocketTypeEnum type = 3; // Socket connection state // Default: SOCKET_CONNECTION_STATE_UNKNOWN optional android.bluetooth.SocketConnectionstateEnum state = 4; // Number of bytes sent to remote device during this connection optional int64 tx_bytes = 5; // Number of bytes received from remote device during this connection optional int64 rx_bytes = 6; } /** * Logs when something is plugged into or removed from the USB-C connector. * Loading core/proto/android/bluetooth/enums.proto +22 −0 Original line number Diff line number Diff line Loading @@ -110,3 +110,25 @@ enum UnbondReasonEnum { UNBOND_REASON_REMOTE_AUTH_CANCELED = 8; UNBOND_REASON_REMOVED = 9; } enum SocketTypeEnum { SOCKET_TYPE_UNKNOWN = 0; SOCKET_TYPE_RFCOMM = 1; SOCKET_TYPE_SCO = 2; SOCKET_TYPE_L2CAP_BREDR = 3; SOCKET_TYPE_L2CAP_LE = 4; } enum SocketConnectionstateEnum { SOCKET_CONNECTION_STATE_UNKNOWN = 0; // Socket acts as a server waiting for connection SOCKET_CONNECTION_STATE_LISTENING = 1; // Socket acts as a client trying to connect SOCKET_CONNECTION_STATE_CONNECTING = 2; // Socket is connected SOCKET_CONNECTION_STATE_CONNECTED = 3; // Socket tries to disconnect from remote SOCKET_CONNECTION_STATE_DISCONNECTING = 4; // This socket is closed SOCKET_CONNECTION_STATE_DISCONNECTED = 5; } Loading
cmds/statsd/src/atoms.proto +31 −0 Original line number Diff line number Diff line Loading @@ -161,6 +161,7 @@ message Atom { BluetoothBondStateChanged bluetooth_bond_state_changed = 165; BluetoothClassicPairingEventReported bluetooth_classic_pairing_event_reported = 166; BluetoothSmpPairingEventReported bluetooth_smp_pairing_event_reported = 167; BluetoothSocketConnectionStateChanged bluetooth_socket_connection_state_changed = 171; } // Pulled events will start at field 10000. Loading Loading @@ -1718,6 +1719,36 @@ message BluetoothSmpPairingEventReported { optional android.bluetooth.smp.PairingFailReasonEnum smp_fail_reason = 4; } /** * Logs when a Bluetooth socket’s connection state changed * * Logged from: * system/bt */ message BluetoothSocketConnectionStateChanged { // An identifier that can be used to match events for this device. // Currently, this is a salted hash of the MAC address of this Bluetooth device. // Salt: Randomly generated 256 bit value // Hash algorithm: HMAC-SHA256 // Size: 32 byte // Default: null or empty if the device identifier is not known optional bytes obfuscated_id = 1 [(android.os.statsd.log_mode) = MODE_BYTES]; // Port of this socket // Default 0 when unknown or don't care optional int32 port = 2; // Socket type as mentioned in // frameworks/base/core/java/android/bluetooth/BluetoothSocket.java // Default: SOCKET_TYPE_UNKNOWN optional android.bluetooth.SocketTypeEnum type = 3; // Socket connection state // Default: SOCKET_CONNECTION_STATE_UNKNOWN optional android.bluetooth.SocketConnectionstateEnum state = 4; // Number of bytes sent to remote device during this connection optional int64 tx_bytes = 5; // Number of bytes received from remote device during this connection optional int64 rx_bytes = 6; } /** * Logs when something is plugged into or removed from the USB-C connector. * Loading
core/proto/android/bluetooth/enums.proto +22 −0 Original line number Diff line number Diff line Loading @@ -110,3 +110,25 @@ enum UnbondReasonEnum { UNBOND_REASON_REMOTE_AUTH_CANCELED = 8; UNBOND_REASON_REMOVED = 9; } enum SocketTypeEnum { SOCKET_TYPE_UNKNOWN = 0; SOCKET_TYPE_RFCOMM = 1; SOCKET_TYPE_SCO = 2; SOCKET_TYPE_L2CAP_BREDR = 3; SOCKET_TYPE_L2CAP_LE = 4; } enum SocketConnectionstateEnum { SOCKET_CONNECTION_STATE_UNKNOWN = 0; // Socket acts as a server waiting for connection SOCKET_CONNECTION_STATE_LISTENING = 1; // Socket acts as a client trying to connect SOCKET_CONNECTION_STATE_CONNECTING = 2; // Socket is connected SOCKET_CONNECTION_STATE_CONNECTED = 3; // Socket tries to disconnect from remote SOCKET_CONNECTION_STATE_DISCONNECTING = 4; // This socket is closed SOCKET_CONNECTION_STATE_DISCONNECTED = 5; }