Contains Ayoub's Ranging and Custom interfaces for the VL53L3CX

Committer:
charlesmn
Date:
Wed Jul 21 14:47:53 2021 +0000
Revision:
1:dae4cb24beec
Parent:
0:c1910e04fc6c
strip out commented out code

Who changed what in which revision?

UserRevisionLine numberNew contents of line
charlesmn 0:c1910e04fc6c 1 /**
charlesmn 0:c1910e04fc6c 2 ******************************************************************************
charlesmn 0:c1910e04fc6c 3 * @file vl53l3x_class.cpp
charlesmn 0:c1910e04fc6c 4 * @author CGM
charlesmn 0:c1910e04fc6c 5 * @version V0.0.1
charlesmn 0:c1910e04fc6c 6 * @date 14-December-2021
charlesmn 0:c1910e04fc6c 7 * @brief Implementation file for the VL53LX driver class
charlesmn 0:c1910e04fc6c 8 ******************************************************************************
charlesmn 0:c1910e04fc6c 9 * @attention
charlesmn 0:c1910e04fc6c 10 *
charlesmn 0:c1910e04fc6c 11 * <h2><center>&copy; COPYRIGHT(c) 2021 STMicroelectronics</center></h2>
charlesmn 0:c1910e04fc6c 12 *
charlesmn 0:c1910e04fc6c 13 * Redistribution and use in source and binary forms, with or without modification,
charlesmn 0:c1910e04fc6c 14 * are permitted provided that the following conditions are met:
charlesmn 0:c1910e04fc6c 15 * 1. Redistributions of source code must retain the above copyright notice,
charlesmn 0:c1910e04fc6c 16 * this list of conditions and the following disclaimer.
charlesmn 0:c1910e04fc6c 17 * 2. Redistributions in binary form must reproduce the above copyright notice,
charlesmn 0:c1910e04fc6c 18 * this list of conditions and the following disclaimer in the documentation
charlesmn 0:c1910e04fc6c 19 * and/or other materials provided with the distribution.
charlesmn 0:c1910e04fc6c 20 * 3. Neither the name of STMicroelectronics nor the names of its contributors
charlesmn 0:c1910e04fc6c 21 * may be used to endorse or promote products derived from this software
charlesmn 0:c1910e04fc6c 22 * without specific prior written permission.
charlesmn 0:c1910e04fc6c 23 *
charlesmn 0:c1910e04fc6c 24 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
charlesmn 0:c1910e04fc6c 25 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
charlesmn 0:c1910e04fc6c 26 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
charlesmn 0:c1910e04fc6c 27 * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
charlesmn 0:c1910e04fc6c 28 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
charlesmn 0:c1910e04fc6c 29 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
charlesmn 0:c1910e04fc6c 30 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
charlesmn 0:c1910e04fc6c 31 * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
charlesmn 0:c1910e04fc6c 32 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
charlesmn 0:c1910e04fc6c 33 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
charlesmn 0:c1910e04fc6c 34 *
charlesmn 0:c1910e04fc6c 35 ******************************************************************************
charlesmn 0:c1910e04fc6c 36 * This is just a CPP wrapper around the C files in the module directory which
charlesmn 0:c1910e04fc6c 37 * are from the bare-driver release.
charlesmn 0:c1910e04fc6c 38 */
charlesmn 0:c1910e04fc6c 39
charlesmn 0:c1910e04fc6c 40
charlesmn 0:c1910e04fc6c 41 /* Includes */
charlesmn 0:c1910e04fc6c 42 #include <stdlib.h>
charlesmn 0:c1910e04fc6c 43
charlesmn 0:c1910e04fc6c 44 #include "mbed.h"
charlesmn 0:c1910e04fc6c 45
charlesmn 0:c1910e04fc6c 46 #include "pinmap.h"
charlesmn 0:c1910e04fc6c 47 //#include "Arduino.h"
charlesmn 0:c1910e04fc6c 48 #include "vl53l3cx_class.h"
charlesmn 0:c1910e04fc6c 49 #include "vl53L3_I2c.h"
charlesmn 0:c1910e04fc6c 50 #include "vl53lx_platform.h"
charlesmn 0:c1910e04fc6c 51
charlesmn 0:c1910e04fc6c 52 #include "vl53lx_ll_def.h"
charlesmn 0:c1910e04fc6c 53
charlesmn 0:c1910e04fc6c 54
charlesmn 0:c1910e04fc6c 55 #include "vl53lx_core_support.h"
charlesmn 0:c1910e04fc6c 56 #include "vl53lx_def.h"
charlesmn 0:c1910e04fc6c 57 #include "vl53lx_api_calibration.h"
charlesmn 0:c1910e04fc6c 58 #include "vl53lx_core.h"
charlesmn 0:c1910e04fc6c 59 #include "vl53lx_api.h"
charlesmn 0:c1910e04fc6c 60 #include "vl53lx_wait.h"
charlesmn 0:c1910e04fc6c 61 #include "vl53lx_register_settings.h"
charlesmn 0:c1910e04fc6c 62 #include "vl53lx_register_funcs.h"
charlesmn 0:c1910e04fc6c 63 #include "vl53lx_platform_ipp.h"
charlesmn 0:c1910e04fc6c 64 #include "vl53lx_nvm.h"
charlesmn 0:c1910e04fc6c 65 #include "vl53lx_api_core.h"
charlesmn 0:c1910e04fc6c 66 #include "vl53lx_hist_map.h"
charlesmn 0:c1910e04fc6c 67 #include "vl53lx_api_preset_modes.h"
charlesmn 0:c1910e04fc6c 68 #include "vl53lx_xtalk.h"
charlesmn 0:c1910e04fc6c 69 #include "vl53lx_hist_core.h"
charlesmn 0:c1910e04fc6c 70 #include "vl53lx_hist_algos_gen3.h"
charlesmn 0:c1910e04fc6c 71 #include "vl53lx_hist_algos_gen4.h"
charlesmn 0:c1910e04fc6c 72 #include "vl53lx_dmax.h"
charlesmn 0:c1910e04fc6c 73 #include "vl53lx_sigma_estimate.h"
charlesmn 0:c1910e04fc6c 74 #include "vl53lx_hist_core.h"
charlesmn 0:c1910e04fc6c 75 #include "vl53lx_hist_funcs.h"
charlesmn 0:c1910e04fc6c 76 #include "vl53lx_silicon_core.h"
charlesmn 0:c1910e04fc6c 77
charlesmn 0:c1910e04fc6c 78
charlesmn 0:c1910e04fc6c 79
charlesmn 0:c1910e04fc6c 80 #define TEMP_BUF_SIZE 80
charlesmn 0:c1910e04fc6c 81
charlesmn 0:c1910e04fc6c 82 VL53LX_Error VL53L3CX::VL53L3CX_I2CWrite(uint8_t DeviceAddr, uint16_t RegisterAddr, uint8_t *pBuffer, uint16_t NumByteToWrite)
charlesmn 0:c1910e04fc6c 83 {
charlesmn 0:c1910e04fc6c 84
charlesmn 0:c1910e04fc6c 85 return i2c_inst->VL53L3_i2c_write(pBuffer,DeviceAddr,RegisterAddr,NumByteToWrite);
charlesmn 0:c1910e04fc6c 86 }
charlesmn 0:c1910e04fc6c 87
charlesmn 0:c1910e04fc6c 88
charlesmn 0:c1910e04fc6c 89 VL53LX_Error VL53L3CX::VL53L3CX_I2CRead(uint8_t DeviceAddr, uint16_t RegisterAddr, uint8_t *pBuffer, uint16_t NumByteToRead)
charlesmn 0:c1910e04fc6c 90 {
charlesmn 0:c1910e04fc6c 91
charlesmn 0:c1910e04fc6c 92 return i2c_inst->VL53L3_i2c_read(pBuffer,DeviceAddr,RegisterAddr,NumByteToRead);
charlesmn 0:c1910e04fc6c 93 }
charlesmn 0:c1910e04fc6c 94
charlesmn 0:c1910e04fc6c 95
charlesmn 0:c1910e04fc6c 96 VL53LX_Error VL53L3CX::VL53L3CX_GetTickCount(
charlesmn 0:c1910e04fc6c 97 uint32_t *ptick_count_ms)
charlesmn 0:c1910e04fc6c 98 {
charlesmn 0:c1910e04fc6c 99
charlesmn 0:c1910e04fc6c 100 return VL53LX_GetTickCount(Dev,ptick_count_ms);
charlesmn 0:c1910e04fc6c 101
charlesmn 0:c1910e04fc6c 102 /* Returns current tick count in [ms] */
charlesmn 0:c1910e04fc6c 103
charlesmn 0:c1910e04fc6c 104 }
charlesmn 0:c1910e04fc6c 105
charlesmn 0:c1910e04fc6c 106
charlesmn 0:c1910e04fc6c 107
charlesmn 0:c1910e04fc6c 108 VL53LX_Error VL53L3CX::VL53L3CX_WaitUs(VL53LX_Dev_t *pdev, int32_t wait_num_us)
charlesmn 0:c1910e04fc6c 109 {
charlesmn 0:c1910e04fc6c 110 // (void)pdev;
charlesmn 0:c1910e04fc6c 111 //delay(wait_us / 1000);
charlesmn 0:c1910e04fc6c 112 wait_ms(wait_num_us/1000);
charlesmn 0:c1910e04fc6c 113 return VL53LX_ERROR_NONE;
charlesmn 0:c1910e04fc6c 114 }
charlesmn 0:c1910e04fc6c 115
charlesmn 0:c1910e04fc6c 116
charlesmn 0:c1910e04fc6c 117 VL53LX_Error VL53L3CX::VL53L3CX_WaitMs(VL53LX_DEV Dev, int32_t wait_num_ms)
charlesmn 0:c1910e04fc6c 118 {
charlesmn 0:c1910e04fc6c 119 return VL53LX_WaitMs(Dev,wait_num_ms);
charlesmn 0:c1910e04fc6c 120 }
charlesmn 0:c1910e04fc6c 121
charlesmn 0:c1910e04fc6c 122
charlesmn 0:c1910e04fc6c 123 VL53LX_Error VL53L3CX::VL53L3CX_WaitValueMaskEx(
charlesmn 0:c1910e04fc6c 124 VL53LX_DEV Dev,
charlesmn 0:c1910e04fc6c 125 uint32_t timeout_ms,
charlesmn 0:c1910e04fc6c 126 uint16_t index,
charlesmn 0:c1910e04fc6c 127 uint8_t value,
charlesmn 0:c1910e04fc6c 128 uint8_t mask,
charlesmn 0:c1910e04fc6c 129 uint32_t poll_delay_ms)
charlesmn 0:c1910e04fc6c 130 {
charlesmn 0:c1910e04fc6c 131
charlesmn 0:c1910e04fc6c 132 return VL53LX_WaitValueMaskEx(
charlesmn 0:c1910e04fc6c 133 Dev,
charlesmn 0:c1910e04fc6c 134 timeout_ms,
charlesmn 0:c1910e04fc6c 135 index,
charlesmn 0:c1910e04fc6c 136 value,
charlesmn 0:c1910e04fc6c 137 mask,
charlesmn 0:c1910e04fc6c 138 poll_delay_ms);
charlesmn 0:c1910e04fc6c 139
charlesmn 0:c1910e04fc6c 140 }
charlesmn 0:c1910e04fc6c 141
charlesmn 0:c1910e04fc6c 142
charlesmn 0:c1910e04fc6c 143
charlesmn 0:c1910e04fc6c 144 /* vl53lx_api_core.c */
charlesmn 0:c1910e04fc6c 145
charlesmn 0:c1910e04fc6c 146
charlesmn 0:c1910e04fc6c 147
charlesmn 0:c1910e04fc6c 148 VL53LX_Error VL53L3CX::VL53L3CX_load_patch()
charlesmn 0:c1910e04fc6c 149 {
charlesmn 0:c1910e04fc6c 150
charlesmn 0:c1910e04fc6c 151 return VL53LX_load_patch(Dev);
charlesmn 0:c1910e04fc6c 152 }
charlesmn 0:c1910e04fc6c 153
charlesmn 0:c1910e04fc6c 154
charlesmn 0:c1910e04fc6c 155
charlesmn 0:c1910e04fc6c 156 VL53LX_Error VL53L3CX::VL53L3CX_unload_patch()
charlesmn 0:c1910e04fc6c 157 {
charlesmn 0:c1910e04fc6c 158 return VL53LX_unload_patch(Dev);
charlesmn 0:c1910e04fc6c 159 }
charlesmn 0:c1910e04fc6c 160
charlesmn 0:c1910e04fc6c 161 VL53LX_Error VL53L3CX::VL53L3CX_get_version(VL53LX_ll_version_t *pdata)
charlesmn 0:c1910e04fc6c 162 {
charlesmn 0:c1910e04fc6c 163 return VL53LX_get_version(Dev, pdata);
charlesmn 0:c1910e04fc6c 164 }
charlesmn 0:c1910e04fc6c 165
charlesmn 0:c1910e04fc6c 166
charlesmn 0:c1910e04fc6c 167
charlesmn 0:c1910e04fc6c 168
charlesmn 0:c1910e04fc6c 169
charlesmn 0:c1910e04fc6c 170 VL53LX_Error VL53L3CX::VL53L3CX_data_init(uint8_t read_p2p_data)
charlesmn 0:c1910e04fc6c 171 {
charlesmn 0:c1910e04fc6c 172 return VL53LX_data_init(Dev,read_p2p_data);
charlesmn 0:c1910e04fc6c 173 }
charlesmn 0:c1910e04fc6c 174
charlesmn 0:c1910e04fc6c 175 VL53LX_Error VL53L3CX::VL53L3CX_read_p2p_data()
charlesmn 0:c1910e04fc6c 176 {
charlesmn 0:c1910e04fc6c 177 return VL53LX_read_p2p_data(Dev);
charlesmn 0:c1910e04fc6c 178 }
charlesmn 0:c1910e04fc6c 179
charlesmn 0:c1910e04fc6c 180
charlesmn 0:c1910e04fc6c 181
charlesmn 0:c1910e04fc6c 182
charlesmn 0:c1910e04fc6c 183 VL53LX_Error VL53L3CX::VL53L3CX_set_part_to_part_data(VL53LX_calibration_data_t *pcal_data)
charlesmn 0:c1910e04fc6c 184 {
charlesmn 0:c1910e04fc6c 185 return VL53LX_set_part_to_part_data(Dev, pcal_data);
charlesmn 0:c1910e04fc6c 186 }
charlesmn 0:c1910e04fc6c 187
charlesmn 0:c1910e04fc6c 188 VL53LX_Error VL53L3CX::VL53L3CX_get_part_to_part_data(VL53LX_calibration_data_t *pcal_data)
charlesmn 0:c1910e04fc6c 189 {
charlesmn 0:c1910e04fc6c 190 return VL53LX_get_part_to_part_data(Dev, pcal_data);
charlesmn 0:c1910e04fc6c 191 }
charlesmn 0:c1910e04fc6c 192
charlesmn 0:c1910e04fc6c 193 VL53LX_Error VL53L3CX::VL53L3CX_set_inter_measurement_period_ms(
charlesmn 0:c1910e04fc6c 194 uint32_t inter_measurement_period_ms)
charlesmn 0:c1910e04fc6c 195 {
charlesmn 0:c1910e04fc6c 196 return VL53LX_set_inter_measurement_period_ms(Dev,inter_measurement_period_ms);
charlesmn 0:c1910e04fc6c 197 }
charlesmn 0:c1910e04fc6c 198
charlesmn 0:c1910e04fc6c 199 VL53LX_Error VL53L3CX::VL53L3CX_get_inter_measurement_period_ms(uint32_t *pinter_measurement_period_ms)
charlesmn 0:c1910e04fc6c 200 {
charlesmn 0:c1910e04fc6c 201 return VL53LX_get_inter_measurement_period_ms(Dev, pinter_measurement_period_ms);
charlesmn 0:c1910e04fc6c 202 }
charlesmn 0:c1910e04fc6c 203
charlesmn 0:c1910e04fc6c 204 VL53LX_Error VL53L3CX::VL53L3CX_set_timeouts_us(
charlesmn 0:c1910e04fc6c 205 uint32_t phasecal_config_timeout_us,
charlesmn 0:c1910e04fc6c 206 uint32_t mm_config_timeout_us,
charlesmn 0:c1910e04fc6c 207 uint32_t range_config_timeout_us)
charlesmn 0:c1910e04fc6c 208 {
charlesmn 0:c1910e04fc6c 209
charlesmn 0:c1910e04fc6c 210 return VL53LX_set_timeouts_us(Dev,
charlesmn 0:c1910e04fc6c 211 phasecal_config_timeout_us,
charlesmn 0:c1910e04fc6c 212 mm_config_timeout_us,
charlesmn 0:c1910e04fc6c 213 range_config_timeout_us);
charlesmn 0:c1910e04fc6c 214
charlesmn 0:c1910e04fc6c 215 }
charlesmn 0:c1910e04fc6c 216
charlesmn 0:c1910e04fc6c 217 VL53LX_Error VL53L3CX::VL53L3CX_get_timeouts_us(
charlesmn 0:c1910e04fc6c 218 uint32_t *pphasecal_config_timeout_us,
charlesmn 0:c1910e04fc6c 219 uint32_t *pmm_config_timeout_us,
charlesmn 0:c1910e04fc6c 220 uint32_t *prange_config_timeout_us)
charlesmn 0:c1910e04fc6c 221 {
charlesmn 0:c1910e04fc6c 222
charlesmn 0:c1910e04fc6c 223 return VL53LX_get_timeouts_us(Dev,
charlesmn 0:c1910e04fc6c 224 pphasecal_config_timeout_us,
charlesmn 0:c1910e04fc6c 225 pmm_config_timeout_us,
charlesmn 0:c1910e04fc6c 226 prange_config_timeout_us);
charlesmn 0:c1910e04fc6c 227
charlesmn 0:c1910e04fc6c 228 }
charlesmn 0:c1910e04fc6c 229
charlesmn 0:c1910e04fc6c 230
charlesmn 0:c1910e04fc6c 231
charlesmn 0:c1910e04fc6c 232
charlesmn 0:c1910e04fc6c 233 VL53LX_Error VL53L3CX::VL53L3CX_set_user_zone(
charlesmn 0:c1910e04fc6c 234 VL53LX_user_zone_t *puser_zone)
charlesmn 0:c1910e04fc6c 235 {
charlesmn 0:c1910e04fc6c 236 return VL53LX_set_user_zone(
charlesmn 0:c1910e04fc6c 237 Dev,
charlesmn 0:c1910e04fc6c 238 puser_zone);
charlesmn 0:c1910e04fc6c 239
charlesmn 0:c1910e04fc6c 240 }
charlesmn 0:c1910e04fc6c 241
charlesmn 0:c1910e04fc6c 242 VL53LX_Error VL53L3CX::VL53L3CX_get_user_zone(
charlesmn 0:c1910e04fc6c 243 VL53LX_user_zone_t *puser_zone)
charlesmn 0:c1910e04fc6c 244 {
charlesmn 0:c1910e04fc6c 245 return VL53LX_get_user_zone( Dev, puser_zone);
charlesmn 0:c1910e04fc6c 246 }
charlesmn 0:c1910e04fc6c 247
charlesmn 0:c1910e04fc6c 248 VL53LX_Error VL53L3CX::VL53L3CX_get_mode_mitigation_roi(
charlesmn 0:c1910e04fc6c 249 VL53LX_user_zone_t *pmm_roi)
charlesmn 0:c1910e04fc6c 250 {
charlesmn 0:c1910e04fc6c 251
charlesmn 0:c1910e04fc6c 252 return VL53LX_get_mode_mitigation_roi( Dev, pmm_roi);
charlesmn 0:c1910e04fc6c 253 }
charlesmn 0:c1910e04fc6c 254
charlesmn 0:c1910e04fc6c 255 VL53LX_Error VL53L3CX::VL53L3CX_set_zone_config(
charlesmn 0:c1910e04fc6c 256 VL53LX_zone_config_t *pzone_cfg)
charlesmn 0:c1910e04fc6c 257 {
charlesmn 0:c1910e04fc6c 258
charlesmn 0:c1910e04fc6c 259 return VL53LX_set_zone_config(Dev, pzone_cfg );
charlesmn 0:c1910e04fc6c 260
charlesmn 0:c1910e04fc6c 261 }
charlesmn 0:c1910e04fc6c 262
charlesmn 0:c1910e04fc6c 263
charlesmn 0:c1910e04fc6c 264
charlesmn 0:c1910e04fc6c 265 VL53LX_Error VL53L3CX::VL53L3CX_get_zone_config(
charlesmn 0:c1910e04fc6c 266 VL53LX_zone_config_t *pzone_cfg)
charlesmn 0:c1910e04fc6c 267 {
charlesmn 0:c1910e04fc6c 268
charlesmn 0:c1910e04fc6c 269 return VL53LX_get_zone_config(Dev, pzone_cfg);
charlesmn 0:c1910e04fc6c 270
charlesmn 0:c1910e04fc6c 271 }
charlesmn 0:c1910e04fc6c 272
charlesmn 0:c1910e04fc6c 273 VL53LX_Error VL53L3CX::VL53L3CX_get_preset_mode_timing_cfg(
charlesmn 0:c1910e04fc6c 274 VL53LX_DevicePresetModes device_preset_mode,
charlesmn 0:c1910e04fc6c 275 uint16_t *pdss_config__target_total_rate_mcps,
charlesmn 0:c1910e04fc6c 276 uint32_t *pphasecal_config_timeout_us,
charlesmn 0:c1910e04fc6c 277 uint32_t *pmm_config_timeout_us,
charlesmn 0:c1910e04fc6c 278 uint32_t *prange_config_timeout_us)
charlesmn 0:c1910e04fc6c 279 {
charlesmn 0:c1910e04fc6c 280
charlesmn 0:c1910e04fc6c 281 return VL53LX_get_preset_mode_timing_cfg(Dev,
charlesmn 0:c1910e04fc6c 282 device_preset_mode,
charlesmn 0:c1910e04fc6c 283 pdss_config__target_total_rate_mcps,
charlesmn 0:c1910e04fc6c 284 pphasecal_config_timeout_us,
charlesmn 0:c1910e04fc6c 285 pmm_config_timeout_us,
charlesmn 0:c1910e04fc6c 286 prange_config_timeout_us);
charlesmn 0:c1910e04fc6c 287
charlesmn 0:c1910e04fc6c 288 }
charlesmn 0:c1910e04fc6c 289
charlesmn 0:c1910e04fc6c 290 VL53LX_Error VL53L3CX::VL53L3CX_set_preset_mode(
charlesmn 0:c1910e04fc6c 291 VL53LX_DevicePresetModes device_preset_mode,
charlesmn 0:c1910e04fc6c 292 uint16_t dss_config__target_total_rate_mcps,
charlesmn 0:c1910e04fc6c 293 uint32_t phasecal_config_timeout_us,
charlesmn 0:c1910e04fc6c 294 uint32_t mm_config_timeout_us,
charlesmn 0:c1910e04fc6c 295 uint32_t range_config_timeout_us,
charlesmn 0:c1910e04fc6c 296 uint32_t inter_measurement_period_ms)
charlesmn 0:c1910e04fc6c 297 {
charlesmn 0:c1910e04fc6c 298
charlesmn 0:c1910e04fc6c 299 return VL53LX_set_preset_mode(
charlesmn 0:c1910e04fc6c 300 Dev,
charlesmn 0:c1910e04fc6c 301 device_preset_mode,
charlesmn 0:c1910e04fc6c 302 dss_config__target_total_rate_mcps,
charlesmn 0:c1910e04fc6c 303 phasecal_config_timeout_us,
charlesmn 0:c1910e04fc6c 304 mm_config_timeout_us,
charlesmn 0:c1910e04fc6c 305 range_config_timeout_us,
charlesmn 0:c1910e04fc6c 306 inter_measurement_period_ms);
charlesmn 0:c1910e04fc6c 307
charlesmn 0:c1910e04fc6c 308 }
charlesmn 0:c1910e04fc6c 309
charlesmn 0:c1910e04fc6c 310
charlesmn 0:c1910e04fc6c 311 VL53LX_Error VL53L3CX::VL53L3CX_enable_xtalk_compensation()
charlesmn 0:c1910e04fc6c 312 {
charlesmn 0:c1910e04fc6c 313
charlesmn 0:c1910e04fc6c 314 return VL53LX_enable_xtalk_compensation(Dev);
charlesmn 0:c1910e04fc6c 315
charlesmn 0:c1910e04fc6c 316 }
charlesmn 0:c1910e04fc6c 317
charlesmn 0:c1910e04fc6c 318 void VL53L3CX::VL53L3CX_get_xtalk_compensation_enable(uint8_t *pcrosstalk_compensation_enable)
charlesmn 0:c1910e04fc6c 319 {
charlesmn 0:c1910e04fc6c 320 return VL53LX_get_xtalk_compensation_enable(Dev,pcrosstalk_compensation_enable);
charlesmn 0:c1910e04fc6c 321
charlesmn 0:c1910e04fc6c 322 }
charlesmn 0:c1910e04fc6c 323
charlesmn 0:c1910e04fc6c 324
charlesmn 0:c1910e04fc6c 325
charlesmn 0:c1910e04fc6c 326
charlesmn 0:c1910e04fc6c 327
charlesmn 0:c1910e04fc6c 328
charlesmn 0:c1910e04fc6c 329 VL53LX_Error VL53L3CX::VL53L3CX_disable_xtalk_compensation()
charlesmn 0:c1910e04fc6c 330 {
charlesmn 0:c1910e04fc6c 331
charlesmn 0:c1910e04fc6c 332 return VL53LX_disable_xtalk_compensation(Dev);
charlesmn 0:c1910e04fc6c 333
charlesmn 0:c1910e04fc6c 334 }
charlesmn 0:c1910e04fc6c 335
charlesmn 0:c1910e04fc6c 336
charlesmn 0:c1910e04fc6c 337
charlesmn 0:c1910e04fc6c 338
charlesmn 0:c1910e04fc6c 339 VL53LX_Error VL53L3CX::VL53L3CX_init_and_start_range(
charlesmn 0:c1910e04fc6c 340 uint8_t measurement_mode,
charlesmn 0:c1910e04fc6c 341 VL53LX_DeviceConfigLevel device_config_level)
charlesmn 0:c1910e04fc6c 342 {
charlesmn 0:c1910e04fc6c 343
charlesmn 0:c1910e04fc6c 344 return VL53LX_init_and_start_range( Dev, measurement_mode, device_config_level);
charlesmn 0:c1910e04fc6c 345
charlesmn 0:c1910e04fc6c 346 }
charlesmn 0:c1910e04fc6c 347 VL53LX_Error VL53L3CX::VL53L3CX_stop_range()
charlesmn 0:c1910e04fc6c 348 {
charlesmn 0:c1910e04fc6c 349 return VL53LX_stop_range(Dev);
charlesmn 0:c1910e04fc6c 350 }
charlesmn 0:c1910e04fc6c 351
charlesmn 0:c1910e04fc6c 352 VL53LX_Error VL53L3CX::VL53L3CX_get_measurement_results(
charlesmn 0:c1910e04fc6c 353 VL53LX_DeviceResultsLevel device_results_level)
charlesmn 0:c1910e04fc6c 354 {
charlesmn 0:c1910e04fc6c 355
charlesmn 0:c1910e04fc6c 356 return VL53LX_get_measurement_results( Dev, device_results_level);
charlesmn 0:c1910e04fc6c 357
charlesmn 0:c1910e04fc6c 358 }
charlesmn 0:c1910e04fc6c 359
charlesmn 0:c1910e04fc6c 360 VL53LX_Error VL53L3CX::VL53L3CX_get_device_results(
charlesmn 0:c1910e04fc6c 361 VL53LX_DeviceResultsLevel device_results_level,
charlesmn 0:c1910e04fc6c 362 VL53LX_range_results_t *prange_results)
charlesmn 0:c1910e04fc6c 363 {
charlesmn 0:c1910e04fc6c 364 return VL53LX_get_device_results( Dev, device_results_level,prange_results);
charlesmn 0:c1910e04fc6c 365 }
charlesmn 0:c1910e04fc6c 366
charlesmn 0:c1910e04fc6c 367 VL53LX_Error VL53L3CX::VL53L3CX_clear_interrupt_and_enable_next_range(
charlesmn 0:c1910e04fc6c 368 uint8_t measurement_mode)
charlesmn 0:c1910e04fc6c 369 {
charlesmn 0:c1910e04fc6c 370 return VL53LX_clear_interrupt_and_enable_next_range(Dev,measurement_mode);
charlesmn 0:c1910e04fc6c 371 }
charlesmn 0:c1910e04fc6c 372
charlesmn 0:c1910e04fc6c 373
charlesmn 0:c1910e04fc6c 374 VL53LX_Error VL53L3CX::VL53L3CX_get_histogram_bin_data(
charlesmn 0:c1910e04fc6c 375 VL53LX_histogram_bin_data_t *pdata)
charlesmn 0:c1910e04fc6c 376 {
charlesmn 0:c1910e04fc6c 377 return VL53LX_get_histogram_bin_data(Dev, pdata);
charlesmn 0:c1910e04fc6c 378 }
charlesmn 0:c1910e04fc6c 379
charlesmn 0:c1910e04fc6c 380 void VL53L3CX::VL53L3CX_copy_sys_and_core_results_to_range_results(
charlesmn 0:c1910e04fc6c 381 int32_t gain_factor,
charlesmn 0:c1910e04fc6c 382 VL53LX_system_results_t *psys,
charlesmn 0:c1910e04fc6c 383 VL53LX_core_results_t *pcore,
charlesmn 0:c1910e04fc6c 384 VL53LX_range_results_t *presults)
charlesmn 0:c1910e04fc6c 385 {
charlesmn 0:c1910e04fc6c 386
charlesmn 0:c1910e04fc6c 387 return VL53LX_copy_sys_and_core_results_to_range_results(
charlesmn 0:c1910e04fc6c 388 gain_factor,
charlesmn 0:c1910e04fc6c 389 psys,
charlesmn 0:c1910e04fc6c 390 pcore,
charlesmn 0:c1910e04fc6c 391 presults);
charlesmn 0:c1910e04fc6c 392
charlesmn 0:c1910e04fc6c 393 }
charlesmn 0:c1910e04fc6c 394
charlesmn 0:c1910e04fc6c 395 VL53LX_Error VL53L3CX::VL53L3CX_set_zone_dss_config(
charlesmn 0:c1910e04fc6c 396 VL53LX_zone_private_dyn_cfg_t *pzone_dyn_cfg)
charlesmn 0:c1910e04fc6c 397 {
charlesmn 0:c1910e04fc6c 398
charlesmn 0:c1910e04fc6c 399 return VL53LX_set_zone_dss_config( Dev,
charlesmn 0:c1910e04fc6c 400 pzone_dyn_cfg);
charlesmn 0:c1910e04fc6c 401
charlesmn 0:c1910e04fc6c 402 }
charlesmn 0:c1910e04fc6c 403
charlesmn 0:c1910e04fc6c 404
charlesmn 0:c1910e04fc6c 405
charlesmn 0:c1910e04fc6c 406 VL53LX_Error VL53L3CX::VL53L3CX_set_dmax_mode(
charlesmn 0:c1910e04fc6c 407 VL53LX_DeviceDmaxMode dmax_mode)
charlesmn 0:c1910e04fc6c 408 {
charlesmn 0:c1910e04fc6c 409
charlesmn 0:c1910e04fc6c 410 return VL53LX_set_dmax_mode(Dev,dmax_mode);
charlesmn 0:c1910e04fc6c 411
charlesmn 0:c1910e04fc6c 412 }
charlesmn 0:c1910e04fc6c 413
charlesmn 0:c1910e04fc6c 414
charlesmn 0:c1910e04fc6c 415 VL53LX_Error VL53L3CX::VL53L3CX_get_dmax_mode(
charlesmn 0:c1910e04fc6c 416 VL53LX_DeviceDmaxMode *pdmax_mode)
charlesmn 0:c1910e04fc6c 417 {
charlesmn 0:c1910e04fc6c 418
charlesmn 0:c1910e04fc6c 419 return VL53LX_get_dmax_mode( Dev,pdmax_mode);
charlesmn 0:c1910e04fc6c 420
charlesmn 0:c1910e04fc6c 421 }
charlesmn 0:c1910e04fc6c 422
charlesmn 0:c1910e04fc6c 423
charlesmn 0:c1910e04fc6c 424 VL53LX_Error VL53L3CX::VL53L3CX_get_dmax_calibration_data(
charlesmn 0:c1910e04fc6c 425 VL53LX_DeviceDmaxMode dmax_mode,
charlesmn 0:c1910e04fc6c 426 VL53LX_dmax_calibration_data_t *pdmax_cal)
charlesmn 0:c1910e04fc6c 427 {
charlesmn 0:c1910e04fc6c 428
charlesmn 0:c1910e04fc6c 429 return VL53LX_get_dmax_calibration_data(Dev, dmax_mode, pdmax_cal);
charlesmn 0:c1910e04fc6c 430
charlesmn 0:c1910e04fc6c 431 }
charlesmn 0:c1910e04fc6c 432
charlesmn 0:c1910e04fc6c 433
charlesmn 0:c1910e04fc6c 434
charlesmn 0:c1910e04fc6c 435
charlesmn 0:c1910e04fc6c 436 VL53LX_Error VL53L3CX::VL53L3CX_set_offset_correction_mode(
charlesmn 0:c1910e04fc6c 437 VL53LX_OffsetCorrectionMode offset_cor_mode)
charlesmn 0:c1910e04fc6c 438 {
charlesmn 0:c1910e04fc6c 439
charlesmn 0:c1910e04fc6c 440 return VL53LX_set_offset_correction_mode(Dev, offset_cor_mode);
charlesmn 0:c1910e04fc6c 441
charlesmn 0:c1910e04fc6c 442 }
charlesmn 0:c1910e04fc6c 443
charlesmn 0:c1910e04fc6c 444
charlesmn 0:c1910e04fc6c 445 VL53LX_Error VL53L3CX::VL53L3CX_get_offset_correction_mode(
charlesmn 0:c1910e04fc6c 446 VL53LX_OffsetCorrectionMode *poffset_cor_mode)
charlesmn 0:c1910e04fc6c 447 {
charlesmn 0:c1910e04fc6c 448 return VL53LX_get_offset_correction_mode( Dev, poffset_cor_mode);
charlesmn 0:c1910e04fc6c 449
charlesmn 0:c1910e04fc6c 450 }
charlesmn 0:c1910e04fc6c 451
charlesmn 0:c1910e04fc6c 452
charlesmn 0:c1910e04fc6c 453
charlesmn 0:c1910e04fc6c 454 VL53LX_Error VL53L3CX::VL53L3CX_get_tuning_debug_data(
charlesmn 0:c1910e04fc6c 455 VL53LX_tuning_parameters_t *ptun_data)
charlesmn 0:c1910e04fc6c 456 {
charlesmn 0:c1910e04fc6c 457
charlesmn 0:c1910e04fc6c 458 return VL53LX_get_tuning_debug_data(Dev,ptun_data);
charlesmn 0:c1910e04fc6c 459
charlesmn 0:c1910e04fc6c 460 }
charlesmn 0:c1910e04fc6c 461
charlesmn 0:c1910e04fc6c 462 VL53LX_Error VL53L3CX::VL53L3CX_get_tuning_parm(
charlesmn 0:c1910e04fc6c 463 VL53LX_TuningParms tuning_parm_key,
charlesmn 0:c1910e04fc6c 464 int32_t *ptuning_parm_value)
charlesmn 0:c1910e04fc6c 465 {
charlesmn 0:c1910e04fc6c 466
charlesmn 0:c1910e04fc6c 467 return VL53LX_get_tuning_parm(Dev, tuning_parm_key,
charlesmn 0:c1910e04fc6c 468 ptuning_parm_value);
charlesmn 0:c1910e04fc6c 469
charlesmn 0:c1910e04fc6c 470 }
charlesmn 0:c1910e04fc6c 471
charlesmn 0:c1910e04fc6c 472
charlesmn 0:c1910e04fc6c 473 VL53LX_Error VL53L3CX::VL53L3CX_set_tuning_parm(
charlesmn 0:c1910e04fc6c 474 VL53LX_TuningParms tuning_parm_key,
charlesmn 0:c1910e04fc6c 475 int32_t tuning_parm_value)
charlesmn 0:c1910e04fc6c 476 {
charlesmn 0:c1910e04fc6c 477
charlesmn 0:c1910e04fc6c 478 return VL53LX_set_tuning_parm(Dev, tuning_parm_key, tuning_parm_value);
charlesmn 0:c1910e04fc6c 479
charlesmn 0:c1910e04fc6c 480 }
charlesmn 0:c1910e04fc6c 481
charlesmn 0:c1910e04fc6c 482 VL53LX_Error VL53L3CX::VL53L3CX_dynamic_xtalk_correction_enable()
charlesmn 0:c1910e04fc6c 483 {
charlesmn 0:c1910e04fc6c 484
charlesmn 0:c1910e04fc6c 485 return VL53LX_dynamic_xtalk_correction_enable(Dev);
charlesmn 0:c1910e04fc6c 486
charlesmn 0:c1910e04fc6c 487 }
charlesmn 0:c1910e04fc6c 488
charlesmn 0:c1910e04fc6c 489 VL53LX_Error VL53L3CX::VL53L3CX_dynamic_xtalk_correction_disable()
charlesmn 0:c1910e04fc6c 490 {
charlesmn 0:c1910e04fc6c 491 return VL53LX_dynamic_xtalk_correction_disable(Dev);
charlesmn 0:c1910e04fc6c 492
charlesmn 0:c1910e04fc6c 493 }
charlesmn 0:c1910e04fc6c 494 VL53LX_Error VL53L3CX::VL53L3CX_dynamic_xtalk_correction_apply_enable()
charlesmn 0:c1910e04fc6c 495 {
charlesmn 0:c1910e04fc6c 496
charlesmn 0:c1910e04fc6c 497 return VL53LX_dynamic_xtalk_correction_apply_enable(Dev);
charlesmn 0:c1910e04fc6c 498 }
charlesmn 0:c1910e04fc6c 499
charlesmn 0:c1910e04fc6c 500 VL53LX_Error VL53L3CX::VL53L3CX_dynamic_xtalk_correction_apply_disable()
charlesmn 0:c1910e04fc6c 501 {
charlesmn 0:c1910e04fc6c 502
charlesmn 0:c1910e04fc6c 503 return VL53LX_dynamic_xtalk_correction_apply_disable(Dev);
charlesmn 0:c1910e04fc6c 504
charlesmn 0:c1910e04fc6c 505 }
charlesmn 0:c1910e04fc6c 506
charlesmn 0:c1910e04fc6c 507
charlesmn 0:c1910e04fc6c 508 VL53LX_Error VL53L3CX::VL53L3CX_dynamic_xtalk_correction_single_apply_enable()
charlesmn 0:c1910e04fc6c 509 {
charlesmn 0:c1910e04fc6c 510
charlesmn 0:c1910e04fc6c 511 return VL53LX_dynamic_xtalk_correction_single_apply_enable(Dev);
charlesmn 0:c1910e04fc6c 512
charlesmn 0:c1910e04fc6c 513 }
charlesmn 0:c1910e04fc6c 514
charlesmn 0:c1910e04fc6c 515 VL53LX_Error VL53L3CX::VL53L3CX_dynamic_xtalk_correction_single_apply_disable()
charlesmn 0:c1910e04fc6c 516 {
charlesmn 0:c1910e04fc6c 517
charlesmn 0:c1910e04fc6c 518 return VL53LX_dynamic_xtalk_correction_single_apply_disable(Dev);
charlesmn 0:c1910e04fc6c 519
charlesmn 0:c1910e04fc6c 520 }
charlesmn 0:c1910e04fc6c 521
charlesmn 0:c1910e04fc6c 522
charlesmn 0:c1910e04fc6c 523 VL53LX_Error VL53L3CX::VL53L3CX_get_current_xtalk_settings(
charlesmn 0:c1910e04fc6c 524 VL53LX_xtalk_calibration_results_t *pxtalk
charlesmn 0:c1910e04fc6c 525 )
charlesmn 0:c1910e04fc6c 526 {
charlesmn 0:c1910e04fc6c 527
charlesmn 0:c1910e04fc6c 528 return VL53LX_get_current_xtalk_settings(Dev,pxtalk);
charlesmn 0:c1910e04fc6c 529
charlesmn 0:c1910e04fc6c 530 }
charlesmn 0:c1910e04fc6c 531 VL53LX_Error VL53L3CX::VL53L3CX_set_current_xtalk_settings(
charlesmn 0:c1910e04fc6c 532 VL53LX_xtalk_calibration_results_t *pxtalk
charlesmn 0:c1910e04fc6c 533 )
charlesmn 0:c1910e04fc6c 534 {
charlesmn 0:c1910e04fc6c 535 return VL53LX_set_current_xtalk_settings(Dev, pxtalk);
charlesmn 0:c1910e04fc6c 536
charlesmn 0:c1910e04fc6c 537 }
charlesmn 0:c1910e04fc6c 538
charlesmn 0:c1910e04fc6c 539 /* vl53lx_register_funcs.c */
charlesmn 0:c1910e04fc6c 540
charlesmn 0:c1910e04fc6c 541 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_static_nvm_managed(
charlesmn 0:c1910e04fc6c 542 VL53LX_static_nvm_managed_t *pdata,
charlesmn 0:c1910e04fc6c 543 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 544 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 545 {
charlesmn 0:c1910e04fc6c 546
charlesmn 0:c1910e04fc6c 547 return VL53LX_i2c_encode_static_nvm_managed( pdata, buf_size, pbuffer);
charlesmn 0:c1910e04fc6c 548
charlesmn 0:c1910e04fc6c 549 }
charlesmn 0:c1910e04fc6c 550
charlesmn 0:c1910e04fc6c 551 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_static_nvm_managed(
charlesmn 0:c1910e04fc6c 552 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 553 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 554 VL53LX_static_nvm_managed_t *pdata)
charlesmn 0:c1910e04fc6c 555 {
charlesmn 0:c1910e04fc6c 556
charlesmn 0:c1910e04fc6c 557
charlesmn 0:c1910e04fc6c 558 return VL53LX_i2c_decode_static_nvm_managed(
charlesmn 0:c1910e04fc6c 559 buf_size,
charlesmn 0:c1910e04fc6c 560 pbuffer,
charlesmn 0:c1910e04fc6c 561 pdata);
charlesmn 0:c1910e04fc6c 562
charlesmn 0:c1910e04fc6c 563 }
charlesmn 0:c1910e04fc6c 564
charlesmn 0:c1910e04fc6c 565 VL53LX_Error VL53L3CX::VL53L3CX_set_static_nvm_managed(
charlesmn 0:c1910e04fc6c 566 VL53LX_static_nvm_managed_t *pdata)
charlesmn 0:c1910e04fc6c 567 {
charlesmn 0:c1910e04fc6c 568
charlesmn 0:c1910e04fc6c 569 return VL53LX_set_static_nvm_managed( Dev, pdata);
charlesmn 0:c1910e04fc6c 570
charlesmn 0:c1910e04fc6c 571 }
charlesmn 0:c1910e04fc6c 572
charlesmn 0:c1910e04fc6c 573 VL53LX_Error VL53L3CX::VL53L3CX_get_static_nvm_managed(
charlesmn 0:c1910e04fc6c 574 VL53LX_static_nvm_managed_t *pdata)
charlesmn 0:c1910e04fc6c 575 {
charlesmn 0:c1910e04fc6c 576
charlesmn 0:c1910e04fc6c 577 return VL53LX_get_static_nvm_managed( Dev,
charlesmn 0:c1910e04fc6c 578 pdata);
charlesmn 0:c1910e04fc6c 579
charlesmn 0:c1910e04fc6c 580 }
charlesmn 0:c1910e04fc6c 581
charlesmn 0:c1910e04fc6c 582
charlesmn 0:c1910e04fc6c 583 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_customer_nvm_managed(
charlesmn 0:c1910e04fc6c 584 VL53LX_customer_nvm_managed_t *pdata,
charlesmn 0:c1910e04fc6c 585 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 586 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 587 {
charlesmn 0:c1910e04fc6c 588
charlesmn 0:c1910e04fc6c 589
charlesmn 0:c1910e04fc6c 590 return VL53LX_i2c_encode_customer_nvm_managed( pdata,
charlesmn 0:c1910e04fc6c 591 buf_size,
charlesmn 0:c1910e04fc6c 592 pbuffer);
charlesmn 0:c1910e04fc6c 593
charlesmn 0:c1910e04fc6c 594 }
charlesmn 0:c1910e04fc6c 595
charlesmn 0:c1910e04fc6c 596 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_customer_nvm_managed(
charlesmn 0:c1910e04fc6c 597 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 598 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 599 VL53LX_customer_nvm_managed_t *pdata)
charlesmn 0:c1910e04fc6c 600 {
charlesmn 0:c1910e04fc6c 601
charlesmn 0:c1910e04fc6c 602 return VL53LX_i2c_decode_customer_nvm_managed( buf_size,
charlesmn 0:c1910e04fc6c 603 pbuffer,
charlesmn 0:c1910e04fc6c 604 pdata);
charlesmn 0:c1910e04fc6c 605
charlesmn 0:c1910e04fc6c 606 }
charlesmn 0:c1910e04fc6c 607
charlesmn 0:c1910e04fc6c 608 VL53LX_Error VL53L3CX::VL53L3CX_set_customer_nvm_managed(
charlesmn 0:c1910e04fc6c 609 VL53LX_customer_nvm_managed_t *pdata)
charlesmn 0:c1910e04fc6c 610 {
charlesmn 0:c1910e04fc6c 611
charlesmn 0:c1910e04fc6c 612
charlesmn 0:c1910e04fc6c 613 return VL53LX_set_customer_nvm_managed(Dev,
charlesmn 0:c1910e04fc6c 614 pdata);
charlesmn 0:c1910e04fc6c 615
charlesmn 0:c1910e04fc6c 616 }
charlesmn 0:c1910e04fc6c 617
charlesmn 0:c1910e04fc6c 618 VL53LX_Error VL53L3CX::VL53L3CX_get_customer_nvm_managed(
charlesmn 0:c1910e04fc6c 619 VL53LX_customer_nvm_managed_t *pdata)
charlesmn 0:c1910e04fc6c 620 {
charlesmn 0:c1910e04fc6c 621
charlesmn 0:c1910e04fc6c 622 return VL53LX_get_customer_nvm_managed(Dev,pdata);
charlesmn 0:c1910e04fc6c 623
charlesmn 0:c1910e04fc6c 624 }
charlesmn 0:c1910e04fc6c 625
charlesmn 0:c1910e04fc6c 626
charlesmn 0:c1910e04fc6c 627 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_static_config(
charlesmn 0:c1910e04fc6c 628 VL53LX_static_config_t *pdata,
charlesmn 0:c1910e04fc6c 629 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 630 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 631 {
charlesmn 0:c1910e04fc6c 632
charlesmn 0:c1910e04fc6c 633 return VL53LX_i2c_encode_static_config(pdata, buf_size, pbuffer);
charlesmn 0:c1910e04fc6c 634
charlesmn 0:c1910e04fc6c 635 }
charlesmn 0:c1910e04fc6c 636
charlesmn 0:c1910e04fc6c 637 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_static_config(
charlesmn 0:c1910e04fc6c 638 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 639 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 640 VL53LX_static_config_t *pdata)
charlesmn 0:c1910e04fc6c 641 {
charlesmn 0:c1910e04fc6c 642
charlesmn 0:c1910e04fc6c 643 return VL53LX_i2c_decode_static_config( buf_size, pbuffer, pdata);
charlesmn 0:c1910e04fc6c 644
charlesmn 0:c1910e04fc6c 645 }
charlesmn 0:c1910e04fc6c 646
charlesmn 0:c1910e04fc6c 647 VL53LX_Error VL53L3CX::VL53L3CX_set_static_config(
charlesmn 0:c1910e04fc6c 648 VL53LX_static_config_t *pdata)
charlesmn 0:c1910e04fc6c 649 {
charlesmn 0:c1910e04fc6c 650
charlesmn 0:c1910e04fc6c 651 return VL53LX_set_static_config(Dev, pdata);
charlesmn 0:c1910e04fc6c 652
charlesmn 0:c1910e04fc6c 653 }
charlesmn 0:c1910e04fc6c 654
charlesmn 0:c1910e04fc6c 655 VL53LX_Error VL53L3CX::VL53L3CX_get_static_config(
charlesmn 0:c1910e04fc6c 656 VL53LX_static_config_t *pdata)
charlesmn 0:c1910e04fc6c 657 {
charlesmn 0:c1910e04fc6c 658
charlesmn 0:c1910e04fc6c 659 return VL53LX_get_static_config( Dev, pdata);
charlesmn 0:c1910e04fc6c 660
charlesmn 0:c1910e04fc6c 661 }
charlesmn 0:c1910e04fc6c 662
charlesmn 0:c1910e04fc6c 663
charlesmn 0:c1910e04fc6c 664 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_general_config(
charlesmn 0:c1910e04fc6c 665 VL53LX_general_config_t *pdata,
charlesmn 0:c1910e04fc6c 666 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 667 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 668 {
charlesmn 0:c1910e04fc6c 669
charlesmn 0:c1910e04fc6c 670 return VL53LX_i2c_encode_general_config(
charlesmn 0:c1910e04fc6c 671 pdata,
charlesmn 0:c1910e04fc6c 672 buf_size,
charlesmn 0:c1910e04fc6c 673 pbuffer);
charlesmn 0:c1910e04fc6c 674
charlesmn 0:c1910e04fc6c 675 }
charlesmn 0:c1910e04fc6c 676
charlesmn 0:c1910e04fc6c 677
charlesmn 0:c1910e04fc6c 678 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_general_config(
charlesmn 0:c1910e04fc6c 679 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 680 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 681 VL53LX_general_config_t *pdata)
charlesmn 0:c1910e04fc6c 682 {
charlesmn 0:c1910e04fc6c 683
charlesmn 0:c1910e04fc6c 684 return VL53LX_i2c_decode_general_config(
charlesmn 0:c1910e04fc6c 685 buf_size,
charlesmn 0:c1910e04fc6c 686 pbuffer,
charlesmn 0:c1910e04fc6c 687 pdata);
charlesmn 0:c1910e04fc6c 688
charlesmn 0:c1910e04fc6c 689 }
charlesmn 0:c1910e04fc6c 690
charlesmn 0:c1910e04fc6c 691 VL53LX_Error VL53L3CX::VL53L3CX_set_general_config(
charlesmn 0:c1910e04fc6c 692 VL53LX_general_config_t *pdata)
charlesmn 0:c1910e04fc6c 693 {
charlesmn 0:c1910e04fc6c 694
charlesmn 0:c1910e04fc6c 695 return VL53LX_set_general_config( Dev, pdata);
charlesmn 0:c1910e04fc6c 696
charlesmn 0:c1910e04fc6c 697 }
charlesmn 0:c1910e04fc6c 698
charlesmn 0:c1910e04fc6c 699
charlesmn 0:c1910e04fc6c 700 VL53LX_Error VL53L3CX::VL53L3CX_get_general_config(
charlesmn 0:c1910e04fc6c 701 VL53LX_general_config_t *pdata)
charlesmn 0:c1910e04fc6c 702 {
charlesmn 0:c1910e04fc6c 703
charlesmn 0:c1910e04fc6c 704 return VL53LX_get_general_config( Dev,pdata);
charlesmn 0:c1910e04fc6c 705
charlesmn 0:c1910e04fc6c 706 }
charlesmn 0:c1910e04fc6c 707
charlesmn 0:c1910e04fc6c 708
charlesmn 0:c1910e04fc6c 709 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_timing_config(
charlesmn 0:c1910e04fc6c 710 VL53LX_timing_config_t *pdata,
charlesmn 0:c1910e04fc6c 711 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 712 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 713 {
charlesmn 0:c1910e04fc6c 714
charlesmn 0:c1910e04fc6c 715 return VL53LX_i2c_encode_timing_config(
charlesmn 0:c1910e04fc6c 716 pdata,
charlesmn 0:c1910e04fc6c 717 buf_size,
charlesmn 0:c1910e04fc6c 718 pbuffer);
charlesmn 0:c1910e04fc6c 719
charlesmn 0:c1910e04fc6c 720 }
charlesmn 0:c1910e04fc6c 721
charlesmn 0:c1910e04fc6c 722 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_timing_config(
charlesmn 0:c1910e04fc6c 723 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 724 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 725 VL53LX_timing_config_t *pdata)
charlesmn 0:c1910e04fc6c 726 {
charlesmn 0:c1910e04fc6c 727
charlesmn 0:c1910e04fc6c 728 return VL53LX_i2c_decode_timing_config(
charlesmn 0:c1910e04fc6c 729 buf_size,
charlesmn 0:c1910e04fc6c 730 pbuffer,
charlesmn 0:c1910e04fc6c 731 pdata);
charlesmn 0:c1910e04fc6c 732
charlesmn 0:c1910e04fc6c 733 }
charlesmn 0:c1910e04fc6c 734
charlesmn 0:c1910e04fc6c 735 VL53LX_Error VL53L3CX::VL53L3CX_set_timing_config(
charlesmn 0:c1910e04fc6c 736 VL53LX_timing_config_t *pdata)
charlesmn 0:c1910e04fc6c 737 {
charlesmn 0:c1910e04fc6c 738
charlesmn 0:c1910e04fc6c 739 return VL53LX_set_timing_config( Dev, pdata);
charlesmn 0:c1910e04fc6c 740
charlesmn 0:c1910e04fc6c 741 }
charlesmn 0:c1910e04fc6c 742
charlesmn 0:c1910e04fc6c 743 VL53LX_Error VL53L3CX::VL53L3CX_get_timing_config(
charlesmn 0:c1910e04fc6c 744 VL53LX_timing_config_t *pdata)
charlesmn 0:c1910e04fc6c 745 {
charlesmn 0:c1910e04fc6c 746
charlesmn 0:c1910e04fc6c 747 return VL53LX_set_timing_config( Dev, pdata);
charlesmn 0:c1910e04fc6c 748
charlesmn 0:c1910e04fc6c 749 }
charlesmn 0:c1910e04fc6c 750
charlesmn 0:c1910e04fc6c 751 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_dynamic_config(
charlesmn 0:c1910e04fc6c 752 VL53LX_dynamic_config_t *pdata,
charlesmn 0:c1910e04fc6c 753 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 754 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 755 {
charlesmn 0:c1910e04fc6c 756
charlesmn 0:c1910e04fc6c 757 return VL53LX_i2c_encode_dynamic_config( pdata, buf_size, pbuffer);
charlesmn 0:c1910e04fc6c 758
charlesmn 0:c1910e04fc6c 759 }
charlesmn 0:c1910e04fc6c 760
charlesmn 0:c1910e04fc6c 761 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_dynamic_config(
charlesmn 0:c1910e04fc6c 762 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 763 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 764 VL53LX_dynamic_config_t *pdata)
charlesmn 0:c1910e04fc6c 765 {
charlesmn 0:c1910e04fc6c 766
charlesmn 0:c1910e04fc6c 767 return VL53LX_i2c_decode_dynamic_config(buf_size,pbuffer,pdata);
charlesmn 0:c1910e04fc6c 768
charlesmn 0:c1910e04fc6c 769 }
charlesmn 0:c1910e04fc6c 770
charlesmn 0:c1910e04fc6c 771 VL53LX_Error VL53L3CX::VL53L3CX_set_dynamic_config(
charlesmn 0:c1910e04fc6c 772 VL53LX_dynamic_config_t *pdata)
charlesmn 0:c1910e04fc6c 773 {
charlesmn 0:c1910e04fc6c 774
charlesmn 0:c1910e04fc6c 775 return VL53LX_set_dynamic_config( Dev, pdata);
charlesmn 0:c1910e04fc6c 776
charlesmn 0:c1910e04fc6c 777 }
charlesmn 0:c1910e04fc6c 778
charlesmn 0:c1910e04fc6c 779
charlesmn 0:c1910e04fc6c 780 VL53LX_Error VL53L3CX::VL53L3CX_get_dynamic_config(
charlesmn 0:c1910e04fc6c 781 VL53LX_dynamic_config_t *pdata)
charlesmn 0:c1910e04fc6c 782 {
charlesmn 0:c1910e04fc6c 783
charlesmn 0:c1910e04fc6c 784 return VL53LX_get_dynamic_config( Dev,pdata);
charlesmn 0:c1910e04fc6c 785
charlesmn 0:c1910e04fc6c 786 }
charlesmn 0:c1910e04fc6c 787
charlesmn 0:c1910e04fc6c 788 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_system_control(
charlesmn 0:c1910e04fc6c 789 VL53LX_system_control_t *pdata,
charlesmn 0:c1910e04fc6c 790 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 791 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 792 {
charlesmn 0:c1910e04fc6c 793
charlesmn 0:c1910e04fc6c 794 return VL53LX_i2c_encode_system_control( pdata,
charlesmn 0:c1910e04fc6c 795 buf_size,
charlesmn 0:c1910e04fc6c 796 pbuffer);
charlesmn 0:c1910e04fc6c 797
charlesmn 0:c1910e04fc6c 798 }
charlesmn 0:c1910e04fc6c 799
charlesmn 0:c1910e04fc6c 800 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_system_control(
charlesmn 0:c1910e04fc6c 801 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 802 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 803 VL53LX_system_control_t *pdata)
charlesmn 0:c1910e04fc6c 804 {
charlesmn 0:c1910e04fc6c 805
charlesmn 0:c1910e04fc6c 806
charlesmn 0:c1910e04fc6c 807 return VL53LX_i2c_decode_system_control(
charlesmn 0:c1910e04fc6c 808 buf_size,
charlesmn 0:c1910e04fc6c 809 pbuffer,
charlesmn 0:c1910e04fc6c 810 pdata);
charlesmn 0:c1910e04fc6c 811
charlesmn 0:c1910e04fc6c 812
charlesmn 0:c1910e04fc6c 813
charlesmn 0:c1910e04fc6c 814 }
charlesmn 0:c1910e04fc6c 815
charlesmn 0:c1910e04fc6c 816
charlesmn 0:c1910e04fc6c 817 VL53LX_Error VL53L3CX::VL53L3CX_set_system_control(
charlesmn 0:c1910e04fc6c 818 VL53LX_system_control_t *pdata)
charlesmn 0:c1910e04fc6c 819 {
charlesmn 0:c1910e04fc6c 820
charlesmn 0:c1910e04fc6c 821 return VL53LX_set_system_control(Dev,pdata);
charlesmn 0:c1910e04fc6c 822
charlesmn 0:c1910e04fc6c 823 }
charlesmn 0:c1910e04fc6c 824
charlesmn 0:c1910e04fc6c 825
charlesmn 0:c1910e04fc6c 826 VL53LX_Error VL53L3CX::VL53L3CX_get_system_control(
charlesmn 0:c1910e04fc6c 827 VL53LX_system_control_t *pdata)
charlesmn 0:c1910e04fc6c 828 {
charlesmn 0:c1910e04fc6c 829
charlesmn 0:c1910e04fc6c 830 return VL53LX_get_system_control(Dev,pdata);
charlesmn 0:c1910e04fc6c 831
charlesmn 0:c1910e04fc6c 832 }
charlesmn 0:c1910e04fc6c 833
charlesmn 0:c1910e04fc6c 834
charlesmn 0:c1910e04fc6c 835 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_system_results(
charlesmn 0:c1910e04fc6c 836 VL53LX_system_results_t *pdata,
charlesmn 0:c1910e04fc6c 837 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 838 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 839 {
charlesmn 0:c1910e04fc6c 840
charlesmn 0:c1910e04fc6c 841 return VL53LX_i2c_encode_system_results(pdata,
charlesmn 0:c1910e04fc6c 842 buf_size,
charlesmn 0:c1910e04fc6c 843 pbuffer);
charlesmn 0:c1910e04fc6c 844
charlesmn 0:c1910e04fc6c 845 }
charlesmn 0:c1910e04fc6c 846
charlesmn 0:c1910e04fc6c 847 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_system_results(
charlesmn 0:c1910e04fc6c 848 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 849 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 850 VL53LX_system_results_t *pdata)
charlesmn 0:c1910e04fc6c 851 {
charlesmn 0:c1910e04fc6c 852
charlesmn 0:c1910e04fc6c 853
charlesmn 0:c1910e04fc6c 854 return VL53LX_i2c_decode_system_results( buf_size,pbuffer,pdata);
charlesmn 0:c1910e04fc6c 855
charlesmn 0:c1910e04fc6c 856 }
charlesmn 0:c1910e04fc6c 857
charlesmn 0:c1910e04fc6c 858 VL53LX_Error VL53L3CX::VL53L3CX_set_system_results(
charlesmn 0:c1910e04fc6c 859 VL53LX_system_results_t *pdata)
charlesmn 0:c1910e04fc6c 860 {
charlesmn 0:c1910e04fc6c 861
charlesmn 0:c1910e04fc6c 862 return VL53LX_set_system_results(Dev,pdata);
charlesmn 0:c1910e04fc6c 863
charlesmn 0:c1910e04fc6c 864 }
charlesmn 0:c1910e04fc6c 865
charlesmn 0:c1910e04fc6c 866 VL53LX_Error VL53L3CX::VL53L3CX_get_system_results(
charlesmn 0:c1910e04fc6c 867 VL53LX_system_results_t *pdata)
charlesmn 0:c1910e04fc6c 868 {
charlesmn 0:c1910e04fc6c 869
charlesmn 0:c1910e04fc6c 870 return VL53LX_get_system_results(Dev,pdata);
charlesmn 0:c1910e04fc6c 871
charlesmn 0:c1910e04fc6c 872 }
charlesmn 0:c1910e04fc6c 873 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_core_results(
charlesmn 0:c1910e04fc6c 874 VL53LX_core_results_t *pdata,
charlesmn 0:c1910e04fc6c 875 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 876 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 877 {
charlesmn 0:c1910e04fc6c 878
charlesmn 0:c1910e04fc6c 879
charlesmn 0:c1910e04fc6c 880 return VL53LX_i2c_encode_core_results(
charlesmn 0:c1910e04fc6c 881 pdata,
charlesmn 0:c1910e04fc6c 882 buf_size,
charlesmn 0:c1910e04fc6c 883 pbuffer);
charlesmn 0:c1910e04fc6c 884
charlesmn 0:c1910e04fc6c 885 }
charlesmn 0:c1910e04fc6c 886
charlesmn 0:c1910e04fc6c 887
charlesmn 0:c1910e04fc6c 888 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_core_results(
charlesmn 0:c1910e04fc6c 889 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 890 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 891 VL53LX_core_results_t *pdata)
charlesmn 0:c1910e04fc6c 892 {
charlesmn 0:c1910e04fc6c 893
charlesmn 0:c1910e04fc6c 894
charlesmn 0:c1910e04fc6c 895 return VL53LX_i2c_decode_core_results( buf_size,
charlesmn 0:c1910e04fc6c 896 pbuffer,
charlesmn 0:c1910e04fc6c 897 pdata);
charlesmn 0:c1910e04fc6c 898 }
charlesmn 0:c1910e04fc6c 899
charlesmn 0:c1910e04fc6c 900 VL53LX_Error VL53L3CX::VL53L3CX_set_core_results(
charlesmn 0:c1910e04fc6c 901 VL53LX_core_results_t *pdata)
charlesmn 0:c1910e04fc6c 902 {
charlesmn 0:c1910e04fc6c 903
charlesmn 0:c1910e04fc6c 904 return VL53LX_set_core_results( Dev, pdata);
charlesmn 0:c1910e04fc6c 905
charlesmn 0:c1910e04fc6c 906 }
charlesmn 0:c1910e04fc6c 907
charlesmn 0:c1910e04fc6c 908
charlesmn 0:c1910e04fc6c 909 VL53LX_Error VL53L3CX::VL53L3CX_get_core_results(
charlesmn 0:c1910e04fc6c 910 VL53LX_core_results_t *pdata)
charlesmn 0:c1910e04fc6c 911 {
charlesmn 0:c1910e04fc6c 912
charlesmn 0:c1910e04fc6c 913 return VL53LX_get_core_results( Dev, pdata);
charlesmn 0:c1910e04fc6c 914
charlesmn 0:c1910e04fc6c 915 }
charlesmn 0:c1910e04fc6c 916
charlesmn 0:c1910e04fc6c 917 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_debug_results(
charlesmn 0:c1910e04fc6c 918 VL53LX_debug_results_t *pdata,
charlesmn 0:c1910e04fc6c 919 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 920 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 921 {
charlesmn 0:c1910e04fc6c 922
charlesmn 0:c1910e04fc6c 923 return VL53LX_i2c_encode_debug_results(pdata, buf_size, pbuffer);
charlesmn 0:c1910e04fc6c 924
charlesmn 0:c1910e04fc6c 925
charlesmn 0:c1910e04fc6c 926 }
charlesmn 0:c1910e04fc6c 927
charlesmn 0:c1910e04fc6c 928 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_debug_results(
charlesmn 0:c1910e04fc6c 929 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 930 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 931 VL53LX_debug_results_t *pdata)
charlesmn 0:c1910e04fc6c 932 {
charlesmn 0:c1910e04fc6c 933
charlesmn 0:c1910e04fc6c 934 return VL53LX_i2c_decode_debug_results(buf_size,pbuffer,pdata);
charlesmn 0:c1910e04fc6c 935
charlesmn 0:c1910e04fc6c 936 }
charlesmn 0:c1910e04fc6c 937
charlesmn 0:c1910e04fc6c 938 VL53LX_Error VL53L3CX::VL53L3CX_set_debug_results(
charlesmn 0:c1910e04fc6c 939 VL53LX_debug_results_t *pdata)
charlesmn 0:c1910e04fc6c 940 {
charlesmn 0:c1910e04fc6c 941
charlesmn 0:c1910e04fc6c 942 return VL53LX_set_debug_results(Dev, pdata);
charlesmn 0:c1910e04fc6c 943
charlesmn 0:c1910e04fc6c 944 }
charlesmn 0:c1910e04fc6c 945
charlesmn 0:c1910e04fc6c 946 VL53LX_Error VL53L3CX::VL53L3CX_get_debug_results(
charlesmn 0:c1910e04fc6c 947 VL53LX_debug_results_t *pdata)
charlesmn 0:c1910e04fc6c 948 {
charlesmn 0:c1910e04fc6c 949
charlesmn 0:c1910e04fc6c 950 return VL53LX_get_debug_results( Dev, pdata);
charlesmn 0:c1910e04fc6c 951
charlesmn 0:c1910e04fc6c 952 }
charlesmn 0:c1910e04fc6c 953
charlesmn 0:c1910e04fc6c 954 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_nvm_copy_data(
charlesmn 0:c1910e04fc6c 955 VL53LX_nvm_copy_data_t *pdata,
charlesmn 0:c1910e04fc6c 956 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 957 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 958 {
charlesmn 0:c1910e04fc6c 959
charlesmn 0:c1910e04fc6c 960 return VL53LX_i2c_encode_nvm_copy_data(pdata,buf_size,pbuffer);
charlesmn 0:c1910e04fc6c 961
charlesmn 0:c1910e04fc6c 962 }
charlesmn 0:c1910e04fc6c 963
charlesmn 0:c1910e04fc6c 964
charlesmn 0:c1910e04fc6c 965
charlesmn 0:c1910e04fc6c 966 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_nvm_copy_data(
charlesmn 0:c1910e04fc6c 967 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 968 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 969 VL53LX_nvm_copy_data_t *pdata)
charlesmn 0:c1910e04fc6c 970 {
charlesmn 0:c1910e04fc6c 971
charlesmn 0:c1910e04fc6c 972 return VL53LX_i2c_decode_nvm_copy_data(
charlesmn 0:c1910e04fc6c 973 buf_size,
charlesmn 0:c1910e04fc6c 974 pbuffer,
charlesmn 0:c1910e04fc6c 975 pdata);
charlesmn 0:c1910e04fc6c 976
charlesmn 0:c1910e04fc6c 977 }
charlesmn 0:c1910e04fc6c 978
charlesmn 0:c1910e04fc6c 979
charlesmn 0:c1910e04fc6c 980 VL53LX_Error VL53L3CX::VL53L3CX_set_nvm_copy_data(
charlesmn 0:c1910e04fc6c 981 VL53LX_nvm_copy_data_t *pdata)
charlesmn 0:c1910e04fc6c 982 {
charlesmn 0:c1910e04fc6c 983
charlesmn 0:c1910e04fc6c 984 return VL53LX_set_nvm_copy_data( Dev, pdata);
charlesmn 0:c1910e04fc6c 985
charlesmn 0:c1910e04fc6c 986 }
charlesmn 0:c1910e04fc6c 987
charlesmn 0:c1910e04fc6c 988 VL53LX_Error VL53L3CX::VL53L3CX_get_nvm_copy_data(
charlesmn 0:c1910e04fc6c 989 VL53LX_nvm_copy_data_t *pdata)
charlesmn 0:c1910e04fc6c 990 {
charlesmn 0:c1910e04fc6c 991
charlesmn 0:c1910e04fc6c 992 return VL53LX_get_nvm_copy_data(Dev, pdata);
charlesmn 0:c1910e04fc6c 993
charlesmn 0:c1910e04fc6c 994 }
charlesmn 0:c1910e04fc6c 995
charlesmn 0:c1910e04fc6c 996
charlesmn 0:c1910e04fc6c 997 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_prev_shadow_system_results(
charlesmn 0:c1910e04fc6c 998 VL53LX_prev_shadow_system_results_t *pdata,
charlesmn 0:c1910e04fc6c 999 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1000 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 1001 {
charlesmn 0:c1910e04fc6c 1002
charlesmn 0:c1910e04fc6c 1003 return VL53LX_i2c_encode_prev_shadow_system_results(
charlesmn 0:c1910e04fc6c 1004 pdata,
charlesmn 0:c1910e04fc6c 1005 buf_size,
charlesmn 0:c1910e04fc6c 1006 pbuffer);
charlesmn 0:c1910e04fc6c 1007
charlesmn 0:c1910e04fc6c 1008 }
charlesmn 0:c1910e04fc6c 1009
charlesmn 0:c1910e04fc6c 1010
charlesmn 0:c1910e04fc6c 1011
charlesmn 0:c1910e04fc6c 1012 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_prev_shadow_system_results(
charlesmn 0:c1910e04fc6c 1013 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1014 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 1015 VL53LX_prev_shadow_system_results_t *pdata)
charlesmn 0:c1910e04fc6c 1016 {
charlesmn 0:c1910e04fc6c 1017
charlesmn 0:c1910e04fc6c 1018 return VL53LX_i2c_decode_prev_shadow_system_results( buf_size, pbuffer, pdata);
charlesmn 0:c1910e04fc6c 1019
charlesmn 0:c1910e04fc6c 1020 }
charlesmn 0:c1910e04fc6c 1021
charlesmn 0:c1910e04fc6c 1022 VL53LX_Error VL53L3CX::VL53L3CX_set_prev_shadow_system_results(
charlesmn 0:c1910e04fc6c 1023 VL53LX_prev_shadow_system_results_t *pdata)
charlesmn 0:c1910e04fc6c 1024 {
charlesmn 0:c1910e04fc6c 1025
charlesmn 0:c1910e04fc6c 1026 return VL53LX_set_prev_shadow_system_results( Dev,pdata);
charlesmn 0:c1910e04fc6c 1027
charlesmn 0:c1910e04fc6c 1028 }
charlesmn 0:c1910e04fc6c 1029
charlesmn 0:c1910e04fc6c 1030 VL53LX_Error VL53L3CX::VL53L3CX_get_prev_shadow_system_results(
charlesmn 0:c1910e04fc6c 1031 VL53LX_prev_shadow_system_results_t *pdata)
charlesmn 0:c1910e04fc6c 1032 {
charlesmn 0:c1910e04fc6c 1033
charlesmn 0:c1910e04fc6c 1034 return VL53LX_get_prev_shadow_system_results( Dev,pdata);
charlesmn 0:c1910e04fc6c 1035
charlesmn 0:c1910e04fc6c 1036 }
charlesmn 0:c1910e04fc6c 1037 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_prev_shadow_core_results(
charlesmn 0:c1910e04fc6c 1038 VL53LX_prev_shadow_core_results_t *pdata,
charlesmn 0:c1910e04fc6c 1039 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1040 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 1041 {
charlesmn 0:c1910e04fc6c 1042
charlesmn 0:c1910e04fc6c 1043 return VL53LX_i2c_encode_prev_shadow_core_results( pdata, buf_size, pbuffer);
charlesmn 0:c1910e04fc6c 1044
charlesmn 0:c1910e04fc6c 1045 }
charlesmn 0:c1910e04fc6c 1046
charlesmn 0:c1910e04fc6c 1047 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_prev_shadow_core_results(
charlesmn 0:c1910e04fc6c 1048 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1049 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 1050 VL53LX_prev_shadow_core_results_t *pdata)
charlesmn 0:c1910e04fc6c 1051 {
charlesmn 0:c1910e04fc6c 1052
charlesmn 0:c1910e04fc6c 1053 return VL53LX_i2c_decode_prev_shadow_core_results( buf_size, pbuffer, pdata);
charlesmn 0:c1910e04fc6c 1054
charlesmn 0:c1910e04fc6c 1055 }
charlesmn 0:c1910e04fc6c 1056
charlesmn 0:c1910e04fc6c 1057 VL53LX_Error VL53L3CX::VL53L3CX_set_prev_shadow_core_results(
charlesmn 0:c1910e04fc6c 1058 VL53LX_prev_shadow_core_results_t *pdata)
charlesmn 0:c1910e04fc6c 1059 {
charlesmn 0:c1910e04fc6c 1060
charlesmn 0:c1910e04fc6c 1061 return VL53LX_set_prev_shadow_core_results(Dev, pdata);
charlesmn 0:c1910e04fc6c 1062
charlesmn 0:c1910e04fc6c 1063 }
charlesmn 0:c1910e04fc6c 1064
charlesmn 0:c1910e04fc6c 1065 VL53LX_Error VL53L3CX::VL53L3CX_get_prev_shadow_core_results(
charlesmn 0:c1910e04fc6c 1066 VL53LX_prev_shadow_core_results_t *pdata)
charlesmn 0:c1910e04fc6c 1067 {
charlesmn 0:c1910e04fc6c 1068
charlesmn 0:c1910e04fc6c 1069 return VL53LX_get_prev_shadow_core_results( Dev, pdata);
charlesmn 0:c1910e04fc6c 1070
charlesmn 0:c1910e04fc6c 1071 }
charlesmn 0:c1910e04fc6c 1072
charlesmn 0:c1910e04fc6c 1073 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_patch_debug(
charlesmn 0:c1910e04fc6c 1074 VL53LX_patch_debug_t *pdata,
charlesmn 0:c1910e04fc6c 1075 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1076 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 1077 {
charlesmn 0:c1910e04fc6c 1078
charlesmn 0:c1910e04fc6c 1079 return VL53LX_i2c_encode_patch_debug(
charlesmn 0:c1910e04fc6c 1080 pdata,
charlesmn 0:c1910e04fc6c 1081 buf_size,
charlesmn 0:c1910e04fc6c 1082 pbuffer);
charlesmn 0:c1910e04fc6c 1083
charlesmn 0:c1910e04fc6c 1084 }
charlesmn 0:c1910e04fc6c 1085
charlesmn 0:c1910e04fc6c 1086 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_patch_debug(
charlesmn 0:c1910e04fc6c 1087 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1088 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 1089 VL53LX_patch_debug_t *pdata)
charlesmn 0:c1910e04fc6c 1090 {
charlesmn 0:c1910e04fc6c 1091
charlesmn 0:c1910e04fc6c 1092 return VL53LX_i2c_decode_patch_debug(
charlesmn 0:c1910e04fc6c 1093 buf_size,
charlesmn 0:c1910e04fc6c 1094 pbuffer,
charlesmn 0:c1910e04fc6c 1095 pdata);
charlesmn 0:c1910e04fc6c 1096
charlesmn 0:c1910e04fc6c 1097 }
charlesmn 0:c1910e04fc6c 1098
charlesmn 0:c1910e04fc6c 1099 VL53LX_Error VL53L3CX::VL53L3CX_set_patch_debug(
charlesmn 0:c1910e04fc6c 1100 VL53LX_patch_debug_t *pdata)
charlesmn 0:c1910e04fc6c 1101 {
charlesmn 0:c1910e04fc6c 1102
charlesmn 0:c1910e04fc6c 1103 return VL53LX_set_patch_debug( Dev, pdata);
charlesmn 0:c1910e04fc6c 1104
charlesmn 0:c1910e04fc6c 1105 }
charlesmn 0:c1910e04fc6c 1106
charlesmn 0:c1910e04fc6c 1107 VL53LX_Error VL53L3CX::VL53L3CX_get_patch_debug(
charlesmn 0:c1910e04fc6c 1108 VL53LX_patch_debug_t *pdata)
charlesmn 0:c1910e04fc6c 1109 {
charlesmn 0:c1910e04fc6c 1110
charlesmn 0:c1910e04fc6c 1111 return VL53LX_get_patch_debug( Dev,pdata);
charlesmn 0:c1910e04fc6c 1112
charlesmn 0:c1910e04fc6c 1113 }
charlesmn 0:c1910e04fc6c 1114 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_gph_general_config(
charlesmn 0:c1910e04fc6c 1115 VL53LX_gph_general_config_t *pdata,
charlesmn 0:c1910e04fc6c 1116 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1117 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 1118 {
charlesmn 0:c1910e04fc6c 1119
charlesmn 0:c1910e04fc6c 1120 return VL53LX_i2c_encode_gph_general_config( pdata, buf_size, pbuffer);
charlesmn 0:c1910e04fc6c 1121
charlesmn 0:c1910e04fc6c 1122 }
charlesmn 0:c1910e04fc6c 1123 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_gph_general_config(
charlesmn 0:c1910e04fc6c 1124 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1125 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 1126 VL53LX_gph_general_config_t *pdata)
charlesmn 0:c1910e04fc6c 1127 {
charlesmn 0:c1910e04fc6c 1128
charlesmn 0:c1910e04fc6c 1129 return VL53LX_i2c_decode_gph_general_config( buf_size, pbuffer, pdata);
charlesmn 0:c1910e04fc6c 1130
charlesmn 0:c1910e04fc6c 1131 }
charlesmn 0:c1910e04fc6c 1132
charlesmn 0:c1910e04fc6c 1133 VL53LX_Error VL53L3CX::VL53L3CX_set_gph_general_config(
charlesmn 0:c1910e04fc6c 1134 VL53LX_gph_general_config_t *pdata)
charlesmn 0:c1910e04fc6c 1135 {
charlesmn 0:c1910e04fc6c 1136
charlesmn 0:c1910e04fc6c 1137 return VL53LX_set_gph_general_config( Dev, pdata);
charlesmn 0:c1910e04fc6c 1138
charlesmn 0:c1910e04fc6c 1139 }
charlesmn 0:c1910e04fc6c 1140 VL53LX_Error VL53L3CX::VL53L3CX_get_gph_general_config(
charlesmn 0:c1910e04fc6c 1141 VL53LX_gph_general_config_t *pdata)
charlesmn 0:c1910e04fc6c 1142 {
charlesmn 0:c1910e04fc6c 1143
charlesmn 0:c1910e04fc6c 1144 return VL53LX_get_gph_general_config( Dev, pdata);
charlesmn 0:c1910e04fc6c 1145
charlesmn 0:c1910e04fc6c 1146 }
charlesmn 0:c1910e04fc6c 1147
charlesmn 0:c1910e04fc6c 1148 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_gph_static_config(
charlesmn 0:c1910e04fc6c 1149 VL53LX_gph_static_config_t *pdata,
charlesmn 0:c1910e04fc6c 1150 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1151 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 1152 {
charlesmn 0:c1910e04fc6c 1153
charlesmn 0:c1910e04fc6c 1154
charlesmn 0:c1910e04fc6c 1155 return VL53LX_i2c_encode_gph_static_config(
charlesmn 0:c1910e04fc6c 1156 pdata,
charlesmn 0:c1910e04fc6c 1157 buf_size,
charlesmn 0:c1910e04fc6c 1158 pbuffer);
charlesmn 0:c1910e04fc6c 1159
charlesmn 0:c1910e04fc6c 1160
charlesmn 0:c1910e04fc6c 1161 }
charlesmn 0:c1910e04fc6c 1162 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_gph_static_config(
charlesmn 0:c1910e04fc6c 1163 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1164 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 1165 VL53LX_gph_static_config_t *pdata)
charlesmn 0:c1910e04fc6c 1166 {
charlesmn 0:c1910e04fc6c 1167
charlesmn 0:c1910e04fc6c 1168 return VL53LX_i2c_decode_gph_static_config(
charlesmn 0:c1910e04fc6c 1169 buf_size,
charlesmn 0:c1910e04fc6c 1170 pbuffer,
charlesmn 0:c1910e04fc6c 1171 pdata);
charlesmn 0:c1910e04fc6c 1172
charlesmn 0:c1910e04fc6c 1173 }
charlesmn 0:c1910e04fc6c 1174 VL53LX_Error VL53L3CX::VL53L3CX_set_gph_static_config(
charlesmn 0:c1910e04fc6c 1175 VL53LX_gph_static_config_t *pdata)
charlesmn 0:c1910e04fc6c 1176 {
charlesmn 0:c1910e04fc6c 1177
charlesmn 0:c1910e04fc6c 1178 return VL53LX_set_gph_static_config( Dev, pdata);
charlesmn 0:c1910e04fc6c 1179
charlesmn 0:c1910e04fc6c 1180 }
charlesmn 0:c1910e04fc6c 1181
charlesmn 0:c1910e04fc6c 1182 VL53LX_Error VL53L3CX::VL53L3CX_get_gph_static_config(
charlesmn 0:c1910e04fc6c 1183 VL53LX_gph_static_config_t *pdata)
charlesmn 0:c1910e04fc6c 1184 {
charlesmn 0:c1910e04fc6c 1185
charlesmn 0:c1910e04fc6c 1186 return VL53LX_get_gph_static_config( Dev,pdata);
charlesmn 0:c1910e04fc6c 1187
charlesmn 0:c1910e04fc6c 1188 }
charlesmn 0:c1910e04fc6c 1189
charlesmn 0:c1910e04fc6c 1190 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_gph_timing_config(
charlesmn 0:c1910e04fc6c 1191 VL53LX_gph_timing_config_t *pdata,
charlesmn 0:c1910e04fc6c 1192 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1193 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 1194 {
charlesmn 0:c1910e04fc6c 1195
charlesmn 0:c1910e04fc6c 1196 return VL53LX_i2c_encode_gph_timing_config( pdata,
charlesmn 0:c1910e04fc6c 1197 buf_size,
charlesmn 0:c1910e04fc6c 1198 pbuffer);
charlesmn 0:c1910e04fc6c 1199
charlesmn 0:c1910e04fc6c 1200
charlesmn 0:c1910e04fc6c 1201 }
charlesmn 0:c1910e04fc6c 1202
charlesmn 0:c1910e04fc6c 1203
charlesmn 0:c1910e04fc6c 1204 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_gph_timing_config(
charlesmn 0:c1910e04fc6c 1205 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1206 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 1207 VL53LX_gph_timing_config_t *pdata)
charlesmn 0:c1910e04fc6c 1208 {
charlesmn 0:c1910e04fc6c 1209
charlesmn 0:c1910e04fc6c 1210 return VL53LX_i2c_decode_gph_timing_config(
charlesmn 0:c1910e04fc6c 1211 buf_size,
charlesmn 0:c1910e04fc6c 1212 pbuffer,
charlesmn 0:c1910e04fc6c 1213 pdata);
charlesmn 0:c1910e04fc6c 1214
charlesmn 0:c1910e04fc6c 1215 }
charlesmn 0:c1910e04fc6c 1216
charlesmn 0:c1910e04fc6c 1217 VL53LX_Error VL53L3CX::VL53L3CX_set_gph_timing_config(
charlesmn 0:c1910e04fc6c 1218 VL53LX_gph_timing_config_t *pdata)
charlesmn 0:c1910e04fc6c 1219 {
charlesmn 0:c1910e04fc6c 1220
charlesmn 0:c1910e04fc6c 1221 return VL53LX_set_gph_timing_config( Dev,pdata);
charlesmn 0:c1910e04fc6c 1222
charlesmn 0:c1910e04fc6c 1223 }
charlesmn 0:c1910e04fc6c 1224
charlesmn 0:c1910e04fc6c 1225 VL53LX_Error VL53L3CX::VL53L3CX_get_gph_timing_config(
charlesmn 0:c1910e04fc6c 1226 VL53LX_gph_timing_config_t *pdata)
charlesmn 0:c1910e04fc6c 1227 {
charlesmn 0:c1910e04fc6c 1228
charlesmn 0:c1910e04fc6c 1229 return VL53LX_get_gph_timing_config(Dev, pdata);
charlesmn 0:c1910e04fc6c 1230
charlesmn 0:c1910e04fc6c 1231 }
charlesmn 0:c1910e04fc6c 1232
charlesmn 0:c1910e04fc6c 1233 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_fw_internal(
charlesmn 0:c1910e04fc6c 1234 VL53LX_fw_internal_t *pdata,
charlesmn 0:c1910e04fc6c 1235 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1236 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 1237 {
charlesmn 0:c1910e04fc6c 1238
charlesmn 0:c1910e04fc6c 1239 return VL53LX_i2c_encode_fw_internal(
charlesmn 0:c1910e04fc6c 1240 pdata,
charlesmn 0:c1910e04fc6c 1241 buf_size,
charlesmn 0:c1910e04fc6c 1242 pbuffer);
charlesmn 0:c1910e04fc6c 1243
charlesmn 0:c1910e04fc6c 1244 }
charlesmn 0:c1910e04fc6c 1245
charlesmn 0:c1910e04fc6c 1246 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_fw_internal(
charlesmn 0:c1910e04fc6c 1247 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1248 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 1249 VL53LX_fw_internal_t *pdata)
charlesmn 0:c1910e04fc6c 1250 {
charlesmn 0:c1910e04fc6c 1251
charlesmn 0:c1910e04fc6c 1252 return VL53LX_i2c_decode_fw_internal( buf_size, pbuffer, pdata);
charlesmn 0:c1910e04fc6c 1253
charlesmn 0:c1910e04fc6c 1254 }
charlesmn 0:c1910e04fc6c 1255
charlesmn 0:c1910e04fc6c 1256 VL53LX_Error VL53L3CX::VL53L3CX_set_fw_internal(
charlesmn 0:c1910e04fc6c 1257 VL53LX_fw_internal_t *pdata)
charlesmn 0:c1910e04fc6c 1258 {
charlesmn 0:c1910e04fc6c 1259
charlesmn 0:c1910e04fc6c 1260 return VL53LX_set_fw_internal( Dev,pdata);
charlesmn 0:c1910e04fc6c 1261
charlesmn 0:c1910e04fc6c 1262 }
charlesmn 0:c1910e04fc6c 1263 VL53LX_Error VL53L3CX::VL53L3CX_get_fw_internal(
charlesmn 0:c1910e04fc6c 1264 VL53LX_fw_internal_t *pdata)
charlesmn 0:c1910e04fc6c 1265 {
charlesmn 0:c1910e04fc6c 1266
charlesmn 0:c1910e04fc6c 1267 return VL53LX_get_fw_internal( Dev, pdata);
charlesmn 0:c1910e04fc6c 1268
charlesmn 0:c1910e04fc6c 1269 }
charlesmn 0:c1910e04fc6c 1270
charlesmn 0:c1910e04fc6c 1271 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_patch_results(
charlesmn 0:c1910e04fc6c 1272 VL53LX_patch_results_t *pdata,
charlesmn 0:c1910e04fc6c 1273 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1274 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 1275 {
charlesmn 0:c1910e04fc6c 1276
charlesmn 0:c1910e04fc6c 1277 return VL53LX_i2c_encode_patch_results(pdata, buf_size, pbuffer);
charlesmn 0:c1910e04fc6c 1278
charlesmn 0:c1910e04fc6c 1279 }
charlesmn 0:c1910e04fc6c 1280
charlesmn 0:c1910e04fc6c 1281 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_patch_results(
charlesmn 0:c1910e04fc6c 1282 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1283 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 1284 VL53LX_patch_results_t *pdata)
charlesmn 0:c1910e04fc6c 1285 {
charlesmn 0:c1910e04fc6c 1286 return VL53LX_i2c_decode_patch_results( buf_size, pbuffer, pdata);
charlesmn 0:c1910e04fc6c 1287 }
charlesmn 0:c1910e04fc6c 1288
charlesmn 0:c1910e04fc6c 1289
charlesmn 0:c1910e04fc6c 1290 VL53LX_Error VL53L3CX::VL53L3CX_set_patch_results(
charlesmn 0:c1910e04fc6c 1291 VL53LX_patch_results_t *pdata)
charlesmn 0:c1910e04fc6c 1292 {
charlesmn 0:c1910e04fc6c 1293
charlesmn 0:c1910e04fc6c 1294 return VL53LX_set_patch_results( Dev, pdata);
charlesmn 0:c1910e04fc6c 1295
charlesmn 0:c1910e04fc6c 1296 }
charlesmn 0:c1910e04fc6c 1297
charlesmn 0:c1910e04fc6c 1298 VL53LX_Error VL53L3CX::VL53L3CX_get_patch_results(
charlesmn 0:c1910e04fc6c 1299 VL53LX_patch_results_t *pdata)
charlesmn 0:c1910e04fc6c 1300 {
charlesmn 0:c1910e04fc6c 1301
charlesmn 0:c1910e04fc6c 1302 return VL53LX_get_patch_results( Dev, pdata);
charlesmn 0:c1910e04fc6c 1303 }
charlesmn 0:c1910e04fc6c 1304
charlesmn 0:c1910e04fc6c 1305 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_shadow_system_results(
charlesmn 0:c1910e04fc6c 1306 VL53LX_shadow_system_results_t *pdata,
charlesmn 0:c1910e04fc6c 1307 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1308 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 1309 {
charlesmn 0:c1910e04fc6c 1310 return VL53LX_i2c_encode_shadow_system_results(pdata,buf_size,pbuffer);
charlesmn 0:c1910e04fc6c 1311 }
charlesmn 0:c1910e04fc6c 1312
charlesmn 0:c1910e04fc6c 1313 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_shadow_system_results(
charlesmn 0:c1910e04fc6c 1314 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1315 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 1316 VL53LX_shadow_system_results_t *pdata)
charlesmn 0:c1910e04fc6c 1317 {
charlesmn 0:c1910e04fc6c 1318 return VL53LX_i2c_decode_shadow_system_results( buf_size, pbuffer,pdata);
charlesmn 0:c1910e04fc6c 1319 }
charlesmn 0:c1910e04fc6c 1320
charlesmn 0:c1910e04fc6c 1321 VL53LX_Error VL53L3CX::VL53L3CX_set_shadow_system_results(
charlesmn 0:c1910e04fc6c 1322 VL53LX_shadow_system_results_t *pdata)
charlesmn 0:c1910e04fc6c 1323 {
charlesmn 0:c1910e04fc6c 1324
charlesmn 0:c1910e04fc6c 1325 return VL53LX_set_shadow_system_results( Dev, pdata);
charlesmn 0:c1910e04fc6c 1326
charlesmn 0:c1910e04fc6c 1327 }
charlesmn 0:c1910e04fc6c 1328
charlesmn 0:c1910e04fc6c 1329
charlesmn 0:c1910e04fc6c 1330 VL53LX_Error VL53L3CX::VL53L3CX_get_shadow_system_results(
charlesmn 0:c1910e04fc6c 1331 VL53LX_shadow_system_results_t *pdata)
charlesmn 0:c1910e04fc6c 1332 {
charlesmn 0:c1910e04fc6c 1333
charlesmn 0:c1910e04fc6c 1334 return VL53LX_get_shadow_system_results( Dev, pdata);
charlesmn 0:c1910e04fc6c 1335
charlesmn 0:c1910e04fc6c 1336 }
charlesmn 0:c1910e04fc6c 1337
charlesmn 0:c1910e04fc6c 1338 VL53LX_Error VL53L3CX::VL53L3CX_i2c_encode_shadow_core_results(
charlesmn 0:c1910e04fc6c 1339 VL53LX_shadow_core_results_t *pdata,
charlesmn 0:c1910e04fc6c 1340 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1341 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 1342 {
charlesmn 0:c1910e04fc6c 1343
charlesmn 0:c1910e04fc6c 1344 return VL53LX_i2c_encode_shadow_core_results( pdata, buf_size, pbuffer);
charlesmn 0:c1910e04fc6c 1345
charlesmn 0:c1910e04fc6c 1346 }
charlesmn 0:c1910e04fc6c 1347
charlesmn 0:c1910e04fc6c 1348 VL53LX_Error VL53L3CX::VL53L3CX_i2c_decode_shadow_core_results(
charlesmn 0:c1910e04fc6c 1349 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1350 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 1351 VL53LX_shadow_core_results_t *pdata)
charlesmn 0:c1910e04fc6c 1352 {
charlesmn 0:c1910e04fc6c 1353
charlesmn 0:c1910e04fc6c 1354 return VL53LX_i2c_decode_shadow_core_results( buf_size,pbuffer,pdata);
charlesmn 0:c1910e04fc6c 1355
charlesmn 0:c1910e04fc6c 1356 }
charlesmn 0:c1910e04fc6c 1357
charlesmn 0:c1910e04fc6c 1358 VL53LX_Error VL53L3CX::VL53L3CX_set_shadow_core_results(
charlesmn 0:c1910e04fc6c 1359 VL53LX_shadow_core_results_t *pdata)
charlesmn 0:c1910e04fc6c 1360 {
charlesmn 0:c1910e04fc6c 1361
charlesmn 0:c1910e04fc6c 1362 return VL53LX_set_shadow_core_results( Dev,pdata);
charlesmn 0:c1910e04fc6c 1363
charlesmn 0:c1910e04fc6c 1364 }
charlesmn 0:c1910e04fc6c 1365
charlesmn 0:c1910e04fc6c 1366 VL53LX_Error VL53L3CX::VL53L3CX_get_shadow_core_results(
charlesmn 0:c1910e04fc6c 1367 VL53LX_shadow_core_results_t *pdata)
charlesmn 0:c1910e04fc6c 1368 {
charlesmn 0:c1910e04fc6c 1369
charlesmn 0:c1910e04fc6c 1370 return VL53LX_get_shadow_core_results( Dev,pdata);
charlesmn 0:c1910e04fc6c 1371
charlesmn 0:c1910e04fc6c 1372 }
charlesmn 0:c1910e04fc6c 1373
charlesmn 0:c1910e04fc6c 1374
charlesmn 0:c1910e04fc6c 1375 /* vl53lx_nvm.c */
charlesmn 0:c1910e04fc6c 1376
charlesmn 0:c1910e04fc6c 1377 VL53LX_Error VL53L3CX::VL53L3CX_nvm_enable(
charlesmn 0:c1910e04fc6c 1378 uint16_t nvm_ctrl_pulse_width,
charlesmn 0:c1910e04fc6c 1379 int32_t nvm_power_up_delay_us)
charlesmn 0:c1910e04fc6c 1380 {
charlesmn 0:c1910e04fc6c 1381
charlesmn 0:c1910e04fc6c 1382 return VL53LX_nvm_enable(Dev, nvm_ctrl_pulse_width, nvm_power_up_delay_us);
charlesmn 0:c1910e04fc6c 1383
charlesmn 0:c1910e04fc6c 1384 }
charlesmn 0:c1910e04fc6c 1385
charlesmn 0:c1910e04fc6c 1386 VL53LX_Error VL53L3CX::VL53L3CX_nvm_read(
charlesmn 0:c1910e04fc6c 1387 uint8_t start_address,
charlesmn 0:c1910e04fc6c 1388 uint8_t count,
charlesmn 0:c1910e04fc6c 1389 uint8_t *pdata)
charlesmn 0:c1910e04fc6c 1390 {
charlesmn 0:c1910e04fc6c 1391
charlesmn 0:c1910e04fc6c 1392 return VL53LX_nvm_read( Dev, start_address, count, pdata);
charlesmn 0:c1910e04fc6c 1393
charlesmn 0:c1910e04fc6c 1394 }
charlesmn 0:c1910e04fc6c 1395
charlesmn 0:c1910e04fc6c 1396 VL53LX_Error VL53L3CX::VL53L3CX_nvm_disable()
charlesmn 0:c1910e04fc6c 1397 {
charlesmn 0:c1910e04fc6c 1398
charlesmn 0:c1910e04fc6c 1399 return VL53LX_nvm_disable( Dev );
charlesmn 0:c1910e04fc6c 1400
charlesmn 0:c1910e04fc6c 1401 }
charlesmn 0:c1910e04fc6c 1402
charlesmn 0:c1910e04fc6c 1403
charlesmn 0:c1910e04fc6c 1404 VL53LX_Error VL53L3CX::VL53L3CX_nvm_format_decode(
charlesmn 0:c1910e04fc6c 1405 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1406 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 1407 VL53LX_decoded_nvm_data_t *pdata)
charlesmn 0:c1910e04fc6c 1408 {
charlesmn 0:c1910e04fc6c 1409
charlesmn 0:c1910e04fc6c 1410 return VL53LX_nvm_disable( Dev );
charlesmn 0:c1910e04fc6c 1411
charlesmn 0:c1910e04fc6c 1412 }
charlesmn 0:c1910e04fc6c 1413 VL53LX_Error VL53L3CX::VL53L3CX_nvm_decode_optical_centre(
charlesmn 0:c1910e04fc6c 1414 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1415 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 1416 VL53LX_optical_centre_t *pdata)
charlesmn 0:c1910e04fc6c 1417 {
charlesmn 0:c1910e04fc6c 1418
charlesmn 0:c1910e04fc6c 1419 return VL53LX_nvm_decode_optical_centre( buf_size, pbuffer, pdata);
charlesmn 0:c1910e04fc6c 1420
charlesmn 0:c1910e04fc6c 1421 }
charlesmn 0:c1910e04fc6c 1422
charlesmn 0:c1910e04fc6c 1423 VL53LX_Error VL53L3CX::VL53L3CX_nvm_decode_cal_peak_rate_map(
charlesmn 0:c1910e04fc6c 1424 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1425 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 1426 VL53LX_cal_peak_rate_map_t *pdata)
charlesmn 0:c1910e04fc6c 1427 {
charlesmn 0:c1910e04fc6c 1428
charlesmn 0:c1910e04fc6c 1429 return VL53LX_nvm_decode_cal_peak_rate_map( buf_size, pbuffer, pdata);
charlesmn 0:c1910e04fc6c 1430
charlesmn 0:c1910e04fc6c 1431 }
charlesmn 0:c1910e04fc6c 1432
charlesmn 0:c1910e04fc6c 1433 VL53LX_Error VL53L3CX::VL53L3CX_nvm_decode_additional_offset_cal_data(
charlesmn 0:c1910e04fc6c 1434 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1435 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 1436 VL53LX_additional_offset_cal_data_t *pdata)
charlesmn 0:c1910e04fc6c 1437 {
charlesmn 0:c1910e04fc6c 1438
charlesmn 0:c1910e04fc6c 1439 return VL53LX_nvm_decode_additional_offset_cal_data( buf_size, pbuffer, pdata);
charlesmn 0:c1910e04fc6c 1440
charlesmn 0:c1910e04fc6c 1441 }
charlesmn 0:c1910e04fc6c 1442
charlesmn 0:c1910e04fc6c 1443
charlesmn 0:c1910e04fc6c 1444 VL53LX_Error VL53L3CX::VL53L3CX_nvm_decode_fmt_range_results_data(
charlesmn 0:c1910e04fc6c 1445 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1446 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 1447 VL53LX_decoded_nvm_fmt_range_data_t *pdata)
charlesmn 0:c1910e04fc6c 1448 {
charlesmn 0:c1910e04fc6c 1449
charlesmn 0:c1910e04fc6c 1450 return VL53LX_nvm_decode_fmt_range_results_data( buf_size, pbuffer,pdata);
charlesmn 0:c1910e04fc6c 1451
charlesmn 0:c1910e04fc6c 1452 }
charlesmn 0:c1910e04fc6c 1453
charlesmn 0:c1910e04fc6c 1454
charlesmn 0:c1910e04fc6c 1455 VL53LX_Error VL53L3CX::VL53L3CX_nvm_decode_fmt_info(
charlesmn 0:c1910e04fc6c 1456 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1457 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 1458 VL53LX_decoded_nvm_fmt_info_t *pdata)
charlesmn 0:c1910e04fc6c 1459 {
charlesmn 0:c1910e04fc6c 1460
charlesmn 0:c1910e04fc6c 1461 return VL53LX_nvm_decode_fmt_info( buf_size, pbuffer, pdata);
charlesmn 0:c1910e04fc6c 1462
charlesmn 0:c1910e04fc6c 1463 }
charlesmn 0:c1910e04fc6c 1464
charlesmn 0:c1910e04fc6c 1465
charlesmn 0:c1910e04fc6c 1466 VL53LX_Error VL53L3CX::VL53L3CX_nvm_decode_ews_info(
charlesmn 0:c1910e04fc6c 1467 uint16_t buf_size,
charlesmn 0:c1910e04fc6c 1468 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 1469 VL53LX_decoded_nvm_ews_info_t *pdata)
charlesmn 0:c1910e04fc6c 1470 {
charlesmn 0:c1910e04fc6c 1471
charlesmn 0:c1910e04fc6c 1472
charlesmn 0:c1910e04fc6c 1473 return VL53LX_nvm_decode_ews_info(
charlesmn 0:c1910e04fc6c 1474 buf_size,
charlesmn 0:c1910e04fc6c 1475 pbuffer,
charlesmn 0:c1910e04fc6c 1476 pdata);
charlesmn 0:c1910e04fc6c 1477
charlesmn 0:c1910e04fc6c 1478
charlesmn 0:c1910e04fc6c 1479 }
charlesmn 0:c1910e04fc6c 1480
charlesmn 0:c1910e04fc6c 1481
charlesmn 0:c1910e04fc6c 1482 void VL53L3CX::VL53L3CX_nvm_format_encode(
charlesmn 0:c1910e04fc6c 1483 VL53LX_decoded_nvm_data_t *pnvm_info,
charlesmn 0:c1910e04fc6c 1484 uint8_t *pnvm_data)
charlesmn 0:c1910e04fc6c 1485 {
charlesmn 0:c1910e04fc6c 1486 SUPPRESS_UNUSED_WARNING(pnvm_info);
charlesmn 0:c1910e04fc6c 1487 SUPPRESS_UNUSED_WARNING(pnvm_data);
charlesmn 0:c1910e04fc6c 1488 }
charlesmn 0:c1910e04fc6c 1489
charlesmn 0:c1910e04fc6c 1490 VL53LX_Error VL53L3CX::VL53L3CX_read_nvm_raw_data(
charlesmn 0:c1910e04fc6c 1491 uint8_t start_address,
charlesmn 0:c1910e04fc6c 1492 uint8_t count,
charlesmn 0:c1910e04fc6c 1493 uint8_t *pnvm_raw_data)
charlesmn 0:c1910e04fc6c 1494 {
charlesmn 0:c1910e04fc6c 1495
charlesmn 0:c1910e04fc6c 1496 return VL53LX_read_nvm_raw_data(
charlesmn 0:c1910e04fc6c 1497 Dev,
charlesmn 0:c1910e04fc6c 1498 start_address,
charlesmn 0:c1910e04fc6c 1499 count,
charlesmn 0:c1910e04fc6c 1500 pnvm_raw_data);
charlesmn 0:c1910e04fc6c 1501
charlesmn 0:c1910e04fc6c 1502 }
charlesmn 0:c1910e04fc6c 1503
charlesmn 0:c1910e04fc6c 1504 VL53LX_Error VL53L3CX::VL53L3CX_read_nvm(
charlesmn 0:c1910e04fc6c 1505 uint8_t nvm_format,
charlesmn 0:c1910e04fc6c 1506 VL53LX_decoded_nvm_data_t *pnvm_info)
charlesmn 0:c1910e04fc6c 1507 {
charlesmn 0:c1910e04fc6c 1508
charlesmn 0:c1910e04fc6c 1509 return VL53LX_read_nvm(Dev, nvm_format,pnvm_info);
charlesmn 0:c1910e04fc6c 1510
charlesmn 0:c1910e04fc6c 1511 }
charlesmn 0:c1910e04fc6c 1512
charlesmn 0:c1910e04fc6c 1513 VL53LX_Error VL53L3CX::VL53L3CX_read_nvm_optical_centre(
charlesmn 0:c1910e04fc6c 1514 VL53LX_optical_centre_t *pcentre)
charlesmn 0:c1910e04fc6c 1515 {
charlesmn 0:c1910e04fc6c 1516
charlesmn 0:c1910e04fc6c 1517 return VL53LX_read_nvm_optical_centre(
charlesmn 0:c1910e04fc6c 1518 Dev,
charlesmn 0:c1910e04fc6c 1519 pcentre);
charlesmn 0:c1910e04fc6c 1520
charlesmn 0:c1910e04fc6c 1521 }
charlesmn 0:c1910e04fc6c 1522
charlesmn 0:c1910e04fc6c 1523 VL53LX_Error VL53L3CX::VL53L3CX_read_nvm_cal_peak_rate_map(
charlesmn 0:c1910e04fc6c 1524 VL53LX_cal_peak_rate_map_t *pcal_data)
charlesmn 0:c1910e04fc6c 1525 {
charlesmn 0:c1910e04fc6c 1526
charlesmn 0:c1910e04fc6c 1527
charlesmn 0:c1910e04fc6c 1528 return VL53LX_read_nvm_cal_peak_rate_map(
charlesmn 0:c1910e04fc6c 1529 Dev,
charlesmn 0:c1910e04fc6c 1530 pcal_data);
charlesmn 0:c1910e04fc6c 1531
charlesmn 0:c1910e04fc6c 1532 }
charlesmn 0:c1910e04fc6c 1533
charlesmn 0:c1910e04fc6c 1534
charlesmn 0:c1910e04fc6c 1535 VL53LX_Error VL53L3CX::VL53L3CX_read_nvm_additional_offset_cal_data(
charlesmn 0:c1910e04fc6c 1536 VL53LX_additional_offset_cal_data_t *pcal_data)
charlesmn 0:c1910e04fc6c 1537 {
charlesmn 0:c1910e04fc6c 1538
charlesmn 0:c1910e04fc6c 1539 return VL53LX_read_nvm_additional_offset_cal_data(
charlesmn 0:c1910e04fc6c 1540 Dev,
charlesmn 0:c1910e04fc6c 1541 pcal_data);
charlesmn 0:c1910e04fc6c 1542
charlesmn 0:c1910e04fc6c 1543 }
charlesmn 0:c1910e04fc6c 1544
charlesmn 0:c1910e04fc6c 1545 VL53LX_Error VL53L3CX::VL53L3CX_read_nvm_fmt_range_results_data(
charlesmn 0:c1910e04fc6c 1546 uint16_t range_results_select,
charlesmn 0:c1910e04fc6c 1547 VL53LX_decoded_nvm_fmt_range_data_t *prange_data)
charlesmn 0:c1910e04fc6c 1548 {
charlesmn 0:c1910e04fc6c 1549 return VL53LX_read_nvm_fmt_range_results_data(
charlesmn 0:c1910e04fc6c 1550 Dev,
charlesmn 0:c1910e04fc6c 1551 range_results_select,
charlesmn 0:c1910e04fc6c 1552 prange_data);
charlesmn 0:c1910e04fc6c 1553
charlesmn 0:c1910e04fc6c 1554 }
charlesmn 0:c1910e04fc6c 1555
charlesmn 0:c1910e04fc6c 1556 /* vl53lx_platform_ipp.c */
charlesmn 0:c1910e04fc6c 1557
charlesmn 0:c1910e04fc6c 1558 VL53LX_Error VL53L3CX::VL53L3CX_ipp_hist_process_data(
charlesmn 0:c1910e04fc6c 1559 VL53LX_dmax_calibration_data_t *pdmax_cal,
charlesmn 0:c1910e04fc6c 1560 VL53LX_hist_gen3_dmax_config_t *pdmax_cfg,
charlesmn 0:c1910e04fc6c 1561 VL53LX_hist_post_process_config_t *ppost_cfg,
charlesmn 0:c1910e04fc6c 1562 VL53LX_histogram_bin_data_t *pbins,
charlesmn 0:c1910e04fc6c 1563 VL53LX_xtalk_histogram_data_t *pxtalk,
charlesmn 0:c1910e04fc6c 1564 uint8_t *pArea1,
charlesmn 0:c1910e04fc6c 1565 uint8_t *pArea2,
charlesmn 0:c1910e04fc6c 1566 uint8_t *phisto_merge_nb,
charlesmn 0:c1910e04fc6c 1567 VL53LX_range_results_t *presults)
charlesmn 0:c1910e04fc6c 1568 {
charlesmn 0:c1910e04fc6c 1569
charlesmn 0:c1910e04fc6c 1570 return VL53L3CX_ipp_hist_process_data( pdmax_cal, pdmax_cfg,ppost_cfg,pbins,pxtalk,pArea1,pArea2,phisto_merge_nb,presults);
charlesmn 0:c1910e04fc6c 1571
charlesmn 0:c1910e04fc6c 1572 }
charlesmn 0:c1910e04fc6c 1573
charlesmn 0:c1910e04fc6c 1574
charlesmn 0:c1910e04fc6c 1575 VL53LX_Error VL53L3CX::VL53L3CX_ipp_hist_ambient_dmax(
charlesmn 0:c1910e04fc6c 1576 uint16_t target_reflectance,
charlesmn 0:c1910e04fc6c 1577 VL53LX_dmax_calibration_data_t *pdmax_cal,
charlesmn 0:c1910e04fc6c 1578 VL53LX_hist_gen3_dmax_config_t *pdmax_cfg,
charlesmn 0:c1910e04fc6c 1579 VL53LX_histogram_bin_data_t *pbins,
charlesmn 0:c1910e04fc6c 1580 int16_t *pambient_dmax_mm)
charlesmn 0:c1910e04fc6c 1581 {
charlesmn 0:c1910e04fc6c 1582
charlesmn 0:c1910e04fc6c 1583
charlesmn 0:c1910e04fc6c 1584 return VL53LX_ipp_hist_ambient_dmax( Dev,
charlesmn 0:c1910e04fc6c 1585 target_reflectance,
charlesmn 0:c1910e04fc6c 1586 pdmax_cal,
charlesmn 0:c1910e04fc6c 1587 pdmax_cfg,
charlesmn 0:c1910e04fc6c 1588 pbins,
charlesmn 0:c1910e04fc6c 1589 pambient_dmax_mm);
charlesmn 0:c1910e04fc6c 1590
charlesmn 0:c1910e04fc6c 1591
charlesmn 0:c1910e04fc6c 1592 }
charlesmn 0:c1910e04fc6c 1593
charlesmn 0:c1910e04fc6c 1594
charlesmn 0:c1910e04fc6c 1595 VL53LX_Error VL53L3CX::VL53L3CX_ipp_xtalk_calibration_process_data(
charlesmn 0:c1910e04fc6c 1596 VL53LX_xtalk_range_results_t *pxtalk_ranges,
charlesmn 0:c1910e04fc6c 1597 VL53LX_xtalk_histogram_data_t *pxtalk_shape,
charlesmn 0:c1910e04fc6c 1598 VL53LX_xtalk_calibration_results_t *pxtalk_cal)
charlesmn 0:c1910e04fc6c 1599 {
charlesmn 0:c1910e04fc6c 1600
charlesmn 0:c1910e04fc6c 1601 return VL53LX_ipp_xtalk_calibration_process_data( Dev,
charlesmn 0:c1910e04fc6c 1602 pxtalk_ranges,
charlesmn 0:c1910e04fc6c 1603 pxtalk_shape,
charlesmn 0:c1910e04fc6c 1604 pxtalk_cal);
charlesmn 0:c1910e04fc6c 1605
charlesmn 0:c1910e04fc6c 1606 }
charlesmn 0:c1910e04fc6c 1607
charlesmn 0:c1910e04fc6c 1608
charlesmn 0:c1910e04fc6c 1609
charlesmn 0:c1910e04fc6c 1610
charlesmn 0:c1910e04fc6c 1611 /* vl53lx_hist_funcs.c */
charlesmn 0:c1910e04fc6c 1612
charlesmn 0:c1910e04fc6c 1613 VL53LX_Error VL53L3CX::VL53L3CX_hist_process_data(
charlesmn 0:c1910e04fc6c 1614 VL53LX_dmax_calibration_data_t *pdmax_cal,
charlesmn 0:c1910e04fc6c 1615 VL53LX_hist_gen3_dmax_config_t *pdmax_cfg,
charlesmn 0:c1910e04fc6c 1616 VL53LX_hist_post_process_config_t *ppost_cfg,
charlesmn 0:c1910e04fc6c 1617 VL53LX_histogram_bin_data_t *pbins_input,
charlesmn 0:c1910e04fc6c 1618 VL53LX_xtalk_histogram_data_t *pxtalk_shape,
charlesmn 0:c1910e04fc6c 1619 uint8_t *pArea1,
charlesmn 0:c1910e04fc6c 1620 uint8_t *pArea2,
charlesmn 0:c1910e04fc6c 1621 VL53LX_range_results_t *presults,
charlesmn 0:c1910e04fc6c 1622 uint8_t *HistMergeNumber)
charlesmn 0:c1910e04fc6c 1623 {
charlesmn 0:c1910e04fc6c 1624
charlesmn 0:c1910e04fc6c 1625 return VL53LX_hist_process_data(pdmax_cal,pdmax_cfg,ppost_cfg,pbins_input,
charlesmn 0:c1910e04fc6c 1626 pxtalk_shape,pArea1,pArea2,presults,HistMergeNumber);
charlesmn 0:c1910e04fc6c 1627
charlesmn 0:c1910e04fc6c 1628 }
charlesmn 0:c1910e04fc6c 1629
charlesmn 0:c1910e04fc6c 1630 VL53LX_Error VL53L3CX::VL53L3CX_hist_ambient_dmax(
charlesmn 0:c1910e04fc6c 1631 uint16_t target_reflectance,
charlesmn 0:c1910e04fc6c 1632 VL53LX_dmax_calibration_data_t *pdmax_cal,
charlesmn 0:c1910e04fc6c 1633 VL53LX_hist_gen3_dmax_config_t *pdmax_cfg,
charlesmn 0:c1910e04fc6c 1634 VL53LX_histogram_bin_data_t *pbins,
charlesmn 0:c1910e04fc6c 1635 int16_t *pambient_dmax_mm)
charlesmn 0:c1910e04fc6c 1636 {
charlesmn 0:c1910e04fc6c 1637
charlesmn 0:c1910e04fc6c 1638 return VL53LX_hist_ambient_dmax(target_reflectance, pdmax_cal, pdmax_cfg, pbins,pambient_dmax_mm);
charlesmn 0:c1910e04fc6c 1639
charlesmn 0:c1910e04fc6c 1640 }
charlesmn 0:c1910e04fc6c 1641
charlesmn 0:c1910e04fc6c 1642 /* vl53lx_core_support.c */
charlesmn 0:c1910e04fc6c 1643
charlesmn 0:c1910e04fc6c 1644 uint32_t VL53L3CX::VL53L3CX_calc_pll_period_us(
charlesmn 0:c1910e04fc6c 1645 uint16_t fast_osc_frequency)
charlesmn 0:c1910e04fc6c 1646 {
charlesmn 0:c1910e04fc6c 1647
charlesmn 0:c1910e04fc6c 1648 return VL53LX_calc_pll_period_us(fast_osc_frequency);
charlesmn 0:c1910e04fc6c 1649
charlesmn 0:c1910e04fc6c 1650 }
charlesmn 0:c1910e04fc6c 1651
charlesmn 0:c1910e04fc6c 1652 uint32_t VL53L3CX::VL53L3CX_duration_maths(
charlesmn 0:c1910e04fc6c 1653 uint32_t pll_period_us,
charlesmn 0:c1910e04fc6c 1654 uint32_t vcsel_parm_pclks,
charlesmn 0:c1910e04fc6c 1655 uint32_t window_vclks,
charlesmn 0:c1910e04fc6c 1656 uint32_t elapsed_mclks)
charlesmn 0:c1910e04fc6c 1657 {
charlesmn 0:c1910e04fc6c 1658
charlesmn 0:c1910e04fc6c 1659 return VL53LX_duration_maths( pll_period_us,vcsel_parm_pclks,window_vclks,elapsed_mclks);
charlesmn 0:c1910e04fc6c 1660
charlesmn 0:c1910e04fc6c 1661 }
charlesmn 0:c1910e04fc6c 1662
charlesmn 0:c1910e04fc6c 1663 uint32_t VL53L3CX::VL53L3CX_events_per_spad_maths(
charlesmn 0:c1910e04fc6c 1664 int32_t VL53LX_p_010,
charlesmn 0:c1910e04fc6c 1665 uint16_t num_spads,
charlesmn 0:c1910e04fc6c 1666 uint32_t duration)
charlesmn 0:c1910e04fc6c 1667 {
charlesmn 0:c1910e04fc6c 1668
charlesmn 0:c1910e04fc6c 1669 return VL53LX_events_per_spad_maths( VL53LX_p_010,num_spads, duration);
charlesmn 0:c1910e04fc6c 1670
charlesmn 0:c1910e04fc6c 1671 }
charlesmn 0:c1910e04fc6c 1672
charlesmn 0:c1910e04fc6c 1673 uint32_t VL53L3CX::VL53L3CX_isqrt(uint32_t num)
charlesmn 0:c1910e04fc6c 1674 {
charlesmn 0:c1910e04fc6c 1675
charlesmn 0:c1910e04fc6c 1676 return VL53LX_isqrt(num);
charlesmn 0:c1910e04fc6c 1677
charlesmn 0:c1910e04fc6c 1678 }
charlesmn 0:c1910e04fc6c 1679
charlesmn 0:c1910e04fc6c 1680 void VL53L3CX::VL53L3CX_hist_calc_zero_distance_phase(
charlesmn 0:c1910e04fc6c 1681 VL53LX_histogram_bin_data_t *pdata)
charlesmn 0:c1910e04fc6c 1682 {
charlesmn 0:c1910e04fc6c 1683
charlesmn 0:c1910e04fc6c 1684 return VL53LX_hist_calc_zero_distance_phase(pdata);
charlesmn 0:c1910e04fc6c 1685
charlesmn 0:c1910e04fc6c 1686 }
charlesmn 0:c1910e04fc6c 1687
charlesmn 0:c1910e04fc6c 1688 void VL53L3CX::VL53L3CX_hist_estimate_ambient_from_thresholded_bins(
charlesmn 0:c1910e04fc6c 1689 int32_t ambient_threshold_sigma,
charlesmn 0:c1910e04fc6c 1690 VL53LX_histogram_bin_data_t *pdata)
charlesmn 0:c1910e04fc6c 1691 {
charlesmn 0:c1910e04fc6c 1692
charlesmn 0:c1910e04fc6c 1693 return VL53LX_hist_estimate_ambient_from_thresholded_bins( ambient_threshold_sigma, pdata);
charlesmn 0:c1910e04fc6c 1694
charlesmn 0:c1910e04fc6c 1695 }
charlesmn 0:c1910e04fc6c 1696
charlesmn 0:c1910e04fc6c 1697
charlesmn 0:c1910e04fc6c 1698 void VL53L3CX::VL53L3CX_hist_remove_ambient_bins(
charlesmn 0:c1910e04fc6c 1699 VL53LX_histogram_bin_data_t *pdata)
charlesmn 0:c1910e04fc6c 1700 {
charlesmn 0:c1910e04fc6c 1701
charlesmn 0:c1910e04fc6c 1702 return VL53LX_hist_remove_ambient_bins(pdata);
charlesmn 0:c1910e04fc6c 1703
charlesmn 0:c1910e04fc6c 1704 }
charlesmn 0:c1910e04fc6c 1705
charlesmn 0:c1910e04fc6c 1706
charlesmn 0:c1910e04fc6c 1707 uint32_t VL53L3CX::VL53L3CX_calc_pll_period_mm(
charlesmn 0:c1910e04fc6c 1708 uint16_t fast_osc_frequency)
charlesmn 0:c1910e04fc6c 1709 {
charlesmn 0:c1910e04fc6c 1710
charlesmn 0:c1910e04fc6c 1711 return VL53LX_calc_pll_period_mm( fast_osc_frequency);
charlesmn 0:c1910e04fc6c 1712
charlesmn 0:c1910e04fc6c 1713 }
charlesmn 0:c1910e04fc6c 1714
charlesmn 0:c1910e04fc6c 1715
charlesmn 0:c1910e04fc6c 1716 uint16_t VL53L3CX::VL53L3CX_rate_maths(
charlesmn 0:c1910e04fc6c 1717 int32_t VL53LX_p_018,
charlesmn 0:c1910e04fc6c 1718 uint32_t time_us)
charlesmn 0:c1910e04fc6c 1719 {
charlesmn 0:c1910e04fc6c 1720
charlesmn 0:c1910e04fc6c 1721 return VL53LX_rate_maths( VL53LX_p_018 , time_us);
charlesmn 0:c1910e04fc6c 1722
charlesmn 0:c1910e04fc6c 1723 }
charlesmn 0:c1910e04fc6c 1724
charlesmn 0:c1910e04fc6c 1725 uint16_t VL53L3CX::VL53L3CX_rate_per_spad_maths(
charlesmn 0:c1910e04fc6c 1726 uint32_t frac_bits,
charlesmn 0:c1910e04fc6c 1727 uint32_t peak_count_rate,
charlesmn 0:c1910e04fc6c 1728 uint16_t num_spads,
charlesmn 0:c1910e04fc6c 1729 uint32_t max_output_value)
charlesmn 0:c1910e04fc6c 1730 {
charlesmn 0:c1910e04fc6c 1731
charlesmn 0:c1910e04fc6c 1732 return VL53LX_rate_per_spad_maths( frac_bits,
charlesmn 0:c1910e04fc6c 1733 peak_count_rate,
charlesmn 0:c1910e04fc6c 1734 num_spads,
charlesmn 0:c1910e04fc6c 1735 max_output_value);
charlesmn 0:c1910e04fc6c 1736
charlesmn 0:c1910e04fc6c 1737 }
charlesmn 0:c1910e04fc6c 1738
charlesmn 0:c1910e04fc6c 1739 int32_t VL53L3CX::VL53L3CX_range_maths(
charlesmn 0:c1910e04fc6c 1740 uint16_t fast_osc_frequency,
charlesmn 0:c1910e04fc6c 1741 uint16_t VL53LX_p_014,
charlesmn 0:c1910e04fc6c 1742 uint16_t zero_distance_phase,
charlesmn 0:c1910e04fc6c 1743 uint8_t fractional_bits,
charlesmn 0:c1910e04fc6c 1744 int32_t gain_factor,
charlesmn 0:c1910e04fc6c 1745 int32_t range_offset_mm)
charlesmn 0:c1910e04fc6c 1746 {
charlesmn 0:c1910e04fc6c 1747
charlesmn 0:c1910e04fc6c 1748 return VL53LX_range_maths( fast_osc_frequency,
charlesmn 0:c1910e04fc6c 1749 VL53LX_p_014,
charlesmn 0:c1910e04fc6c 1750 zero_distance_phase,
charlesmn 0:c1910e04fc6c 1751 fractional_bits,
charlesmn 0:c1910e04fc6c 1752 gain_factor,
charlesmn 0:c1910e04fc6c 1753 range_offset_mm);
charlesmn 0:c1910e04fc6c 1754
charlesmn 0:c1910e04fc6c 1755 }
charlesmn 0:c1910e04fc6c 1756
charlesmn 0:c1910e04fc6c 1757 uint8_t VL53L3CX::VL53L3CX_decode_vcsel_period(uint8_t vcsel_period_reg)
charlesmn 0:c1910e04fc6c 1758 {
charlesmn 0:c1910e04fc6c 1759 return VL53LX_decode_vcsel_period( vcsel_period_reg);
charlesmn 0:c1910e04fc6c 1760
charlesmn 0:c1910e04fc6c 1761 }
charlesmn 0:c1910e04fc6c 1762
charlesmn 0:c1910e04fc6c 1763
charlesmn 0:c1910e04fc6c 1764 void VL53L3CX::VL53L3CX_copy_xtalk_bin_data_to_histogram_data_struct(
charlesmn 0:c1910e04fc6c 1765 VL53LX_xtalk_histogram_shape_t *pxtalk,
charlesmn 0:c1910e04fc6c 1766 VL53LX_histogram_bin_data_t *phist)
charlesmn 0:c1910e04fc6c 1767 {
charlesmn 0:c1910e04fc6c 1768
charlesmn 0:c1910e04fc6c 1769 VL53LX_copy_xtalk_bin_data_to_histogram_data_struct( pxtalk, phist);
charlesmn 0:c1910e04fc6c 1770
charlesmn 0:c1910e04fc6c 1771 }
charlesmn 0:c1910e04fc6c 1772
charlesmn 0:c1910e04fc6c 1773 void VL53L3CX::VL53L3CX_init_histogram_bin_data_struct(
charlesmn 0:c1910e04fc6c 1774 int32_t bin_value,
charlesmn 0:c1910e04fc6c 1775 uint16_t VL53LX_p_021,
charlesmn 0:c1910e04fc6c 1776 VL53LX_histogram_bin_data_t *pdata)
charlesmn 0:c1910e04fc6c 1777 {
charlesmn 0:c1910e04fc6c 1778
charlesmn 0:c1910e04fc6c 1779 VL53LX_init_histogram_bin_data_struct( bin_value,
charlesmn 0:c1910e04fc6c 1780 VL53LX_p_021,
charlesmn 0:c1910e04fc6c 1781 pdata);
charlesmn 0:c1910e04fc6c 1782
charlesmn 0:c1910e04fc6c 1783 }
charlesmn 0:c1910e04fc6c 1784
charlesmn 0:c1910e04fc6c 1785 void VL53L3CX::VL53L3CX_decode_row_col(
charlesmn 0:c1910e04fc6c 1786 uint8_t spad_number,
charlesmn 0:c1910e04fc6c 1787 uint8_t *prow,
charlesmn 0:c1910e04fc6c 1788 uint8_t *pcol)
charlesmn 0:c1910e04fc6c 1789 {
charlesmn 0:c1910e04fc6c 1790
charlesmn 0:c1910e04fc6c 1791 VL53LX_decode_row_col( spad_number,
charlesmn 0:c1910e04fc6c 1792 prow,
charlesmn 0:c1910e04fc6c 1793 pcol);
charlesmn 0:c1910e04fc6c 1794
charlesmn 0:c1910e04fc6c 1795 }
charlesmn 0:c1910e04fc6c 1796
charlesmn 0:c1910e04fc6c 1797 void VL53L3CX::VL53L3CX_hist_find_min_max_bin_values(
charlesmn 0:c1910e04fc6c 1798 VL53LX_histogram_bin_data_t *pdata)
charlesmn 0:c1910e04fc6c 1799 {
charlesmn 0:c1910e04fc6c 1800
charlesmn 0:c1910e04fc6c 1801 VL53LX_hist_find_min_max_bin_values(pdata);
charlesmn 0:c1910e04fc6c 1802
charlesmn 0:c1910e04fc6c 1803 }
charlesmn 0:c1910e04fc6c 1804
charlesmn 0:c1910e04fc6c 1805 void VL53L3CX::VL53L3CX_hist_estimate_ambient_from_ambient_bins(
charlesmn 0:c1910e04fc6c 1806 VL53LX_histogram_bin_data_t *pdata)
charlesmn 0:c1910e04fc6c 1807 {
charlesmn 0:c1910e04fc6c 1808 VL53LX_hist_estimate_ambient_from_ambient_bins(pdata);
charlesmn 0:c1910e04fc6c 1809
charlesmn 0:c1910e04fc6c 1810 }
charlesmn 0:c1910e04fc6c 1811 /* vl53lx_core.c */
charlesmn 0:c1910e04fc6c 1812 void VL53L3CX::VL53L3CX_init_version()
charlesmn 0:c1910e04fc6c 1813 {
charlesmn 0:c1910e04fc6c 1814 VL53LX_init_version(Dev);
charlesmn 0:c1910e04fc6c 1815
charlesmn 0:c1910e04fc6c 1816 }
charlesmn 0:c1910e04fc6c 1817
charlesmn 0:c1910e04fc6c 1818 void VL53L3CX::VL53L3CX_init_ll_driver_state(
charlesmn 0:c1910e04fc6c 1819 VL53LX_DeviceState device_state)
charlesmn 0:c1910e04fc6c 1820 {
charlesmn 0:c1910e04fc6c 1821
charlesmn 0:c1910e04fc6c 1822 VL53LX_init_ll_driver_state(Dev, device_state);
charlesmn 0:c1910e04fc6c 1823
charlesmn 0:c1910e04fc6c 1824 }
charlesmn 0:c1910e04fc6c 1825
charlesmn 0:c1910e04fc6c 1826
charlesmn 0:c1910e04fc6c 1827 VL53LX_Error VL53L3CX::VL53L3CX_update_ll_driver_rd_state()
charlesmn 0:c1910e04fc6c 1828 {
charlesmn 0:c1910e04fc6c 1829
charlesmn 0:c1910e04fc6c 1830 return VL53LX_update_ll_driver_rd_state(Dev);
charlesmn 0:c1910e04fc6c 1831
charlesmn 0:c1910e04fc6c 1832 }
charlesmn 0:c1910e04fc6c 1833
charlesmn 0:c1910e04fc6c 1834 VL53LX_Error VL53L3CX::VL53L3CX_check_ll_driver_rd_state()
charlesmn 0:c1910e04fc6c 1835 {
charlesmn 0:c1910e04fc6c 1836
charlesmn 0:c1910e04fc6c 1837 return VL53LX_check_ll_driver_rd_state(Dev);
charlesmn 0:c1910e04fc6c 1838
charlesmn 0:c1910e04fc6c 1839 }
charlesmn 0:c1910e04fc6c 1840
charlesmn 0:c1910e04fc6c 1841
charlesmn 0:c1910e04fc6c 1842 VL53LX_Error VL53L3CX::VL53L3CX_update_ll_driver_cfg_state()
charlesmn 0:c1910e04fc6c 1843 {
charlesmn 0:c1910e04fc6c 1844
charlesmn 0:c1910e04fc6c 1845 return VL53LX_update_ll_driver_cfg_state(Dev);
charlesmn 0:c1910e04fc6c 1846
charlesmn 0:c1910e04fc6c 1847 }
charlesmn 0:c1910e04fc6c 1848
charlesmn 0:c1910e04fc6c 1849 void VL53L3CX::VL53L3CX_copy_rtn_good_spads_to_buffer(
charlesmn 0:c1910e04fc6c 1850 VL53LX_nvm_copy_data_t *pdata,
charlesmn 0:c1910e04fc6c 1851 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 1852 {
charlesmn 0:c1910e04fc6c 1853
charlesmn 0:c1910e04fc6c 1854 VL53LX_copy_rtn_good_spads_to_buffer( pdata,pbuffer);
charlesmn 0:c1910e04fc6c 1855
charlesmn 0:c1910e04fc6c 1856 }
charlesmn 0:c1910e04fc6c 1857
charlesmn 0:c1910e04fc6c 1858 void VL53L3CX::VL53L3CX_init_system_results(
charlesmn 0:c1910e04fc6c 1859 VL53LX_system_results_t *pdata)
charlesmn 0:c1910e04fc6c 1860 {
charlesmn 0:c1910e04fc6c 1861
charlesmn 0:c1910e04fc6c 1862 VL53LX_init_system_results(pdata);
charlesmn 0:c1910e04fc6c 1863
charlesmn 0:c1910e04fc6c 1864 }
charlesmn 0:c1910e04fc6c 1865 void VL53L3CX::VL53L3CX_init_zone_results_structure(
charlesmn 0:c1910e04fc6c 1866 uint8_t active_zones,
charlesmn 0:c1910e04fc6c 1867 VL53LX_zone_results_t *pdata)
charlesmn 0:c1910e04fc6c 1868 {
charlesmn 0:c1910e04fc6c 1869
charlesmn 0:c1910e04fc6c 1870 V53L1_init_zone_results_structure(active_zones, pdata);
charlesmn 0:c1910e04fc6c 1871
charlesmn 0:c1910e04fc6c 1872 }
charlesmn 0:c1910e04fc6c 1873
charlesmn 0:c1910e04fc6c 1874 void VL53L3CX::VL53L3CX_init_zone_dss_configs()
charlesmn 0:c1910e04fc6c 1875 {
charlesmn 0:c1910e04fc6c 1876
charlesmn 0:c1910e04fc6c 1877 V53L1_init_zone_dss_configs(Dev);
charlesmn 0:c1910e04fc6c 1878
charlesmn 0:c1910e04fc6c 1879 }
charlesmn 0:c1910e04fc6c 1880
charlesmn 0:c1910e04fc6c 1881 void VL53L3CX::VL53L3CX_init_histogram_config_structure(
charlesmn 0:c1910e04fc6c 1882 uint8_t even_bin0,
charlesmn 0:c1910e04fc6c 1883 uint8_t even_bin1,
charlesmn 0:c1910e04fc6c 1884 uint8_t even_bin2,
charlesmn 0:c1910e04fc6c 1885 uint8_t even_bin3,
charlesmn 0:c1910e04fc6c 1886 uint8_t even_bin4,
charlesmn 0:c1910e04fc6c 1887 uint8_t even_bin5,
charlesmn 0:c1910e04fc6c 1888 uint8_t odd_bin0,
charlesmn 0:c1910e04fc6c 1889 uint8_t odd_bin1,
charlesmn 0:c1910e04fc6c 1890 uint8_t odd_bin2,
charlesmn 0:c1910e04fc6c 1891 uint8_t odd_bin3,
charlesmn 0:c1910e04fc6c 1892 uint8_t odd_bin4,
charlesmn 0:c1910e04fc6c 1893 uint8_t odd_bin5,
charlesmn 0:c1910e04fc6c 1894 VL53LX_histogram_config_t *pdata)
charlesmn 0:c1910e04fc6c 1895 {
charlesmn 0:c1910e04fc6c 1896
charlesmn 0:c1910e04fc6c 1897
charlesmn 0:c1910e04fc6c 1898 VL53LX_init_histogram_config_structure(even_bin0,
charlesmn 0:c1910e04fc6c 1899 even_bin1,
charlesmn 0:c1910e04fc6c 1900 even_bin2,
charlesmn 0:c1910e04fc6c 1901 even_bin3,
charlesmn 0:c1910e04fc6c 1902 even_bin4,
charlesmn 0:c1910e04fc6c 1903 even_bin5,
charlesmn 0:c1910e04fc6c 1904 odd_bin0,
charlesmn 0:c1910e04fc6c 1905 odd_bin1,
charlesmn 0:c1910e04fc6c 1906 odd_bin2,
charlesmn 0:c1910e04fc6c 1907 odd_bin3,
charlesmn 0:c1910e04fc6c 1908 odd_bin4,
charlesmn 0:c1910e04fc6c 1909 odd_bin5,
charlesmn 0:c1910e04fc6c 1910 pdata);
charlesmn 0:c1910e04fc6c 1911
charlesmn 0:c1910e04fc6c 1912 }
charlesmn 0:c1910e04fc6c 1913
charlesmn 0:c1910e04fc6c 1914 void VL53L3CX::VL53L3CX_init_histogram_multizone_config_structure(
charlesmn 0:c1910e04fc6c 1915 uint8_t even_bin0,
charlesmn 0:c1910e04fc6c 1916 uint8_t even_bin1,
charlesmn 0:c1910e04fc6c 1917 uint8_t even_bin2,
charlesmn 0:c1910e04fc6c 1918 uint8_t even_bin3,
charlesmn 0:c1910e04fc6c 1919 uint8_t even_bin4,
charlesmn 0:c1910e04fc6c 1920 uint8_t even_bin5,
charlesmn 0:c1910e04fc6c 1921 uint8_t odd_bin0,
charlesmn 0:c1910e04fc6c 1922 uint8_t odd_bin1,
charlesmn 0:c1910e04fc6c 1923 uint8_t odd_bin2,
charlesmn 0:c1910e04fc6c 1924 uint8_t odd_bin3,
charlesmn 0:c1910e04fc6c 1925 uint8_t odd_bin4,
charlesmn 0:c1910e04fc6c 1926 uint8_t odd_bin5,
charlesmn 0:c1910e04fc6c 1927 VL53LX_histogram_config_t *pdata)
charlesmn 0:c1910e04fc6c 1928 {
charlesmn 0:c1910e04fc6c 1929
charlesmn 0:c1910e04fc6c 1930 VL53LX_init_histogram_multizone_config_structure( even_bin0,
charlesmn 0:c1910e04fc6c 1931 even_bin1,
charlesmn 0:c1910e04fc6c 1932 even_bin2,
charlesmn 0:c1910e04fc6c 1933 even_bin3,
charlesmn 0:c1910e04fc6c 1934 even_bin4,
charlesmn 0:c1910e04fc6c 1935 even_bin5,
charlesmn 0:c1910e04fc6c 1936 odd_bin0,
charlesmn 0:c1910e04fc6c 1937 odd_bin1,
charlesmn 0:c1910e04fc6c 1938 odd_bin2,
charlesmn 0:c1910e04fc6c 1939 odd_bin3,
charlesmn 0:c1910e04fc6c 1940 odd_bin4,
charlesmn 0:c1910e04fc6c 1941 odd_bin5,
charlesmn 0:c1910e04fc6c 1942 pdata);
charlesmn 0:c1910e04fc6c 1943
charlesmn 0:c1910e04fc6c 1944 }
charlesmn 0:c1910e04fc6c 1945
charlesmn 0:c1910e04fc6c 1946 void VL53L3CX::VL53L3CX_init_xtalk_bin_data_struct(
charlesmn 0:c1910e04fc6c 1947 uint32_t bin_value,
charlesmn 0:c1910e04fc6c 1948 uint16_t VL53LX_p_021,
charlesmn 0:c1910e04fc6c 1949 VL53LX_xtalk_histogram_shape_t *pdata)
charlesmn 0:c1910e04fc6c 1950 {
charlesmn 0:c1910e04fc6c 1951
charlesmn 0:c1910e04fc6c 1952 VL53LX_init_xtalk_bin_data_struct( bin_value,
charlesmn 0:c1910e04fc6c 1953 VL53LX_p_021,
charlesmn 0:c1910e04fc6c 1954 pdata);
charlesmn 0:c1910e04fc6c 1955
charlesmn 0:c1910e04fc6c 1956 }
charlesmn 0:c1910e04fc6c 1957
charlesmn 0:c1910e04fc6c 1958 void VL53L3CX::VL53L3CX_i2c_encode_uint16_t(
charlesmn 0:c1910e04fc6c 1959 uint16_t ip_value,
charlesmn 0:c1910e04fc6c 1960 uint16_t count,
charlesmn 0:c1910e04fc6c 1961 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 1962 {
charlesmn 0:c1910e04fc6c 1963
charlesmn 0:c1910e04fc6c 1964 VL53LX_i2c_encode_uint16_t( ip_value,
charlesmn 0:c1910e04fc6c 1965 count,
charlesmn 0:c1910e04fc6c 1966 pbuffer);
charlesmn 0:c1910e04fc6c 1967
charlesmn 0:c1910e04fc6c 1968 }
charlesmn 0:c1910e04fc6c 1969
charlesmn 0:c1910e04fc6c 1970 uint16_t VL53L3CX::VL53L3CX_i2c_decode_uint16_t(
charlesmn 0:c1910e04fc6c 1971 uint16_t count,
charlesmn 0:c1910e04fc6c 1972 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 1973 {
charlesmn 0:c1910e04fc6c 1974
charlesmn 0:c1910e04fc6c 1975 return VL53LX_i2c_decode_uint16_t( count, pbuffer);
charlesmn 0:c1910e04fc6c 1976
charlesmn 0:c1910e04fc6c 1977 }
charlesmn 0:c1910e04fc6c 1978
charlesmn 0:c1910e04fc6c 1979 void VL53L3CX::VL53L3CX_i2c_encode_int16_t(
charlesmn 0:c1910e04fc6c 1980 int16_t ip_value,
charlesmn 0:c1910e04fc6c 1981 uint16_t count,
charlesmn 0:c1910e04fc6c 1982 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 1983 {
charlesmn 0:c1910e04fc6c 1984
charlesmn 0:c1910e04fc6c 1985 return VL53LX_i2c_encode_uint16_t( ip_value, count, pbuffer);
charlesmn 0:c1910e04fc6c 1986
charlesmn 0:c1910e04fc6c 1987 }
charlesmn 0:c1910e04fc6c 1988
charlesmn 0:c1910e04fc6c 1989 int16_t VL53L3CX::VL53L3CX_i2c_decode_int16_t(
charlesmn 0:c1910e04fc6c 1990 uint16_t count,
charlesmn 0:c1910e04fc6c 1991 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 1992 {
charlesmn 0:c1910e04fc6c 1993
charlesmn 0:c1910e04fc6c 1994 return VL53LX_i2c_decode_int16_t(count,pbuffer);
charlesmn 0:c1910e04fc6c 1995
charlesmn 0:c1910e04fc6c 1996 }
charlesmn 0:c1910e04fc6c 1997
charlesmn 0:c1910e04fc6c 1998 void VL53L3CX::VL53L3CX_i2c_encode_uint32_t(
charlesmn 0:c1910e04fc6c 1999 uint32_t ip_value,
charlesmn 0:c1910e04fc6c 2000 uint16_t count,
charlesmn 0:c1910e04fc6c 2001 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 2002 {
charlesmn 0:c1910e04fc6c 2003
charlesmn 0:c1910e04fc6c 2004 VL53LX_i2c_encode_uint32_t(ip_value,count,pbuffer);
charlesmn 0:c1910e04fc6c 2005
charlesmn 0:c1910e04fc6c 2006 }
charlesmn 0:c1910e04fc6c 2007
charlesmn 0:c1910e04fc6c 2008
charlesmn 0:c1910e04fc6c 2009 uint32_t VL53L3CX::VL53L3CX_i2c_decode_uint32_t(
charlesmn 0:c1910e04fc6c 2010 uint16_t count,
charlesmn 0:c1910e04fc6c 2011 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 2012 {
charlesmn 0:c1910e04fc6c 2013
charlesmn 0:c1910e04fc6c 2014 return VL53LX_i2c_decode_uint32_t( count, pbuffer);
charlesmn 0:c1910e04fc6c 2015
charlesmn 0:c1910e04fc6c 2016 }
charlesmn 0:c1910e04fc6c 2017
charlesmn 0:c1910e04fc6c 2018 uint32_t VL53L3CX::VL53L3CX_i2c_decode_with_mask(
charlesmn 0:c1910e04fc6c 2019 uint16_t count,
charlesmn 0:c1910e04fc6c 2020 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 2021 uint32_t bit_mask,
charlesmn 0:c1910e04fc6c 2022 uint32_t down_shift,
charlesmn 0:c1910e04fc6c 2023 uint32_t offset)
charlesmn 0:c1910e04fc6c 2024 {
charlesmn 0:c1910e04fc6c 2025
charlesmn 0:c1910e04fc6c 2026 return VL53LX_i2c_decode_with_mask( count, pbuffer, bit_mask,down_shift,offset);
charlesmn 0:c1910e04fc6c 2027
charlesmn 0:c1910e04fc6c 2028 }
charlesmn 0:c1910e04fc6c 2029
charlesmn 0:c1910e04fc6c 2030 void VL53L3CX::VL53L3CX_i2c_encode_int32_t(
charlesmn 0:c1910e04fc6c 2031 int32_t ip_value,
charlesmn 0:c1910e04fc6c 2032 uint16_t count,
charlesmn 0:c1910e04fc6c 2033 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 2034 {
charlesmn 0:c1910e04fc6c 2035
charlesmn 0:c1910e04fc6c 2036 return VL53LX_i2c_encode_int32_t( ip_value, count, pbuffer);
charlesmn 0:c1910e04fc6c 2037
charlesmn 0:c1910e04fc6c 2038 }
charlesmn 0:c1910e04fc6c 2039
charlesmn 0:c1910e04fc6c 2040 int32_t VL53L3CX::VL53L3CX_i2c_decode_int32_t(
charlesmn 0:c1910e04fc6c 2041 uint16_t count,
charlesmn 0:c1910e04fc6c 2042 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 2043 {
charlesmn 0:c1910e04fc6c 2044
charlesmn 0:c1910e04fc6c 2045 return VL53LX_i2c_decode_int32_t( count,pbuffer);
charlesmn 0:c1910e04fc6c 2046
charlesmn 0:c1910e04fc6c 2047 }
charlesmn 0:c1910e04fc6c 2048
charlesmn 0:c1910e04fc6c 2049 VL53LX_Error VL53L3CX::VL53L3CX_start_test(
charlesmn 0:c1910e04fc6c 2050 uint8_t test_mode__ctrl)
charlesmn 0:c1910e04fc6c 2051 {
charlesmn 0:c1910e04fc6c 2052
charlesmn 0:c1910e04fc6c 2053 return VL53LX_start_test(Dev,test_mode__ctrl);
charlesmn 0:c1910e04fc6c 2054
charlesmn 0:c1910e04fc6c 2055 }
charlesmn 0:c1910e04fc6c 2056 VL53LX_Error VL53L3CX::VL53L3CX_set_firmware_enable_register(uint8_t value)
charlesmn 0:c1910e04fc6c 2057 {
charlesmn 0:c1910e04fc6c 2058
charlesmn 0:c1910e04fc6c 2059 return VL53LX_set_firmware_enable_register(Dev,value);
charlesmn 0:c1910e04fc6c 2060
charlesmn 0:c1910e04fc6c 2061 }
charlesmn 0:c1910e04fc6c 2062
charlesmn 0:c1910e04fc6c 2063 VL53LX_Error VL53L3CX::VL53L3CX_enable_firmware()
charlesmn 0:c1910e04fc6c 2064 {
charlesmn 0:c1910e04fc6c 2065
charlesmn 0:c1910e04fc6c 2066 return VL53LX_enable_firmware(Dev);
charlesmn 0:c1910e04fc6c 2067
charlesmn 0:c1910e04fc6c 2068 }
charlesmn 0:c1910e04fc6c 2069
charlesmn 0:c1910e04fc6c 2070 VL53LX_Error VL53L3CX::VL53L3CX_disable_firmware()
charlesmn 0:c1910e04fc6c 2071 {
charlesmn 0:c1910e04fc6c 2072 return VL53LX_disable_firmware(Dev);
charlesmn 0:c1910e04fc6c 2073 }
charlesmn 0:c1910e04fc6c 2074
charlesmn 0:c1910e04fc6c 2075
charlesmn 0:c1910e04fc6c 2076 VL53LX_Error VL53L3CX::VL53L3CX_set_powerforce_register(
charlesmn 0:c1910e04fc6c 2077 uint8_t value)
charlesmn 0:c1910e04fc6c 2078 {
charlesmn 0:c1910e04fc6c 2079
charlesmn 0:c1910e04fc6c 2080 return VL53LX_set_powerforce_register(Dev, value);
charlesmn 0:c1910e04fc6c 2081
charlesmn 0:c1910e04fc6c 2082 }
charlesmn 0:c1910e04fc6c 2083
charlesmn 0:c1910e04fc6c 2084
charlesmn 0:c1910e04fc6c 2085 VL53LX_Error VL53L3CX::VL53L3CX_enable_powerforce()
charlesmn 0:c1910e04fc6c 2086 {
charlesmn 0:c1910e04fc6c 2087
charlesmn 0:c1910e04fc6c 2088 return VL53LX_enable_powerforce(Dev);
charlesmn 0:c1910e04fc6c 2089
charlesmn 0:c1910e04fc6c 2090 }
charlesmn 0:c1910e04fc6c 2091
charlesmn 0:c1910e04fc6c 2092 VL53LX_Error VL53L3CX::VL53L3CX_disable_powerforce()
charlesmn 0:c1910e04fc6c 2093 {
charlesmn 0:c1910e04fc6c 2094
charlesmn 0:c1910e04fc6c 2095 return VL53LX_disable_powerforce(Dev);
charlesmn 0:c1910e04fc6c 2096
charlesmn 0:c1910e04fc6c 2097 }
charlesmn 0:c1910e04fc6c 2098
charlesmn 0:c1910e04fc6c 2099 VL53LX_Error VL53L3CX::VL53L3CX_clear_interrupt()
charlesmn 0:c1910e04fc6c 2100 {
charlesmn 0:c1910e04fc6c 2101
charlesmn 0:c1910e04fc6c 2102 return VL53LX_clear_interrupt(Dev);
charlesmn 0:c1910e04fc6c 2103
charlesmn 0:c1910e04fc6c 2104 }
charlesmn 0:c1910e04fc6c 2105
charlesmn 0:c1910e04fc6c 2106
charlesmn 0:c1910e04fc6c 2107 VL53LX_Error VL53L3CX::VL53L3CX_force_shadow_stream_count_to_zero()
charlesmn 0:c1910e04fc6c 2108 {
charlesmn 0:c1910e04fc6c 2109
charlesmn 0:c1910e04fc6c 2110 return VL53LX_force_shadow_stream_count_to_zero(Dev);
charlesmn 0:c1910e04fc6c 2111
charlesmn 0:c1910e04fc6c 2112 }
charlesmn 0:c1910e04fc6c 2113
charlesmn 0:c1910e04fc6c 2114 uint32_t VL53L3CX::VL53L3CX_calc_macro_period_us(
charlesmn 0:c1910e04fc6c 2115 uint16_t fast_osc_frequency,
charlesmn 0:c1910e04fc6c 2116 uint8_t VL53LX_p_005)
charlesmn 0:c1910e04fc6c 2117 {
charlesmn 0:c1910e04fc6c 2118
charlesmn 0:c1910e04fc6c 2119 return VL53LX_calc_macro_period_us(
charlesmn 0:c1910e04fc6c 2120 fast_osc_frequency,
charlesmn 0:c1910e04fc6c 2121 VL53LX_p_005);
charlesmn 0:c1910e04fc6c 2122
charlesmn 0:c1910e04fc6c 2123 }
charlesmn 0:c1910e04fc6c 2124
charlesmn 0:c1910e04fc6c 2125 uint16_t VL53L3CX::VL53L3CX_calc_range_ignore_threshold(
charlesmn 0:c1910e04fc6c 2126 uint32_t central_rate,
charlesmn 0:c1910e04fc6c 2127 int16_t x_gradient,
charlesmn 0:c1910e04fc6c 2128 int16_t y_gradient,
charlesmn 0:c1910e04fc6c 2129 uint8_t rate_mult)
charlesmn 0:c1910e04fc6c 2130 {
charlesmn 0:c1910e04fc6c 2131
charlesmn 0:c1910e04fc6c 2132 return VL53LX_calc_range_ignore_threshold( central_rate,
charlesmn 0:c1910e04fc6c 2133 x_gradient,
charlesmn 0:c1910e04fc6c 2134 y_gradient,
charlesmn 0:c1910e04fc6c 2135 rate_mult);
charlesmn 0:c1910e04fc6c 2136
charlesmn 0:c1910e04fc6c 2137
charlesmn 0:c1910e04fc6c 2138 }
charlesmn 0:c1910e04fc6c 2139
charlesmn 0:c1910e04fc6c 2140 uint32_t VL53L3CX::VL53L3CX_calc_timeout_mclks(
charlesmn 0:c1910e04fc6c 2141 uint32_t timeout_us,
charlesmn 0:c1910e04fc6c 2142 uint32_t macro_period_us)
charlesmn 0:c1910e04fc6c 2143 {
charlesmn 0:c1910e04fc6c 2144
charlesmn 0:c1910e04fc6c 2145 return VL53LX_calc_timeout_mclks(timeout_us, macro_period_us);
charlesmn 0:c1910e04fc6c 2146
charlesmn 0:c1910e04fc6c 2147 }
charlesmn 0:c1910e04fc6c 2148 uint16_t VL53L3CX::VL53L3CX_calc_encoded_timeout(
charlesmn 0:c1910e04fc6c 2149 uint32_t timeout_us,
charlesmn 0:c1910e04fc6c 2150 uint32_t macro_period_us)
charlesmn 0:c1910e04fc6c 2151 {
charlesmn 0:c1910e04fc6c 2152
charlesmn 0:c1910e04fc6c 2153 return VL53LX_calc_encoded_timeout(timeout_us,
charlesmn 0:c1910e04fc6c 2154 macro_period_us);
charlesmn 0:c1910e04fc6c 2155 }
charlesmn 0:c1910e04fc6c 2156
charlesmn 0:c1910e04fc6c 2157 uint32_t VL53L3CX::VL53L3CX_calc_timeout_us(
charlesmn 0:c1910e04fc6c 2158 uint32_t timeout_mclks,
charlesmn 0:c1910e04fc6c 2159 uint32_t macro_period_us)
charlesmn 0:c1910e04fc6c 2160 {
charlesmn 0:c1910e04fc6c 2161
charlesmn 0:c1910e04fc6c 2162 return VL53LX_calc_timeout_us(timeout_mclks,
charlesmn 0:c1910e04fc6c 2163 macro_period_us);
charlesmn 0:c1910e04fc6c 2164
charlesmn 0:c1910e04fc6c 2165 }
charlesmn 0:c1910e04fc6c 2166
charlesmn 0:c1910e04fc6c 2167 uint32_t VL53L3CX::VL53L3CX_calc_crosstalk_plane_offset_with_margin(
charlesmn 0:c1910e04fc6c 2168 uint32_t plane_offset_kcps,
charlesmn 0:c1910e04fc6c 2169 int16_t margin_offset_kcps)
charlesmn 0:c1910e04fc6c 2170 {
charlesmn 0:c1910e04fc6c 2171
charlesmn 0:c1910e04fc6c 2172 return VL53LX_calc_crosstalk_plane_offset_with_margin( plane_offset_kcps,
charlesmn 0:c1910e04fc6c 2173 margin_offset_kcps);
charlesmn 0:c1910e04fc6c 2174 }
charlesmn 0:c1910e04fc6c 2175
charlesmn 0:c1910e04fc6c 2176 uint32_t VL53L3CX::VL53L3CX_calc_decoded_timeout_us(
charlesmn 0:c1910e04fc6c 2177 uint16_t timeout_encoded,
charlesmn 0:c1910e04fc6c 2178 uint32_t macro_period_us)
charlesmn 0:c1910e04fc6c 2179 {
charlesmn 0:c1910e04fc6c 2180
charlesmn 0:c1910e04fc6c 2181 return VL53LX_calc_decoded_timeout_us( timeout_encoded,
charlesmn 0:c1910e04fc6c 2182 macro_period_us);
charlesmn 0:c1910e04fc6c 2183
charlesmn 0:c1910e04fc6c 2184 }
charlesmn 0:c1910e04fc6c 2185
charlesmn 0:c1910e04fc6c 2186 uint16_t VL53L3CX::VL53L3CX_encode_timeout(uint32_t timeout_mclks)
charlesmn 0:c1910e04fc6c 2187 {
charlesmn 0:c1910e04fc6c 2188
charlesmn 0:c1910e04fc6c 2189 return VL53LX_encode_timeout(timeout_mclks);
charlesmn 0:c1910e04fc6c 2190
charlesmn 0:c1910e04fc6c 2191 }
charlesmn 0:c1910e04fc6c 2192
charlesmn 0:c1910e04fc6c 2193 uint32_t VL53L3CX::VL53L3CX_decode_timeout(uint16_t encoded_timeout)
charlesmn 0:c1910e04fc6c 2194 {
charlesmn 0:c1910e04fc6c 2195
charlesmn 0:c1910e04fc6c 2196 return VL53LX_decode_timeout(encoded_timeout);
charlesmn 0:c1910e04fc6c 2197
charlesmn 0:c1910e04fc6c 2198 }
charlesmn 0:c1910e04fc6c 2199
charlesmn 0:c1910e04fc6c 2200
charlesmn 0:c1910e04fc6c 2201
charlesmn 0:c1910e04fc6c 2202
charlesmn 0:c1910e04fc6c 2203 VL53LX_Error VL53L3CX::VL53L3CX_calc_timeout_register_values(
charlesmn 0:c1910e04fc6c 2204 uint32_t phasecal_config_timeout_us,
charlesmn 0:c1910e04fc6c 2205 uint32_t mm_config_timeout_us,
charlesmn 0:c1910e04fc6c 2206 uint32_t range_config_timeout_us,
charlesmn 0:c1910e04fc6c 2207 uint16_t fast_osc_frequency,
charlesmn 0:c1910e04fc6c 2208 VL53LX_general_config_t *pgeneral,
charlesmn 0:c1910e04fc6c 2209 VL53LX_timing_config_t *ptiming)
charlesmn 0:c1910e04fc6c 2210 {
charlesmn 0:c1910e04fc6c 2211
charlesmn 0:c1910e04fc6c 2212 return VL53LX_calc_timeout_register_values(
charlesmn 0:c1910e04fc6c 2213 phasecal_config_timeout_us,
charlesmn 0:c1910e04fc6c 2214 mm_config_timeout_us,
charlesmn 0:c1910e04fc6c 2215 range_config_timeout_us,
charlesmn 0:c1910e04fc6c 2216 fast_osc_frequency,
charlesmn 0:c1910e04fc6c 2217 pgeneral,
charlesmn 0:c1910e04fc6c 2218 ptiming);
charlesmn 0:c1910e04fc6c 2219
charlesmn 0:c1910e04fc6c 2220
charlesmn 0:c1910e04fc6c 2221 }
charlesmn 0:c1910e04fc6c 2222
charlesmn 0:c1910e04fc6c 2223 uint8_t VL53L3CX::VL53L3CX_encode_vcsel_period(uint8_t VL53LX_p_030)
charlesmn 0:c1910e04fc6c 2224 {
charlesmn 0:c1910e04fc6c 2225
charlesmn 0:c1910e04fc6c 2226 return VL53LX_encode_vcsel_period(VL53LX_p_030);
charlesmn 0:c1910e04fc6c 2227
charlesmn 0:c1910e04fc6c 2228 }
charlesmn 0:c1910e04fc6c 2229
charlesmn 0:c1910e04fc6c 2230 uint32_t VL53L3CX::VL53L3CX_decode_unsigned_integer(
charlesmn 0:c1910e04fc6c 2231 uint8_t *pbuffer,
charlesmn 0:c1910e04fc6c 2232 uint8_t no_of_bytes)
charlesmn 0:c1910e04fc6c 2233 {
charlesmn 0:c1910e04fc6c 2234
charlesmn 0:c1910e04fc6c 2235 return VL53LX_decode_unsigned_integer(pbuffer, no_of_bytes);
charlesmn 0:c1910e04fc6c 2236
charlesmn 0:c1910e04fc6c 2237 }
charlesmn 0:c1910e04fc6c 2238
charlesmn 0:c1910e04fc6c 2239
charlesmn 0:c1910e04fc6c 2240 void VL53L3CX::VL53L3CX_encode_unsigned_integer(
charlesmn 0:c1910e04fc6c 2241 uint32_t ip_value,
charlesmn 0:c1910e04fc6c 2242 uint8_t no_of_bytes,
charlesmn 0:c1910e04fc6c 2243 uint8_t *pbuffer)
charlesmn 0:c1910e04fc6c 2244 {
charlesmn 0:c1910e04fc6c 2245
charlesmn 0:c1910e04fc6c 2246 VL53LX_encode_unsigned_integer( ip_value,
charlesmn 0:c1910e04fc6c 2247 no_of_bytes,
charlesmn 0:c1910e04fc6c 2248 pbuffer);
charlesmn 0:c1910e04fc6c 2249
charlesmn 0:c1910e04fc6c 2250 }
charlesmn 0:c1910e04fc6c 2251
charlesmn 0:c1910e04fc6c 2252 VL53LX_Error VL53L3CX::VL53L3CX_hist_copy_and_scale_ambient_info(
charlesmn 0:c1910e04fc6c 2253 VL53LX_zone_hist_info_t *pidata,
charlesmn 0:c1910e04fc6c 2254 VL53LX_histogram_bin_data_t *podata)
charlesmn 0:c1910e04fc6c 2255 {
charlesmn 0:c1910e04fc6c 2256
charlesmn 0:c1910e04fc6c 2257 return VL53LX_hist_copy_and_scale_ambient_info( pidata,
charlesmn 0:c1910e04fc6c 2258 podata);
charlesmn 0:c1910e04fc6c 2259
charlesmn 0:c1910e04fc6c 2260
charlesmn 0:c1910e04fc6c 2261 }
charlesmn 0:c1910e04fc6c 2262
charlesmn 0:c1910e04fc6c 2263
charlesmn 0:c1910e04fc6c 2264 void VL53L3CX::VL53L3CX_hist_get_bin_sequence_config(
charlesmn 0:c1910e04fc6c 2265 VL53LX_histogram_bin_data_t *pdata)
charlesmn 0:c1910e04fc6c 2266 {
charlesmn 0:c1910e04fc6c 2267
charlesmn 0:c1910e04fc6c 2268 VL53LX_hist_get_bin_sequence_config(Dev, pdata);
charlesmn 0:c1910e04fc6c 2269
charlesmn 0:c1910e04fc6c 2270 }
charlesmn 0:c1910e04fc6c 2271
charlesmn 0:c1910e04fc6c 2272
charlesmn 0:c1910e04fc6c 2273 VL53LX_Error VL53L3CX::VL53L3CX_hist_phase_consistency_check(
charlesmn 0:c1910e04fc6c 2274 VL53LX_zone_hist_info_t *phist_prev,
charlesmn 0:c1910e04fc6c 2275 VL53LX_zone_objects_t *prange_prev,
charlesmn 0:c1910e04fc6c 2276 VL53LX_range_results_t *prange_curr)
charlesmn 0:c1910e04fc6c 2277 {
charlesmn 0:c1910e04fc6c 2278
charlesmn 0:c1910e04fc6c 2279 return VL53LX_hist_phase_consistency_check(
charlesmn 0:c1910e04fc6c 2280 Dev,
charlesmn 0:c1910e04fc6c 2281 phist_prev,
charlesmn 0:c1910e04fc6c 2282 prange_prev,
charlesmn 0:c1910e04fc6c 2283 prange_curr);
charlesmn 0:c1910e04fc6c 2284
charlesmn 0:c1910e04fc6c 2285 }
charlesmn 0:c1910e04fc6c 2286
charlesmn 0:c1910e04fc6c 2287
charlesmn 0:c1910e04fc6c 2288
charlesmn 0:c1910e04fc6c 2289 VL53LX_Error VL53L3CX::VL53L3CX_hist_events_consistency_check(
charlesmn 0:c1910e04fc6c 2290 uint8_t event_sigma,
charlesmn 0:c1910e04fc6c 2291 uint16_t min_effective_spad_count,
charlesmn 0:c1910e04fc6c 2292 VL53LX_zone_hist_info_t *phist_prev,
charlesmn 0:c1910e04fc6c 2293 VL53LX_object_data_t *prange_prev,
charlesmn 0:c1910e04fc6c 2294 VL53LX_range_data_t *prange_curr,
charlesmn 0:c1910e04fc6c 2295 int32_t *pevents_tolerance,
charlesmn 0:c1910e04fc6c 2296 int32_t *pevents_delta,
charlesmn 0:c1910e04fc6c 2297 VL53LX_DeviceError *prange_status)
charlesmn 0:c1910e04fc6c 2298 {
charlesmn 0:c1910e04fc6c 2299
charlesmn 0:c1910e04fc6c 2300 return VL53LX_hist_events_consistency_check( event_sigma,
charlesmn 0:c1910e04fc6c 2301 min_effective_spad_count,
charlesmn 0:c1910e04fc6c 2302 phist_prev,
charlesmn 0:c1910e04fc6c 2303 prange_prev,
charlesmn 0:c1910e04fc6c 2304 prange_curr,
charlesmn 0:c1910e04fc6c 2305 pevents_tolerance,
charlesmn 0:c1910e04fc6c 2306 pevents_delta,
charlesmn 0:c1910e04fc6c 2307 prange_status);
charlesmn 0:c1910e04fc6c 2308
charlesmn 0:c1910e04fc6c 2309 }
charlesmn 0:c1910e04fc6c 2310
charlesmn 0:c1910e04fc6c 2311
charlesmn 0:c1910e04fc6c 2312 VL53LX_Error VL53L3CX::VL53L3CX_hist_merged_pulse_check(
charlesmn 0:c1910e04fc6c 2313 int16_t min_max_tolerance_mm,
charlesmn 0:c1910e04fc6c 2314 VL53LX_range_data_t *pdata,
charlesmn 0:c1910e04fc6c 2315 VL53LX_DeviceError *prange_status)
charlesmn 0:c1910e04fc6c 2316 {
charlesmn 0:c1910e04fc6c 2317
charlesmn 0:c1910e04fc6c 2318 return VL53LX_hist_merged_pulse_check( min_max_tolerance_mm,
charlesmn 0:c1910e04fc6c 2319 pdata,
charlesmn 0:c1910e04fc6c 2320 prange_status);
charlesmn 0:c1910e04fc6c 2321
charlesmn 0:c1910e04fc6c 2322 }
charlesmn 0:c1910e04fc6c 2323
charlesmn 0:c1910e04fc6c 2324
charlesmn 0:c1910e04fc6c 2325 VL53LX_Error VL53L3CX::VL53L3CX_hist_xmonitor_consistency_check(
charlesmn 0:c1910e04fc6c 2326 VL53LX_zone_hist_info_t *phist_prev,
charlesmn 0:c1910e04fc6c 2327 VL53LX_zone_objects_t *prange_prev,
charlesmn 0:c1910e04fc6c 2328 VL53LX_range_data_t *prange_curr)
charlesmn 0:c1910e04fc6c 2329 {
charlesmn 0:c1910e04fc6c 2330
charlesmn 0:c1910e04fc6c 2331 return VL53LX_hist_xmonitor_consistency_check(
charlesmn 0:c1910e04fc6c 2332 Dev,
charlesmn 0:c1910e04fc6c 2333 phist_prev,
charlesmn 0:c1910e04fc6c 2334 prange_prev,
charlesmn 0:c1910e04fc6c 2335 prange_curr);
charlesmn 0:c1910e04fc6c 2336
charlesmn 0:c1910e04fc6c 2337 }
charlesmn 0:c1910e04fc6c 2338
charlesmn 0:c1910e04fc6c 2339 VL53LX_Error VL53L3CX::VL53L3CX_hist_wrap_dmax(
charlesmn 0:c1910e04fc6c 2340 VL53LX_hist_post_process_config_t *phistpostprocess,
charlesmn 0:c1910e04fc6c 2341 VL53LX_histogram_bin_data_t *pcurrent,
charlesmn 0:c1910e04fc6c 2342 int16_t *pwrap_dmax_mm)
charlesmn 0:c1910e04fc6c 2343 {
charlesmn 0:c1910e04fc6c 2344
charlesmn 0:c1910e04fc6c 2345
charlesmn 0:c1910e04fc6c 2346 return VL53LX_hist_wrap_dmax( phistpostprocess,
charlesmn 0:c1910e04fc6c 2347 pcurrent,
charlesmn 0:c1910e04fc6c 2348 pwrap_dmax_mm);
charlesmn 0:c1910e04fc6c 2349
charlesmn 0:c1910e04fc6c 2350 }
charlesmn 0:c1910e04fc6c 2351
charlesmn 0:c1910e04fc6c 2352
charlesmn 0:c1910e04fc6c 2353 void VL53L3CX::VL53L3CX_hist_combine_mm1_mm2_offsets(
charlesmn 0:c1910e04fc6c 2354 int16_t mm1_offset_mm,
charlesmn 0:c1910e04fc6c 2355 int16_t mm2_offset_mm,
charlesmn 0:c1910e04fc6c 2356 uint8_t encoded_mm_roi_centre,
charlesmn 0:c1910e04fc6c 2357 uint8_t encoded_mm_roi_size,
charlesmn 0:c1910e04fc6c 2358 uint8_t encoded_zone_centre,
charlesmn 0:c1910e04fc6c 2359 uint8_t encoded_zone_size,
charlesmn 0:c1910e04fc6c 2360 VL53LX_additional_offset_cal_data_t *pcal_data,
charlesmn 0:c1910e04fc6c 2361 uint8_t *pgood_spads,
charlesmn 0:c1910e04fc6c 2362 uint16_t aperture_attenuation,
charlesmn 0:c1910e04fc6c 2363 int16_t *prange_offset_mm)
charlesmn 0:c1910e04fc6c 2364 {
charlesmn 0:c1910e04fc6c 2365
charlesmn 0:c1910e04fc6c 2366 return VL53LX_hist_combine_mm1_mm2_offsets(
charlesmn 0:c1910e04fc6c 2367 mm1_offset_mm,
charlesmn 0:c1910e04fc6c 2368 mm2_offset_mm,
charlesmn 0:c1910e04fc6c 2369 encoded_mm_roi_centre,
charlesmn 0:c1910e04fc6c 2370 encoded_mm_roi_size,
charlesmn 0:c1910e04fc6c 2371 encoded_zone_centre,
charlesmn 0:c1910e04fc6c 2372 encoded_zone_size,
charlesmn 0:c1910e04fc6c 2373 pcal_data,
charlesmn 0:c1910e04fc6c 2374 pgood_spads,
charlesmn 0:c1910e04fc6c 2375 aperture_attenuation,
charlesmn 0:c1910e04fc6c 2376 prange_offset_mm);
charlesmn 0:c1910e04fc6c 2377
charlesmn 0:c1910e04fc6c 2378 }
charlesmn 0:c1910e04fc6c 2379
charlesmn 0:c1910e04fc6c 2380 VL53LX_Error VL53L3CX::VL53L3CX_hist_xtalk_extract_calc_window(
charlesmn 0:c1910e04fc6c 2381 int16_t target_distance_mm,
charlesmn 0:c1910e04fc6c 2382 uint16_t target_width_oversize,
charlesmn 0:c1910e04fc6c 2383 VL53LX_histogram_bin_data_t *phist_bins,
charlesmn 0:c1910e04fc6c 2384 VL53LX_hist_xtalk_extract_data_t *pxtalk_data)
charlesmn 0:c1910e04fc6c 2385 {
charlesmn 0:c1910e04fc6c 2386
charlesmn 0:c1910e04fc6c 2387 return VL53LX_hist_xtalk_extract_calc_window( target_distance_mm,
charlesmn 0:c1910e04fc6c 2388 target_width_oversize,
charlesmn 0:c1910e04fc6c 2389 phist_bins,
charlesmn 0:c1910e04fc6c 2390 pxtalk_data);
charlesmn 0:c1910e04fc6c 2391
charlesmn 0:c1910e04fc6c 2392 }
charlesmn 0:c1910e04fc6c 2393
charlesmn 0:c1910e04fc6c 2394
charlesmn 0:c1910e04fc6c 2395 VL53LX_Error VL53L3CX::VL53L3CX_hist_xtalk_extract_calc_event_sums(
charlesmn 0:c1910e04fc6c 2396 VL53LX_histogram_bin_data_t *phist_bins,
charlesmn 0:c1910e04fc6c 2397 VL53LX_hist_xtalk_extract_data_t *pxtalk_data)
charlesmn 0:c1910e04fc6c 2398 {
charlesmn 0:c1910e04fc6c 2399
charlesmn 0:c1910e04fc6c 2400 return VL53LX_hist_xtalk_extract_calc_event_sums( phist_bins, pxtalk_data);
charlesmn 0:c1910e04fc6c 2401
charlesmn 0:c1910e04fc6c 2402 }
charlesmn 0:c1910e04fc6c 2403 VL53LX_Error VL53L3CX::VL53L3CX_hist_xtalk_extract_calc_rate_per_spad(
charlesmn 0:c1910e04fc6c 2404 VL53LX_hist_xtalk_extract_data_t *pxtalk_data)
charlesmn 0:c1910e04fc6c 2405 {
charlesmn 0:c1910e04fc6c 2406
charlesmn 0:c1910e04fc6c 2407 return VL53LX_hist_xtalk_extract_calc_rate_per_spad( pxtalk_data );
charlesmn 0:c1910e04fc6c 2408
charlesmn 0:c1910e04fc6c 2409 }
charlesmn 0:c1910e04fc6c 2410
charlesmn 0:c1910e04fc6c 2411 VL53LX_Error VL53L3CX::VL53L3CX_hist_xtalk_extract_calc_shape(
charlesmn 0:c1910e04fc6c 2412 VL53LX_hist_xtalk_extract_data_t *pxtalk_data,
charlesmn 0:c1910e04fc6c 2413 VL53LX_xtalk_histogram_shape_t *pxtalk_shape)
charlesmn 0:c1910e04fc6c 2414 {
charlesmn 0:c1910e04fc6c 2415
charlesmn 0:c1910e04fc6c 2416 return VL53LX_hist_xtalk_extract_calc_shape( pxtalk_data, pxtalk_shape);
charlesmn 0:c1910e04fc6c 2417
charlesmn 0:c1910e04fc6c 2418 }
charlesmn 0:c1910e04fc6c 2419
charlesmn 0:c1910e04fc6c 2420
charlesmn 0:c1910e04fc6c 2421
charlesmn 0:c1910e04fc6c 2422 VL53LX_Error VL53L3CX::VL53L3CX_hist_xtalk_shape_model(
charlesmn 0:c1910e04fc6c 2423 uint16_t events_per_bin,
charlesmn 0:c1910e04fc6c 2424 uint16_t pulse_centre,
charlesmn 0:c1910e04fc6c 2425 uint16_t pulse_width,
charlesmn 0:c1910e04fc6c 2426 VL53LX_xtalk_histogram_shape_t *pxtalk_shape)
charlesmn 0:c1910e04fc6c 2427 {
charlesmn 0:c1910e04fc6c 2428
charlesmn 0:c1910e04fc6c 2429
charlesmn 0:c1910e04fc6c 2430 VL53LX_Error status = VL53LX_ERROR_NONE;
charlesmn 0:c1910e04fc6c 2431
charlesmn 0:c1910e04fc6c 2432 uint32_t phase_start = 0;
charlesmn 0:c1910e04fc6c 2433 uint32_t phase_stop = 0;
charlesmn 0:c1910e04fc6c 2434 uint32_t phase_bin = 0;
charlesmn 0:c1910e04fc6c 2435
charlesmn 0:c1910e04fc6c 2436 uint32_t bin_start = 0;
charlesmn 0:c1910e04fc6c 2437 uint32_t bin_stop = 0;
charlesmn 0:c1910e04fc6c 2438
charlesmn 0:c1910e04fc6c 2439 uint32_t lb = 0;
charlesmn 0:c1910e04fc6c 2440 uint16_t VL53LX_p_018 = 0;
charlesmn 0:c1910e04fc6c 2441
charlesmn 0:c1910e04fc6c 2442 pxtalk_shape->VL53LX_p_019 = 0;
charlesmn 0:c1910e04fc6c 2443 pxtalk_shape->VL53LX_p_020 = VL53LX_XTALK_HISTO_BINS;
charlesmn 0:c1910e04fc6c 2444 pxtalk_shape->VL53LX_p_021 = VL53LX_XTALK_HISTO_BINS;
charlesmn 0:c1910e04fc6c 2445
charlesmn 0:c1910e04fc6c 2446 pxtalk_shape->zero_distance_phase = pulse_centre;
charlesmn 0:c1910e04fc6c 2447 pxtalk_shape->phasecal_result__reference_phase =
charlesmn 0:c1910e04fc6c 2448 pulse_centre + (3 * 2048);
charlesmn 0:c1910e04fc6c 2449
charlesmn 0:c1910e04fc6c 2450
charlesmn 0:c1910e04fc6c 2451 if (pulse_centre > (pulse_width >> 1))
charlesmn 0:c1910e04fc6c 2452 phase_start = (uint32_t)pulse_centre -
charlesmn 0:c1910e04fc6c 2453 ((uint32_t)pulse_width >> 1);
charlesmn 0:c1910e04fc6c 2454 else {
charlesmn 0:c1910e04fc6c 2455 phase_start = 0;
charlesmn 0:c1910e04fc6c 2456 }
charlesmn 0:c1910e04fc6c 2457
charlesmn 0:c1910e04fc6c 2458 phase_stop = (uint32_t)pulse_centre +
charlesmn 0:c1910e04fc6c 2459 ((uint32_t)pulse_width >> 1);
charlesmn 0:c1910e04fc6c 2460
charlesmn 0:c1910e04fc6c 2461
charlesmn 0:c1910e04fc6c 2462 bin_start = (phase_start / 2048);
charlesmn 0:c1910e04fc6c 2463 bin_stop = (phase_stop / 2048);
charlesmn 0:c1910e04fc6c 2464
charlesmn 0:c1910e04fc6c 2465 for (lb = 0; lb < VL53LX_XTALK_HISTO_BINS; lb++) {
charlesmn 0:c1910e04fc6c 2466 VL53LX_p_018 = 0;
charlesmn 0:c1910e04fc6c 2467
charlesmn 0:c1910e04fc6c 2468
charlesmn 0:c1910e04fc6c 2469 if (lb == bin_start && lb == bin_stop) {
charlesmn 0:c1910e04fc6c 2470 VL53LX_p_018 =
charlesmn 0:c1910e04fc6c 2471 VL53LX_hist_xtalk_shape_model_interp(
charlesmn 0:c1910e04fc6c 2472 events_per_bin,
charlesmn 0:c1910e04fc6c 2473 phase_stop - phase_start);
charlesmn 0:c1910e04fc6c 2474
charlesmn 0:c1910e04fc6c 2475 } else if (lb > bin_start && lb < bin_stop) {
charlesmn 0:c1910e04fc6c 2476
charlesmn 0:c1910e04fc6c 2477
charlesmn 0:c1910e04fc6c 2478 VL53LX_p_018 = events_per_bin;
charlesmn 0:c1910e04fc6c 2479
charlesmn 0:c1910e04fc6c 2480 } else if (lb == bin_start) {
charlesmn 0:c1910e04fc6c 2481
charlesmn 0:c1910e04fc6c 2482
charlesmn 0:c1910e04fc6c 2483 phase_bin = (lb + 1) * 2048;
charlesmn 0:c1910e04fc6c 2484 VL53LX_p_018 =
charlesmn 0:c1910e04fc6c 2485 VL53LX_hist_xtalk_shape_model_interp(
charlesmn 0:c1910e04fc6c 2486 events_per_bin,
charlesmn 0:c1910e04fc6c 2487 (phase_bin - phase_start));
charlesmn 0:c1910e04fc6c 2488
charlesmn 0:c1910e04fc6c 2489 } else if (lb == bin_stop) {
charlesmn 0:c1910e04fc6c 2490
charlesmn 0:c1910e04fc6c 2491
charlesmn 0:c1910e04fc6c 2492 phase_bin = lb * 2048;
charlesmn 0:c1910e04fc6c 2493 VL53LX_p_018 =
charlesmn 0:c1910e04fc6c 2494 VL53LX_hist_xtalk_shape_model_interp(
charlesmn 0:c1910e04fc6c 2495 events_per_bin,
charlesmn 0:c1910e04fc6c 2496 (phase_stop - phase_bin));
charlesmn 0:c1910e04fc6c 2497 }
charlesmn 0:c1910e04fc6c 2498
charlesmn 0:c1910e04fc6c 2499 pxtalk_shape->bin_data[lb] = VL53LX_p_018;
charlesmn 0:c1910e04fc6c 2500 }
charlesmn 0:c1910e04fc6c 2501
charlesmn 0:c1910e04fc6c 2502
charlesmn 0:c1910e04fc6c 2503 return status;
charlesmn 0:c1910e04fc6c 2504 }
charlesmn 0:c1910e04fc6c 2505
charlesmn 0:c1910e04fc6c 2506 uint16_t VL53L3CX::VL53L3CX_hist_xtalk_shape_model_interp(
charlesmn 0:c1910e04fc6c 2507 uint16_t events_per_bin,
charlesmn 0:c1910e04fc6c 2508 uint32_t phase_delta)
charlesmn 0:c1910e04fc6c 2509 {
charlesmn 0:c1910e04fc6c 2510
charlesmn 0:c1910e04fc6c 2511 return VL53LX_hist_xtalk_shape_model_interp( events_per_bin,phase_delta);
charlesmn 0:c1910e04fc6c 2512
charlesmn 0:c1910e04fc6c 2513 }
charlesmn 0:c1910e04fc6c 2514
charlesmn 0:c1910e04fc6c 2515 void VL53L3CX::VL53L3CX_spad_number_to_byte_bit_index(
charlesmn 0:c1910e04fc6c 2516 uint8_t spad_number,
charlesmn 0:c1910e04fc6c 2517 uint8_t *pbyte_index,
charlesmn 0:c1910e04fc6c 2518 uint8_t *pbit_index,
charlesmn 0:c1910e04fc6c 2519 uint8_t *pbit_mask)
charlesmn 0:c1910e04fc6c 2520 {
charlesmn 0:c1910e04fc6c 2521 VL53LX_spad_number_to_byte_bit_index(
charlesmn 0:c1910e04fc6c 2522 spad_number,
charlesmn 0:c1910e04fc6c 2523 pbyte_index,
charlesmn 0:c1910e04fc6c 2524 pbit_index,
charlesmn 0:c1910e04fc6c 2525 pbit_mask);
charlesmn 0:c1910e04fc6c 2526
charlesmn 0:c1910e04fc6c 2527 }
charlesmn 0:c1910e04fc6c 2528
charlesmn 0:c1910e04fc6c 2529 void VL53L3CX::VL53L3CX_encode_row_col(
charlesmn 0:c1910e04fc6c 2530 uint8_t row,
charlesmn 0:c1910e04fc6c 2531 uint8_t col,
charlesmn 0:c1910e04fc6c 2532 uint8_t *pspad_number)
charlesmn 0:c1910e04fc6c 2533 {
charlesmn 0:c1910e04fc6c 2534
charlesmn 0:c1910e04fc6c 2535 VL53LX_encode_row_col(row, col, pspad_number);
charlesmn 0:c1910e04fc6c 2536
charlesmn 0:c1910e04fc6c 2537 }
charlesmn 0:c1910e04fc6c 2538 void VL53L3CX::VL53L3CX_decode_zone_size(
charlesmn 0:c1910e04fc6c 2539 uint8_t encoded_xy_size,
charlesmn 0:c1910e04fc6c 2540 uint8_t *pwidth,
charlesmn 0:c1910e04fc6c 2541 uint8_t *pheight)
charlesmn 0:c1910e04fc6c 2542 {
charlesmn 0:c1910e04fc6c 2543
charlesmn 0:c1910e04fc6c 2544 VL53LX_decode_zone_size(encoded_xy_size, pwidth, pheight);
charlesmn 0:c1910e04fc6c 2545
charlesmn 0:c1910e04fc6c 2546 }
charlesmn 0:c1910e04fc6c 2547
charlesmn 0:c1910e04fc6c 2548 void VL53L3CX::VL53L3CX_encode_zone_size(
charlesmn 0:c1910e04fc6c 2549 uint8_t width,
charlesmn 0:c1910e04fc6c 2550 uint8_t height,
charlesmn 0:c1910e04fc6c 2551 uint8_t *pencoded_xy_size)
charlesmn 0:c1910e04fc6c 2552 {
charlesmn 0:c1910e04fc6c 2553
charlesmn 0:c1910e04fc6c 2554 VL53LX_encode_zone_size(width, height, pencoded_xy_size);
charlesmn 0:c1910e04fc6c 2555
charlesmn 0:c1910e04fc6c 2556 }
charlesmn 0:c1910e04fc6c 2557
charlesmn 0:c1910e04fc6c 2558 void VL53L3CX::VL53L3CX_decode_zone_limits(
charlesmn 0:c1910e04fc6c 2559 uint8_t encoded_xy_centre,
charlesmn 0:c1910e04fc6c 2560 uint8_t encoded_xy_size,
charlesmn 0:c1910e04fc6c 2561 int16_t *px_ll,
charlesmn 0:c1910e04fc6c 2562 int16_t *py_ll,
charlesmn 0:c1910e04fc6c 2563 int16_t *px_ur,
charlesmn 0:c1910e04fc6c 2564 int16_t *py_ur)
charlesmn 0:c1910e04fc6c 2565 {
charlesmn 0:c1910e04fc6c 2566
charlesmn 0:c1910e04fc6c 2567 VL53LX_decode_zone_limits(
charlesmn 0:c1910e04fc6c 2568 encoded_xy_centre,
charlesmn 0:c1910e04fc6c 2569 encoded_xy_size,
charlesmn 0:c1910e04fc6c 2570 px_ll,
charlesmn 0:c1910e04fc6c 2571 py_ll,
charlesmn 0:c1910e04fc6c 2572 px_ur,
charlesmn 0:c1910e04fc6c 2573 py_ur);
charlesmn 0:c1910e04fc6c 2574
charlesmn 0:c1910e04fc6c 2575 }
charlesmn 0:c1910e04fc6c 2576
charlesmn 0:c1910e04fc6c 2577 uint8_t VL53L3CX::VL53L3CX_is_aperture_location(
charlesmn 0:c1910e04fc6c 2578 uint8_t row,
charlesmn 0:c1910e04fc6c 2579 uint8_t col)
charlesmn 0:c1910e04fc6c 2580 {
charlesmn 0:c1910e04fc6c 2581
charlesmn 0:c1910e04fc6c 2582 return VL53LX_is_aperture_location( row, col);
charlesmn 0:c1910e04fc6c 2583
charlesmn 0:c1910e04fc6c 2584 }
charlesmn 0:c1910e04fc6c 2585
charlesmn 0:c1910e04fc6c 2586 void VL53L3CX::VL53L3CX_calc_max_effective_spads(
charlesmn 0:c1910e04fc6c 2587 uint8_t encoded_zone_centre,
charlesmn 0:c1910e04fc6c 2588 uint8_t encoded_zone_size,
charlesmn 0:c1910e04fc6c 2589 uint8_t *pgood_spads,
charlesmn 0:c1910e04fc6c 2590 uint16_t aperture_attenuation,
charlesmn 0:c1910e04fc6c 2591 uint16_t *pmax_effective_spads)
charlesmn 0:c1910e04fc6c 2592 {
charlesmn 0:c1910e04fc6c 2593
charlesmn 0:c1910e04fc6c 2594 VL53LX_calc_max_effective_spads(encoded_zone_centre,
charlesmn 0:c1910e04fc6c 2595 encoded_zone_size,
charlesmn 0:c1910e04fc6c 2596 pgood_spads,
charlesmn 0:c1910e04fc6c 2597 aperture_attenuation,
charlesmn 0:c1910e04fc6c 2598 pmax_effective_spads);
charlesmn 0:c1910e04fc6c 2599
charlesmn 0:c1910e04fc6c 2600 }
charlesmn 0:c1910e04fc6c 2601
charlesmn 0:c1910e04fc6c 2602
charlesmn 0:c1910e04fc6c 2603
charlesmn 0:c1910e04fc6c 2604
charlesmn 0:c1910e04fc6c 2605 void VL53L3CX::VL53L3CX_calc_mm_effective_spads(
charlesmn 0:c1910e04fc6c 2606 uint8_t encoded_mm_roi_centre,
charlesmn 0:c1910e04fc6c 2607 uint8_t encoded_mm_roi_size,
charlesmn 0:c1910e04fc6c 2608 uint8_t encoded_zone_centre,
charlesmn 0:c1910e04fc6c 2609 uint8_t encoded_zone_size,
charlesmn 0:c1910e04fc6c 2610 uint8_t *pgood_spads,
charlesmn 0:c1910e04fc6c 2611 uint16_t aperture_attenuation,
charlesmn 0:c1910e04fc6c 2612 uint16_t *pmm_inner_effective_spads,
charlesmn 0:c1910e04fc6c 2613 uint16_t *pmm_outer_effective_spads)
charlesmn 0:c1910e04fc6c 2614 {
charlesmn 0:c1910e04fc6c 2615
charlesmn 0:c1910e04fc6c 2616 VL53LX_calc_mm_effective_spads( encoded_mm_roi_centre,
charlesmn 0:c1910e04fc6c 2617 encoded_mm_roi_size,
charlesmn 0:c1910e04fc6c 2618 encoded_zone_centre,
charlesmn 0:c1910e04fc6c 2619 encoded_zone_size,
charlesmn 0:c1910e04fc6c 2620 pgood_spads,
charlesmn 0:c1910e04fc6c 2621 aperture_attenuation,
charlesmn 0:c1910e04fc6c 2622 pmm_inner_effective_spads,
charlesmn 0:c1910e04fc6c 2623 pmm_outer_effective_spads);
charlesmn 0:c1910e04fc6c 2624
charlesmn 0:c1910e04fc6c 2625 }
charlesmn 0:c1910e04fc6c 2626
charlesmn 0:c1910e04fc6c 2627
charlesmn 0:c1910e04fc6c 2628 void VL53L3CX::VL53L3CX_hist_copy_results_to_sys_and_core(
charlesmn 0:c1910e04fc6c 2629 VL53LX_histogram_bin_data_t *pbins,
charlesmn 0:c1910e04fc6c 2630 VL53LX_range_results_t *phist,
charlesmn 0:c1910e04fc6c 2631 VL53LX_system_results_t *psys,
charlesmn 0:c1910e04fc6c 2632 VL53LX_core_results_t *pcore)
charlesmn 0:c1910e04fc6c 2633 {
charlesmn 0:c1910e04fc6c 2634
charlesmn 0:c1910e04fc6c 2635 return VL53LX_hist_copy_results_to_sys_and_core(pbins,
charlesmn 0:c1910e04fc6c 2636 phist,
charlesmn 0:c1910e04fc6c 2637 psys,
charlesmn 0:c1910e04fc6c 2638 pcore);
charlesmn 0:c1910e04fc6c 2639
charlesmn 0:c1910e04fc6c 2640
charlesmn 0:c1910e04fc6c 2641 }
charlesmn 0:c1910e04fc6c 2642
charlesmn 0:c1910e04fc6c 2643
charlesmn 0:c1910e04fc6c 2644
charlesmn 0:c1910e04fc6c 2645
charlesmn 0:c1910e04fc6c 2646
charlesmn 0:c1910e04fc6c 2647 VL53LX_Error VL53L3CX::VL53L3CX_save_cfg_data()
charlesmn 0:c1910e04fc6c 2648 {
charlesmn 0:c1910e04fc6c 2649
charlesmn 0:c1910e04fc6c 2650 return VL53LX_save_cfg_data(Dev);
charlesmn 0:c1910e04fc6c 2651
charlesmn 0:c1910e04fc6c 2652 }
charlesmn 0:c1910e04fc6c 2653
charlesmn 0:c1910e04fc6c 2654
charlesmn 0:c1910e04fc6c 2655 VL53LX_Error VL53L3CX::VL53L3CX_dynamic_zone_update(
charlesmn 0:c1910e04fc6c 2656 VL53LX_range_results_t *presults)
charlesmn 0:c1910e04fc6c 2657 {
charlesmn 0:c1910e04fc6c 2658
charlesmn 0:c1910e04fc6c 2659 return VL53LX_dynamic_zone_update(Dev, presults);
charlesmn 0:c1910e04fc6c 2660
charlesmn 0:c1910e04fc6c 2661 }
charlesmn 0:c1910e04fc6c 2662
charlesmn 0:c1910e04fc6c 2663 VL53LX_Error VL53L3CX::VL53L3CX_multizone_hist_bins_update()
charlesmn 0:c1910e04fc6c 2664 {
charlesmn 0:c1910e04fc6c 2665
charlesmn 0:c1910e04fc6c 2666 return VL53LX_multizone_hist_bins_update(Dev);
charlesmn 0:c1910e04fc6c 2667
charlesmn 0:c1910e04fc6c 2668 }
charlesmn 0:c1910e04fc6c 2669
charlesmn 0:c1910e04fc6c 2670 VL53LX_Error VL53L3CX::VL53L3CX_update_internal_stream_counters(
charlesmn 0:c1910e04fc6c 2671 uint8_t external_stream_count,
charlesmn 0:c1910e04fc6c 2672 uint8_t *pinternal_stream_count,
charlesmn 0:c1910e04fc6c 2673 uint8_t *pinternal_stream_count_val)
charlesmn 0:c1910e04fc6c 2674 {
charlesmn 0:c1910e04fc6c 2675
charlesmn 0:c1910e04fc6c 2676
charlesmn 0:c1910e04fc6c 2677 return VL53LX_update_internal_stream_counters( Dev,
charlesmn 0:c1910e04fc6c 2678 external_stream_count,
charlesmn 0:c1910e04fc6c 2679 pinternal_stream_count,
charlesmn 0:c1910e04fc6c 2680 pinternal_stream_count_val);
charlesmn 0:c1910e04fc6c 2681
charlesmn 0:c1910e04fc6c 2682 }
charlesmn 0:c1910e04fc6c 2683
charlesmn 0:c1910e04fc6c 2684
charlesmn 0:c1910e04fc6c 2685 VL53LX_Error VL53L3CX::VL53L3CX_set_histogram_multizone_initial_bin_config(
charlesmn 0:c1910e04fc6c 2686 VL53LX_zone_config_t *pzone_cfg,
charlesmn 0:c1910e04fc6c 2687 VL53LX_histogram_config_t *phist_cfg,
charlesmn 0:c1910e04fc6c 2688 VL53LX_histogram_config_t *pmulti_hist)
charlesmn 0:c1910e04fc6c 2689 {
charlesmn 0:c1910e04fc6c 2690
charlesmn 0:c1910e04fc6c 2691 return VL53LX_set_histogram_multizone_initial_bin_config(pzone_cfg,
charlesmn 0:c1910e04fc6c 2692 phist_cfg,
charlesmn 0:c1910e04fc6c 2693 pmulti_hist);
charlesmn 0:c1910e04fc6c 2694
charlesmn 0:c1910e04fc6c 2695 }
charlesmn 0:c1910e04fc6c 2696
charlesmn 0:c1910e04fc6c 2697 uint8_t VL53L3CX::VL53L3CX_encode_GPIO_interrupt_config(
charlesmn 0:c1910e04fc6c 2698 VL53LX_GPIO_interrupt_config_t *pintconf)
charlesmn 0:c1910e04fc6c 2699 {
charlesmn 0:c1910e04fc6c 2700
charlesmn 0:c1910e04fc6c 2701 return VL53LX_encode_GPIO_interrupt_config(pintconf);
charlesmn 0:c1910e04fc6c 2702
charlesmn 0:c1910e04fc6c 2703 }
charlesmn 0:c1910e04fc6c 2704
charlesmn 0:c1910e04fc6c 2705 VL53LX_GPIO_interrupt_config_t VL53L3CX::VL53L3CX_decode_GPIO_interrupt_config(
charlesmn 0:c1910e04fc6c 2706 uint8_t system__interrupt_config)
charlesmn 0:c1910e04fc6c 2707 {
charlesmn 0:c1910e04fc6c 2708
charlesmn 0:c1910e04fc6c 2709 return VL53LX_decode_GPIO_interrupt_config( system__interrupt_config);
charlesmn 0:c1910e04fc6c 2710
charlesmn 0:c1910e04fc6c 2711 }
charlesmn 0:c1910e04fc6c 2712
charlesmn 0:c1910e04fc6c 2713 VL53LX_Error VL53L3CX::VL53L3CX_set_GPIO_distance_threshold(
charlesmn 0:c1910e04fc6c 2714 uint16_t threshold_high,
charlesmn 0:c1910e04fc6c 2715 uint16_t threshold_low)
charlesmn 0:c1910e04fc6c 2716 {
charlesmn 0:c1910e04fc6c 2717
charlesmn 0:c1910e04fc6c 2718 return VL53LX_set_GPIO_distance_threshold( Dev,
charlesmn 0:c1910e04fc6c 2719 threshold_high,
charlesmn 0:c1910e04fc6c 2720 threshold_low);
charlesmn 0:c1910e04fc6c 2721
charlesmn 0:c1910e04fc6c 2722 }
charlesmn 0:c1910e04fc6c 2723
charlesmn 0:c1910e04fc6c 2724
charlesmn 0:c1910e04fc6c 2725 VL53LX_Error VL53L3CX::VL53L3CX_set_GPIO_rate_threshold(
charlesmn 0:c1910e04fc6c 2726 uint16_t threshold_high,
charlesmn 0:c1910e04fc6c 2727 uint16_t threshold_low)
charlesmn 0:c1910e04fc6c 2728 {
charlesmn 0:c1910e04fc6c 2729
charlesmn 0:c1910e04fc6c 2730 return VL53LX_set_GPIO_rate_threshold( Dev,
charlesmn 0:c1910e04fc6c 2731 threshold_high,
charlesmn 0:c1910e04fc6c 2732 threshold_low);
charlesmn 0:c1910e04fc6c 2733
charlesmn 0:c1910e04fc6c 2734 }
charlesmn 0:c1910e04fc6c 2735
charlesmn 0:c1910e04fc6c 2736 VL53LX_Error VL53L3CX::VL53L3CX_set_GPIO_thresholds_from_struct(
charlesmn 0:c1910e04fc6c 2737 VL53LX_GPIO_interrupt_config_t *pintconf)
charlesmn 0:c1910e04fc6c 2738 {
charlesmn 0:c1910e04fc6c 2739
charlesmn 0:c1910e04fc6c 2740 return VL53LX_set_GPIO_thresholds_from_struct( Dev, pintconf);
charlesmn 0:c1910e04fc6c 2741 }
charlesmn 0:c1910e04fc6c 2742
charlesmn 0:c1910e04fc6c 2743
charlesmn 0:c1910e04fc6c 2744 VL53LX_Error VL53L3CX::VL53L3CX_set_ref_spad_char_config(
charlesmn 0:c1910e04fc6c 2745 uint8_t vcsel_period_a,
charlesmn 0:c1910e04fc6c 2746 uint32_t phasecal_timeout_us,
charlesmn 0:c1910e04fc6c 2747 uint16_t total_rate_target_mcps,
charlesmn 0:c1910e04fc6c 2748 uint16_t max_count_rate_rtn_limit_mcps,
charlesmn 0:c1910e04fc6c 2749 uint16_t min_count_rate_rtn_limit_mcps,
charlesmn 0:c1910e04fc6c 2750 uint16_t fast_osc_frequency)
charlesmn 0:c1910e04fc6c 2751 {
charlesmn 0:c1910e04fc6c 2752
charlesmn 0:c1910e04fc6c 2753 return VL53LX_set_ref_spad_char_config(Dev,
charlesmn 0:c1910e04fc6c 2754 vcsel_period_a,
charlesmn 0:c1910e04fc6c 2755 phasecal_timeout_us,
charlesmn 0:c1910e04fc6c 2756 total_rate_target_mcps,
charlesmn 0:c1910e04fc6c 2757 max_count_rate_rtn_limit_mcps,
charlesmn 0:c1910e04fc6c 2758 min_count_rate_rtn_limit_mcps,
charlesmn 0:c1910e04fc6c 2759 fast_osc_frequency);
charlesmn 0:c1910e04fc6c 2760
charlesmn 0:c1910e04fc6c 2761 }
charlesmn 0:c1910e04fc6c 2762
charlesmn 0:c1910e04fc6c 2763 VL53LX_Error VL53L3CX::VL53L3CX_set_ssc_config(
charlesmn 0:c1910e04fc6c 2764 VL53LX_ssc_config_t *pssc_cfg,
charlesmn 0:c1910e04fc6c 2765 uint16_t fast_osc_frequency)
charlesmn 0:c1910e04fc6c 2766 {
charlesmn 0:c1910e04fc6c 2767
charlesmn 0:c1910e04fc6c 2768 return VL53LX_set_ssc_config( Dev,
charlesmn 0:c1910e04fc6c 2769 pssc_cfg,
charlesmn 0:c1910e04fc6c 2770 fast_osc_frequency);
charlesmn 0:c1910e04fc6c 2771
charlesmn 0:c1910e04fc6c 2772
charlesmn 0:c1910e04fc6c 2773 }
charlesmn 0:c1910e04fc6c 2774
charlesmn 0:c1910e04fc6c 2775
charlesmn 0:c1910e04fc6c 2776 VL53LX_Error VL53L3CX::VL53L3CX_get_spad_rate_data(
charlesmn 0:c1910e04fc6c 2777 VL53LX_spad_rate_data_t *pspad_rates)
charlesmn 0:c1910e04fc6c 2778 {
charlesmn 0:c1910e04fc6c 2779
charlesmn 0:c1910e04fc6c 2780 return VL53LX_get_spad_rate_data( Dev, pspad_rates);
charlesmn 0:c1910e04fc6c 2781
charlesmn 0:c1910e04fc6c 2782 }
charlesmn 0:c1910e04fc6c 2783
charlesmn 0:c1910e04fc6c 2784 VL53LX_Error VL53L3CX::VL53L3CX_dynamic_xtalk_correction_calc_required_samples()
charlesmn 0:c1910e04fc6c 2785 {
charlesmn 0:c1910e04fc6c 2786
charlesmn 0:c1910e04fc6c 2787 return VL53LX_dynamic_xtalk_correction_calc_required_samples( Dev);
charlesmn 0:c1910e04fc6c 2788 }
charlesmn 0:c1910e04fc6c 2789
charlesmn 0:c1910e04fc6c 2790 VL53LX_Error VL53L3CX::VL53L3CX_dynamic_xtalk_correction_calc_new_xtalk(
charlesmn 0:c1910e04fc6c 2791 uint32_t xtalk_offset_out,
charlesmn 0:c1910e04fc6c 2792 VL53LX_smudge_corrector_config_t *pconfig,
charlesmn 0:c1910e04fc6c 2793 VL53LX_smudge_corrector_data_t *pout,
charlesmn 0:c1910e04fc6c 2794 uint8_t add_smudge,
charlesmn 0:c1910e04fc6c 2795 uint8_t soft_update
charlesmn 0:c1910e04fc6c 2796 )
charlesmn 0:c1910e04fc6c 2797 {
charlesmn 0:c1910e04fc6c 2798
charlesmn 0:c1910e04fc6c 2799 return VL53LX_dynamic_xtalk_correction_calc_new_xtalk( Dev, xtalk_offset_out, pconfig, pout,add_smudge,soft_update);
charlesmn 0:c1910e04fc6c 2800 }
charlesmn 0:c1910e04fc6c 2801
charlesmn 0:c1910e04fc6c 2802
charlesmn 0:c1910e04fc6c 2803
charlesmn 0:c1910e04fc6c 2804 VL53LX_Error VL53L3CX::VL53L3CX_dynamic_xtalk_correction_corrector()
charlesmn 0:c1910e04fc6c 2805 {
charlesmn 0:c1910e04fc6c 2806
charlesmn 0:c1910e04fc6c 2807 return VL53LX_dynamic_xtalk_correction_corrector( Dev);
charlesmn 0:c1910e04fc6c 2808 }
charlesmn 0:c1910e04fc6c 2809
charlesmn 0:c1910e04fc6c 2810 VL53LX_Error VL53L3CX::VL53L3CX_dynamic_xtalk_correction_data_init()
charlesmn 0:c1910e04fc6c 2811 {
charlesmn 0:c1910e04fc6c 2812 return VL53LX_dynamic_xtalk_correction_data_init( Dev);
charlesmn 0:c1910e04fc6c 2813 }
charlesmn 0:c1910e04fc6c 2814
charlesmn 0:c1910e04fc6c 2815
charlesmn 0:c1910e04fc6c 2816 VL53LX_Error VL53L3CX::VL53L3CX_dynamic_xtalk_correction_output_init(
charlesmn 0:c1910e04fc6c 2817 VL53LX_LLDriverResults_t *pres
charlesmn 0:c1910e04fc6c 2818 )
charlesmn 0:c1910e04fc6c 2819 {
charlesmn 0:c1910e04fc6c 2820
charlesmn 0:c1910e04fc6c 2821 return VL53LX_dynamic_xtalk_correction_output_init(pres);
charlesmn 0:c1910e04fc6c 2822
charlesmn 0:c1910e04fc6c 2823 }
charlesmn 0:c1910e04fc6c 2824
charlesmn 0:c1910e04fc6c 2825 VL53LX_Error VL53L3CX::VL53L3CX_xtalk_cal_data_init()
charlesmn 0:c1910e04fc6c 2826 {
charlesmn 0:c1910e04fc6c 2827
charlesmn 0:c1910e04fc6c 2828 return VL53LX_xtalk_cal_data_init( Dev );
charlesmn 0:c1910e04fc6c 2829
charlesmn 0:c1910e04fc6c 2830 }
charlesmn 0:c1910e04fc6c 2831
charlesmn 0:c1910e04fc6c 2832 VL53LX_Error VL53L3CX::VL53L3CX_low_power_auto_data_init()
charlesmn 0:c1910e04fc6c 2833 {
charlesmn 0:c1910e04fc6c 2834
charlesmn 0:c1910e04fc6c 2835 return VL53LX_low_power_auto_data_init( Dev);
charlesmn 0:c1910e04fc6c 2836
charlesmn 0:c1910e04fc6c 2837 }
charlesmn 0:c1910e04fc6c 2838
charlesmn 0:c1910e04fc6c 2839 VL53LX_Error VL53L3CX::VL53L3CX_low_power_auto_data_stop_range()
charlesmn 0:c1910e04fc6c 2840 {
charlesmn 0:c1910e04fc6c 2841
charlesmn 0:c1910e04fc6c 2842 return VL53LX_low_power_auto_data_stop_range(Dev);
charlesmn 0:c1910e04fc6c 2843
charlesmn 0:c1910e04fc6c 2844 }
charlesmn 0:c1910e04fc6c 2845
charlesmn 0:c1910e04fc6c 2846 VL53LX_Error VL53L3CX::VL53L3CX_config_low_power_auto_mode(
charlesmn 0:c1910e04fc6c 2847 VL53LX_general_config_t *pgeneral,
charlesmn 0:c1910e04fc6c 2848 VL53LX_dynamic_config_t *pdynamic,
charlesmn 0:c1910e04fc6c 2849 VL53LX_low_power_auto_data_t *plpadata
charlesmn 0:c1910e04fc6c 2850 )
charlesmn 0:c1910e04fc6c 2851 {
charlesmn 0:c1910e04fc6c 2852
charlesmn 0:c1910e04fc6c 2853 return VL53LX_config_low_power_auto_mode( pgeneral, pdynamic,plpadata);
charlesmn 0:c1910e04fc6c 2854
charlesmn 0:c1910e04fc6c 2855 }
charlesmn 0:c1910e04fc6c 2856
charlesmn 0:c1910e04fc6c 2857
charlesmn 0:c1910e04fc6c 2858 VL53LX_Error VL53L3CX::VL53L3CX_low_power_auto_setup_manual_calibration()
charlesmn 0:c1910e04fc6c 2859 {
charlesmn 0:c1910e04fc6c 2860
charlesmn 0:c1910e04fc6c 2861 return VL53LX_low_power_auto_setup_manual_calibration( Dev);
charlesmn 0:c1910e04fc6c 2862 }
charlesmn 0:c1910e04fc6c 2863
charlesmn 0:c1910e04fc6c 2864
charlesmn 0:c1910e04fc6c 2865 VL53LX_Error VL53L3CX::VL53L3CX_low_power_auto_update_DSS()
charlesmn 0:c1910e04fc6c 2866 {
charlesmn 0:c1910e04fc6c 2867
charlesmn 0:c1910e04fc6c 2868 return VL53LX_low_power_auto_update_DSS( Dev );
charlesmn 0:c1910e04fc6c 2869
charlesmn 0:c1910e04fc6c 2870 }
charlesmn 0:c1910e04fc6c 2871
charlesmn 0:c1910e04fc6c 2872 VL53LX_Error VL53L3CX::VL53L3CX_compute_histo_merge_nb(uint8_t *histo_merge_nb)
charlesmn 0:c1910e04fc6c 2873 {
charlesmn 0:c1910e04fc6c 2874
charlesmn 0:c1910e04fc6c 2875 return VL53LX_compute_histo_merge_nb( Dev, histo_merge_nb);
charlesmn 0:c1910e04fc6c 2876
charlesmn 0:c1910e04fc6c 2877 }
charlesmn 0:c1910e04fc6c 2878
charlesmn 0:c1910e04fc6c 2879 /* vl53lx_wait.c */
charlesmn 0:c1910e04fc6c 2880
charlesmn 0:c1910e04fc6c 2881
charlesmn 0:c1910e04fc6c 2882 VL53LX_Error VL53L3CX::VL53L3CX_wait_for_boot_completion()
charlesmn 0:c1910e04fc6c 2883 {
charlesmn 0:c1910e04fc6c 2884
charlesmn 0:c1910e04fc6c 2885 return VL53LX_wait_for_boot_completion(Dev);
charlesmn 0:c1910e04fc6c 2886
charlesmn 0:c1910e04fc6c 2887 }
charlesmn 0:c1910e04fc6c 2888
charlesmn 0:c1910e04fc6c 2889 VL53LX_Error VL53L3CX::VL53L3CX_wait_for_firmware_ready()
charlesmn 0:c1910e04fc6c 2890 {
charlesmn 0:c1910e04fc6c 2891
charlesmn 0:c1910e04fc6c 2892 return VL53LX_wait_for_firmware_ready(Dev);
charlesmn 0:c1910e04fc6c 2893
charlesmn 0:c1910e04fc6c 2894 }
charlesmn 0:c1910e04fc6c 2895
charlesmn 0:c1910e04fc6c 2896
charlesmn 0:c1910e04fc6c 2897 VL53LX_Error VL53L3CX::VL53L3CX_wait_for_range_completion()
charlesmn 0:c1910e04fc6c 2898 {
charlesmn 0:c1910e04fc6c 2899
charlesmn 0:c1910e04fc6c 2900 return VL53LX_wait_for_range_completion(Dev);
charlesmn 0:c1910e04fc6c 2901
charlesmn 0:c1910e04fc6c 2902 }
charlesmn 0:c1910e04fc6c 2903 VL53LX_Error VL53L3CX::VL53L3CX_wait_for_test_completion()
charlesmn 0:c1910e04fc6c 2904 {
charlesmn 0:c1910e04fc6c 2905 return VL53LX_wait_for_test_completion(Dev);
charlesmn 0:c1910e04fc6c 2906 }
charlesmn 0:c1910e04fc6c 2907
charlesmn 0:c1910e04fc6c 2908 VL53LX_Error VL53L3CX::VL53L3CX_is_boot_complete(
charlesmn 0:c1910e04fc6c 2909 uint8_t *pready)
charlesmn 0:c1910e04fc6c 2910 {
charlesmn 0:c1910e04fc6c 2911
charlesmn 0:c1910e04fc6c 2912 return VL53LX_is_boot_complete( Dev,
charlesmn 0:c1910e04fc6c 2913 pready);
charlesmn 0:c1910e04fc6c 2914
charlesmn 0:c1910e04fc6c 2915 }
charlesmn 0:c1910e04fc6c 2916
charlesmn 0:c1910e04fc6c 2917 VL53LX_Error VL53L3CX::VL53L3CX_is_firmware_ready(
charlesmn 0:c1910e04fc6c 2918 uint8_t *pready)
charlesmn 0:c1910e04fc6c 2919 {
charlesmn 0:c1910e04fc6c 2920
charlesmn 0:c1910e04fc6c 2921 return VL53LX_is_firmware_ready( Dev, pready);
charlesmn 0:c1910e04fc6c 2922
charlesmn 0:c1910e04fc6c 2923 }
charlesmn 0:c1910e04fc6c 2924 VL53LX_Error VL53L3CX::VL53L3CX_is_new_data_ready(
charlesmn 0:c1910e04fc6c 2925 uint8_t *pready)
charlesmn 0:c1910e04fc6c 2926 {
charlesmn 0:c1910e04fc6c 2927
charlesmn 0:c1910e04fc6c 2928 return VL53LX_is_new_data_ready(Dev, pready);
charlesmn 0:c1910e04fc6c 2929
charlesmn 0:c1910e04fc6c 2930 }
charlesmn 0:c1910e04fc6c 2931
charlesmn 0:c1910e04fc6c 2932 VL53LX_Error VL53L3CX::VL53L3CX_poll_for_boot_completion(
charlesmn 0:c1910e04fc6c 2933 uint32_t timeout_ms)
charlesmn 0:c1910e04fc6c 2934 {
charlesmn 0:c1910e04fc6c 2935
charlesmn 0:c1910e04fc6c 2936 return VL53LX_poll_for_boot_completion(Dev,timeout_ms);
charlesmn 0:c1910e04fc6c 2937
charlesmn 0:c1910e04fc6c 2938 }
charlesmn 0:c1910e04fc6c 2939
charlesmn 0:c1910e04fc6c 2940 VL53LX_Error VL53L3CX::VL53L3CX_poll_for_firmware_ready(
charlesmn 0:c1910e04fc6c 2941 uint32_t timeout_ms)
charlesmn 0:c1910e04fc6c 2942 {
charlesmn 0:c1910e04fc6c 2943
charlesmn 0:c1910e04fc6c 2944 return VL53LX_poll_for_firmware_ready(Dev,timeout_ms);
charlesmn 0:c1910e04fc6c 2945
charlesmn 0:c1910e04fc6c 2946 }
charlesmn 0:c1910e04fc6c 2947
charlesmn 0:c1910e04fc6c 2948 VL53LX_Error VL53L3CX::VL53L3CX_poll_for_range_completion(
charlesmn 0:c1910e04fc6c 2949 uint32_t timeout_ms)
charlesmn 0:c1910e04fc6c 2950 {
charlesmn 0:c1910e04fc6c 2951
charlesmn 0:c1910e04fc6c 2952 return VL53LX_poll_for_range_completion(Dev, timeout_ms);
charlesmn 0:c1910e04fc6c 2953
charlesmn 0:c1910e04fc6c 2954 }
charlesmn 0:c1910e04fc6c 2955
charlesmn 0:c1910e04fc6c 2956 /* vl53lx_zone_presets.c */
charlesmn 0:c1910e04fc6c 2957
charlesmn 0:c1910e04fc6c 2958
charlesmn 0:c1910e04fc6c 2959 VL53LX_Error VL53L3CX::VL53L3CX_init_zone_config_histogram_bins(
charlesmn 0:c1910e04fc6c 2960 VL53LX_zone_config_t *pdata)
charlesmn 0:c1910e04fc6c 2961 {
charlesmn 0:c1910e04fc6c 2962
charlesmn 0:c1910e04fc6c 2963 return VL53LX_init_zone_config_histogram_bins(pdata);
charlesmn 0:c1910e04fc6c 2964
charlesmn 0:c1910e04fc6c 2965 }
charlesmn 0:c1910e04fc6c 2966
charlesmn 0:c1910e04fc6c 2967 /* vl53lx_api_preset_modes.h */
charlesmn 0:c1910e04fc6c 2968
charlesmn 0:c1910e04fc6c 2969 VL53LX_Error VL53L3CX::VL53L3CX_init_refspadchar_config_struct(
charlesmn 0:c1910e04fc6c 2970 VL53LX_refspadchar_config_t *pdata)
charlesmn 0:c1910e04fc6c 2971 {
charlesmn 0:c1910e04fc6c 2972
charlesmn 0:c1910e04fc6c 2973 return VL53LX_init_refspadchar_config_struct(pdata);
charlesmn 0:c1910e04fc6c 2974
charlesmn 0:c1910e04fc6c 2975 }
charlesmn 0:c1910e04fc6c 2976
charlesmn 0:c1910e04fc6c 2977 VL53LX_Error VL53L3CX::VL53L3CX_init_ssc_config_struct(
charlesmn 0:c1910e04fc6c 2978 VL53LX_ssc_config_t *pdata)
charlesmn 0:c1910e04fc6c 2979 {
charlesmn 0:c1910e04fc6c 2980
charlesmn 0:c1910e04fc6c 2981 return VL53LX_init_ssc_config_struct(pdata);
charlesmn 0:c1910e04fc6c 2982
charlesmn 0:c1910e04fc6c 2983 }
charlesmn 0:c1910e04fc6c 2984
charlesmn 0:c1910e04fc6c 2985
charlesmn 0:c1910e04fc6c 2986 VL53LX_Error VL53L3CX::VL53L3CX_init_xtalk_config_struct(
charlesmn 0:c1910e04fc6c 2987 VL53LX_customer_nvm_managed_t *pnvm,
charlesmn 0:c1910e04fc6c 2988 VL53LX_xtalk_config_t *pdata)
charlesmn 0:c1910e04fc6c 2989 {
charlesmn 0:c1910e04fc6c 2990
charlesmn 0:c1910e04fc6c 2991 return VL53LX_init_xtalk_config_struct(
charlesmn 0:c1910e04fc6c 2992 pnvm,
charlesmn 0:c1910e04fc6c 2993 pdata);
charlesmn 0:c1910e04fc6c 2994
charlesmn 0:c1910e04fc6c 2995 }
charlesmn 0:c1910e04fc6c 2996
charlesmn 0:c1910e04fc6c 2997 VL53LX_Error VL53L3CX::VL53L3CX_init_xtalk_extract_config_struct(
charlesmn 0:c1910e04fc6c 2998 VL53LX_xtalkextract_config_t *pdata)
charlesmn 0:c1910e04fc6c 2999 {
charlesmn 0:c1910e04fc6c 3000
charlesmn 0:c1910e04fc6c 3001 return VL53LX_init_xtalk_extract_config_struct(pdata);
charlesmn 0:c1910e04fc6c 3002
charlesmn 0:c1910e04fc6c 3003 }
charlesmn 0:c1910e04fc6c 3004
charlesmn 0:c1910e04fc6c 3005
charlesmn 0:c1910e04fc6c 3006 VL53LX_Error VL53L3CX::VL53L3CX_init_offset_cal_config_struct(
charlesmn 0:c1910e04fc6c 3007 VL53LX_offsetcal_config_t *pdata)
charlesmn 0:c1910e04fc6c 3008 {
charlesmn 0:c1910e04fc6c 3009
charlesmn 0:c1910e04fc6c 3010 return VL53LX_init_offset_cal_config_struct(pdata);
charlesmn 0:c1910e04fc6c 3011
charlesmn 0:c1910e04fc6c 3012 }
charlesmn 0:c1910e04fc6c 3013
charlesmn 0:c1910e04fc6c 3014 VL53LX_Error VL53L3CX::VL53L3CX_init_zone_cal_config_struct(
charlesmn 0:c1910e04fc6c 3015 VL53LX_zonecal_config_t *pdata)
charlesmn 0:c1910e04fc6c 3016 {
charlesmn 0:c1910e04fc6c 3017
charlesmn 0:c1910e04fc6c 3018 return VL53LX_init_zone_cal_config_struct(pdata);
charlesmn 0:c1910e04fc6c 3019
charlesmn 0:c1910e04fc6c 3020 }
charlesmn 0:c1910e04fc6c 3021
charlesmn 0:c1910e04fc6c 3022 VL53LX_Error VL53L3CX::VL53L3CX_init_hist_post_process_config_struct(
charlesmn 0:c1910e04fc6c 3023 uint8_t xtalk_compensation_enable,
charlesmn 0:c1910e04fc6c 3024 VL53LX_hist_post_process_config_t *pdata)
charlesmn 0:c1910e04fc6c 3025 {
charlesmn 0:c1910e04fc6c 3026
charlesmn 0:c1910e04fc6c 3027 return VL53LX_init_hist_post_process_config_struct(
charlesmn 0:c1910e04fc6c 3028 xtalk_compensation_enable,
charlesmn 0:c1910e04fc6c 3029 pdata);
charlesmn 0:c1910e04fc6c 3030
charlesmn 0:c1910e04fc6c 3031 }
charlesmn 0:c1910e04fc6c 3032
charlesmn 0:c1910e04fc6c 3033
charlesmn 0:c1910e04fc6c 3034 VL53LX_Error VL53L3CX::VL53L3CX_init_dmax_calibration_data_struct(
charlesmn 0:c1910e04fc6c 3035 VL53LX_dmax_calibration_data_t *pdata)
charlesmn 0:c1910e04fc6c 3036 {
charlesmn 0:c1910e04fc6c 3037
charlesmn 0:c1910e04fc6c 3038 return VL53LX_init_dmax_calibration_data_struct( pdata );
charlesmn 0:c1910e04fc6c 3039
charlesmn 0:c1910e04fc6c 3040 }
charlesmn 0:c1910e04fc6c 3041
charlesmn 0:c1910e04fc6c 3042 VL53LX_Error VL53L3CX::VL53L3CX_init_tuning_parm_storage_struct(
charlesmn 0:c1910e04fc6c 3043 VL53LX_tuning_parm_storage_t *pdata)
charlesmn 0:c1910e04fc6c 3044 {
charlesmn 0:c1910e04fc6c 3045
charlesmn 0:c1910e04fc6c 3046 return VL53LX_init_tuning_parm_storage_struct( pdata );
charlesmn 0:c1910e04fc6c 3047
charlesmn 0:c1910e04fc6c 3048 }
charlesmn 0:c1910e04fc6c 3049
charlesmn 0:c1910e04fc6c 3050 VL53LX_Error VL53L3CX::VL53L3CX_init_hist_gen3_dmax_config_struct(
charlesmn 0:c1910e04fc6c 3051 VL53LX_hist_gen3_dmax_config_t *pdata)
charlesmn 0:c1910e04fc6c 3052 {
charlesmn 0:c1910e04fc6c 3053 return VL53LX_init_hist_gen3_dmax_config_struct( pdata);
charlesmn 0:c1910e04fc6c 3054 }
charlesmn 0:c1910e04fc6c 3055
charlesmn 0:c1910e04fc6c 3056
charlesmn 0:c1910e04fc6c 3057 VL53LX_Error VL53L3CX::VL53L3CX_preset_mode_standard_ranging(
charlesmn 0:c1910e04fc6c 3058 VL53LX_static_config_t *pstatic,
charlesmn 0:c1910e04fc6c 3059 VL53LX_histogram_config_t *phistogram,
charlesmn 0:c1910e04fc6c 3060 VL53LX_general_config_t *pgeneral,
charlesmn 0:c1910e04fc6c 3061 VL53LX_timing_config_t *ptiming,
charlesmn 0:c1910e04fc6c 3062 VL53LX_dynamic_config_t *pdynamic,
charlesmn 0:c1910e04fc6c 3063 VL53LX_system_control_t *psystem,
charlesmn 0:c1910e04fc6c 3064 VL53LX_tuning_parm_storage_t *ptuning_parms,
charlesmn 0:c1910e04fc6c 3065 VL53LX_zone_config_t *pzone_cfg)
charlesmn 0:c1910e04fc6c 3066 {
charlesmn 0:c1910e04fc6c 3067
charlesmn 0:c1910e04fc6c 3068
charlesmn 0:c1910e04fc6c 3069 return VL53LX_preset_mode_standard_ranging(
charlesmn 0:c1910e04fc6c 3070 pstatic,
charlesmn 0:c1910e04fc6c 3071 phistogram,
charlesmn 0:c1910e04fc6c 3072 pgeneral,
charlesmn 0:c1910e04fc6c 3073 ptiming,
charlesmn 0:c1910e04fc6c 3074 pdynamic,
charlesmn 0:c1910e04fc6c 3075 psystem,
charlesmn 0:c1910e04fc6c 3076 ptuning_parms,
charlesmn 0:c1910e04fc6c 3077 pzone_cfg);
charlesmn 0:c1910e04fc6c 3078 }
charlesmn 0:c1910e04fc6c 3079
charlesmn 0:c1910e04fc6c 3080 VL53LX_Error VL53L3CX::VL53L3CX_preset_mode_histogram_ranging(
charlesmn 0:c1910e04fc6c 3081 VL53LX_hist_post_process_config_t *phistpostprocess,
charlesmn 0:c1910e04fc6c 3082 VL53LX_static_config_t *pstatic,
charlesmn 0:c1910e04fc6c 3083 VL53LX_histogram_config_t *phistogram,
charlesmn 0:c1910e04fc6c 3084 VL53LX_general_config_t *pgeneral,
charlesmn 0:c1910e04fc6c 3085 VL53LX_timing_config_t *ptiming,
charlesmn 0:c1910e04fc6c 3086 VL53LX_dynamic_config_t *pdynamic,
charlesmn 0:c1910e04fc6c 3087 VL53LX_system_control_t *psystem,
charlesmn 0:c1910e04fc6c 3088 VL53LX_tuning_parm_storage_t *ptuning_parms,
charlesmn 0:c1910e04fc6c 3089 VL53LX_zone_config_t *pzone_cfg)
charlesmn 0:c1910e04fc6c 3090 {
charlesmn 0:c1910e04fc6c 3091
charlesmn 0:c1910e04fc6c 3092 return VL53LX_preset_mode_histogram_ranging( phistpostprocess,
charlesmn 0:c1910e04fc6c 3093 pstatic,
charlesmn 0:c1910e04fc6c 3094 phistogram,
charlesmn 0:c1910e04fc6c 3095 pgeneral,
charlesmn 0:c1910e04fc6c 3096 ptiming,
charlesmn 0:c1910e04fc6c 3097 pdynamic,
charlesmn 0:c1910e04fc6c 3098 psystem,
charlesmn 0:c1910e04fc6c 3099 ptuning_parms,
charlesmn 0:c1910e04fc6c 3100 pzone_cfg);
charlesmn 0:c1910e04fc6c 3101
charlesmn 0:c1910e04fc6c 3102 }
charlesmn 0:c1910e04fc6c 3103
charlesmn 0:c1910e04fc6c 3104
charlesmn 0:c1910e04fc6c 3105 VL53LX_Error VL53L3CX::VL53L3CX_preset_mode_histogram_long_range(
charlesmn 0:c1910e04fc6c 3106 VL53LX_hist_post_process_config_t *phistpostprocess,
charlesmn 0:c1910e04fc6c 3107 VL53LX_static_config_t *pstatic,
charlesmn 0:c1910e04fc6c 3108 VL53LX_histogram_config_t *phistogram,
charlesmn 0:c1910e04fc6c 3109 VL53LX_general_config_t *pgeneral,
charlesmn 0:c1910e04fc6c 3110 VL53LX_timing_config_t *ptiming,
charlesmn 0:c1910e04fc6c 3111 VL53LX_dynamic_config_t *pdynamic,
charlesmn 0:c1910e04fc6c 3112 VL53LX_system_control_t *psystem,
charlesmn 0:c1910e04fc6c 3113 VL53LX_tuning_parm_storage_t *ptuning_parms,
charlesmn 0:c1910e04fc6c 3114 VL53LX_zone_config_t *pzone_cfg)
charlesmn 0:c1910e04fc6c 3115 {
charlesmn 0:c1910e04fc6c 3116
charlesmn 0:c1910e04fc6c 3117 return VL53LX_preset_mode_histogram_long_range( phistpostprocess,
charlesmn 0:c1910e04fc6c 3118 pstatic,
charlesmn 0:c1910e04fc6c 3119 phistogram,
charlesmn 0:c1910e04fc6c 3120 pgeneral,
charlesmn 0:c1910e04fc6c 3121 ptiming,
charlesmn 0:c1910e04fc6c 3122 pdynamic,
charlesmn 0:c1910e04fc6c 3123 psystem,
charlesmn 0:c1910e04fc6c 3124 ptuning_parms,
charlesmn 0:c1910e04fc6c 3125 pzone_cfg);
charlesmn 0:c1910e04fc6c 3126
charlesmn 0:c1910e04fc6c 3127 }
charlesmn 0:c1910e04fc6c 3128
charlesmn 0:c1910e04fc6c 3129
charlesmn 0:c1910e04fc6c 3130
charlesmn 0:c1910e04fc6c 3131 VL53LX_Error VL53L3CX::VL53L3CX_preset_mode_histogram_medium_range(
charlesmn 0:c1910e04fc6c 3132 VL53LX_hist_post_process_config_t *phistpostprocess,
charlesmn 0:c1910e04fc6c 3133 VL53LX_static_config_t *pstatic,
charlesmn 0:c1910e04fc6c 3134 VL53LX_histogram_config_t *phistogram,
charlesmn 0:c1910e04fc6c 3135 VL53LX_general_config_t *pgeneral,
charlesmn 0:c1910e04fc6c 3136 VL53LX_timing_config_t *ptiming,
charlesmn 0:c1910e04fc6c 3137 VL53LX_dynamic_config_t *pdynamic,
charlesmn 0:c1910e04fc6c 3138 VL53LX_system_control_t *psystem,
charlesmn 0:c1910e04fc6c 3139 VL53LX_tuning_parm_storage_t *ptuning_parms,
charlesmn 0:c1910e04fc6c 3140 VL53LX_zone_config_t *pzone_cfg)
charlesmn 0:c1910e04fc6c 3141 {
charlesmn 0:c1910e04fc6c 3142
charlesmn 0:c1910e04fc6c 3143
charlesmn 0:c1910e04fc6c 3144 return VL53LX_preset_mode_histogram_medium_range( phistpostprocess,
charlesmn 0:c1910e04fc6c 3145 pstatic,
charlesmn 0:c1910e04fc6c 3146 phistogram,
charlesmn 0:c1910e04fc6c 3147 pgeneral,
charlesmn 0:c1910e04fc6c 3148 ptiming,
charlesmn 0:c1910e04fc6c 3149 pdynamic,
charlesmn 0:c1910e04fc6c 3150 psystem,
charlesmn 0:c1910e04fc6c 3151 ptuning_parms,
charlesmn 0:c1910e04fc6c 3152 pzone_cfg);
charlesmn 0:c1910e04fc6c 3153
charlesmn 0:c1910e04fc6c 3154 }
charlesmn 0:c1910e04fc6c 3155
charlesmn 0:c1910e04fc6c 3156
charlesmn 0:c1910e04fc6c 3157 VL53LX_Error VL53L3CX::VL53L3CX_preset_mode_histogram_short_range(
charlesmn 0:c1910e04fc6c 3158 VL53LX_hist_post_process_config_t *phistpostprocess,
charlesmn 0:c1910e04fc6c 3159 VL53LX_static_config_t *pstatic,
charlesmn 0:c1910e04fc6c 3160 VL53LX_histogram_config_t *phistogram,
charlesmn 0:c1910e04fc6c 3161 VL53LX_general_config_t *pgeneral,
charlesmn 0:c1910e04fc6c 3162 VL53LX_timing_config_t *ptiming,
charlesmn 0:c1910e04fc6c 3163 VL53LX_dynamic_config_t *pdynamic,
charlesmn 0:c1910e04fc6c 3164 VL53LX_system_control_t *psystem,
charlesmn 0:c1910e04fc6c 3165 VL53LX_tuning_parm_storage_t *ptuning_parms,
charlesmn 0:c1910e04fc6c 3166 VL53LX_zone_config_t *pzone_cfg)
charlesmn 0:c1910e04fc6c 3167 {
charlesmn 0:c1910e04fc6c 3168
charlesmn 0:c1910e04fc6c 3169
charlesmn 0:c1910e04fc6c 3170 return VL53LX_preset_mode_histogram_short_range(phistpostprocess,
charlesmn 0:c1910e04fc6c 3171 pstatic,
charlesmn 0:c1910e04fc6c 3172 phistogram,
charlesmn 0:c1910e04fc6c 3173 pgeneral,
charlesmn 0:c1910e04fc6c 3174 ptiming,
charlesmn 0:c1910e04fc6c 3175 pdynamic,
charlesmn 0:c1910e04fc6c 3176 psystem,
charlesmn 0:c1910e04fc6c 3177 ptuning_parms,
charlesmn 0:c1910e04fc6c 3178 pzone_cfg);
charlesmn 0:c1910e04fc6c 3179
charlesmn 0:c1910e04fc6c 3180 }
charlesmn 0:c1910e04fc6c 3181
charlesmn 0:c1910e04fc6c 3182
charlesmn 0:c1910e04fc6c 3183
charlesmn 0:c1910e04fc6c 3184
charlesmn 0:c1910e04fc6c 3185
charlesmn 0:c1910e04fc6c 3186 void VL53L3CX::VL53L3CX_copy_hist_bins_to_static_cfg(
charlesmn 0:c1910e04fc6c 3187 VL53LX_histogram_config_t *phistogram,
charlesmn 0:c1910e04fc6c 3188 VL53LX_static_config_t *pstatic,
charlesmn 0:c1910e04fc6c 3189 VL53LX_timing_config_t *ptiming)
charlesmn 0:c1910e04fc6c 3190 {
charlesmn 0:c1910e04fc6c 3191
charlesmn 0:c1910e04fc6c 3192 return VL53LX_copy_hist_bins_to_static_cfg(phistogram,
charlesmn 0:c1910e04fc6c 3193 pstatic,
charlesmn 0:c1910e04fc6c 3194 ptiming);
charlesmn 0:c1910e04fc6c 3195
charlesmn 0:c1910e04fc6c 3196 }
charlesmn 0:c1910e04fc6c 3197
charlesmn 0:c1910e04fc6c 3198
charlesmn 0:c1910e04fc6c 3199 /* vl53lx_silicon_core.c */
charlesmn 0:c1910e04fc6c 3200
charlesmn 0:c1910e04fc6c 3201 VL53LX_Error VL53L3CX::VL53L3CX_is_firmware_ready_silicon(
charlesmn 0:c1910e04fc6c 3202 uint8_t *pready)
charlesmn 0:c1910e04fc6c 3203 {
charlesmn 0:c1910e04fc6c 3204
charlesmn 0:c1910e04fc6c 3205 return VL53LX_is_firmware_ready_silicon( Dev, pready);
charlesmn 0:c1910e04fc6c 3206
charlesmn 0:c1910e04fc6c 3207 }
charlesmn 0:c1910e04fc6c 3208
charlesmn 0:c1910e04fc6c 3209 /* vl53lx_hist_core.c */
charlesmn 0:c1910e04fc6c 3210
charlesmn 0:c1910e04fc6c 3211
charlesmn 0:c1910e04fc6c 3212 /* vl53lx_xtalk.c */
charlesmn 0:c1910e04fc6c 3213
charlesmn 0:c1910e04fc6c 3214
charlesmn 0:c1910e04fc6c 3215 VL53LX_Error VL53L3CX::VL53L3CX_xtalk_calibration_process_data(
charlesmn 0:c1910e04fc6c 3216 VL53LX_xtalk_range_results_t *pxtalk_results,
charlesmn 0:c1910e04fc6c 3217 VL53LX_xtalk_histogram_data_t *pxtalk_shape,
charlesmn 0:c1910e04fc6c 3218 VL53LX_xtalk_calibration_results_t *pxtalk_cal)
charlesmn 0:c1910e04fc6c 3219 {
charlesmn 0:c1910e04fc6c 3220
charlesmn 0:c1910e04fc6c 3221 return VL53LX_xtalk_calibration_process_data( pxtalk_results,
charlesmn 0:c1910e04fc6c 3222 pxtalk_shape,
charlesmn 0:c1910e04fc6c 3223 pxtalk_cal);
charlesmn 0:c1910e04fc6c 3224
charlesmn 0:c1910e04fc6c 3225 }
charlesmn 0:c1910e04fc6c 3226
charlesmn 0:c1910e04fc6c 3227
charlesmn 0:c1910e04fc6c 3228
charlesmn 0:c1910e04fc6c 3229
charlesmn 0:c1910e04fc6c 3230 /* vl53lx_sigma_estimate.c */
charlesmn 0:c1910e04fc6c 3231
charlesmn 0:c1910e04fc6c 3232
charlesmn 0:c1910e04fc6c 3233
charlesmn 0:c1910e04fc6c 3234 /* vl53lx_hist_algos_gen3.c */
charlesmn 0:c1910e04fc6c 3235
charlesmn 0:c1910e04fc6c 3236
charlesmn 0:c1910e04fc6c 3237
charlesmn 0:c1910e04fc6c 3238
charlesmn 0:c1910e04fc6c 3239
charlesmn 0:c1910e04fc6c 3240 /* vl53lx_hist_algos_gen4.c */
charlesmn 0:c1910e04fc6c 3241
charlesmn 0:c1910e04fc6c 3242
charlesmn 0:c1910e04fc6c 3243
charlesmn 0:c1910e04fc6c 3244
charlesmn 0:c1910e04fc6c 3245
charlesmn 0:c1910e04fc6c 3246 /* vl53lx_dmax.c */
charlesmn 0:c1910e04fc6c 3247
charlesmn 0:c1910e04fc6c 3248
charlesmn 0:c1910e04fc6c 3249
charlesmn 0:c1910e04fc6c 3250
charlesmn 0:c1910e04fc6c 3251
charlesmn 0:c1910e04fc6c 3252 /* vl53lx_api_calibration.c */
charlesmn 0:c1910e04fc6c 3253
charlesmn 0:c1910e04fc6c 3254
charlesmn 0:c1910e04fc6c 3255 VL53LX_Error VL53L3CX::VL53L3CX_run_ref_spad_char(
charlesmn 0:c1910e04fc6c 3256 VL53LX_Error *pcal_status)
charlesmn 0:c1910e04fc6c 3257 {
charlesmn 0:c1910e04fc6c 3258 return VL53LX_run_ref_spad_char(Dev, pcal_status);
charlesmn 0:c1910e04fc6c 3259 }
charlesmn 0:c1910e04fc6c 3260
charlesmn 0:c1910e04fc6c 3261
charlesmn 0:c1910e04fc6c 3262 VL53LX_Error VL53L3CX::VL53L3CX_get_and_avg_xtalk_samples(
charlesmn 0:c1910e04fc6c 3263 uint8_t num_of_samples,
charlesmn 0:c1910e04fc6c 3264 uint8_t measurement_mode,
charlesmn 0:c1910e04fc6c 3265 int16_t xtalk_filter_thresh_max_mm,
charlesmn 0:c1910e04fc6c 3266 int16_t xtalk_filter_thresh_min_mm,
charlesmn 0:c1910e04fc6c 3267 uint16_t xtalk_max_valid_rate_kcps,
charlesmn 0:c1910e04fc6c 3268 uint8_t xtalk_result_id,
charlesmn 0:c1910e04fc6c 3269 uint8_t xtalk_histo_id,
charlesmn 0:c1910e04fc6c 3270 VL53LX_xtalk_range_results_t *pXR,
charlesmn 0:c1910e04fc6c 3271 VL53LX_histogram_bin_data_t *psum_histo,
charlesmn 0:c1910e04fc6c 3272 VL53LX_histogram_bin_data_t *pavg_histo)
charlesmn 0:c1910e04fc6c 3273 {
charlesmn 0:c1910e04fc6c 3274
charlesmn 0:c1910e04fc6c 3275 return VL53LX_get_and_avg_xtalk_samples( Dev,
charlesmn 0:c1910e04fc6c 3276 num_of_samples,
charlesmn 0:c1910e04fc6c 3277 measurement_mode,
charlesmn 0:c1910e04fc6c 3278 xtalk_filter_thresh_max_mm,
charlesmn 0:c1910e04fc6c 3279 xtalk_filter_thresh_min_mm,
charlesmn 0:c1910e04fc6c 3280 xtalk_max_valid_rate_kcps,
charlesmn 0:c1910e04fc6c 3281 xtalk_result_id,
charlesmn 0:c1910e04fc6c 3282 xtalk_histo_id,
charlesmn 0:c1910e04fc6c 3283 pXR,
charlesmn 0:c1910e04fc6c 3284 psum_histo,
charlesmn 0:c1910e04fc6c 3285 pavg_histo);
charlesmn 0:c1910e04fc6c 3286
charlesmn 0:c1910e04fc6c 3287 }
charlesmn 0:c1910e04fc6c 3288
charlesmn 0:c1910e04fc6c 3289
charlesmn 0:c1910e04fc6c 3290
charlesmn 0:c1910e04fc6c 3291 VL53LX_Error VL53L3CX::VL53L3CX_run_device_test(
charlesmn 0:c1910e04fc6c 3292 VL53LX_DeviceTestMode device_test_mode)
charlesmn 0:c1910e04fc6c 3293 {
charlesmn 0:c1910e04fc6c 3294 return VL53LX_run_device_test( Dev, device_test_mode);
charlesmn 0:c1910e04fc6c 3295 }
charlesmn 0:c1910e04fc6c 3296
charlesmn 0:c1910e04fc6c 3297 void VL53L3CX::VL53L3CX_hist_xtalk_extract_data_init(
charlesmn 0:c1910e04fc6c 3298 VL53LX_hist_xtalk_extract_data_t *pxtalk_data)
charlesmn 0:c1910e04fc6c 3299 {
charlesmn 0:c1910e04fc6c 3300
charlesmn 0:c1910e04fc6c 3301 VL53LX_hist_xtalk_extract_data_init(pxtalk_data);
charlesmn 0:c1910e04fc6c 3302
charlesmn 0:c1910e04fc6c 3303 }
charlesmn 0:c1910e04fc6c 3304
charlesmn 0:c1910e04fc6c 3305 VL53LX_Error VL53L3CX::VL53L3CX_hist_xtalk_extract_update(
charlesmn 0:c1910e04fc6c 3306 int16_t target_distance_mm,
charlesmn 0:c1910e04fc6c 3307 uint16_t target_width_oversize,
charlesmn 0:c1910e04fc6c 3308 VL53LX_histogram_bin_data_t *phist_bins,
charlesmn 0:c1910e04fc6c 3309 VL53LX_hist_xtalk_extract_data_t *pxtalk_data)
charlesmn 0:c1910e04fc6c 3310 {
charlesmn 0:c1910e04fc6c 3311
charlesmn 0:c1910e04fc6c 3312 return VL53LX_hist_xtalk_extract_update(target_distance_mm,
charlesmn 0:c1910e04fc6c 3313 target_width_oversize,
charlesmn 0:c1910e04fc6c 3314 phist_bins,
charlesmn 0:c1910e04fc6c 3315 pxtalk_data);
charlesmn 0:c1910e04fc6c 3316
charlesmn 0:c1910e04fc6c 3317 }
charlesmn 0:c1910e04fc6c 3318
charlesmn 0:c1910e04fc6c 3319
charlesmn 0:c1910e04fc6c 3320 VL53LX_Error VL53L3CX::VL53L3CX_hist_xtalk_extract_fini(
charlesmn 0:c1910e04fc6c 3321 VL53LX_histogram_bin_data_t *phist_bins,
charlesmn 0:c1910e04fc6c 3322 VL53LX_hist_xtalk_extract_data_t *pxtalk_data,
charlesmn 0:c1910e04fc6c 3323 VL53LX_xtalk_calibration_results_t *pxtalk_cal,
charlesmn 0:c1910e04fc6c 3324 VL53LX_xtalk_histogram_shape_t *pxtalk_shape)
charlesmn 0:c1910e04fc6c 3325 {
charlesmn 0:c1910e04fc6c 3326
charlesmn 0:c1910e04fc6c 3327 return VL53LX_hist_xtalk_extract_fini( phist_bins,
charlesmn 0:c1910e04fc6c 3328 pxtalk_data,
charlesmn 0:c1910e04fc6c 3329 pxtalk_cal,
charlesmn 0:c1910e04fc6c 3330 pxtalk_shape);
charlesmn 0:c1910e04fc6c 3331
charlesmn 0:c1910e04fc6c 3332 }
charlesmn 0:c1910e04fc6c 3333
charlesmn 0:c1910e04fc6c 3334
charlesmn 0:c1910e04fc6c 3335 VL53LX_Error VL53L3CX::VL53L3CX_run_hist_xtalk_extraction(
charlesmn 0:c1910e04fc6c 3336 int16_t cal_distance_mm,
charlesmn 0:c1910e04fc6c 3337 VL53LX_Error *pcal_status)
charlesmn 0:c1910e04fc6c 3338 {
charlesmn 0:c1910e04fc6c 3339 return VL53LX_run_hist_xtalk_extraction(Dev, cal_distance_mm, pcal_status);
charlesmn 0:c1910e04fc6c 3340 }
charlesmn 0:c1910e04fc6c 3341
charlesmn 0:c1910e04fc6c 3342 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3343
charlesmn 0:c1910e04fc6c 3344 VL53LX_Error VL53L3CX::VL53L3CX_GetVersion(VL53LX_Version_t *pVersion)
charlesmn 0:c1910e04fc6c 3345 {
charlesmn 0:c1910e04fc6c 3346 return VL53LX_GetVersion( pVersion);
charlesmn 0:c1910e04fc6c 3347 }
charlesmn 0:c1910e04fc6c 3348
charlesmn 0:c1910e04fc6c 3349 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3350 VL53LX_Error VL53L3CX::VL53L3CX_GetProductRevision(
charlesmn 0:c1910e04fc6c 3351 uint8_t *pProductRevisionMajor, uint8_t *pProductRevisionMinor)
charlesmn 0:c1910e04fc6c 3352 {
charlesmn 0:c1910e04fc6c 3353 return VL53LX_GetProductRevision( Dev,
charlesmn 0:c1910e04fc6c 3354 pProductRevisionMajor,
charlesmn 0:c1910e04fc6c 3355 pProductRevisionMinor);
charlesmn 0:c1910e04fc6c 3356 }
charlesmn 0:c1910e04fc6c 3357
charlesmn 0:c1910e04fc6c 3358 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3359 VL53LX_Error VL53L3CX::VL53L3CX_GetDeviceInfo(
charlesmn 0:c1910e04fc6c 3360 VL53LX_DeviceInfo_t *pVL53LX_DeviceInfo)
charlesmn 0:c1910e04fc6c 3361 {
charlesmn 0:c1910e04fc6c 3362 return VL53LX_GetDeviceInfo( Dev,pVL53LX_DeviceInfo);
charlesmn 0:c1910e04fc6c 3363 }
charlesmn 0:c1910e04fc6c 3364
charlesmn 0:c1910e04fc6c 3365 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3366 VL53LX_Error VL53L3CX::VL53L3CX_GetUID(uint64_t *pUid)
charlesmn 0:c1910e04fc6c 3367 {
charlesmn 0:c1910e04fc6c 3368 return VL53LX_GetUID( Dev, pUid);
charlesmn 0:c1910e04fc6c 3369 }
charlesmn 0:c1910e04fc6c 3370 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3371 VL53LX_Error VL53L3CX::VL53L3CX_SetDeviceAddress(uint8_t DeviceAddress)
charlesmn 0:c1910e04fc6c 3372 {
charlesmn 0:c1910e04fc6c 3373 return VL53LX_SetDeviceAddress(Dev, DeviceAddress);
charlesmn 0:c1910e04fc6c 3374 }
charlesmn 0:c1910e04fc6c 3375
charlesmn 0:c1910e04fc6c 3376 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3377 VL53LX_Error VL53L3CX::VL53L3CX_DataInit()
charlesmn 0:c1910e04fc6c 3378 {
charlesmn 0:c1910e04fc6c 3379 return VL53LX_DataInit(Dev);
charlesmn 0:c1910e04fc6c 3380 }
charlesmn 0:c1910e04fc6c 3381
charlesmn 0:c1910e04fc6c 3382 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3383 VL53LX_Error VL53L3CX::VL53L3CX_WaitDeviceBooted()
charlesmn 0:c1910e04fc6c 3384 {
charlesmn 0:c1910e04fc6c 3385 return VL53LX_WaitDeviceBooted(Dev);
charlesmn 0:c1910e04fc6c 3386 }
charlesmn 0:c1910e04fc6c 3387
charlesmn 0:c1910e04fc6c 3388
charlesmn 0:c1910e04fc6c 3389 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3390 VL53LX_Error VL53L3CX::VL53L3CX_SetDistanceMode(
charlesmn 0:c1910e04fc6c 3391 VL53LX_DistanceModes DistanceMode)
charlesmn 0:c1910e04fc6c 3392 {
charlesmn 0:c1910e04fc6c 3393
charlesmn 0:c1910e04fc6c 3394 return VL53LX_SetDistanceMode(Dev, DistanceMode);
charlesmn 0:c1910e04fc6c 3395
charlesmn 0:c1910e04fc6c 3396 }
charlesmn 0:c1910e04fc6c 3397 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3398 VL53LX_Error VL53L3CX::VL53L3CX_GetDistanceMode(
charlesmn 0:c1910e04fc6c 3399 VL53LX_DistanceModes *pDistanceMode)
charlesmn 0:c1910e04fc6c 3400 {
charlesmn 0:c1910e04fc6c 3401 return VL53LX_GetDistanceMode(Dev, pDistanceMode);;
charlesmn 0:c1910e04fc6c 3402 }
charlesmn 0:c1910e04fc6c 3403
charlesmn 0:c1910e04fc6c 3404 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3405 VL53LX_Error VL53L3CX::VL53L3CX_SetMeasurementTimingBudgetMicroSeconds(
charlesmn 0:c1910e04fc6c 3406 uint32_t MeasurementTimingBudgetMicroSeconds)
charlesmn 0:c1910e04fc6c 3407 {
charlesmn 0:c1910e04fc6c 3408
charlesmn 0:c1910e04fc6c 3409 return VL53LX_SetMeasurementTimingBudgetMicroSeconds(Dev,
charlesmn 0:c1910e04fc6c 3410 MeasurementTimingBudgetMicroSeconds);
charlesmn 0:c1910e04fc6c 3411
charlesmn 0:c1910e04fc6c 3412 }
charlesmn 0:c1910e04fc6c 3413
charlesmn 0:c1910e04fc6c 3414 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3415 VL53LX_Error VL53L3CX::VL53L3CX_GetMeasurementTimingBudgetMicroSeconds(
charlesmn 0:c1910e04fc6c 3416 uint32_t *pMeasurementTimingBudgetMicroSeconds)
charlesmn 0:c1910e04fc6c 3417 {
charlesmn 0:c1910e04fc6c 3418 return VL53LX_GetMeasurementTimingBudgetMicroSeconds(Dev,pMeasurementTimingBudgetMicroSeconds);
charlesmn 0:c1910e04fc6c 3419 }
charlesmn 0:c1910e04fc6c 3420
charlesmn 0:c1910e04fc6c 3421 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3422 VL53LX_Error VL53L3CX::VL53L3CX_StartMeasurement()
charlesmn 0:c1910e04fc6c 3423 {
charlesmn 0:c1910e04fc6c 3424 return VL53LX_StartMeasurement(Dev);
charlesmn 0:c1910e04fc6c 3425 }
charlesmn 0:c1910e04fc6c 3426
charlesmn 0:c1910e04fc6c 3427 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3428 VL53LX_Error VL53L3CX::VL53L3CX_StopMeasurement()
charlesmn 0:c1910e04fc6c 3429 {
charlesmn 0:c1910e04fc6c 3430 return VL53LX_StopMeasurement(Dev);
charlesmn 0:c1910e04fc6c 3431 }
charlesmn 0:c1910e04fc6c 3432
charlesmn 0:c1910e04fc6c 3433 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3434 VL53LX_Error VL53L3CX::VL53L3CX_ClearInterruptAndStartMeasurement()
charlesmn 0:c1910e04fc6c 3435 {
charlesmn 0:c1910e04fc6c 3436 return VL53LX_ClearInterruptAndStartMeasurement(Dev);
charlesmn 0:c1910e04fc6c 3437 }
charlesmn 0:c1910e04fc6c 3438
charlesmn 0:c1910e04fc6c 3439 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3440 VL53LX_Error VL53L3CX::VL53L3CX_GetMeasurementDataReady(uint8_t *pMeasurementDataReady)
charlesmn 0:c1910e04fc6c 3441 {
charlesmn 0:c1910e04fc6c 3442 return VL53LX_GetMeasurementDataReady(Dev, pMeasurementDataReady);
charlesmn 0:c1910e04fc6c 3443 }
charlesmn 0:c1910e04fc6c 3444 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3445 VL53LX_Error VL53L3CX::VL53L3CX_WaitMeasurementDataReady()
charlesmn 0:c1910e04fc6c 3446 {
charlesmn 0:c1910e04fc6c 3447 return VL53LX_WaitMeasurementDataReady(Dev);
charlesmn 0:c1910e04fc6c 3448 }
charlesmn 0:c1910e04fc6c 3449
charlesmn 0:c1910e04fc6c 3450
charlesmn 0:c1910e04fc6c 3451
charlesmn 0:c1910e04fc6c 3452 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3453 VL53LX_Error VL53L3CX::VL53L3CX_GetMultiRangingData(
charlesmn 0:c1910e04fc6c 3454 VL53LX_MultiRangingData_t *pMultiRangingData)
charlesmn 0:c1910e04fc6c 3455 {
charlesmn 0:c1910e04fc6c 3456
charlesmn 0:c1910e04fc6c 3457 return VL53LX_GetMultiRangingData(Dev, pMultiRangingData);
charlesmn 0:c1910e04fc6c 3458
charlesmn 0:c1910e04fc6c 3459 }
charlesmn 0:c1910e04fc6c 3460 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3461 VL53LX_Error VL53L3CX::VL53L3CX_GetAdditionalData(VL53LX_AdditionalData_t *pAdditionalData)
charlesmn 0:c1910e04fc6c 3462 {
charlesmn 0:c1910e04fc6c 3463 return VL53LX_GetAdditionalData( Dev,pAdditionalData);
charlesmn 0:c1910e04fc6c 3464 }
charlesmn 0:c1910e04fc6c 3465
charlesmn 0:c1910e04fc6c 3466 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3467 VL53LX_Error VL53L3CX::VL53L3CX_SetTuningParameter(
charlesmn 0:c1910e04fc6c 3468 uint16_t TuningParameterId, int32_t TuningParameterValue)
charlesmn 0:c1910e04fc6c 3469 {
charlesmn 0:c1910e04fc6c 3470
charlesmn 0:c1910e04fc6c 3471 return VL53LX_SetTuningParameter( Dev, TuningParameterId, TuningParameterValue);
charlesmn 0:c1910e04fc6c 3472
charlesmn 0:c1910e04fc6c 3473 }
charlesmn 0:c1910e04fc6c 3474
charlesmn 0:c1910e04fc6c 3475 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3476 VL53LX_Error VL53L3CX::VL53L3CX_GetTuningParameter(
charlesmn 0:c1910e04fc6c 3477 uint16_t TuningParameterId, int32_t *pTuningParameterValue)
charlesmn 0:c1910e04fc6c 3478 {
charlesmn 0:c1910e04fc6c 3479
charlesmn 0:c1910e04fc6c 3480 return VL53LX_GetTuningParameter( Dev, TuningParameterId, pTuningParameterValue);
charlesmn 0:c1910e04fc6c 3481
charlesmn 0:c1910e04fc6c 3482 }
charlesmn 0:c1910e04fc6c 3483
charlesmn 0:c1910e04fc6c 3484 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3485 VL53LX_Error VL53L3CX::VL53L3CX_PerformRefSpadManagement()
charlesmn 0:c1910e04fc6c 3486 {
charlesmn 0:c1910e04fc6c 3487
charlesmn 0:c1910e04fc6c 3488 return VL53LX_PerformRefSpadManagement(Dev);
charlesmn 0:c1910e04fc6c 3489
charlesmn 0:c1910e04fc6c 3490 }
charlesmn 0:c1910e04fc6c 3491
charlesmn 0:c1910e04fc6c 3492 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3493 VL53LX_Error VL53L3CX::VL53L3CX_SmudgeCorrectionEnable(
charlesmn 0:c1910e04fc6c 3494 VL53LX_SmudgeCorrectionModes Mode)
charlesmn 0:c1910e04fc6c 3495 {
charlesmn 0:c1910e04fc6c 3496
charlesmn 0:c1910e04fc6c 3497 return VL53LX_SmudgeCorrectionEnable(Dev, Mode);
charlesmn 0:c1910e04fc6c 3498
charlesmn 0:c1910e04fc6c 3499 }
charlesmn 0:c1910e04fc6c 3500
charlesmn 0:c1910e04fc6c 3501 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3502 VL53LX_Error VL53L3CX::VL53L3CX_SetXTalkCompensationEnable(
charlesmn 0:c1910e04fc6c 3503 uint8_t XTalkCompensationEnable)
charlesmn 0:c1910e04fc6c 3504 {
charlesmn 0:c1910e04fc6c 3505
charlesmn 0:c1910e04fc6c 3506 return VL53LX_SetXTalkCompensationEnable( Dev, XTalkCompensationEnable );
charlesmn 0:c1910e04fc6c 3507
charlesmn 0:c1910e04fc6c 3508 }
charlesmn 0:c1910e04fc6c 3509
charlesmn 0:c1910e04fc6c 3510 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3511 VL53LX_Error VL53L3CX::VL53L3CX_GetXTalkCompensationEnable(
charlesmn 0:c1910e04fc6c 3512 uint8_t *pXTalkCompensationEnable)
charlesmn 0:c1910e04fc6c 3513 {
charlesmn 0:c1910e04fc6c 3514
charlesmn 0:c1910e04fc6c 3515 return VL53LX_GetXTalkCompensationEnable( Dev,pXTalkCompensationEnable);
charlesmn 0:c1910e04fc6c 3516
charlesmn 0:c1910e04fc6c 3517 }
charlesmn 0:c1910e04fc6c 3518
charlesmn 0:c1910e04fc6c 3519 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3520 VL53LX_Error VL53L3CX::VL53L3CX_PerformXTalkCalibration()
charlesmn 0:c1910e04fc6c 3521 {
charlesmn 0:c1910e04fc6c 3522
charlesmn 0:c1910e04fc6c 3523 return VL53LX_PerformXTalkCalibration( Dev);
charlesmn 0:c1910e04fc6c 3524
charlesmn 0:c1910e04fc6c 3525 }
charlesmn 0:c1910e04fc6c 3526
charlesmn 0:c1910e04fc6c 3527 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3528 VL53LX_Error VL53L3CX::VL53L3CX_SetOffsetCorrectionMode(
charlesmn 0:c1910e04fc6c 3529 VL53LX_OffsetCorrectionModes OffsetCorrectionMode)
charlesmn 0:c1910e04fc6c 3530 {
charlesmn 0:c1910e04fc6c 3531
charlesmn 0:c1910e04fc6c 3532 return VL53LX_SetOffsetCorrectionMode(Dev, OffsetCorrectionMode);
charlesmn 0:c1910e04fc6c 3533
charlesmn 0:c1910e04fc6c 3534 }
charlesmn 0:c1910e04fc6c 3535
charlesmn 0:c1910e04fc6c 3536 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3537 VL53LX_Error VL53L3CX::VL53L3CX_PerformOffsetSimpleCalibration(
charlesmn 0:c1910e04fc6c 3538 int32_t CalDistanceMilliMeter)
charlesmn 0:c1910e04fc6c 3539 {
charlesmn 0:c1910e04fc6c 3540
charlesmn 0:c1910e04fc6c 3541 return VL53LX_PerformOffsetSimpleCalibration(Dev, CalDistanceMilliMeter);
charlesmn 0:c1910e04fc6c 3542
charlesmn 0:c1910e04fc6c 3543 }
charlesmn 0:c1910e04fc6c 3544
charlesmn 0:c1910e04fc6c 3545 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3546 VL53LX_Error VL53L3CX::VL53L3CX_PerformOffsetZeroDistanceCalibration()
charlesmn 0:c1910e04fc6c 3547 {
charlesmn 0:c1910e04fc6c 3548
charlesmn 0:c1910e04fc6c 3549 return VL53LX_PerformOffsetZeroDistanceCalibration( Dev );
charlesmn 0:c1910e04fc6c 3550
charlesmn 0:c1910e04fc6c 3551 }
charlesmn 0:c1910e04fc6c 3552
charlesmn 0:c1910e04fc6c 3553 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3554 VL53LX_Error VL53L3CX::VL53L3CX_SetCalibrationData(
charlesmn 0:c1910e04fc6c 3555 VL53LX_CalibrationData_t *pCalibrationData)
charlesmn 0:c1910e04fc6c 3556 {
charlesmn 0:c1910e04fc6c 3557
charlesmn 0:c1910e04fc6c 3558 return VL53LX_SetCalibrationData(Dev, pCalibrationData);
charlesmn 0:c1910e04fc6c 3559
charlesmn 0:c1910e04fc6c 3560 }
charlesmn 0:c1910e04fc6c 3561
charlesmn 0:c1910e04fc6c 3562 /* vl53lx_api.c */
charlesmn 0:c1910e04fc6c 3563 VL53LX_Error VL53L3CX::VL53L3CX_GetCalibrationData(
charlesmn 0:c1910e04fc6c 3564 VL53LX_CalibrationData_t *pCalibrationData)
charlesmn 0:c1910e04fc6c 3565 {
charlesmn 0:c1910e04fc6c 3566
charlesmn 0:c1910e04fc6c 3567 return VL53LX_GetCalibrationData(Dev,pCalibrationData);
charlesmn 0:c1910e04fc6c 3568
charlesmn 0:c1910e04fc6c 3569 }
charlesmn 0:c1910e04fc6c 3570
charlesmn 0:c1910e04fc6c 3571
charlesmn 0:c1910e04fc6c 3572 VL53LX_Error VL53L3CX::VL53L3CX_PerformOffsetPerVcselCalibration(
charlesmn 0:c1910e04fc6c 3573 int32_t CalDistanceMilliMeter)
charlesmn 0:c1910e04fc6c 3574 {
charlesmn 0:c1910e04fc6c 3575
charlesmn 0:c1910e04fc6c 3576 return VL53LX_PerformOffsetPerVcselCalibration( Dev, CalDistanceMilliMeter);
charlesmn 0:c1910e04fc6c 3577
charlesmn 0:c1910e04fc6c 3578 }
charlesmn 0:c1910e04fc6c 3579