Keywords

1 Introduction

As people’s indoor activities increase, the demand for indoor positioning increases, and indoor positioning systems are rapidly developed. Indoor positioning system combined with mobile cloud computing can provide users with real-time fast location service [1, 2]. Users can obtain real-time positioning information or search for lost children [3, 4] by accessing the mobile cloud server through the Internet. However, the current positioning servers are not ideal because of the large signal interference, long response time and large energy consumption [5, 6].

In the current indoor location research, RSSI-based localization technique is widely used in the Bluetooth low power (BLE) system [7, 8]. Distance measurement can be extracted through RSSI [9, 10]. The more accurate the distance calculated by RSSI, the more accurate the positioning. A stronger signal is less susceptible to interference [11], and the RSSI value obtained is more accuracy. In the realistic environment, a large number of beacons are deployed, generating a large amount of positioning information. Increased positioning information will increase the burden on the mobile cloud server, and the service response time will increase. At the same time, severe signal interference affects the quality of RSSI value. A large number of positioning devices lack reasonable management and monitoring, which increases system energy consumption and damage. Therefore, the control of beacon’s working modes are also as important as the position estimation method [12, 13].

In this paper, we propose an mobile cloud computing based Bluetooth low energy (BLE) localization system. A simultaneous localization and power adaptation scheme is proposed to reduce the total power consumption and guarantee position estimation accuracy. The first contribution is that a min-max based positioning algorithm is developed to obtain the information of targets. By turning off a large number of beacons that are far away from the user, the acquisition of invalid positioning data and interference of signals can be reduced. We verify that the system obtain higher positioning accuracy due to the reduction of interference and operate simply. The second contribution is the energy conservation method that monitors the working modes of beacons using the mobile cloud computing architecture. Electricity consumption is greatly reduced in the entire service compared to the process without control. In the real experiment, we find that the system can keep strong robustness for long-time services is possible by monitoring working status of beacons and finding early fault.

The rest of the paper is organized as follows: Sect. 2 describes the architecture of the system proposed followed by details of the composition of the proposed system, the function of the proposed system, which including localization function and energy conservation control. This is then followed by experiments and the discussion of the experimental results in Sect. 3. Conclusions are presented in Sect. 4.

2 Proposed Positioning System

2.1 System Architecture

The proposed system consist of five parts: user, data collection unit (DCU), data transmission unit (DTU), the mobile cloud server. The user requests the location service by accessing the mobile cloud server, and uploads the BT information of the device including the name and physical address, and then keep the BT on until the end of the service request. DCU consists of a certain number of beacons. DCU will periodically search for mobile terminal data, which contains Bluetooth information and RSSI values, and then upload the data to the mobile cloud server through the DTU. The DTU connects the DCU to the mobile cloud server. The mobile cloud server can not only obtain the position data from DCU through the DTU, but also transmit the control instruction management DCU through the DTU. The filtering of all positioning data and the calculation of user location are done in the mobile cloud server. The mobile cloud server manages the DCU according to the location of the user, reducing the energy consumption of DCU. After the location information is calculated, it is uploaded to the mobile cloud server, and the user can obtain his location by accessing the mobile cloud server. The system architecture is show in Fig. 1.

Fig. 1.
figure 1

System architecture

The mobile cloud server mainly implements two functions, one is positioning and the other is energy conservation control. During the positioning process, RSSI measurements to the target is collected through beacons of the DCU and forwarded to the mobile cloud server through a nearby DTU. The target terminal is equipped with BLE chips and broadcast mobile terminal data periodically to the beacons. Mobile cloud server calculate the location with enough data through min-max algorithm and confirm a area which represent position. During the energy saving control process, the cloud server generates energy adaptation scheme according to the location of mobile terminal to control and deduce the power consumption for DCU.

2.2 Localization Function

In the localization function, mobile terminal such as SmartPhone request service from the mobile cloud server and open BLE to broadcast the information (e.g., ID). Beacons upload the ID and RSSI extracted from the information broadcasted by the user. The server filters out the data including the mobile device according to the ID, and selects the RSSI value for the positioning calculation according to the set threshold.

