Page 488 - From GMS to LTE
P. 488

474  From GSM to LTE-Advanced Pro and 5G

            Device 1                                Device 2

                        ACL connection establishment


                 L2CAP connection establishment, PSM 0x0001      Service
                                                                 database
               SDP_Service_Search_Attribute_Req (UUID 0x1103)

                 SDP_Service_Search_Attr_Response (Records)


                         L2CAP connection release             ACL connection
                                                              remains in
                                                              place
                 L2CAP connection establishment, PSM 0x0003

                                  …
            Figure 7.12  Establishment of a connection to a service.

            UUIDs of all services it offers to other devices. The parameters of the individual services
            can then be retrieved from the database with SDP_Service_Search_Attribute_Request
            messages. For a service query, the database also returns the name for the requested
            service that can be set by the higher layers of the Bluetooth stack. Therefore, it is
              possible to have country‐ and language‐specific service names that are automatically
            assigned, for example, during the installation of the Bluetooth stack. The name, how-
            ever, is just for presenting the service to the user. The Bluetooth stack itself always
            identifies a service by its UUID and never by using the service name (see Figure 7.12).
             In practice, information that was initially retrieved from the service database of a
            remote device is usually stored on the application layer to allow quicker access to the
            remote device in subsequent communication sessions.
             To finish the database request, the remote device releases the L2CAP connection by
            sending an L2CAP_Disconnection_Request message. If the device wants to establish a
            connection to one of the detected services right away, the ACL connection remains in
            place and another L2CAP_Connection_Request message is sent. This message, how-
            ever, does not contain the PSM ID 0x0001 for the service database as before, but con-
            tains the PSM ID for the higher layer that needs to be contacted for the selected service.
            For most services this will be the RFCOMM layer, which offers a virtual serial connec-
            tion. This service is accessed via PSM 0x0003. One of the few services that does not use
            the RFCOMM layer for data transfer is voice application (e.g. headset profile), which
            uses SCO connections for synchronous data transfer.

            7.4.7  The RFCOMM Layer
            As has been shown in Section 7.4.5, the L2CAP layer is used to multiplex several data
            streams over a single physical connection. The service database, for example, is a ser-
            vice that is accessed via the L2CAP PSM 0x0001. Other services can be accessed in a
            similar way using other PSM IDs. In practice, some services also commonly use another
   483   484   485   486   487   488   489   490   491   492   493