1 Introduction

Bluetooth (BT) communication standard has been widely adopted for the deployment of personal area network (PAN) and body area network (BAN) networking applications.

Although it was initially created to avoid cables in short range networks, BT interfaces have been integrated into a high diversity of commercial devices, from handheld products (smartphones, laptops, electronic pads, tablets) to medical sensors, automobile electronics, music players, headsets or gaming consoles such as Sony PlayStation 3 or Nintendo Wii. This expansion of BT-enabled hardware fostered the release in 2004 of a version of the standard (BT 2.0 + EDR) aimed at providing a bandwidth higher than the basic speed supported by BT 1.1 and 1.2 versions. In BT 1.1 and 1.2 this basic bit rate of 1 Mbps was achieved with a Gaussian frequency shift keying (GFSK) modulation. On the contrary, the main novelty of BT 2.0 + EDR and 2.1 + EDR standards [1, 2] (hereinafter referred to as BT 2.x + EDR) is the adoption of two new modulation schemes. These schemes allow a faster data transfer through the so-called enhanced data rates (EDR). These novel differential phase shift keying (DPSK) based schemes (π/4-DQPSK and 8-DPSK) enable the transmission of the BT packet payload at a bit rate of 2 Mbps or 3 Mbps, respectively.

BT physical layer operates in the Industrial, Scientific and Medical (ISM) 2.4 GHz unlicensed band. As a result, BT radio connections are prone to interferences from other wireless transmitters (Bluetooth or not) working in the same ISM band. Because of the popularity of some of these technologies coexisting in the same ISM band (especially 802.11 but also 802.15.4), most real transmission of BT-capable applications will take place in the presence of a strong environmental noise.

Common non real-time data are transmitted by BT through asynchronous connection-oriented links (ACL). Bluetooth ACL packets must be positively acknowledged by the receiver if they are properly received. In other case, the packet must be retransmitted, which increases the transmission delay and degrades the performance of BT. Noise can induce unrecoverable bit errors in the packets and provoke these retransmissions. In this sense, the impact of the noise on the bit errors suffered by the BT signal highly depends on the modulation scheme that is being employed. In fact, EDR allows higher bit data rates at the cost of a higher sensitivity to the noise.

This paper analytically characterizes and evaluates the effects of noise on the packet delay experienced by transmissions for the different modulations contemplated by BT. The study permits to assess the feasibility of BT communications in the presence of a certain noise level, characterized as a value of signal-to-noise ratio (SNR) per bit.

This paper is organized as follows: Sect. 2 reviews the literature related to the modelling and performance evaluation of the different modulations contemplated by the BT 2.x + EDR specification (GFSK, π/4-DQPSK and 8-DPSK). Basing on existing studies, Sect. 3 presents a model to compute the delay of BT packets in ideal conditions (i.e. with no packet retransmissions). In Sect. 4 this model is extended to characterize the non-ideal case where noise introduces an extra delay due to retransmissions. This analytical model is utilized in Sect. 5 to evaluate the performance of the different modulations for different noise levels. Section 6 presents an empirical evaluation of the analytical model for actual transmissions using the basic rate. Finally Sect. 7 recapitulates the main conclusions of the paper.

2 Related work

Many works in the literature have provided insights on the analysis of the existing modulation techniques for RF communications. In the case of the three modulating schemes employed by BT 2.x + EDR, extensive studies have been devoted to characterize the relationship between the SNR and the bit error ratio (BER). For example the performance of GFSK is modelled in [3], π/4-DQPSK in [411] and 8-DPSK in [1214].

Some of these abstract models are particularized to improve or evaluate specific characteristics of the BT transceivers. For example, the study in [15] offers an analysis of the GFSK modulation with non-coherent detection for systems that employ frequency hopping as the spread spectrum technique (which is the case of BT). Assuming a Rayleigh-type radio channel, the authors propose a model to relate the BER to the SNR ratio and the modulation index.

The work in [16] details the design of a GFSK transceiver with carrier frequency offset correction. The design incorporates a mechanism to simplify the implementation of a multi-symbol receiver. The study shows the results that could be obtained if this design is applied to a BT receiver.

Similarly, the paper in [17] proposes a scheme for a digital GFSK transceiver that includes a new method to estimate the carrier frequency. The scheme is evaluated through simulations analysing the obtained BER. Simulations assume an additive white Gaussian noise (AWGN) channel.

An analogous mechanism for carrier synchronization in a GFSK receiver is offered in [18]. By means of simulations the mechanism (which is not implemented) is contrasted against the behaviour (in terms of the obtained BER) of the typical DFT-based method. Noise is also modelled by an AWGN channel.

After proposing a new radio channel model (based on Markov chains), the performance of BT piconets is evaluated in [19].

Other works in the literature specifically focus on characterizing the impact of noise on BT transmissions. Authors in [20] study the performance of BT 1.1 in Gaussian and Rayleigh-type channels. The paper provides an analytical formulation (with some mathematical mistakes) to calculate the throughput that can be obtained by the different BT packet types as a function of the SNR. The proposed expressions allow to compute the packet error rate (PER) from the BER experienced by a GFSK modulation. Finally the study discusses the convenience of the different packet types for the considered channel types (Raleigh or AWGN).

A RF simulation system for BT transceivers is presented in [21]. The system emulates the channel by combining an AWGN and the effect of interfering signals.

Authors in [22] propose a set of rules to select the BT packet type basing on the estimated SNR. The study suggests employing new modulations (not considered by BT 2.x + EDR) and new algorithms to calculate the SNR. However, the viability of the implementation of these algorithms at the LM (Link Manager) layer of an actual BT host controller is not analysed.

The performance of BT transmissions in Nakagami-type channels is studied in [23] through simulations by observing the evolution of the BER as a function of the SNR. Analyses are conducted for different values of the fading parameter of the Nakagami distribution (as well as for an AWGN channel).

The study in [24] expands the model in [20] (conceived for BT 1.1) to include the EDR modes. As in [20] the benefits of using the different sizes for the new packet types—under an AWGN channel—are evaluated. The paper proposes a set of rules for selecting the packet type as a function of the SNR. Authors suggest that this selection must be performed at the L2CAP layer although they do not clarify how this decision must be implemented at the baseband layer.

A MATLAB simulation model for the physical layer of a BT 2.0 + EDR transceiver is presented in [25]. The BER computed with this model for different values of SNR is compared to that obtained with theoretical models which also assume an AWGN channel.

The operation of Wireless Application Protocol (WAP) applications over BT is evaluated in [26]. The modelling of the communications again assumes that bit errors in a simulated BT piconet are caused by an AWGN channel.

Zanella [27] presents a Markovian model of the BT 2.0 + EDR transmissions in fading channels. In [28] the same author offers theoretical expressions to calculate the bit error probability for BT 2.0 transmissions for both AGWM and Rice fading channels.