In this paper, the positioning calculated by Min-Max algorithm. The Min-Max also known as Bounding Box algorithm, is a simple and straightforward method. We can calculate \(r_{j}\) based on RSSI of each beacon j of which location \(a_{j}=(a_{xj},a_{yj})\). Building bounding box given by \([a_{xj}-r_{j},a_{yj}-r_{j}]\times [a_{xj}+r_{j},a_{yj}+r_{j}]\), its side length is twice that of \(r_{j}\). Overlap region (OR) of all bounding box conclude the position, its vertices \(V = \{(A,D),(B,D)(A,C),(B,C)\}\) as Fig. 1 obtain from 1. The center of OR can be estimated to be the position \((x,y) = (\frac{A+B}{2},\frac{C+D}{2})\). In Fig. 2, the midpoints \(M = \{a(\frac{A+B}{2},D),b(\frac{A+B}{2},C),c(A,\frac{C+D}{2}),\) \(d(B,\frac{C+D}{2})\}\) of each side of the bounding box can represent the boundary of OR, serves as a basis of the energy conservation control method.

$$\begin{aligned} \left\{ \begin{array}{ll} A=max^{N}_{j=1}\{a_{xj}-r_{j}\}\\ \\ B=min^{N}_{j=1}\{a_{xj}+r_{j}\}\\ \\ C=min^{N}_{j=1}\{a_{yj}+r_{j}\}\\ \\ D=max^{N}_{j=1}\{a_{yj}-r_{j}\}\\ \end{array} \right. \end{aligned}$$
(1)
Fig. 2.
figure 2

Bounding box and midpoints which represent the boundary of OR

The users can access the mobile cloud server to get the current localization. In this system, only the mobile terminal broadcast signal. In an ideal state, signal interference is reduced. Therefore, enhancing the terminal’s transmit power can improve robustness of RSSI and make positioning more accurate. In the search phase, user can search the people who only wear a devices that can broadcast such as Smartband through server.

2.3 Energy Conservation Control

We divide the plane region into multiple rectangular units, which are composed of subregions with equal areas. Each rectangular unit contains a DCU. The server judges the rectangular unit where the terminal is located based on the OR and operate open the DCU. Beacon has three working modes: working mode, standby mode and sleep mode. Operate the working mode of beacon according to the feature point of OR in subregion.

Fig. 3.
figure 3

The rule of trigger regional division (Color figure online)

The subregion consists of three special areas, which trigger different control actions. There are three operating conditions:

Independent region control: :

The yellow part in Fig. 3 is called the independent area. When OR overlaps with independent region, such as a, c, and b points, only the beacons in subregion \(A_{1,1}\) are set to work mode, and the beacons of other subregions are set to wait mode. The beacon in the rectangular area not overlaps with OR is set to sleep mode.

Critical region control: :

The green part in Fig. 3 is called the critical region. Terminal will cross over to the next subregion, if OR overlaps with critical region, such as d point. To avoid losing positioning, the beacons in another subarea adjacent to critical region such as \(A_{1,2}\) participates in positioning work with working mode.

Public region control: :

The green part in Fig. 3 is called the public region. If OR overlaps with public region, beacons in four adjacent areas will be set to work mode. Server operate more beacons to participate in positioning work.

The server judge a cross-regional behavior by the distance between the terminal and the next rectangular area that can prevent loss of positioning due to the user’s sudden return to the original rectangular area. Beacons in the second rectangular will be open and wait if distance is within the threshold. Only the beacons in the current rectangular area will be open if the distance exceed the threshold value.

During the entire positioning process, the dormant beacons are periodically woken up to listen to the server’s control operations and send its own working status to the server. Server monitor all beacons and provide timely maintenance information by judging working status include electricity of power source and working mode that can keep the system stable.

Fig. 4.
figure 4

The development board

3 Experiment and Analysis

3.1 Experiment Condition

In order to calculate the distance between the beacons and the target, an RSSI that can be obtained by BT of the beacon is used. The beacon contains a Node32s development board with ESP-WROOM-32 that has built-in BLE and WiFi modules. Figure 4 is a physical map of the development board. The development board also has a variety of energy-saving modes, among which the deep sleep mode consumes the lowest energy. The development board’s consumption data comes from its technical manual as shown in Table 1.

Table 1. Work energy consumption

3.2 Positioning Experiment and Analysis

The positioning experiment was set up in a \(8.86*5.86\,\mathrm{{m}}^{2}\) laboratory, as shown in Fig. 5, with the blue circle representing the beacon. The beacons are mounted on a wall 1.2 m high, beacon in the center is arranged on a shelf. Terminal are mounted on a shelf 1.2 m high. The scanning frequency of beacon was 0.5 Hz. The terminal contains an Node32s development board whose transmitting power is 10 dBm to broadcast BT signal. The server obtains data transmitted by all beacons and calculate positioning with three optimal RSSI within the threshold range that is −10 dBm to \(-75\) dBm.

Fig. 5.
figure 5

The actual experiments environment.

The two fixed positions show in Fig. 5 have been considered to test the estimation accuracy. The RSSI acquisition time is \(T = 2.2 \,\mathrm{{s}}\), in which the BT search time is \(2 \,\mathrm{{s}}\) and the WiFi transmission time is \(0.2 \,\mathrm{{s}}\). Position estimation has been performed 1000 times. The position error is the Euclidian distance between the estimated position and the real position.

Figure 6 show the CDF of localization errors at two fixed position. These result combine with the datum of two test points demonstrate that the proposed position method achieves around 3 m \(98\%\) localization error and the average error for positioning is around 1.55 m.

Fig. 6.
figure 6

CDFs of localization errors of the trajectories with two fixed positions.

3.3 Energy Conservation Control Analysis

The average operating current of the beacon calculated is \(102.3 \,\mathrm{{mA}}\) according to operating time of BT and WiFi in working mode. In waiting mode, WiFi operate sniffer that average operating current is \(90 \,\mathrm{{mA}}\).

Through a simulation experiment, we analyze the energy consumption of the system when a person walks through a \(36*36\,\mathrm{{m}}^{2}\) area. This area is divided into 16 rectangular areas whose size is \(9*9\,\mathrm{{m}}^{2}\). Each rectangular area is divided into 9 subregions whose size is \(3*3\,\mathrm{{m}}^{2}\). The Critical region of each subregion is 0.5 m wide. In order to travel to all regions, the terminal moves in a 5-step Hilbert curve at a step of 1.12 m/T, as shown in Fig. 7. The curve step length of 1.12 m is approximately the distance people take two steps. In experiments, 169 beacons are arranged at the intersection of all subregions, which can reduce the number of points in the system.

During the simulation experiment, the system has located 1024 times according to Hilbert curve, so the overall positioning time is \(1024 *T\). At the positioning i, the energy consumption of positioning can be expressed as \(W_{i}\), there are \(P_{i}\) beacons in working mode, \(Q_{i}\) beacons in waiting mode and \(S_{i}\) beacons in sleeping mode. All of beacons with working mode which current is \(102.3 \,\mathrm{{mA}}\) work in the experiment without control. The \(W_{i}\) of each positioning is the same. By (2), we can calculate the total energy consumption W.

$$\begin{aligned} \left\{ \begin{array}{ll} W_{i}=3.3*(102.3P_{i}+90Q_{i}+0.9S_{i})*\frac{T}{3600}\\ \\ W = \sum \limits _{i=1}^nW_i\\ \end{array} \right. \end{aligned}$$
(2)
Fig. 7.
figure 7

Trajectories and the anchor deployment.

Table 2. Positioning energy consumption

The Table 2 show that energy consumption contrast without control has been reduced significantly, and average energy consumption reduced 30 times. The energy conservation control method has its own research and application value in practice and it is worth further study and optimization.

4 Conclusion

In this paper, we propose and implement the positioning system which use mobile cloud computing with high accuracy and low energy consumption. Most signal interference and energy consumption can reduce with control of the mobile cloud server. Each terminal simply broadcasts its BT signal while signal collection and positioning computations are done at the server side by beacons and the mobile cloud server. By controlling the working mode of the beacon according to the area where the terminal is located, it can reduce the acquisition of invalid data that increases the mobile cloud server load, at the same time the energy consumption of the system can be reduce. Furthermore, the mobile cloud server monitors the performance of the beacons and provides guarantee for the maintenance of the nodes that the system can work normally for a long time.