Indoor positioning

ArcGIS IPS is an indoor positioning system that allows you to locate yourself and others inside a building in real time. Similar to GPS, it puts a blue dot on indoor maps and uses location services to help you navigate to any point of interest or destination. In addition, ArcGIS IPS supports:

  • Wayfinding
  • Location tracking and sharing
  • Location data collection
  • Analytics

IPS-aware maps allow you to build apps that work with ArcGIS IPS to locate yourself inside a building.

Indoor positioning in a mobile app

IPS-aware maps

To create an IPS-aware map, see Get started with ArcGIS IPS. Here, you will find information about making a map IPS-aware, configuring, and sharing IPS-aware maps with ArcGIS Pro.

All IPS-aware maps must conform to the ArcGIS IPS Information Model that specify components such as the:

  • ArcGIS IPS Data Model - Tables and feature classes that enable indoor positioning and maintain up-to-date information about the beacon infrastructure.
  • IPS quality dataset - Point feature classes used to assess the performance of the ArcGIS IPS deployment.
  • Beacons - Bluetooth Low Energy (BLE) beacons.
  • Floor plan - Sites, facilities, levels, and other details.
  • Transitions - Exits and entrances.
  • Pathways - Line features that the device location can snap to.

Once the map is IPS-aware, you can then use ArcGIS IPS Setup apps to plan and perform survey recordings inside facilities where you want to enable ArcGIS IPS. You can collect radio signals from Bluetooth Low Energy (BLE) beacons inside your buildings. For details, see ArcGIS IPS Setup for use with Android or ArcGIS IPS Setup for use with iOS. When using an IPS-aware map you should also consider the following device limitations:

  • Wi-Fi IPS is not supported on iOS devices because Apple blocks 3rd-party software from using Wi-Fi for positioning.

  • If your facility has a mix of beacon-based IPS and Apple indoors positioning, the IndoorsLocationDataSource will utilize the beacon-based IPS, in preference.

Add indoor positioning to your app

Each IPS-aware map contains map layers to visualize indoor space and has access to indoor positioning data that determines the device location. To display the device location, create the indoor location data source from the indoor positioning definition of the IPS-aware map, as follows:

  1. Load the IPS-aware map and add it into the map view. This is a web map created with ArcGIS Pro that is hosted as a portal item in ArcGIS Online or in ArcGIS Enterprise.

  2. Obtain an indoor positioning definition from the loaded Map.indoorPositioningDefinition. If this value is null, the map isn't IPS-aware and can't be used for indoor positioning.

  3. Load the indoor positioning definition to avoid any delay when the IndoorsLocationDataSource is started.

  4. Create an IndoorsLocationDataSource using the IndoorPositioningDefinition.

  5. Assign the IndoorsLocationDataSource to the map view's LocationDisplay.
  6. Start the location display's data source and set the LocationDisplay.AutoPanMode. The device location will appear on the display as a blue dot and update as the user moves throughout the space.

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
    /// A location display using the system location data source as a default data source.
    @State private var indoorLocationDisplay = LocationDisplay(dataSource: SystemLocationDataSource())
    var body: some View {
        MapView(map: map)
            .locationDisplay(indoorLocationDisplay)

            .task {
                do {
                    // Loads the IPS-aware map.
                    try await map.load()

                    // Obtains the indoor positioning definition from the map.
                    guard let indoorPositioningDefinition = map.indoorPositioningDefinition else { return }

                    // Loads the indoor positioning definition and its related data.
                    try await indoorPositioningDefinition.load()

                    // Creates the indoors location data source using the indoor positioning definition.
                    let indoorLocationDataSource = IndoorsLocationDataSource(definition: indoorPositioningDefinition)

                    // Creates the map view's location display using the indoors location data source.
                    indoorLocationDisplay = LocationDisplay(dataSource: indoorLocationDataSource)
                    try await indoorLocationDisplay.dataSource.start()
                    indoorLocationDisplay.autoPanMode = .recenter
                } catch {
                    print("Error starting location display.")
                }
            }

    }

Handle location changes

You can handle a status changed event so that the IndoorsLocationDataSource is notified when the location data source starts, stops, or fails to start.

An IPS location populates additional properties with the current floor and the transmitter (beacon) count. When the floor changes, you can update the map to filter the display of features for the current floor. The floor value returned with the location is an integer that represents the vertical offset, where 0 is the ground floor. This value increases by one for each floor above the ground floor and decreases by one for each floor below.

Use code like the following to read additional properties for the location when it changes.

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
        let additionalSourceProperties = location.additionalSourceProperties
        let floor = additionalSourceProperties[.floor] as? Int
        let positionSource = additionalSourceProperties[.positionSource]
        let satelliteCount = additionalSourceProperties[.satelliteCount]

In addition to getting the floor, you can get the position source, which will be BLE (Bluetooth Low Energy) when using IPS and GNSS (Global Navigation Satellite Systems) when using GPS. You can also get the count of transmitters (beacons) or satellites used to determine the location.

You can use a definition expression to filter layers in the map to only show features for the current floor. For efficiency, you should only filter features when the floor changes rather than with each location update. Depending on the schema for your floor-aware data, you may need to map the vertical offset value to a level ID in order to filter features by floor (level).

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
        guard let featureLayers = map.operationalLayers.filter({ $0 is FeatureLayer }) as? [FeatureLayer] else { return }
        featureLayers.forEach { featureLayer in
            featureLayer.definitionExpression = "VERTICAL_ORDER = \(currentFloor)"
        }

App permissions

If your app is using Bluetooth on the device to scan for beacon signals or GPS, make sure to add the appropriate permissions.

Add this key to your app's Info.plist file.

Use dark colors for code blocksCopy
1
2
3
4
<key>NSBluetoothAlwaysUsageDescription</key>
<string>Bluetooth access is required for indoor positioning</string>
<key>NSLocationWhenInUseUsageDescription</key>
<string>Location services are required for GNSS positioning</string>

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.