forked from nrfconnect/sdk-nrf
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathKconfig
More file actions
307 lines (241 loc) · 10.2 KB
/
Kconfig
File metadata and controls
307 lines (241 loc) · 10.2 KB
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
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
#
# Copyright (c) 2021 Nordic Semiconductor ASA
#
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#
menuconfig LOCATION
bool "Location"
if LOCATION
config LOCATION_METHOD_GNSS
bool "Allow GNSS to be used for obtaining the location"
depends on NRF_MODEM_LIB
depends on LTE_LINK_CONTROL
imply LTE_LC_NEIGHBOR_CELL_MEAS_MODULE
imply LTE_LC_PSM_MODULE
imply LTE_LC_MODEM_SLEEP_MODULE
default y
config LOCATION_METHOD_CELLULAR
bool "Allow cellular positioning to be used for obtaining the location"
depends on NRF_MODEM_LIB
depends on LTE_LINK_CONTROL
imply LTE_LC_NEIGHBOR_CELL_MEAS_MODULE
default y
config LOCATION_METHOD_WIFI
bool "Allow Wi-Fi positioning to be used for obtaining the location"
depends on WIFI
select NET_MGMT if LOCATION_METHOD_WIFI_NET_MGMT
select NET_MGMT_EVENT if LOCATION_METHOD_WIFI_NET_MGMT
select NET_MGMT_EVENT_INFO if LOCATION_METHOD_WIFI_NET_MGMT
select NET_L2_WIFI_MGMT if LOCATION_METHOD_WIFI_NET_MGMT
config LOCATION_METHOD_WIFI_NET_MGMT
bool
depends on LOCATION_METHOD_WIFI
default y
help
Use the Network Management APIs for Wi-Fi functionality. This is
separated here from other dependencies to allow disabling of
Network Management APIs in tests for mocking purposes.
config LOCATION_METHOD_WIFI_NET_IF_UPDOWN
bool
default y if (BOARD_THINGY91X_NRF9151 || BOARD_THINGY91X_NRF9151_NS || BOARD_THINGY91X_NRF5340_CPUAPP || BOARD_THINGY91X_NRF5340_CPUAPP_NS)
depends on LOCATION_METHOD_WIFI_NET_MGMT
help
Use the Network Interface Up/Down APIs for Wi-Fi functionality.
config LOCATION_METHODS_LIST_SIZE
int "Maximum number of location methods in configuration"
default 3
help
Maximum number of location methods within location_config structure.
config LOCATION_DATA_DETAILS
bool "Gather and include detailed data into the location_event_data"
config LOCATION_WORKQUEUE_STACK_SIZE
int "Stack size for the library work queue"
default 4096
if LOCATION_METHOD_GNSS
config LOCATION_METHOD_GNSS_VISIBILITY_DETECTION_EXEC_TIME
int "GNSS execution time for obstructed visibility detection"
default 3000
help
Sets the time (in milliseconds) since GNSS start after which the obstructed visibility
detection is performed. The default value is a good starting point when A-GNSS is used.
Without assistance, the value should probably be adjusted, because GNSS acquires
satellites more slowly.
config LOCATION_METHOD_GNSS_VISIBILITY_DETECTION_SAT_LIMIT
int "GNSS obstructed visibility detection satellite limit"
default 3
help
Sets the minimum number of satellites which must have been acquired by GNSS when the
obstructed visibility detection is performed. If less satellites have been acquired,
GNSS is stopped immediately to save energy. The default value is a good starting point
when A-GNSS is used. Without assistance, the value should probably be adjusted, because
GNSS acquires satellites more slowly.
config LOCATION_METHOD_GNSS_PRIORITIZE_QZSS_ASSISTANCE
bool "Allow A-GNSS data request when only QZSS assistance is needed"
help
By default, QZSS assistance data is only requested when some other assistance data is
needed at the same time. Enabling this option allows A-GNSS data request to be sent also
when only QZSS assistance data (usually ephemerides) is needed.
config LOCATION_SERVICE_NRF_CLOUD_GNSS_POS_SEND
bool "Send GNSS coordinates to nRF Cloud"
depends on !LOCATION_SERVICE_EXTERNAL
depends on NRF_CLOUD_REST || NRF_CLOUD_MQTT || NRF_CLOUD_COAP
help
Send GNSS coordinates to nRF Cloud.
endif # LOCATION_METHOD_GNSS
if LOCATION_METHOD_WIFI
config LOCATION_METHOD_WIFI_SCANNING_RESULTS_MAX_CNT
int "Max number of Wi-Fi scanning results"
default 10
help
Maximum number of Wi-Fi scanning results to use when creating HTTP request.
Increasing the max number will increase the library's RAM usage.
endif # LOCATION_METHOD_WIFI
# Cellular and Wi-Fi service configurations
if LOCATION_METHOD_CELLULAR || LOCATION_METHOD_WIFI
config LOCATION_SERVICE_CLOUD_RECV_BUF_SIZE
int "Receive buffer size"
default 512
help
Size of the buffer used to store the response from the location service.
config LOCATION_SERVICE_NRF_CLOUD
bool "nRF Cloud location service"
default y if !LOCATION_SERVICE_EXTERNAL
depends on NRF_CLOUD_REST || NRF_CLOUD_MQTT || NRF_CLOUD_COAP
select NRF_CLOUD_LOCATION if NRF_CLOUD_MQTT
select NRF_CLOUD_REST_AUTOGEN_JWT if NRF_CLOUD_REST
help
Use nRF Cloud location service.
endif # LOCATION_METHOD_CELLULAR || LOCATION_METHOD_WIFI
config LOCATION_SERVICE_EXTERNAL
bool "Requesting A-GNSS, P-GPS, LTE neighbor cell and Wi-Fi access point data is handled by the application outside of Location library"
help
Allow application to download the A-GNSS and P-GPS data and merely feed it to
Location library for processing.
Also, allow application to send cellular neighbor cell and Wi-Fi access point information
to a cloud service and respond to the Location library with the outcome.
# Configurations for location_request() default values
choice LOCATION_REQUEST_DEFAULT_METHOD_FIRST
prompt "Default first priority method"
default LOCATION_REQUEST_DEFAULT_METHOD_FIRST_GNSS if LOCATION_METHOD_GNSS
default LOCATION_REQUEST_DEFAULT_METHOD_FIRST_WIFI if LOCATION_METHOD_WIFI
default LOCATION_REQUEST_DEFAULT_METHOD_FIRST_CELLULAR if LOCATION_METHOD_CELLULAR
help
Default first priority method used in location_config_defaults_set() function
within location_config structure if method_types member is NULL.
config LOCATION_REQUEST_DEFAULT_METHOD_FIRST_GNSS
bool "GNSS positioning"
config LOCATION_REQUEST_DEFAULT_METHOD_FIRST_WIFI
bool "Wi-Fi positioning"
config LOCATION_REQUEST_DEFAULT_METHOD_FIRST_CELLULAR
bool "Cellular positioning"
endchoice
choice LOCATION_REQUEST_DEFAULT_METHOD_SECOND
prompt "Default second priority method"
default LOCATION_REQUEST_DEFAULT_METHOD_SECOND_WIFI if LOCATION_METHOD_WIFI && !LOCATION_REQUEST_DEFAULT_METHOD_FIRST_WIFI
default LOCATION_REQUEST_DEFAULT_METHOD_SECOND_CELLULAR if LOCATION_METHOD_CELLULAR && !LOCATION_REQUEST_DEFAULT_METHOD_FIRST_CELLULAR
default LOCATION_REQUEST_DEFAULT_METHOD_SECOND_NONE
help
Default second priority method used in location_config_defaults_set() function
within location_config structure if method_types member is NULL.
config LOCATION_REQUEST_DEFAULT_METHOD_SECOND_GNSS
bool "GNSS positioning"
config LOCATION_REQUEST_DEFAULT_METHOD_SECOND_WIFI
bool "Wi-Fi positioning"
config LOCATION_REQUEST_DEFAULT_METHOD_SECOND_CELLULAR
bool "Cellular positioning"
config LOCATION_REQUEST_DEFAULT_METHOD_SECOND_NONE
bool "No second priority method"
endchoice
choice LOCATION_REQUEST_DEFAULT_METHOD_THIRD
prompt "Default third priority method"
default LOCATION_REQUEST_DEFAULT_METHOD_THIRD_CELLULAR if LOCATION_METHOD_CELLULAR && !LOCATION_REQUEST_DEFAULT_METHOD_FIRST_CELLULAR && !LOCATION_REQUEST_DEFAULT_METHOD_SECOND_CELLULAR
default LOCATION_REQUEST_DEFAULT_METHOD_THIRD_NONE
help
Default third priority method used in location_config_defaults_set() function
within location_config structure if method_types member is NULL.
config LOCATION_REQUEST_DEFAULT_METHOD_THIRD_GNSS
bool "GNSS positioning"
config LOCATION_REQUEST_DEFAULT_METHOD_THIRD_WIFI
bool "Wi-Fi positioning"
config LOCATION_REQUEST_DEFAULT_METHOD_THIRD_CELLULAR
bool "Cellular positioning"
config LOCATION_REQUEST_DEFAULT_METHOD_THIRD_NONE
bool "No third priority method"
endchoice
config LOCATION_REQUEST_DEFAULT_INTERVAL
int "Default interval in seconds"
default 0
help
Default value used in location_config_defaults_set() function for interval
member within location_config structure.
config LOCATION_REQUEST_DEFAULT_TIMEOUT
int "Default timeout in milliseconds"
default 300000
help
Default value used in location_config_defaults_set() function for timeout
member within location_config structure.
if LOCATION_METHOD_GNSS
config LOCATION_REQUEST_DEFAULT_GNSS_TIMEOUT
int "Default GNSS timeout in milliseconds"
default 120000
help
Default value used in location_config_defaults_set() function for timeout
member within location_gnss_config structure.
choice LOCATION_REQUEST_DEFAULT_GNSS_ACCURACY
prompt "Default GNSS accuracy level"
default LOCATION_REQUEST_DEFAULT_GNSS_ACCURACY_NORMAL
help
Default value used in location_config_defaults_set() function for accuracy
member within location_gnss_config structure.
config LOCATION_REQUEST_DEFAULT_GNSS_ACCURACY_LOW
bool "GNSS low accuracy"
config LOCATION_REQUEST_DEFAULT_GNSS_ACCURACY_NORMAL
bool "GNSS normal accuracy"
config LOCATION_REQUEST_DEFAULT_GNSS_ACCURACY_HIGH
bool "GNSS high accuracy"
endchoice
config LOCATION_REQUEST_DEFAULT_GNSS_NUM_CONSECUTIVE_FIXES
int "Default number of consecutive fixes in high accuracy mode"
default 3
range 2 256
help
Default value used in location_config_defaults_set() function for num_consecutive_fixes
member within location_gnss_config structure.
config LOCATION_REQUEST_DEFAULT_GNSS_VISIBILITY_DETECTION
bool "Default GNSS visibility detection"
help
Default value used in location_config_defaults_set() function for visibility_detection
member within location_gnss_config structure.
config LOCATION_REQUEST_DEFAULT_GNSS_PRIORITY_MODE
bool "Default GNSS priority mode"
help
Default value used in location_config_defaults_set() function for priority_mode
member within location_gnss_config structure.
endif # LOCATION_METHOD_GNSS
if LOCATION_METHOD_CELLULAR
config LOCATION_REQUEST_DEFAULT_CELLULAR_TIMEOUT
int "Default cellular timeout in milliseconds"
default 30000
help
Default value used in location_config_defaults_set() function for timeout
member within location_cellular_config structure.
config LOCATION_REQUEST_DEFAULT_CELLULAR_CELL_COUNT
int "Number of requested cellular neighbors"
default 4
range 0 15
help
Default value used in location_config_defaults_set() function for cell_count
member within location_cellular_config structure.
endif # LOCATION_METHOD_CELLULAR
if LOCATION_METHOD_WIFI
config LOCATION_REQUEST_DEFAULT_WIFI_TIMEOUT
int "Default Wi-Fi timeout in milliseconds"
default 30000
help
Default value used in location_config_defaults_set() function for timeout
member within location_wifi_config structure.
endif # LOCATION_METHOD_WIFI
module = LOCATION
module-str = Location
source "$(ZEPHYR_BASE)/subsys/logging/Kconfig.template.log_config"
endif # LOCATION