2.2.2.2.2 UDP: Presence Response
When a device receives a presence request, it responds with a presence response to notify that it’s available.
|
|
|
|
|
|
|
|
|
|
1 |
|
|
|
|
|
|
|
|
|
2 |
|
|
|
|
|
|
|
|
|
3 |
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
MessageType |
DiscoveryType |
ConnectionMode |
|||||||||||||||||||||||||||||
|
DeviceType |
DeviceNameLength |
||||||||||||||||||||||||||||||
|
DeviceName (variable) |
|||||||||||||||||||||||||||||||
|
... |
|||||||||||||||||||||||||||||||
|
... |
|||||||||||||||||||||||||||||||
|
DeviceIdSalt |
|||||||||||||||||||||||||||||||
|
DeviceIdHash |
|||||||||||||||||||||||||||||||
MessageType (1 byte): Indicates current message type – in this case, Discovery (1).
DiscoveryType (1 byte): Indicates type of discovery message, in this case, Presence Response (1).
ConnectionMode (2 bytes): Displays types of available connections.
-
Value
Meaning
0
None
1
Proximal
2
Legacy
-
DeviceType (2 bytes): SKU of the device
-
Value
Meaning
1
Xbox One
6
Apple iPhone
7
Apple iPad
8
Android device
9
Windows 10 Desktop
11
Windows 10 Phone
12
Linux device
13
Windows IoT
14
Surface Hub
-
DeviceNameLength (2 bytes): Length of the machine name of the device.
DeviceName (variable): This is character representation of the name of the device. The size of the list is bounded by the previous message.
DeviceIdSalt (4 bytes): A randomly generated salt.
DeviceIdHash (4 bytes): Salted SHA-256 hash of the internal CDP device ID. This is used to correlate the advertising device to a list of known devices without advertising the full device ID.