Support dynamic upgrade when the device is connected to Wifi AP after initial connection.

PiperOrigin-RevId: 556959762
This commit is contained in:
hai007
2023-08-14 17:25:59 -07:00
committed by Copybara-Service
parent fabeff0d57
commit eb4a37084b
@@ -47,6 +47,7 @@ message V1Frame {
AUTHENTICATION_RESULT = 9;
AUTO_RESUME = 10;
AUTO_RECONNECT = 11;
BANDWIDTH_UPGRADE_RETRY = 12;
}
optional FrameType type = 1;
@@ -62,6 +63,7 @@ message V1Frame {
optional AuthenticationResultFrame authentication_result = 10;
optional AutoResumeFrame auto_resume = 11;
optional AutoReconnectFrame auto_reconnect = 12;
optional BandwidthUpgradeRetryFrame bandwidth_upgrade_retry = 13;
}
message ConnectionRequestFrame {
@@ -307,6 +309,34 @@ message BandwidthUpgradeNegotiationFrame {
optional ClientIntroductionAck client_introduction_ack = 4;
}
message BandwidthUpgradeRetryFrame {
// Should always match cs/symbol:location.nearby.proto.connections.Medium
// LINT.IfChange
enum Medium {
UNKNOWN_MEDIUM = 0;
// 1 is reserved.
BLUETOOTH = 2;
WIFI_HOTSPOT = 3;
BLE = 4;
WIFI_LAN = 5;
WIFI_AWARE = 6;
NFC = 7;
WIFI_DIRECT = 8;
WEB_RTC = 9;
BLE_L2CAP = 10;
USB = 11;
}
// LINT.ThenChange(//depot/google3/third_party/nearby/proto/connections_enums.proto)
// The mediums this device supports upgrading to. This list should be filtered
// by both the strategy and this device's individual limitations.
repeated Medium supported_medium = 1;
// If true, expect the remote endpoint to send back the latest
// supported_medium.
optional bool is_request = 2;
}
message KeepAliveFrame {
// And ack will be sent after receiving KEEP_ALIVE frame.
optional bool ack = 1;