distance_reg_protocol.h
Go to the documentation of this file.
1 // Copyright (c) Acconeer AB, 2025
2 // All rights reserved
3
4 #ifndef DISTANCE_REG_PROTOCOL_H_
5 #define DISTANCE_REG_PROTOCOL_H_
6
7 #include <stdbool.h>
8 #include <stdint.h>
9
10 // The number of registers in the application
11 #define DISTANCE_REG_REGISTER_COUNT 41U
12
13 // The register address defines
14 #define DISTANCE_REG_VERSION_ADDRESS 0U
15 #define DISTANCE_REG_PROTOCOL_STATUS_ADDRESS 1U
16 #define DISTANCE_REG_MEASURE_COUNTER_ADDRESS 2U
17 #define DISTANCE_REG_DETECTOR_STATUS_ADDRESS 3U
18 #define DISTANCE_REG_DISTANCE_RESULT_ADDRESS 16U
19 #define DISTANCE_REG_PEAK0_DISTANCE_ADDRESS 17U
20 #define DISTANCE_REG_PEAK1_DISTANCE_ADDRESS 18U
21 #define DISTANCE_REG_PEAK2_DISTANCE_ADDRESS 19U
22 #define DISTANCE_REG_PEAK3_DISTANCE_ADDRESS 20U
23 #define DISTANCE_REG_PEAK4_DISTANCE_ADDRESS 21U
24 #define DISTANCE_REG_PEAK5_DISTANCE_ADDRESS 22U
25 #define DISTANCE_REG_PEAK6_DISTANCE_ADDRESS 23U
26 #define DISTANCE_REG_PEAK7_DISTANCE_ADDRESS 24U
27 #define DISTANCE_REG_PEAK8_DISTANCE_ADDRESS 25U
28 #define DISTANCE_REG_PEAK9_DISTANCE_ADDRESS 26U
29 #define DISTANCE_REG_PEAK0_STRENGTH_ADDRESS 27U
30 #define DISTANCE_REG_PEAK1_STRENGTH_ADDRESS 28U
31 #define DISTANCE_REG_PEAK2_STRENGTH_ADDRESS 29U
32 #define DISTANCE_REG_PEAK3_STRENGTH_ADDRESS 30U
33 #define DISTANCE_REG_PEAK4_STRENGTH_ADDRESS 31U
34 #define DISTANCE_REG_PEAK5_STRENGTH_ADDRESS 32U
35 #define DISTANCE_REG_PEAK6_STRENGTH_ADDRESS 33U
36 #define DISTANCE_REG_PEAK7_STRENGTH_ADDRESS 34U
37 #define DISTANCE_REG_PEAK8_STRENGTH_ADDRESS 35U
38 #define DISTANCE_REG_PEAK9_STRENGTH_ADDRESS 36U
39 #define DISTANCE_REG_START_ADDRESS 64U
40 #define DISTANCE_REG_END_ADDRESS 65U
41 #define DISTANCE_REG_MAX_STEP_LENGTH_ADDRESS 66U
42 #define DISTANCE_REG_CLOSE_RANGE_LEAKAGE_CANCELLATION_ADDRESS 67U
43 #define DISTANCE_REG_SIGNAL_QUALITY_ADDRESS 68U
44 #define DISTANCE_REG_MAX_PROFILE_ADDRESS 69U
45 #define DISTANCE_REG_THRESHOLD_METHOD_ADDRESS 70U
46 #define DISTANCE_REG_PEAK_SORTING_ADDRESS 71U
47 #define DISTANCE_REG_NUM_FRAMES_RECORDED_THRESHOLD_ADDRESS 72U
48 #define DISTANCE_REG_FIXED_AMPLITUDE_THRESHOLD_VALUE_ADDRESS 73U
49 #define DISTANCE_REG_THRESHOLD_SENSITIVITY_ADDRESS 74U
50 #define DISTANCE_REG_REFLECTOR_SHAPE_ADDRESS 75U
51 #define DISTANCE_REG_FIXED_STRENGTH_THRESHOLD_VALUE_ADDRESS 76U
52 #define DISTANCE_REG_MEASURE_ON_WAKEUP_ADDRESS 128U
53 #define DISTANCE_REG_COMMAND_ADDRESS 256U
54 #define DISTANCE_REG_APPLICATION_ID_ADDRESS 65535U
55
56 // The defines for version fields (masks ans bit-positions)
57 #define DISTANCE_REG_VERSION_FIELD_MAJOR_POS 16U
58 #define DISTANCE_REG_VERSION_FIELD_MAJOR_MASK 0xffff0000
59 #define DISTANCE_REG_VERSION_FIELD_MINOR_POS 8U
60 #define DISTANCE_REG_VERSION_FIELD_MINOR_MASK 0x0000ff00
61 #define DISTANCE_REG_VERSION_FIELD_PATCH_POS 0U
62 #define DISTANCE_REG_VERSION_FIELD_PATCH_MASK 0x000000ff
63
64 // The defines for protocol_status fields (masks ans bit-positions)
65 #define DISTANCE_REG_PROTOCOL_STATUS_FIELD_PROTOCOL_STATE_ERROR_POS 0U
66 #define DISTANCE_REG_PROTOCOL_STATUS_FIELD_PROTOCOL_STATE_ERROR_MASK 0x00000001
67 #define DISTANCE_REG_PROTOCOL_STATUS_FIELD_PACKET_LENGTH_ERROR_POS 1U
68 #define DISTANCE_REG_PROTOCOL_STATUS_FIELD_PACKET_LENGTH_ERROR_MASK 0x00000002
69 #define DISTANCE_REG_PROTOCOL_STATUS_FIELD_ADDRESS_ERROR_POS 2U
70 #define DISTANCE_REG_PROTOCOL_STATUS_FIELD_ADDRESS_ERROR_MASK 0x00000004
71 #define DISTANCE_REG_PROTOCOL_STATUS_FIELD_WRITE_FAILED_POS 3U
72 #define DISTANCE_REG_PROTOCOL_STATUS_FIELD_WRITE_FAILED_MASK 0x00000008
73 #define DISTANCE_REG_PROTOCOL_STATUS_FIELD_WRITE_TO_READ_ONLY_POS 4U
74 #define DISTANCE_REG_PROTOCOL_STATUS_FIELD_WRITE_TO_READ_ONLY_MASK 0x00000010
75
76 // The defines for detector_status fields (masks ans bit-positions)
77 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_RSS_REGISTER_OK_POS 0U
78 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_RSS_REGISTER_OK_MASK 0x00000001
79 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_CONFIG_CREATE_OK_POS 1U
80 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_CONFIG_CREATE_OK_MASK 0x00000002
81 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_SENSOR_CREATE_OK_POS 2U
82 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_SENSOR_CREATE_OK_MASK 0x00000004
83 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_DETECTOR_CREATE_OK_POS 3U
84 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_DETECTOR_CREATE_OK_MASK 0x00000008
85 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_DETECTOR_BUFFER_OK_POS 4U
86 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_DETECTOR_BUFFER_OK_MASK 0x00000010
87 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_SENSOR_BUFFER_OK_POS 5U
88 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_SENSOR_BUFFER_OK_MASK 0x00000020
89 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_CALIBRATION_BUFFER_OK_POS 6U
90 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_CALIBRATION_BUFFER_OK_MASK 0x00000040
91 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_CONFIG_APPLY_OK_POS 7U
92 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_CONFIG_APPLY_OK_MASK 0x00000080
93 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_SENSOR_CALIBRATE_OK_POS 8U
94 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_SENSOR_CALIBRATE_OK_MASK 0x00000100
95 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_DETECTOR_CALIBRATE_OK_POS 9U
96 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_DETECTOR_CALIBRATE_OK_MASK 0x00000200
97 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_RSS_REGISTER_ERROR_POS 16U
98 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_RSS_REGISTER_ERROR_MASK 0x00010000
99 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_CONFIG_CREATE_ERROR_POS 17U
100 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_CONFIG_CREATE_ERROR_MASK 0x00020000
101 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_SENSOR_CREATE_ERROR_POS 18U
102 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_SENSOR_CREATE_ERROR_MASK 0x00040000
103 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_DETECTOR_CREATE_ERROR_POS 19U
104 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_DETECTOR_CREATE_ERROR_MASK 0x00080000
105 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_DETECTOR_BUFFER_ERROR_POS 20U
106 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_DETECTOR_BUFFER_ERROR_MASK 0x00100000
107 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_SENSOR_BUFFER_ERROR_POS 21U
108 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_SENSOR_BUFFER_ERROR_MASK 0x00200000
109 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_CALIBRATION_BUFFER_ERROR_POS 22U
110 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_CALIBRATION_BUFFER_ERROR_MASK 0x00400000
111 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_CONFIG_APPLY_ERROR_POS 23U
112 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_CONFIG_APPLY_ERROR_MASK 0x00800000
113 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_SENSOR_CALIBRATE_ERROR_POS 24U
114 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_SENSOR_CALIBRATE_ERROR_MASK 0x01000000
115 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_DETECTOR_CALIBRATE_ERROR_POS 25U
116 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_DETECTOR_CALIBRATE_ERROR_MASK 0x02000000
117 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_DETECTOR_ERROR_POS 28U
118 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_DETECTOR_ERROR_MASK 0x10000000
119 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_BUSY_POS 31U
120 #define DISTANCE_REG_DETECTOR_STATUS_FIELD_BUSY_MASK 0x80000000
121
122 // The defines for distance_result fields (masks ans bit-positions)
123 #define DISTANCE_REG_DISTANCE_RESULT_FIELD_NUM_DISTANCES_POS 0U
124 #define DISTANCE_REG_DISTANCE_RESULT_FIELD_NUM_DISTANCES_MASK 0x0000000f
125 #define DISTANCE_REG_DISTANCE_RESULT_FIELD_NEAR_START_EDGE_POS 8U
126 #define DISTANCE_REG_DISTANCE_RESULT_FIELD_NEAR_START_EDGE_MASK 0x00000100
127 #define DISTANCE_REG_DISTANCE_RESULT_FIELD_CALIBRATION_NEEDED_POS 9U
128 #define DISTANCE_REG_DISTANCE_RESULT_FIELD_CALIBRATION_NEEDED_MASK 0x00000200
129 #define DISTANCE_REG_DISTANCE_RESULT_FIELD_MEASURE_DISTANCE_ERROR_POS 10U
130 #define DISTANCE_REG_DISTANCE_RESULT_FIELD_MEASURE_DISTANCE_ERROR_MASK 0x00000400
131 #define DISTANCE_REG_DISTANCE_RESULT_FIELD_TEMPERATURE_POS 16U
132 #define DISTANCE_REG_DISTANCE_RESULT_FIELD_TEMPERATURE_MASK 0xffff0000
133
134 // The defines for max_profile enum values
135 #define DISTANCE_REG_MAX_PROFILE_ENUM_PROFILE1 1U
136 #define DISTANCE_REG_MAX_PROFILE_ENUM_PROFILE2 2U
137 #define DISTANCE_REG_MAX_PROFILE_ENUM_PROFILE3 3U
138 #define DISTANCE_REG_MAX_PROFILE_ENUM_PROFILE4 4U
139 #define DISTANCE_REG_MAX_PROFILE_ENUM_PROFILE5 5U
140
141 // The defines for threshold_method enum values
142 #define DISTANCE_REG_THRESHOLD_METHOD_ENUM_FIXED_AMPLITUDE 1U
143 #define DISTANCE_REG_THRESHOLD_METHOD_ENUM_RECORDED 2U
144 #define DISTANCE_REG_THRESHOLD_METHOD_ENUM_CFAR 3U
145 #define DISTANCE_REG_THRESHOLD_METHOD_ENUM_FIXED_STRENGTH 4U
146
147 // The defines for peak_sorting enum values
148 #define DISTANCE_REG_PEAK_SORTING_ENUM_CLOSEST 1U
149 #define DISTANCE_REG_PEAK_SORTING_ENUM_STRONGEST 2U
150
151 // The defines for reflector_shape enum values
152 #define DISTANCE_REG_REFLECTOR_SHAPE_ENUM_GENERIC 1U
153 #define DISTANCE_REG_REFLECTOR_SHAPE_ENUM_PLANAR 2U
154
155 // The defines for command enum values
156 #define DISTANCE_REG_COMMAND_ENUM_APPLY_CONFIG_AND_CALIBRATE 1U
157 #define DISTANCE_REG_COMMAND_ENUM_MEASURE_DISTANCE 2U
158 #define DISTANCE_REG_COMMAND_ENUM_APPLY_CONFIGURATION 3U
159 #define DISTANCE_REG_COMMAND_ENUM_CALIBRATE 4U
160 #define DISTANCE_REG_COMMAND_ENUM_RECALIBRATE 5U
161 #define DISTANCE_REG_COMMAND_ENUM_ENABLE_UART_LOGS 32U
162 #define DISTANCE_REG_COMMAND_ENUM_DISABLE_UART_LOGS 33U
163 #define DISTANCE_REG_COMMAND_ENUM_LOG_CONFIGURATION 34U
164 #define DISTANCE_REG_COMMAND_ENUM_RESET_MODULE 0x52535421
165
166 // The defines for application_id enum values
167 #define DISTANCE_REG_APPLICATION_ID_ENUM_DISTANCE_DETECTOR 1U
168 #define DISTANCE_REG_APPLICATION_ID_ENUM_PRESENCE_DETECTOR 2U
169 #define DISTANCE_REG_APPLICATION_ID_ENUM_REF_APP_BREATHING 3U
170 #define DISTANCE_REG_APPLICATION_ID_ENUM_EXAMPLE_CARGO 4U
171
172 // The config default defines
173 #define DISTANCE_REG_START_DEFAULT_VALUE 250U
174 #define DISTANCE_REG_END_DEFAULT_VALUE 3000U
175 #define DISTANCE_REG_MAX_STEP_LENGTH_DEFAULT_VALUE 0U
176 #define DISTANCE_REG_CLOSE_RANGE_LEAKAGE_CANCELLATION_DEFAULT_VALUE 1U
177 #define DISTANCE_REG_SIGNAL_QUALITY_DEFAULT_VALUE 15000U
178 #define DISTANCE_REG_MAX_PROFILE_DEFAULT_VALUE DISTANCE_REG_MAX_PROFILE_ENUM_PROFILE5
179 #define DISTANCE_REG_THRESHOLD_METHOD_DEFAULT_VALUE DISTANCE_REG_THRESHOLD_METHOD_ENUM_CFAR
180 #define DISTANCE_REG_PEAK_SORTING_DEFAULT_VALUE DISTANCE_REG_PEAK_SORTING_ENUM_STRONGEST
181 #define DISTANCE_REG_NUM_FRAMES_RECORDED_THRESHOLD_DEFAULT_VALUE 100U
182 #define DISTANCE_REG_FIXED_AMPLITUDE_THRESHOLD_VALUE_DEFAULT_VALUE 100000U
183 #define DISTANCE_REG_THRESHOLD_SENSITIVITY_DEFAULT_VALUE 500U
184 #define DISTANCE_REG_REFLECTOR_SHAPE_DEFAULT_VALUE DISTANCE_REG_REFLECTOR_SHAPE_ENUM_GENERIC
185 #define DISTANCE_REG_FIXED_STRENGTH_THRESHOLD_VALUE_DEFAULT_VALUE 0U
186 #define DISTANCE_REG_MEASURE_ON_WAKEUP_DEFAULT_VALUE 0U
187
188
189 /**
190 * The distance protocol setup function.
191 */
192 void distance_reg_protocol_setup(void);
193
194
195 /**
196 * The distance protocol write default register value function.
197 */
198 void distance_reg_protocol_write_default(void);
199
200
201 /**
202 * Read:
203 * Get the RSS version.
204 */
205 void distance_reg_read_version(uint32_t *value);
206
207
208 /**
209 * Read:
210 * Get protocol error flags.
211 */
212 void distance_reg_read_protocol_status(uint32_t *value);
213
214
215 /**
216 * Read:
217 * Get the measure counter, the number of measurements performed since
218 * restart.
219 */
220 void distance_reg_read_measure_counter(uint32_t *value);
221
222
223 /**
224 * Read:
225 * Get detector status flags.
226 */
227 void distance_reg_read_detector_status(uint32_t *value);
228
229
230 /**
231 * Read:
232 * The result from the distance detector.
233 */
234 void distance_reg_read_distance_result(uint32_t *value);
235
236
237 /**
238 * Read:
239 * The distance to peak 0. Note: This value is a factor 1000 larger
240 * than the RSS value.
241 */
242 void distance_reg_read_peak0_distance(uint32_t *value);
243
244
245 /**
246 * Read:
247 * The distance to peak 1. Note: This value is a factor 1000 larger
248 * than the RSS value.
249 */
250 void distance_reg_read_peak1_distance(uint32_t *value);
251
252
253 /**
254 * Read:
255 * The distance to peak 2. Note: This value is a factor 1000 larger
256 * than the RSS value.
257 */
258 void distance_reg_read_peak2_distance(uint32_t *value);
259
260
261 /**
262 * Read:
263 * The distance to peak 3. Note: This value is a factor 1000 larger
264 * than the RSS value.
265 */
266 void distance_reg_read_peak3_distance(uint32_t *value);
267
268
269 /**
270 * Read:
271 * The distance to peak 4. Note: This value is a factor 1000 larger
272 * than the RSS value.
273 */
274 void distance_reg_read_peak4_distance(uint32_t *value);
275
276
277 /**
278 * Read:
279 * The distance to peak 5. Note: This value is a factor 1000 larger
280 * than the RSS value.
281 */
282 void distance_reg_read_peak5_distance(uint32_t *value);
283
284
285 /**
286 * Read:
287 * The distance to peak 6. Note: This value is a factor 1000 larger
288 * than the RSS value.
289 */
290 void distance_reg_read_peak6_distance(uint32_t *value);
291
292
293 /**
294 * Read:
295 * The distance to peak 7. Note: This value is a factor 1000 larger
296 * than the RSS value.
297 */
298 void distance_reg_read_peak7_distance(uint32_t *value);
299
300
301 /**
302 * Read:
303 * The distance to peak 8. Note: This value is a factor 1000 larger
304 * than the RSS value.
305 */
306 void distance_reg_read_peak8_distance(uint32_t *value);
307
308
309 /**
310 * Read:
311 * The distance to peak 9. Note: This value is a factor 1000 larger
312 * than the RSS value.
313 */
314 void distance_reg_read_peak9_distance(uint32_t *value);
315
316
317 /**
318 * Read:
319 * The reflective strength of peak 0. Note: This value is a factor
320 * 1000 larger than the RSS value.
321 */
322 void distance_reg_read_peak0_strength(uint32_t *value);
323
324
325 /**
326 * Read:
327 * The reflective strength of peak 1. Note: This value is a factor
328 * 1000 larger than the RSS value.
329 */
330 void distance_reg_read_peak1_strength(uint32_t *value);
331
332
333 /**
334 * Read:
335 * The reflective strength of peak 2. Note: This value is a factor
336 * 1000 larger than the RSS value.
337 */
338 void distance_reg_read_peak2_strength(uint32_t *value);
339
340
341 /**
342 * Read:
343 * The reflective strength of peak 3. Note: This value is a factor
344 * 1000 larger than the RSS value.
345 */
346 void distance_reg_read_peak3_strength(uint32_t *value);
347
348
349 /**
350 * Read:
351 * The reflective strength of peak 4. Note: This value is a factor
352 * 1000 larger than the RSS value.
353 */
354 void distance_reg_read_peak4_strength(uint32_t *value);
355
356
357 /**
358 * Read:
359 * The reflective strength of peak 5. Note: This value is a factor
360 * 1000 larger than the RSS value.
361 */
362 void distance_reg_read_peak5_strength(uint32_t *value);
363
364
365 /**
366 * Read:
367 * The reflective strength of peak 6. Note: This value is a factor
368 * 1000 larger than the RSS value.
369 */
370 void distance_reg_read_peak6_strength(uint32_t *value);
371
372
373 /**
374 * Read:
375 * The reflective strength of peak 7. Note: This value is a factor
376 * 1000 larger than the RSS value.
377 */
378 void distance_reg_read_peak7_strength(uint32_t *value);
379
380
381 /**
382 * Read:
383 * The reflective strength of peak 8. Note: This value is a factor
384 * 1000 larger than the RSS value.
385 */
386 void distance_reg_read_peak8_strength(uint32_t *value);
387
388
389 /**
390 * Read:
391 * The reflective strength of peak 9. Note: This value is a factor
392 * 1000 larger than the RSS value.
393 */
394 void distance_reg_read_peak9_strength(uint32_t *value);
395
396
397 /**
398 * Read:
399 * The start of measured interval in millimeters. Note: This value is
400 * a factor 1000 larger than the RSS value.
401 */
402 void distance_reg_read_start(uint32_t *value);
403
404
405 /**
406 * Write:
407 * The start of measured interval in millimeters. Note: This value is
408 * a factor 1000 larger than the RSS value.
409 */
410 bool distance_reg_write_start(const uint32_t value);
411
412
413 /**
414 * Read:
415 * The end of measured interval in millimeters. Note: This value is a
416 * factor 1000 larger than the RSS value.
417 */
418 void distance_reg_read_end(uint32_t *value);
419
420
421 /**
422 * Write:
423 * The end of measured interval in millimeters. Note: This value is a
424 * factor 1000 larger than the RSS value.
425 */
426 bool distance_reg_write_end(const uint32_t value);
427
428
429 /**
430 * Read:
431 * Used to limit step length. If set to 0 (default), the step length
432 * is calculated based on profile.
433 */
434 void distance_reg_read_max_step_length(uint32_t *value);
435
436
437 /**
438 * Write:
439 * Used to limit step length. If set to 0 (default), the step length
440 * is calculated based on profile.
441 */
442 bool distance_reg_write_max_step_length(const uint32_t value);
443
444
445 /**
446 * Read:
447 * Enable the close range leakage cancellation logic.
448 */
449 void distance_reg_read_close_range_leakage_cancellation(uint32_t *value);
450
451
452 /**
453 * Write:
454 * Enable the close range leakage cancellation logic.
455 */
456 bool distance_reg_write_close_range_leakage_cancellation(const uint32_t value);
457
458
459 /**
460 * Read:
461 * High signal quality results in a better SNR (because of higher
462 * HWAAS) and higher power consumption. Note:This value is a factor
463 * 1000 larger than the RSS value.
464 */
465 void distance_reg_read_signal_quality(uint32_t *value);
466
467
468 /**
469 * Write:
470 * High signal quality results in a better SNR (because of higher
471 * HWAAS) and higher power consumption. Note:This value is a factor
472 * 1000 larger than the RSS value.
473 */
474 bool distance_reg_write_signal_quality(const uint32_t value);
475
476
477 /**
478 * Read:
479 * Max profile.
480 */
481 void distance_reg_read_max_profile(uint32_t *value);
482
483
484 /**
485 * Write:
486 * Max profile.
487 */
488 bool distance_reg_write_max_profile(const uint32_t value);
489
490
491 /**
492 * Read:
493 * Threshold method.
494 */
495 void distance_reg_read_threshold_method(uint32_t *value);
496
497
498 /**
499 * Write:
500 * Threshold method.
501 */
502 bool distance_reg_write_threshold_method(const uint32_t value);
503
504
505 /**
506 * Read:
507 * Peak sorting method.
508 */
509 void distance_reg_read_peak_sorting(uint32_t *value);
510
511
512 /**
513 * Write:
514 * Peak sorting method.
515 */
516 bool distance_reg_write_peak_sorting(const uint32_t value);
517
518
519 /**
520 * Read:
521 * The number frames to use for recorded threshold.
522 */
523 void distance_reg_read_num_frames_recorded_threshold(uint32_t *value);
524
525
526 /**
527 * Write:
528 * The number frames to use for recorded threshold.
529 */
530 bool distance_reg_write_num_frames_recorded_threshold(const uint32_t value);
531
532
533 /**
534 * Read:
535 * Fixed amplitude threshold value Note: This value is a factor 1000
536 * larger than the RSS value.
537 */
538 void distance_reg_read_fixed_amplitude_threshold_value(uint32_t *value);
539
540
541 /**
542 * Write:
543 * Fixed amplitude threshold value Note: This value is a factor 1000
544 * larger than the RSS value.
545 */
546 bool distance_reg_write_fixed_amplitude_threshold_value(const uint32_t value);
547
548
549 /**
550 * Read:
551 * Threshold sensitivity (0 <= sensitivity <= 1000) Note: This value
552 * is a factor 1000 larger than the RSS value.
553 */
554 void distance_reg_read_threshold_sensitivity(uint32_t *value);
555
556
557 /**
558 * Write:
559 * Threshold sensitivity (0 <= sensitivity <= 1000) Note: This value
560 * is a factor 1000 larger than the RSS value.
561 */
562 bool distance_reg_write_threshold_sensitivity(const uint32_t value);
563
564
565 /**
566 * Read:
567 * Reflector shape.
568 */
569 void distance_reg_read_reflector_shape(uint32_t *value);
570
571
572 /**
573 * Write:
574 * Reflector shape.
575 */
576 bool distance_reg_write_reflector_shape(const uint32_t value);
577
578
579 /**
580 * Read:
581 * Fixed strength threshold value Note: This value is a factor 1000
582 * larger than the RSS value.
583 */
584 void distance_reg_read_fixed_strength_threshold_value(uint32_t *value);
585
586
587 /**
588 * Write:
589 * Fixed strength threshold value Note: This value is a factor 1000
590 * larger than the RSS value.
591 */
592 bool distance_reg_write_fixed_strength_threshold_value(const uint32_t value);
593
594
595 /**
596 * Read:
597 * Perform measure on wake up.
598 */
599 void distance_reg_read_measure_on_wakeup(uint32_t *value);
600
601
602 /**
603 * Write:
604 * Perform measure on wake up.
605 */
606 bool distance_reg_write_measure_on_wakeup(const uint32_t value);
607
608
609 /**
610 * Write:
611 * Execute command.
612 */
613 bool distance_reg_write_command(const uint32_t value);
614
615
616 /**
617 * Read:
618 * The application id register.
619 */
620 void distance_reg_read_application_id(uint32_t *value);
621
622
623 #endif
distance_reg_read_end
void distance_reg_read_end(uint32_t *value)
Definition: distance_reg_protocol_access.c:264
distance_reg_read_fixed_amplitude_threshold_value
void distance_reg_read_fixed_amplitude_threshold_value(uint32_t *value)
Definition: distance_reg_protocol_access.c:578
distance_reg_read_peak4_strength
void distance_reg_read_peak4_strength(uint32_t *value)
Definition: distance_reg_protocol_access.c:203
distance_reg_read_version
void distance_reg_read_version(uint32_t *value)
Definition: distance_reg_protocol_access.c:61
distance_reg_write_measure_on_wakeup
bool distance_reg_write_measure_on_wakeup(const uint32_t value)
Definition: distance_reg_protocol_access.c:721
distance_reg_read_peak_sorting
void distance_reg_read_peak_sorting(uint32_t *value)
Definition: distance_reg_protocol_access.c:500
distance_reg_read_peak5_strength
void distance_reg_read_peak5_strength(uint32_t *value)
Definition: distance_reg_protocol_access.c:209
distance_reg_write_max_step_length
bool distance_reg_write_max_step_length(const uint32_t value)
Definition: distance_reg_protocol_access.c:297
distance_reg_read_peak7_strength
void distance_reg_read_peak7_strength(uint32_t *value)
Definition: distance_reg_protocol_access.c:221
distance_reg_read_peak9_distance
void distance_reg_read_peak9_distance(uint32_t *value)
Definition: distance_reg_protocol_access.c:173
distance_reg_read_fixed_strength_threshold_value
void distance_reg_read_fixed_strength_threshold_value(uint32_t *value)
Definition: distance_reg_protocol_access.c:603
distance_reg_read_peak4_distance
void distance_reg_read_peak4_distance(uint32_t *value)
Definition: distance_reg_protocol_access.c:143
distance_reg_read_detector_status
void distance_reg_read_detector_status(uint32_t *value)
Definition: distance_reg_protocol_access.c:107
distance_reg_read_application_id
void distance_reg_read_application_id(uint32_t *value)
Definition: distance_reg_protocol_access.c:55
distance_reg_write_reflector_shape
bool distance_reg_write_reflector_shape(const uint32_t value)
Definition: distance_reg_protocol_access.c:675
distance_reg_read_num_frames_recorded_threshold
void distance_reg_read_num_frames_recorded_threshold(uint32_t *value)
Definition: distance_reg_protocol_access.c:555
distance_reg_write_threshold_sensitivity
bool distance_reg_write_threshold_sensitivity(const uint32_t value)
Definition: distance_reg_protocol_access.c:637
distance_reg_read_protocol_status
void distance_reg_read_protocol_status(uint32_t *value)
Definition: distance_reg_protocol_access.c:67
distance_reg_write_fixed_strength_threshold_value
bool distance_reg_write_fixed_strength_threshold_value(const uint32_t value)
Definition: distance_reg_protocol_access.c:612
distance_reg_write_signal_quality
bool distance_reg_write_signal_quality(const uint32_t value)
Definition: distance_reg_protocol_access.c:344
distance_reg_read_distance_result
void distance_reg_read_distance_result(uint32_t *value)
Definition: distance_reg_protocol_access.c:113
distance_reg_read_max_profile
void distance_reg_read_max_profile(uint32_t *value)
Definition: distance_reg_protocol_access.c:360
distance_reg_read_max_step_length
void distance_reg_read_max_step_length(uint32_t *value)
Definition: distance_reg_protocol_access.c:289
distance_reg_read_peak1_distance
void distance_reg_read_peak1_distance(uint32_t *value)
Definition: distance_reg_protocol_access.c:125
distance_reg_read_peak1_strength
void distance_reg_read_peak1_strength(uint32_t *value)
Definition: distance_reg_protocol_access.c:185
distance_reg_read_measure_counter
void distance_reg_read_measure_counter(uint32_t *value)
Definition: distance_reg_protocol_access.c:101
distance_reg_protocol_write_default
void distance_reg_protocol_write_default(void)
Definition: distance_reg_protocol.c:233
distance_reg_read_measure_on_wakeup
void distance_reg_read_measure_on_wakeup(uint32_t *value)
Definition: distance_reg_protocol_access.c:708
distance_reg_read_peak2_strength
void distance_reg_read_peak2_strength(uint32_t *value)
Definition: distance_reg_protocol_access.c:191
distance_reg_read_peak6_strength
void distance_reg_read_peak6_strength(uint32_t *value)
Definition: distance_reg_protocol_access.c:215
distance_reg_read_threshold_sensitivity
void distance_reg_read_threshold_sensitivity(uint32_t *value)
Definition: distance_reg_protocol_access.c:628
distance_reg_write_max_profile
bool distance_reg_write_max_profile(const uint32_t value)
Definition: distance_reg_protocol_access.c:391
distance_reg_read_peak7_distance
void distance_reg_read_peak7_distance(uint32_t *value)
Definition: distance_reg_protocol_access.c:161
distance_reg_read_peak8_strength
void distance_reg_read_peak8_strength(uint32_t *value)
Definition: distance_reg_protocol_access.c:227
distance_reg_read_peak6_distance
void distance_reg_read_peak6_distance(uint32_t *value)
Definition: distance_reg_protocol_access.c:155
distance_reg_read_threshold_method
void distance_reg_read_threshold_method(uint32_t *value)
Definition: distance_reg_protocol_access.c:433
distance_reg_write_end
bool distance_reg_write_end(const uint32_t value)
Definition: distance_reg_protocol_access.c:273
distance_reg_protocol_setup
void distance_reg_protocol_setup(void)
Definition: distance_reg_protocol.c:227
distance_reg_write_close_range_leakage_cancellation
bool distance_reg_write_close_range_leakage_cancellation(const uint32_t value)
Definition: distance_reg_protocol_access.c:320
distance_reg_write_command
bool distance_reg_write_command(const uint32_t value)
Definition: distance_reg_protocol_access.c:731
distance_reg_read_peak0_distance
void distance_reg_read_peak0_distance(uint32_t *value)
Definition: distance_reg_protocol_access.c:119
distance_reg_read_reflector_shape
void distance_reg_read_reflector_shape(uint32_t *value)
Definition: distance_reg_protocol_access.c:653
distance_reg_write_start
bool distance_reg_write_start(const uint32_t value)
Definition: distance_reg_protocol_access.c:248
distance_reg_read_peak3_distance
void distance_reg_read_peak3_distance(uint32_t *value)
Definition: distance_reg_protocol_access.c:137
distance_reg_write_peak_sorting
bool distance_reg_write_peak_sorting(const uint32_t value)
Definition: distance_reg_protocol_access.c:522
distance_reg_read_close_range_leakage_cancellation
void distance_reg_read_close_range_leakage_cancellation(uint32_t *value)
Definition: distance_reg_protocol_access.c:312
distance_reg_read_signal_quality
void distance_reg_read_signal_quality(uint32_t *value)
Definition: distance_reg_protocol_access.c:335
distance_reg_write_num_frames_recorded_threshold
bool distance_reg_write_num_frames_recorded_threshold(const uint32_t value)
Definition: distance_reg_protocol_access.c:563
distance_reg_read_start
void distance_reg_read_start(uint32_t *value)
Definition: distance_reg_protocol_access.c:239
distance_reg_read_peak3_strength
void distance_reg_read_peak3_strength(uint32_t *value)
Definition: distance_reg_protocol_access.c:197
distance_reg_read_peak2_distance
void distance_reg_read_peak2_distance(uint32_t *value)
Definition: distance_reg_protocol_access.c:131
distance_reg_write_threshold_method
bool distance_reg_write_threshold_method(const uint32_t value)
Definition: distance_reg_protocol_access.c:461
distance_reg_write_fixed_amplitude_threshold_value
bool distance_reg_write_fixed_amplitude_threshold_value(const uint32_t value)
Definition: distance_reg_protocol_access.c:587
distance_reg_read_peak9_strength
void distance_reg_read_peak9_strength(uint32_t *value)
Definition: distance_reg_protocol_access.c:233
distance_reg_read_peak8_distance
void distance_reg_read_peak8_distance(uint32_t *value)
Definition: distance_reg_protocol_access.c:167
distance_reg_read_peak0_strength
void distance_reg_read_peak0_strength(uint32_t *value)
Definition: distance_reg_protocol_access.c:179
distance_reg_read_peak5_distance
void distance_reg_read_peak5_distance(uint32_t *value)
Definition: distance_reg_protocol_access.c:149