The recent study in [29] describes different GFSK demodulation techniques in BT framework. In addition, the authors propose a novel scheme for a digital GFSK demodulator that is able to improve the performance of BT without introducing any complexity in the hardware implementation. The analysis of the behaviour is carried out for an AWGN channel.

Other references dealing with the optimization and implementation of BT demodulators for GFSK, π/4-DQPSK and 8 DPSK modulations can be found in [3038].

The throughput of the recent version of BT for low energy devices is modelled in [39]. The model, conceived for error-prone links, offers an expression to compute the maximum throughput as a function of the BER.

As aforementioned, bit error rate has been analytically characterized in some studies (such as those authored by Zanella). However, to the best of our knowledge, the packet delay has not been analytically modelled in the existing literature about the performance of BT 2.x + EDR in noisy environments. Data delay is an important metric to evaluate the performance of any networking application. In fact packet delay is a key factor to determine the quality of service that is actually perceived by the end-users. Moreover, if a finite period (‘flush timeout’) is set for the proper transmission and reception of the BT packets, data can be discarded if not successfully acknowledged within this interval. Additionally ACL links are disconnected if no packets are received during a certain supervision timeout period (whose default value is 20 s). The timeouts set by the upper layers should be also considered to evaluate the impact of packet delay. Consequently, delay induced by environmental noise may cause applications to become not viable if a certain SNR is not guaranteed. The goal of the present work is to offer an analytical characterization of the delay of BT 2.x + EDR standards for the different modulations (packet type) and under diverse conditions of the noise. The model considers the effects of the retransmissions provoked by the noise together with the procedures (packetization, segmentation, header overhead, etc.) operated at the different layers in the whole BT protocol stack for a typical serial port profile (SPP) connection. By employing this model, the performance of the different available rates of BT 2.x + EDR can be predicted as a function of the measured SNR. Thus the utilized modulation at the BT host controller could be dynamically adjusted to minimize the delay.

Hence, the feasibility of using the EDR modulations will be investigated basing on a realistic metric of the behaviour of a BT connection.

3 Characterization of the delay for the ideal case

The specification of BT 2.0 + EDR enables the BT host controller to use diverse types of Baseband packets. The maximum allowed payload sizes for the different packet types are summarized in Table 1. The acronyms DH (data high rate) and DM (data medium rate) indicate the protection utilized by each type for the payload bits. In particular, DM packets incorporate a forward error correction (FEC) field to increase the robustness of the transmission but at the cost of transporting less user data than DH-type. In BT, both DM and DH packets may consist of 1, 3 or 5 BT slots. Thus, in the identifiers of the packet type in Table 1, the number (1, 3 or 5) after DM or DH defines the number of BT slots of the packet. Similarly, the digit before the name indicates the modulation technique and consequently the utilized data rate (1, 2 or 3 Mbps). It should be remarked that EDRs are only conceived for DH-type packets. Thus, DM packets are necessarily transmitted at 1 Mbps.

Table 1 Maximum payload and utilized rate for the different packet types of Bluetooth 2.x + EDR

Aiming at estimating the time required to transmit a BT packet, we have to consider the influence of the existing layers in the BT protocol stack: mainly the BT Baseband, L2CAP (Logical Link Control & Adaptation Protocol) and the protocol selected by the BT profile. BT profiles, which are intended to guarantee the interoperability between different vendors, specify standard interfaces to access particular services. SPP, which is the basis for other BT profiles, is the most commonly implemented profile in commercial BT devices, ranging from handheld devices (BlackBerry units, Smartphones, etc.) to medical wireless sensors or peripherals such as keyboards or GPS.

SPP uses RFCOMM protocol to emulate RS232 cable communications. RFCOMM conveys the user data (organized in frames) to the lower BT stack layers by means of L2CAP. L2CAP multiplex, segment and reassemble the data flowing from/to the upper layers. This fragmentation is executed so that only one single RFCOMM frame is encapsulated into every L2CAP frame. L2CAP frames are in turn layered over BT Baseband. As a consequence, L2CAP frames are divided into a series of BT baseband packets which are transmitted to the radio medium by the physical layer.

To calculate the time which is needed to transmit a certain number of user data bytes, we have to take into account the fragmentation and the packet overhead applied by each protocol layer. In the absence of retransmissions, this time can be computed [40] as:

$$t_{R} (N_{U} ) = n_{nff} (N_{U} ) \cdot t_{ACK} (L_{R} + O_{R} (L_{R} ) + H_{L} ) + t_{TX} (L_{ff} (N_{U} ) + O_{R} (L_{ff} (N_{U} )) + H_{L} )$$
(1)

being:

  • N U : the number of user data bytes,

  • L R : the maximum size of the RFCOMM frames. The value of the size is limited by two bounds: the maximum frame size (N 1) of RFCOMM and the maximum transfer unit of L2CAP for RFCOMM (M R ):

$$L_{R} = \hbox{min} \left( {N_{1} ,M_{R} - O_{R} (N_{1} )} \right)$$
(2)

where O R (x) is the overhead that RFCOMM introduces in each frame: 5 or 4 bytes depending if the data size is higher than 127 bytes or not.

  • H L : the size of the L2CAP header (4 bytes).

  • n nff (N U ): the number of non-final RFCOMM frames which are required to transport the N U user data bytes. This number is directly computed from N U and L R , in the way:

$$n_{nff} (N_{U} ) = \left\lceil {\frac{{N_{U} }}{{L_{R} }}} \right\rceil - 1$$
(3)

where \(\left\lceil x \right\rceil\) represents the lowest integer higher than x.

  • L ff (N U ): the number of data bytes of the last RFCOMM frame, also computable from N U and L R as:

$${L_{ff}}({N_U}) = (({N_U} - 1)\bmod {L_R}) + 1$$
(4)
  • t ACK (x): the delay required to transmit and acknowledge all the Baseband BT packets corresponding to the first and the intermediate RFCOMM frames. This variable has to compute all the one-slot packets (ACK) which must be sent by the receiver to acknowledge every received packet. The term t ACK (x) can be calculated with the recursive expression in Eq. (5). This formula takes into consideration that a RFCOMM frame may require more than one BT packet. In that case, as the last condition in the expression indicates (when x > L 5s ), the frame will be segmented and transmitted as a series of 5-slot BT packets followed by one 1, 3 or 5-slot packet. The formula assumes the optimal case in which no retransmission occurs, so that the transmission of an n-slot packet just requires (n + 1) slots (n for the packet plus 1 slot for the acknowledgment).

$$t_{ACK} (x) = \left\{ {\begin{array}{ll} 0 \hfill & \quad x = 0 \hfill \\ 2 \cdot T_{S} \hfill & \quad 0 < x \le L_{1s} \hfill \\ 4 \cdot T_{S} \hfill & \quad L_{1s} < x \le L_{3s} \hfill \\ 6 \cdot T_{S} \hfill & \quad L_{3s} < x \le L_{5s} \hfill \\ 6 \cdot T_{S} \cdot \left\lfloor {\frac{x}{{L_{5s} }}} \right\rfloor + t_{ACK} (x\;\bmod \;L_{5} ) \hfill & \quad x > L_{5s} \hfill \\ \end{array} } \right.$$
(5)

In the previous expression the operator \(\left\lfloor x \right\rfloor\) represents the highest integer lower than x, T S defines the duration of a BT slot (625 µs), while L 1s , L 3s and L 5s are the maximum sizes of the payload of a 1, 3 and 5-slot BT packet, respectively. These sizes are 17, 121 and 224 bytes for DM-type packets (see Table 1). In the case of DH-type packets, most vendors’ BT 2.x chipset tries to minimize the number of employed BT packets. Consequently, packets with a higher maximum payload (i.e., those used with a rate of 3 Mbps) are chosen. Thus, L 1s , L 3s and L 5s correspond to L H3,1 , L H3,3 and L H3,5 (83, 552 and 1,021 bytes respectively).

  • t TX (x) defines the time to transmit the final RFCOMM frame (of x bytes). As the reception of user data finishes when the last bit of the final frame arrives at the receiver, the term does not add the final acknowledgement slot of the last BT packet by only considering the time needed to convey the bytes in the last frame. Again, this transmission delay essentially depends on the employed packet-type and rate. For the DM-type, we have that:

$$t_{TX}^{M} (x) = \left\{ {\begin{array}{ll} 0 \hfill & \quad x = 0 \hfill \\ {d_{1} (x)} \hfill & \quad 0 < x \le L_{5}^{M} \hfill \\ {t_{TX}^{M} (x\,\bmod \,L_{5}^{M} ) + t_{ACK}^{{}} (L_{5}^{M} )\left\lfloor {{x \mathord{\left/ {\vphantom {x {L_{5}^{M} }}} \right. \kern-0pt} {L_{5}^{M} }}} \right\rfloor } \hfill & \quad x > L_{5}^{M} \hfill \\ \end{array} } \right.$$
(6)

where d 1(x), defined in (8), is the time required to transmit a BT packet with a data payload of x bytes at the basic rate of 1 Mbps.

As in the case of t ACK , this expression for t TX also contemplates the segmentation that takes place if the final L2CAP frame needs more than one DM5 packet (which occurs if x > L M5 ). So, the acknowledgment slots of the corresponding intermediate 5-slot BT packets are also computed.

For DH-type packets, the time to transmit the last packet of the final RFCOMM frame depends on the modulation that is being employed. The selection of the rate in turn relies on the implementation of BT 2.x + EDR. Basing on the tests performed with actual interfaces using chipsets [41] from CSR (the most popular vendor of BT technology), we have concluded in a previous study [40] that the firmware selects the rate following the next criteria:

  1. 1.

    If DH-type packets are considered, the firmware only employs enhanced rates (1-DH1, 1-DH3 and 1-DH5 packets are not utilized).

  2. 2.

    The packet size (that is to say, the number of required slots) is tried to be minimized. Thus, the rate of 3 Mbps is preferred if the use of a rate of 2 Mbps obliges to increase the number of utilized slots.

  3. 3.

    If the data can be transported at 2 Mbps within the same number of slots than at 3 Mbps, the rate of 2 Mbps is chosen as it incorporates a more robust modulation technique.

Assuming these criteria, the term t TX (x) for DH packets can be computed as it follows:

$$t_{TX} (x) = \left\{ {\begin{array}{ll} 0 \hfill & \quad x = 0 \hfill \\ {d_{2} (x)} \hfill & \quad 0 < x \le L_{2,1}^{H} \hfill \\ {d_{3} (x)} \hfill & \quad L_{2,1}^{H} < x \le L_{3,1}^{H} \hfill \\ {d_{2} (x)} \hfill & \quad L_{3,1}^{H} < x \le L_{2,3}^{H} \hfill \\ {d_{3} (x)} \hfill & \quad L_{2,3}^{H} < x \le L_{3,3}^{H} \hfill \\ {d_{2} (x)} \hfill & \quad L_{3,3}^{H} < x \le L_{2,5}^{H} \hfill \\ {d_{3} (x)} \hfill & \quad L_{2,5}^{H} < x \le L_{3,5}^{H} \hfill \\ {t_{ACK} \left( {L_{3,5}^{H} } \right)\cdot\left\lfloor {\frac{x}{{L_{3,5}^{H} }}} \right\rfloor + t_{TX} \left( {x\,\bmod \,L_{3,5}^{H} } \right)} \hfill & \quad x > L_{3,5}^{H} \hfill \\ \end{array} } \right.$$
(7)

The previous expression incorporates the changes in the used modulation (between 2 and 3 Mbps) that occur when the data exceed the maximum payload of the different packet types.

In Eqs. (6) and (7), the variable d i (x) defines the time that the baseband requires to transmit x user data at a rate (i) of 1, 2 or 3 Mbps. This time can be estimated from the number of symbols, n symi (x), that must be sent to transport the data:

$$d_{i} (x) = t_{sym} \cdot n_{{sym_{i} }} (x) + \varDelta_{{EDR_{i} }} \quad {\text{with}}\;i \in \left\{ {1,2,3} \right\}$$
(8)

where t sym is a constant describing the time to transmit a symbol (1 µs, as BT transmits 1 Megasymbol per second for any the employed rate) while Δ EDRi defines the extra-delay caused by the use of the enhanced rates of 2 and 3 Mbps. In particular, under EDR, BT introduces additional control and timing information to allow the radio module to synchronize to the new modulation format (see Fig. 1 for a better understanding of the structure of a BT packet utilizing EDR).

Fig. 1
figure 1

Bluetooth EDR packet format (shadowed fields are specific of EDR packets)

According to the BT specifications [1, 2], this extra delay (Δ EDRi ) results from summing three components:

$$\Delta_{{EDR_{i} }} = \left\{ {\begin{array}{ll} 0&\quad i = 1\\ t_{EDRg} + t_{EDRs} + t_{EDRt} &\quad (i = 2) \vee (i = 3)\\ \end{array} } \right.$$
(9)

where:

  • t EDRg is the guard time between the last symbol of the packet header (encoded with GFSK) and the EDR Synchronization Sequence. This short period enables the BT radio module to prepare for the change in the modulation. The standard defines a variable range for this value from 4.75 to 5.25 µs. For our model t EDRg is rounded to 5 µs.

  • t EDRs is the constant time of 11 µs required to transmit the 11 symbols of the enhanced data rate synchronization sequence. The goal of this sequence is to allow the synchronization of the symbol timing and phase for the new modulation type.

  • t EDRt represents the 2 µs corresponding to the specific 2 symbol trailer that must be added after the packet payload to mark the end of the packet.

On the other hand, the number of required symbols n symi (x) can be directly computed from the type of the utilized rate (i) and the number of bits in the packet payload [n d (x)] and in the associated overhead of the BT packet:

$${n_{sym}}_{_i}(x) = {O_{BB}} + \left\lceil {\frac{{{n_d}(x)}}{i}} \right\rceil$$
(10)

where O BB indicates the 126 bits of overhead of the BT packet (72 bits of the initial access code plus 54 bits of the packet header). These two fields are always transmitted under the basic GFSK modulation (at 1 Mbps, with 1 bit per symbol). Thus, the number of symbols required to transport the overhead coincides with the number of bits O BB . Conversely, as the rest of the packet can make use of the EDRs, the number of symbols that the payload demands depends both on the number of bits n d (x) and the number of bits per symbol i (1, 2 or 3 for a rate of 1, 2 and 3 Mbps, respectively).

To calculate the value of n d (x), we have to consider that DM packets support FEC 2/3 protection, so that 5 redundancy bits are added for every 10 information bits (if the number of bits is not a multiple of 10, the packet is filled with extra bits):

$$n_{d} (x) = \left\{ {\begin{array}{ll} {(x + H_{P} (x) + O_{CRC} ) \cdot 8} \hfill & \quad {\text{DH packets}} \hfill \\ {15 \cdot \left\lceil {\frac{{(x + H_{P} (x) + O_{CRC} ) \cdot 8}}{10}} \right\rceil } \hfill & \quad {\text{DM}}\;{\text{packets}} \hfill \\ \end{array} } \right.$$
(11)

where O CRC (2 bytes) is the overhead incorporated to the CRC field while H P (x) describes the size of the payload header: 1 byte for DM1 and 1-DH1 type packets, and 2 bytes for the rest of packet types:

$$H_{p} (x) = \left\{ {\begin{array}{ll} 1 \hfill & \quad x \le L_{1s} \hfill \\ 2 \hfill & \quad x > L_{1s} \hfill \\ \end{array} } \right.$$
(12)

where L 1s is the maximum size of the payload of a 1-slot packet for DM1 and 1-DH1 types: L 1s  = L M1 (17 bytes) and L 1s  = L H1,1 (27 bytes), respectively. As abovementioned, CSR Bluetooth firmware does not employ 1-DH1 packets. Thus H P (x) is always 2 bytes for DH packets.

The strategy for the rate selection may change for the firmware of other vendors (for example, ISSC BT interfaces [42] only use 3-DH1, 3-DH3 and 3-DH5 packets). However, the previous equations could be easily adapted for these variations.

4 Characterization of the delay with packet retransmissions

The model presented in the previous section is conceived for the optimal case in which all the BT packets are properly received and acknowledged, so that no retransmission is required. However, as aforementioned, environmental noise can cause packet retransmissions, which will be reflected in a variable packet delay. The goal is now to define the analytical relationship between the mean packet delay of the BT transmissions and the existing SNR. As it has been stated in the state-of-the-art (in Sect. 2), the characterization of the transmission channel as an AWGN channel has been widely considered by the literature for the analysis of the performance of BT connections and even for the design of BT radio transceivers [1721, 2326, 2830, 32, 35, 36]. In studies on BT technology, several reasons have been argued to justify the use of this Gaussian characterization of the channel. BT communications are usually deployed in static (indoor) office scenarios. Therefore the transmission model can assume that short term (fast) fading has a marginal effect on BT operation. Typical BT connections consist in low range communications where line-of-sight (LOS) from the receiver to the transmitter normally exists. In this sense, indoor environments are usually determined by the existence of other interfering technologies (such as Wi-Fi) which operate in the same 2.4 GHz ISM band. These interfering sources (with different spectral properties) can be reasonably modelled by a noise with a constant spectral density [4346]. Authors in [47] experimentally show that the in-band interference power of Wi-Fi can be modelled as a band-limited AWGN, at least for the central part of the active Wi-Fi channels.

An AWGN channel adds a white (flat power) noise to the whole considered signal bandwidth. In the next sub-sections, assuming this AWGN channel, a formula for estimating the mean packet delay is calculated.

4.1 Computation of the bit error probability

The first step is to analytically relate the bit error rate (BER) of the BT transmissions to the existing SNR for the different modulations employed by BT, that is to say, GFSK, π/4-DQPSK and 8-DPSK modulations.

For an AWGN channel, a noise with constant energy is added in the whole signal bandwidth. So, the SNR ratio can be expressed [48] as:

$$SNR = \frac{{P_{r} }}{{N_{O} \cdot B}}$$
(13)

where:

  • P r is the power (in W) at the receiver.

  • N o /2 is the power spectral density (PSD) of the noise introduced by the channel, defined in W/Hz.

  • B symbolizes the bandwidth (in Hz) of the signal at the receiver.

Aiming at comparing the impact of noise on the digital modulations utilized by BT 2.x + EDR, we characterize the SNR in terms of the energy emitted per bit or per symbol:

$$SNR = \frac{{P_{r} }}{{N_{0} \cdot B}} = \frac{{E_{S} }}{{N_{0} \cdot B \cdot T_{S} }} = \frac{{E_{b} }}{{N_{0} \cdot B \cdot T_{b} }}$$
(14)

where E s and T s denote the energy (in W) per symbol and the symbol transmission period, respectively, while E b and T b are the energy per bit (in W) and the bit transmission period.

The terms B, T S and T b are pre-defined values by the BT standard. Thus, the SNR can be directly referred to the SNR ratios per symbol (γ s ) and bit (γ b ), as it follows [48]:

$$\gamma_{s} = \frac{{E_{s} }}{{N_{0} }}$$
(15)
$$\gamma_{b} = \frac{{E_{b} }}{{N_{0} }}$$
(16)

The relationship between these two variables can be calculated as:

$$\gamma_{b} = \frac{{\gamma_{s} }}{{log_{2} M}}$$
(17)

where M represents the number of symbols of the modulation constellation.

On the other hand, to compute the BER or bit error probability, P b , as a function of γ b , we have to analyse the particularities of every modulation employed by BT 2.x + EDR. For the case of multi-level symbol constellations, P b can be obtained from the probability of symbol error (P s ) and the number (M) of existing constellation symbols. Assuming that bit errors are uncorrelated, for low values of P s (e.g. below 0.1) P b can be reasonably approximated [48] as:

$$P_{s} = 1 - \left( {1 - P_{b} } \right)^{{log_{2} M}} \mathop \approx \limits_{{P_{b} \to 0}} \left( {log_{2} M} \right)P_{b} \to P_{b} \approx \frac{{P_{s} }}{{log_{2} M}}$$
(18)

The relationship between P b and γ b for the three modulations employed by BT 2.x is obtained in the next three subsections:

4.1.1 GFSK modulation

GFSK scheme can be assimilated to a FSK modulation. To determine the bit error probability, we have to take into account that BT was conceived as a low-cost technology. At the expense of a lower performance, non-coherent detection is preferred to simplify the hardware architecture of the demodulator. When this type of detection is utilized, the bit error probability can be computed [49] as:

$$P_{b} = \frac{1}{2}e^{{\left( { - \frac{{\gamma_{b} }}{2}} \right)}}$$
(19)

The previous expression describes a lower bound for P b which assumes an orthogonal modulation scheme with a modulation index h of 0.5. However, BT specification imposes the index h to have a value in the interval [0.28–0.35], lower than 0.5. Under this non-orthogonal modulation, P b can be estimated [50] from:

$$P_{b} = Q_{1} \left( {\alpha ,\beta } \right) - \frac{1}{2}e^{{\left( { - \frac{{\alpha^{2} + \beta^{2} }}{2}} \right)}} I_{0} \left( {\alpha ,\beta } \right)$$
(20)

where Q 1(α, β) represents the Marcum Q-function, which is defined as follows:

$$Q_{1} \left( {\alpha ,\beta } \right) = \int \limits^{\infty }_{\beta } xe^{{\left( { - \frac{{x^{2} + \alpha^{2} }}{2}} \right)}} I_{0} \left( {\alpha x} \right)dx = e^{{\left( { - \frac{{\alpha^{2} + \beta^{2} }}{2}} \right)}} \cdot \sum_{n=0}^\infty \left( {\frac{\alpha }{\beta }} \right)^{n} I_{n} \left( {\alpha ,\beta } \right);\quad \left( {\beta > \alpha > 0} \right)$$
(21)

where I n (x) expresses the n-order modified Bessel function while α and β are two parameters that can be calculated from γ b [50]:

$$\alpha = \sqrt {\frac{{\gamma_{b} }}{2}\left( {1 - \sqrt {1 - \rho^{2} } } \right)}$$
(22)
$$\beta = \sqrt {\frac{{\gamma_{b} }}{2}\left( {1 + \sqrt {1 - \rho^{2} } } \right)}$$
(23)

In the previous expressions the term ρ is the so-called correlation coefficient, which can be calculated from the modulation index h:

$$\rho = \frac{{\sin \left( {2\pi h} \right)}}{2\pi h}$$
(24)

Therefore, to calculate the bit error probability, P b , for transmissions with the basic rate of BT, we just have to consider that the modulation index h is in the range [0.28–0.35]. In any case, this computation neglects the effect of the Inter-Symbol Interference (ISI) which is introduced by the Gaussian filter implemented by GFSK.

4.1.2 π/4-DQPSK modulation

As it refers to the performance of the radio receiver, π/4-DQPSK (Differential Quaternary PSK) modulation has an identical behaviour to DQPSK (4-DPSK) for an ideal lineal AWGN channel [51]. Thus, for π/4-DQPSK, the symbol error probability, P s , can be approximated [51] as:

$$P_{s} = \frac{{\sin \frac{\pi }{M}}}{2\pi }\int\limits_{{{{ - \pi } \mathord{\left/ {\vphantom {{ - \pi } 2}} \right. \kern-0pt} 2}}}^{{{\pi \mathord{\left/ {\vphantom {\pi 2}} \right. \kern-0pt} 2}}} {\frac{{exp\left( {\gamma_{s} \cdot\left( {1 - \cos \frac{\pi }{M}\cdot\cos \theta } \right)} \right)}}{{\left( {1 - \cos \frac{\pi }{M}\cdot\cos \theta } \right)}}d\theta }$$
(25)

The π/4-DQPSK constellation defines 4 different symbols (M = 4), so that 2 bits are codified per symbol. On the other hand, once the value of M is known, P b and γ b can be easily derived from P s and γ s by applying Eqs. (18) and (17), respectively. So we have that the expression for the calculus of P b under π/4-DQPSK is:

$$P_{b} = \frac{1}{{log_{2} M}}\cdot\frac{{\sin \frac{\pi }{M}}}{2\pi }\int\limits_{{{{ - \pi } \mathord{\left/ {\vphantom {{ - \pi } 2}} \right. \kern-0pt} 2}}}^{{{\pi \mathord{\left/ {\vphantom {\pi 2}} \right. \kern-0pt} 2}}} {\frac{{exp\left( {(\gamma_{b} \cdot log_{2} M)\cdot\left( {1 - \cos \frac{\pi }{M}\cdot\cos \theta } \right)} \right)}}{{\left( {1 - \cos \frac{\pi }{M}\cdot\cos \theta } \right)}}d\theta } {\kern 1pt}$$
(26)

4.1.3 8-DPSK modulation

In this case, the Eq. (26) also permits to calculate the bit error probability, P b , if M is set to 8 (as 8-DPSK codifies log28 = 3 bits per symbol). However, as it is remarked in [50], the exact computation of this formula for P b under M-DPSK becomes very complex for values of M higher than 2. Authors in [51] provide an upper bound for the value of P s which can be computed as:

$$P_{s} \le 2.06 \cdot \sqrt {\frac{{1 + \cos \frac{\pi }{M}}}{{2 \cdot \cos \frac{\pi }{M}}}} \cdot Q\left( {\sqrt {\gamma_{s} \left( {1 - \cos \frac{\pi }{M}} \right)} } \right)$$
(27)

From this expression and Eq. (18), P b can be easily derived.

4.2 Computation of the mean packet delay

After determining the bit error probability (P b ) as a function of the SNR ratio per bit (γ b ), the model developed in Sect. 3 has to be extended to compute the packet delay in scenarios where bit errors and, consequently, packet retransmissions can occur. For this purpose, the components of the delay (now defined as the mean expected values \(\overline{{t_{{ACK_{l} }} }} (x)\) and \(\overline{{t_{{TX_{l} }} }} (x)\)) are recalculated depending on both the employed modulation and the PER, that is to say, the probability that a packet has to be retransmitted due to uncorrectable bit errors. So, the first step to extend the analytical model of Sect. 3 is to determine the relationship between this PER and the bit error probability (P b ). As previously commented, DM packet type includes specific mechanisms to correct bit errors in the payload and reduce packet transmissions. Conversely, the payload of DH packets is unprotected. On the other hand, the packet header presents the same protection with independence of the packet type (the packet header is FEC encoded for both types). As a result, the calculus of this relationship between PER and P b has to be particularized for each packet type and each packet field (payload and header).

4.2.1 Retransmission probability due to errors in the payload of the DH packets

As long as DH packet type does not include any correction mechanism for the payload, the probability that a DH packet is correctly received is the probability that no bit error occurs during the transmission of the packet.

Assuming that bit errors are uncorrelated, the probability of transmitting i correct bits can be characterized as a binomial distribution in the following way:

$$P\left({X = i} \right) = \left({\begin{array}{l} n\\ i\end{array}} \right) \cdot (1 - {P_b})^i \cdot P_b^{n - i}$$
(28)

where the random variable X represents the number of correct bits in a received packet of n bits while P b is the bit error probability.

Thus, if a DH packet with a payload of x bytes contains n d (x) bits, the probability P DHd (x) of receiving this packet without any bit error is:

$$P_{{DH_{d} }} (x) = P\left( {X = n_{d} (x)} \right) = (1 - P_{b} )^{{n_{d} (x)}}$$
(29)

This equation is valid for both the basic transmission mode and the EDRs.

4.2.2 Retransmission probability due to errors in the payload of the DM packets

The payload of DM packets is encoded with a 2/3 FEC protection. In particular, a shortened Hamming (15, 10) code is adopted. This code, which utilizes 15 bits to encode 10 data bits, can correct one bit in every group of 15 bits. Assuming the binomial distribution used for DH packets, the probability of not suffering an unrecoverable error within a group (P g ) can be calculated from the probability of receiving at least 14 correct bits as it follows:

$${P_g} = \sum \limits_{i = 14}^{15} \left({\begin{array}{l}15\\ i\end{array}} \right)\cdot(1 - {P_b})^i \cdot P_b^{\left({15 - i} \right)}$$
(30)

The retransmission of a DM packet is required when two or more bit errors occur in a group. So, the success probability (i.e. the probability P DMd (x) that a DM packet is properly received) can be derived from P g by taking into account the number of n g (x) 15-bit groups in the packet:

$$P_{{DM_{d} }} (x) = P\left( {X = n_{g} (x)} \right) = \left( {P_{g} } \right)^{{n_{g} (x)}}$$
(31)

Both DM and DH packets incorporate a Cyclical Redundancy Code of 16 bits (CRC-16), which enables the detection of any error altering an odd number of bits [52]. Therefore, this model presumes that the probability of not detecting an error at the Baseband layer is negligible. So, all packets with unrecoverable errors are assumed to be retransmitted.

4.2.3 Retransmission probability due to errors in the header of the packets

The header of BT Baseband packets is protected with FEC 1/3. For every bit in the 18-bit header, two redundancy bits are added, so that 18 groups of 3 bits (54 bits) are transmitted in the header of every packet. Under FEC 1/3 protection, a single bit error in any 3-bit group can be corrected. Thus, the probability (P H ) of not suffering an unrecoverable error in the header can be computed as the probability of having one or no error per group:

$${P_H} = \left({3\cdot{(1 - {P_b})}^2\cdot P_b + {{(1 - {P_b})}^3}} \right)^{18}$$
(32)

4.2.4 Global retransmission probability

Assuming again than errors in the payload and in the header are uncorrelated, the global probability of a packet not being retransmitted can be directly determined by multiplying P H by P DMd (x) for DM packets (or by P DHd (x) for DH packets). Then the packet retransmission (or packet loss) probability P l is computable as:

$${P_l}(x) = \left\{\begin{array}{ll} 1 - {P_{DH_d}}(x)\cdot{P_H}&\quad{\text{DH}}\,{\text{packets}}\\ 1 - {P_{DM_d}}(x)\cdot{P_H}&\quad{\text{DM packets}} \end{array} \right.$$
(33)

Once that the packet retransmission probability is known, the next step is to calculate the mean number of times that packets are transmitted. The hardware of the BT host controller can be configured to retransmit a packet up to a certain number of times which is set by a specific timer (flushTO). In most actual implementations, the default value of this timer does not set any limit. As a consequence, the mean number of transmission attempts (\(\overline{{N_{Tx} }}\)) of a packet can be directly derived from the retransmission probability:

$$\overline {{N_{Tx}}} = \left({1 - {P_l}} \right) \cdot \sum\limits_{i = 1}^\infty i\cdot P_l^{\left({i - 1} \right)} = \frac{1}{{1 - {P_l}}}$$
(34)

Taking into account this new variable, we can now calculate the mean time to transmit and confirm x-byte user data when retransmissions take place. As in Sect. 3, the times needed by non-final and final RFCOMM frames are separately estimated.

The mean time (\(\overline{{t_{{ACK_{l} }} }} (x)\)) to transmit and confirm a non-final RFCOMM frame not requiring more than one 5-slot packet can be computed as:

$$\overline {{t_{AC{K_l}}}} \left(x \right) = \frac{P_l}{{1 - {P_l}}}\cdot t_{RTx} \left(x \right) + {t_{ACK}}(x) = \left({\overline {{N_{Tx}}} - 1} \right)\cdot t_{RTx} (x) + {t_{ACK}}(x)$$
(35)

where t ACK (x) is again the time required to transmit and confirm the last (and successful) retransmitted packet, while t RTX (x) represents the mean time required to retransmit a packet.

Remark that, in the previous formula, \(\left({\overline {{N_{Tx}}} - 1} \right) \cdot t_{RTx}(x)\) represents the extra time caused by unsuccessful attempts of transmitting a packet. This delay component t RTx (x) due to the retransmission of a packet must be in the range:

$$t_{{RTx_{min} }} (x) \le t_{RTx} (x) \le t_{{RTx_{max} }} (x)$$
(36)

The inferior limit of this range [t RTXmin (x)] can be computed as:

$$t_{{RTx_{\hbox{min} } }} (x) = \left\{ {\begin{array}{ll} 0 \hfill & x = 0 \hfill \\ 2 \cdot T_{S} \hfill & 0 < x \le L_{1} \hfill \\ 4 \cdot T_{S} \hfill & L_{1} < x \le L_{3} \hfill \\ 6 \cdot T_{S} \hfill & L_{3} < x \le L_{5} \hfill \\ \end{array} } \right.$$
(37)

where L 1, L 2 and L 5 are the maximum sizes of a BT packet of 1, 3 or 5 slots respectively. Table 1 defines the values of these sizes depending on the packet type (DM or DH) and the employed data rate (basic rate for DM packets or up to 3 Mbps for DH packets). In particular, these values are 17, 121 and 224 bytes if DM-type packets are being employed. In opposition, when DH-types (and EDR) are considered, the values for L 1, L 2 and L 5 are determined by the maximum sizes of 3-DH1, 3-DH3 and 3-DH5 packets (83, 552 and 1,021 bytes, respectively).

Note that Eq. (37) presumes the best case in which all packets are retransmitted immediately after a bit error is detected and a negative acknowledgment (NAK) is received at the transmitter to indicate the error. Consequently this delay just computes the slots (1, 3 or 5) to transmit the erroneous packet plus the corresponding slot for the NAK packet. On the other hand, the transmission of two consecutive PDU can be separated up to T poll seconds (n poll slots). So, the maximum delay t RTXmax (x) provoked by a retransmission is:

$$t_{{RTx_{max} }} (x) = T_{poll}$$
(38)

The value of t RTx (x) within this range depends on the hardware implementation of the BT host controller and on the number of slaves that form the BT piconet. In the rest of this analysis of this article we assume the worst case in which every retransmission introduces a delay of T poll .

When the data in an intermediate frame exceed the maximum capacity of the payload of a single BT packet, \(\overline{{t_{{ACK_{{}} }} }} (x)\) can be again recursively calculated as:

$$\overline {{t_{AC{K_l}}}} (x) = \left\{{\begin{array}{ll} 0&\quad x = 0\\ {\left({\overline {{N_{Tx}}} - 1} \right) \cdot {t_{RTx}}(x) + {t_{ACK}}(x)}&\quad 0 < x \le {L_5}\\ {\left({\left({\overline {{N_{Tx}}} - 1} \right) \cdot {t_{RTx}}({L_5}) + {t_{ACK}}({L_5})} \right) \cdot \left\lfloor {\frac{x}{L_5}} \right\rfloor}+{\overline {{t_{AC{K_l}}}} (x\,\bmod \,{L_5})}&\quad x > {L_5}\\ \end{array}} \right.$$
(39)

where L 5 is the maximum size of a 5-slot BT packet.

The time required by the final RFCOMM frame (\(\overline{{t_{{TX_{l} }} }} (x)\)) can be obtained extending the previous equations for \(\overline{{t_{{ACK_{l} }} }} (x)\). Thus, this delay \(\overline{{t_{{TX_{l} }} }} (x)\) can be recursively computed as:

$$\overline {{t_{T{X_l}}}} (x) = \left\{{\begin{array}{ll} 0&{x = 0}\\ {\left({\overline {{N_{Tx}}} - 1} \right)\cdot t_{RTx} (x) + {t_{TX}}(x)}&{0 < x \le {L_5}}\\ {\overline {{t_{AC{K_l}}}} ({L_5})\cdot\left\lfloor {\frac{x}{L_5}} \right\rfloor + \overline{{t_{TX_l}}} (x)\cdot(x\,\bmod \,{L_5})}&{x > {L_5}}\\ \end{array}} \right.$$
(40)

As in the case without retransmissions (see Eq. 7), the previous expression also considers the time to transmit and confirm the intermediate packets of the final frame by adding the term \(\overline{{t_{{ACK_{l} }} }} (x)\) (being \(\left\lfloor {\frac{x}{{L_{5} }}} \right\rfloor\) the number of intermediate packets).

After determining \(\overline{{t_{{ACK_{l} }} }} (x)\) and \(\overline{{t_{{TX_{l} }} }} (x)\), the global mean packet time required to transmit N U user data bytes when retransmissions (losses) occur (\(\overline{{t_{{R_{{M_{l} }} }} }} \left( {N_{U} } \right)\)) is obtained by substituting in Eq. (1) t ACK (x) and t TX (x) by these two new terms. In the sense master–slave, this mean delay is:

$$\overline{{t_{{R_{{M_{l} }} }} }} \left( N \right) = \frac{{T_{poll} }}{2} + n_{nff} (N_{U} )\cdot\overline{{t_{{ACK_{l} }} }} \left( {L_{R} + O_{R} (L_{R} ) + H_{L} } \right) + \overline{{t_{{TX_{l} }} }} \left( {L_{ff} (N_{U} ) + O_{R} (L_{ff} (N_{U} )) + H_{L} } \right)$$
(41)

In the sense slave–master, the mean delay is practically the same. We only have to add the slot (T s ) in which the slave is addressed by the master. So, this mean delay \(\overline{{t_{{R_{{S_{l} }} }} }} \left( N \right)\) is:

$$\overline{{t_{{R_{{S_{l} }} }} }} \left( {N_{U} } \right) = T_{S} + \overline{{t_{{R_{{M_{l} }} }} }} \left( {N_{U} } \right)$$
(42)

5 Discussion of the performance of Bluetooth 2.x + EDR

This section discusses the performance of the different BT modulations in the presence of a certain SNR, that is to say, in the non-ideal case where an existing noise can induce packet losses and, consequently, packet retransmissions. The performance is evaluated in terms of the mean transmission delay, which is calculated by using the previous analytical model implemented through Python scripts [53]. MATLAB computing and simulation environment [54] was also employed. In our study, we consider two scenarios depending on the size of the user data that have to be transmitted. To isolate the effect of the retransmissions, the two considered sizes were 70 and 200 bytes. The limit of 200 bytes is set taking into consideration the lowest maximum capacity of the different BT packet types. The maximum size of the data payload of a single 5-slot DM-type packet is 224 bytes while 5-slot packets of the DH type (1-DH5, 2-DH5 and 5-DH5), which do not include any FEC protection field for the data, can transport more user data in a single packet (see Table 1).

Remark that the comparison would not be adequate for user data that, after adding the headers of L2CAP and RFCOMM layers, require a payload with a size higher than this value of 224 bytes. In that case the transmissions with DM packets would demand to divide the data into several BT packets. This fragmentation implies an intrinsic extra delay which is not directly related to the impact of the noise on the delay experienced by the different modulations employed by BT.

For both scenarios (with N = 70 and 200 bytes), Table 2 presents the mean computed delay \(\left( {\overline{{t_{{TX_{l} }} }} (N)} \right)\) obtained for the ideal case without noise (γ b  = ∞) and for three different values of the SNR per bit (γ b  = 10.5 dB, γ b  = 12 dB and γ b  = 15 dB). The delay is calculated by using the formula in Eq. (41), taking into consideration the overhead introduced by the headers of RFCOMM and L2CAP. Table 2 shows the results for both the basic bit rate of 1 Mbps (which can use DM or DH-type packets) and when the EDRs (which only employ DH-type packets) are utilised. In this second case, the selection of the rate and the packet rate follows the algorithm described in Sect. 3. Accordingly, with the EDR modulations, a 3-DH1 packet is employed to transmit 70 bytes while a 2-DH3 packet is considered to transport 200 user data bytes. In the case of DM packets (always transmitted at the basic rate of 1 Mbps), 70 user data bytes need one DM3 packet (a 3 slot packet) while 200 bytes only fit in a DM5 packet (comprising five slots). If DH type is used at the basic rate, a DH3 and a DH5 packets are required to transport 70 and 200 bytes, respectively.

Table 2 Comparison of the PER, BER and mean transmission delay obtained for the existing packet types and different values of the SNR per bit and diverse packet

For every case, Table 2 also includes the estimated BER and PER. In the table, the obtained transmission delay is marked as ‘infinite’ to indicate an extremely high and unrealistic value that would provoke the connection loss in an actual BT communication.

In the ideal case (γ b  = ∞), results obviously demonstrate the advantages of employing the EDRs, which reduce the delay by more than 50 %. However, the table shows that under the 8-DPSK modulation (utilized by 3-DH1) the packets are very sensitive to the presence of noise. Even for the highest considered SNR, the mean transmission delay is about several seconds (which is unaffordable for most practical applications of BT). As the values of the SNR decrease, the performance of EDR and even DH packets (at the basic rates) severely degrades while DM-type packets still experience delays under 10 ms. For a SNR of 10.5 dB and 200 user data bytes, for example, only DM type packets guarantee the feasibility of the BT connection, as far as the use of DH-type or EDRs induce an intolerable delay.

These conclusions are corroborated in Figs. 2 and 3, which represent again the mean delay \(\overline{{t_{{TX_{l} }} }} (M(N))\) required to transmit 70 and 200 user data bytes, respectively. The delay is calculated as a function of the SNR per bit (γ b ). In order to compare the performance of the two EDR modulations individually, the curves are now computed imposing a fixed packet type. Commercial implementations of the BT Baseband tend to minimize the number of BT packets that are needed to transmit the data flowing from the higher layers. Consequently, for every packet type and data rate, BT chooses (if possible) the shortest packet (i.e. that requiring less slots) that can transport the data without fragmenting them. For the DH, 2-DH and 3-DH packets types, 70 bytes will be transported in one DH3, one 2-DH3 and one 3-DH1 packets, respectively. Similarly, 200 user data bytes require one DH5, one 2-DH3 or one 3-DH3 packet, depending on the employed rate (1, 2 or 3 Mbps).

Fig. 2
figure 2

Mean transmission delay \(\overline{{t_{{TX_{l} }} }} (N)\) as a function of the SNR per bit (γ b ) for the different packet types (DM and DH) and data rates (1, 2 or 3 Mbps). User data size: 70 bytes

Fig. 3
figure 3

Mean transmission delay \(\overline{{t_{{TX_{l} }} }} (N)\) as a function of the SNR per bit (γ b ) for the different packet types (DM and DH) and data rates (1, 2 or 3 Mbps). User data size: 200 bytes

From the graphs, we can clearly observe that the election of the most adequate packet type and data rate must be based on the existing noise conditions. For noisy environments with a low value of the SNR, the use of DH-type packets and certain high rate modulations can lead to high packet delays which will most probably cause the connection loss. In fact, the figures show the existence of different intervals of the SNR for which a specific type of packet and modulation is most suitable. In particular, we can distinguish the following ranges:

  • γ b  ≤ 8.5 dB: Under these circumstances, independently of the employed modulation, the delay soars and the retransmissions renders the connection unfeasible. Thus, the BT link cannot be maintained for all cases.

  • 8.5 dB < γ b  ≤ 10.0 dB: Only FEC protected DM-type packets can be utilized to guarantee the viability of the link. The use of DH-packets induces intolerable transmission delays. Consequently, enhanced rates are not possible for a SNR per bit lower than 10 dB.

  • 10.0 dB < γ b  ≤ 13.8 dB: The use of DH and 2-DH packets is now viable while this is not the case for 3-DH type. From a SNR of 13 dB the delay with DH-2 improves the results obtained with DH packets. Nevertheless, for this range of the SNR, the delay of the transmissions with the DM-packet type (always at the basic rate of 1 Mbps) reaches its minimum so that DM-type still outperforms the behaviour of DH packets at any rate.

  • 13.8 dB < γ b  ≤ 19.0 dB: The lowest delay is accomplished with 2-DH packets. DH-type packets at 1 Mbps also enable a better performance than the DM-type. 3-DH packets only become an option for values of SNR higher than 16 dB.

  • γ b  > 19.0 dB: From this point, we can assume that the optimal performance is achieved with the highest data rate (3-DH).

6 Empirical evaluation of the model for the basic rate

The main problem of evaluating the proposed model with real BT interfaces is that user cannot select the EDR that an actual BT controller employs. When the DH mode (that for which enhanced rates are available) is set, commercial BT hardware is programmed to change the modulation (i.e. the rate) as a function of the detected losses. However, from the tests that we have conducted in our laboratory (with interfaces from different manufacturers), we have concluded that present implementations of BT hosts follow a highly conservative policy to select the modulation. Thus, as soon as any loss is detected, the basic rate of 1 Mbps is set. As a consequence, it is not possible to evaluate the accuracy of the model for the EDRs in the presence of noise in a real scenario.

In any case, we have checked the validity of the model when the DM mode (and consequently the basic data rate) is utilized. For this purpose, we employed the testbed sketched in Fig. 4 and pictured in Fig. 5. To emulate a Gaussian channel in a fully controlled environment, we deployed an evaluation scenario where the transmissions between two BT units are exclusively regulated by two externally adjustable parameters: an attenuation factor and an additive Gaussian white noise. Aiming at this goal, the testbed utilizes a signal attenuator and a commercial noise generator between the two BT devices (which perform as the BT master and the BT slave). To isolate the testbed from any external interference, the communications are carried out through coaxial cables with SMA connectors (the attenuation of the cables and the connectors is lower than 0.5 dB so it can be neglected). BT interfaces were inserted in metal covered boxes for a better isolation.

Fig. 4
figure 4

Connection diagram of the employed testbed

Fig. 5
figure 5

Picture of the global testbed employed to evaluate the accuracy of the model

As it refers to the BT interfaces, the experimental testbed includes two BT development boards from Bluegiga manufacturer [55]. These interfaces, which incorporate a serial peripheral interface (SPI) programming interface, integrate a WT11-E BT module with the Bluecore-4 chipset from CSR (the most popular vendor of BT technology).

To estimate the actual SNR (through the actual power densities of the noise and the signal at the BT receptor), we utilized an N9010A spectrum analyser from Agilent Technologies.

Figures 6 and 7 compare the mean packet delay computed by the model and the empirical results measured in the testbed for two different conditions (i.e. when two different values are set for the power of the additive Gaussian noise). The graphs show the evolution of the delay as a function of the size of the data payload. Both BT modules were connected to the same equipment (a personal computer) to avoid any synchronization problem in the measurements. The connections were accomplished by C-programmed scripts employing the BlueZ protocol stack. The scripts performed a series of periodical and systematic transmissions of user data from the master to the slave (similar results were obtained in the opposite sense). The tests were iterated by modifying the payload data size from 10 to 1,500 bytes. The delay for each data packet was estimated as the time from the start of the transmission in the master to the reception of the last bit in the slave. The delay provoked by the operating system and the USB connections with the modules were measured and detracted from the shown results.

Fig. 6
figure 6

Comparison of the mean packet delay obtained in the real testbed and the results derived from the analytical model for a signal-to-noise ratio (SNR) of 10.95 dB (polling time, Tpoll, of 10 ms)

Fig. 7
figure 7

Comparison of the mean packet delay obtained in the real testbed and the results derived from the analytical model for a signal-to-noise ratio (SNR) of 14.95 dB (polling time, Tpoll, of 10 ms)

Figures 6 and 7 confirm the accuracy of the model to compute the actual delay of a BT connection.

On the other hand, noisy scenarios with very higher delays are also difficult to implement because existing timeouts defined in the protocol stack force the interface to assume that the connection is lost.

We think that the conclusions of this evaluation (showing the accuracy of the model for the basic rate) could be extrapolated to the same tests with BT modules if an enhanced rate could be fixed by the user.

7 Conclusions

This paper has presented an analytical model that allows calculating the transmission delay of BT 2.x + EDR connections in the presence of noise. The model has been particularized for the three modulations (the basic speed of 1 Mbps and the two EDRs) which are provided by the specification. By utilizing the model, we have investigated the feasibility of the different modulations for different levels of noise (expressed in terms of the SNR per bit). As higher rates are associated to less robust signals, the performed study identifies the modulation and packet-type that offer the lowest delay for a certain SNR. This study could be employed to optimize the implementation of the BT host controller, which could select the most adequate packet type and data rate basing on the existing noise conditions.