hh
Dependents: VL53L0X-mbedOS-master VL53L0X-mbedOS-masterbb
vl53l0x_api.h@2:a1dffa1ff38a, 2019-04-23 (annotated)
- Committer:
- mohamedachour
- Date:
- Tue Apr 23 14:27:07 2019 +0000
- Revision:
- 2:a1dffa1ff38a
- Parent:
- 0:e6fcdb78a136
xc
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
mjarvisal | 0:e6fcdb78a136 | 1 | /******************************************************************************* |
mjarvisal | 0:e6fcdb78a136 | 2 | Copyright © 2016, STMicroelectronics International N.V. |
mjarvisal | 0:e6fcdb78a136 | 3 | All rights reserved. |
mjarvisal | 0:e6fcdb78a136 | 4 | |
mjarvisal | 0:e6fcdb78a136 | 5 | Redistribution and use in source and binary forms, with or without |
mjarvisal | 0:e6fcdb78a136 | 6 | modification, are permitted provided that the following conditions are met: |
mjarvisal | 0:e6fcdb78a136 | 7 | * Redistributions of source code must retain the above copyright |
mjarvisal | 0:e6fcdb78a136 | 8 | notice, this list of conditions and the following disclaimer. |
mjarvisal | 0:e6fcdb78a136 | 9 | * Redistributions in binary form must reproduce the above copyright |
mjarvisal | 0:e6fcdb78a136 | 10 | notice, this list of conditions and the following disclaimer in the |
mjarvisal | 0:e6fcdb78a136 | 11 | documentation and/or other materials provided with the distribution. |
mjarvisal | 0:e6fcdb78a136 | 12 | * Neither the name of STMicroelectronics nor the |
mjarvisal | 0:e6fcdb78a136 | 13 | names of its contributors may be used to endorse or promote products |
mjarvisal | 0:e6fcdb78a136 | 14 | derived from this software without specific prior written permission. |
mjarvisal | 0:e6fcdb78a136 | 15 | |
mjarvisal | 0:e6fcdb78a136 | 16 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND |
mjarvisal | 0:e6fcdb78a136 | 17 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED |
mjarvisal | 0:e6fcdb78a136 | 18 | WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, AND |
mjarvisal | 0:e6fcdb78a136 | 19 | NON-INFRINGEMENT OF INTELLECTUAL PROPERTY RIGHTS ARE DISCLAIMED. |
mjarvisal | 0:e6fcdb78a136 | 20 | IN NO EVENT SHALL STMICROELECTRONICS INTERNATIONAL N.V. BE LIABLE FOR ANY |
mjarvisal | 0:e6fcdb78a136 | 21 | DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES |
mjarvisal | 0:e6fcdb78a136 | 22 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; |
mjarvisal | 0:e6fcdb78a136 | 23 | LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND |
mjarvisal | 0:e6fcdb78a136 | 24 | ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
mjarvisal | 0:e6fcdb78a136 | 25 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS |
mjarvisal | 0:e6fcdb78a136 | 26 | SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
mjarvisal | 0:e6fcdb78a136 | 27 | *****************************************************************************/ |
mjarvisal | 0:e6fcdb78a136 | 28 | |
mjarvisal | 0:e6fcdb78a136 | 29 | #ifndef _VL53L0X_API_H_ |
mjarvisal | 0:e6fcdb78a136 | 30 | #define _VL53L0X_API_H_ |
mjarvisal | 0:e6fcdb78a136 | 31 | |
mjarvisal | 0:e6fcdb78a136 | 32 | #include "vl53l0x_api_strings.h" |
mjarvisal | 0:e6fcdb78a136 | 33 | #include "vl53l0x_def.h" |
mjarvisal | 0:e6fcdb78a136 | 34 | #include "vl53l0x_platform.h" |
mjarvisal | 0:e6fcdb78a136 | 35 | |
mjarvisal | 0:e6fcdb78a136 | 36 | #ifdef __cplusplus |
mjarvisal | 0:e6fcdb78a136 | 37 | extern "C" |
mjarvisal | 0:e6fcdb78a136 | 38 | { |
mjarvisal | 0:e6fcdb78a136 | 39 | #endif |
mjarvisal | 0:e6fcdb78a136 | 40 | |
mjarvisal | 0:e6fcdb78a136 | 41 | #ifdef _MSC_VER |
mjarvisal | 0:e6fcdb78a136 | 42 | # ifdef VL53L0X_API_EXPORTS |
mjarvisal | 0:e6fcdb78a136 | 43 | # define VL53L0X_API __declspec(dllexport) |
mjarvisal | 0:e6fcdb78a136 | 44 | # else |
mjarvisal | 0:e6fcdb78a136 | 45 | # define VL53L0X_API |
mjarvisal | 0:e6fcdb78a136 | 46 | # endif |
mjarvisal | 0:e6fcdb78a136 | 47 | #else |
mjarvisal | 0:e6fcdb78a136 | 48 | # define VL53L0X_API |
mjarvisal | 0:e6fcdb78a136 | 49 | #endif |
mjarvisal | 0:e6fcdb78a136 | 50 | |
mjarvisal | 0:e6fcdb78a136 | 51 | /** @defgroup VL53L0X_cut11_group VL53L0X cut1.1 Function Definition |
mjarvisal | 0:e6fcdb78a136 | 52 | * @brief VL53L0X cut1.1 Function Definition |
mjarvisal | 0:e6fcdb78a136 | 53 | * @{ |
mjarvisal | 0:e6fcdb78a136 | 54 | */ |
mjarvisal | 0:e6fcdb78a136 | 55 | |
mjarvisal | 0:e6fcdb78a136 | 56 | /** @defgroup VL53L0X_general_group VL53L0X General Functions |
mjarvisal | 0:e6fcdb78a136 | 57 | * @brief General functions and definitions |
mjarvisal | 0:e6fcdb78a136 | 58 | * @{ |
mjarvisal | 0:e6fcdb78a136 | 59 | */ |
mjarvisal | 0:e6fcdb78a136 | 60 | |
mjarvisal | 0:e6fcdb78a136 | 61 | /** |
mjarvisal | 0:e6fcdb78a136 | 62 | * @brief Return the VL53L0X PAL Implementation Version |
mjarvisal | 0:e6fcdb78a136 | 63 | * |
mjarvisal | 0:e6fcdb78a136 | 64 | * @note This function doesn't access to the device |
mjarvisal | 0:e6fcdb78a136 | 65 | * |
mjarvisal | 0:e6fcdb78a136 | 66 | * @param pVersion Pointer to current PAL Implementation Version |
mjarvisal | 0:e6fcdb78a136 | 67 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 68 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 69 | */ |
mjarvisal | 0:e6fcdb78a136 | 70 | VL53L0X_API VL53L0X_Error VL53L0X_GetVersion(VL53L0X_Version_t *pVersion); |
mjarvisal | 0:e6fcdb78a136 | 71 | |
mjarvisal | 0:e6fcdb78a136 | 72 | /** |
mjarvisal | 0:e6fcdb78a136 | 73 | * @brief Return the PAL Specification Version used for the current |
mjarvisal | 0:e6fcdb78a136 | 74 | * implementation. |
mjarvisal | 0:e6fcdb78a136 | 75 | * |
mjarvisal | 0:e6fcdb78a136 | 76 | * @note This function doesn't access to the device |
mjarvisal | 0:e6fcdb78a136 | 77 | * |
mjarvisal | 0:e6fcdb78a136 | 78 | * @param pPalSpecVersion Pointer to current PAL Specification Version |
mjarvisal | 0:e6fcdb78a136 | 79 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 80 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 81 | */ |
mjarvisal | 0:e6fcdb78a136 | 82 | VL53L0X_API VL53L0X_Error VL53L0X_GetPalSpecVersion( |
mjarvisal | 0:e6fcdb78a136 | 83 | VL53L0X_Version_t *pPalSpecVersion); |
mjarvisal | 0:e6fcdb78a136 | 84 | |
mjarvisal | 0:e6fcdb78a136 | 85 | /** |
mjarvisal | 0:e6fcdb78a136 | 86 | * @brief Reads the Product Revision for a for given Device |
mjarvisal | 0:e6fcdb78a136 | 87 | * This function can be used to distinguish cut1.0 from cut1.1. |
mjarvisal | 0:e6fcdb78a136 | 88 | * |
mjarvisal | 0:e6fcdb78a136 | 89 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 90 | * |
mjarvisal | 0:e6fcdb78a136 | 91 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 92 | * @param pProductRevisionMajor Pointer to Product Revision Major |
mjarvisal | 0:e6fcdb78a136 | 93 | * for a given Device |
mjarvisal | 0:e6fcdb78a136 | 94 | * @param pProductRevisionMinor Pointer to Product Revision Minor |
mjarvisal | 0:e6fcdb78a136 | 95 | * for a given Device |
mjarvisal | 0:e6fcdb78a136 | 96 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 97 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 98 | */ |
mjarvisal | 0:e6fcdb78a136 | 99 | VL53L0X_API VL53L0X_Error VL53L0X_GetProductRevision(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 100 | uint8_t *pProductRevisionMajor, uint8_t *pProductRevisionMinor); |
mjarvisal | 0:e6fcdb78a136 | 101 | |
mjarvisal | 0:e6fcdb78a136 | 102 | /** |
mjarvisal | 0:e6fcdb78a136 | 103 | * @brief Reads the Device information for given Device |
mjarvisal | 0:e6fcdb78a136 | 104 | * |
mjarvisal | 0:e6fcdb78a136 | 105 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 106 | * |
mjarvisal | 0:e6fcdb78a136 | 107 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 108 | * @param pVL53L0X_DeviceInfo Pointer to current device info for a given |
mjarvisal | 0:e6fcdb78a136 | 109 | * Device |
mjarvisal | 0:e6fcdb78a136 | 110 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 111 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 112 | */ |
mjarvisal | 0:e6fcdb78a136 | 113 | VL53L0X_API VL53L0X_Error VL53L0X_GetDeviceInfo(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 114 | VL53L0X_DeviceInfo_t *pVL53L0X_DeviceInfo); |
mjarvisal | 0:e6fcdb78a136 | 115 | |
mjarvisal | 0:e6fcdb78a136 | 116 | /** |
mjarvisal | 0:e6fcdb78a136 | 117 | * @brief Read current status of the error register for the selected device |
mjarvisal | 0:e6fcdb78a136 | 118 | * |
mjarvisal | 0:e6fcdb78a136 | 119 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 120 | * |
mjarvisal | 0:e6fcdb78a136 | 121 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 122 | * @param pDeviceErrorStatus Pointer to current error code of the device |
mjarvisal | 0:e6fcdb78a136 | 123 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 124 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 125 | */ |
mjarvisal | 0:e6fcdb78a136 | 126 | VL53L0X_API VL53L0X_Error VL53L0X_GetDeviceErrorStatus(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 127 | VL53L0X_DeviceError *pDeviceErrorStatus); |
mjarvisal | 0:e6fcdb78a136 | 128 | |
mjarvisal | 0:e6fcdb78a136 | 129 | /** |
mjarvisal | 0:e6fcdb78a136 | 130 | * @brief Human readable Range Status string for a given RangeStatus |
mjarvisal | 0:e6fcdb78a136 | 131 | * |
mjarvisal | 0:e6fcdb78a136 | 132 | * @note This function doesn't access to the device |
mjarvisal | 0:e6fcdb78a136 | 133 | * |
mjarvisal | 0:e6fcdb78a136 | 134 | * @param RangeStatus The RangeStatus code as stored on |
mjarvisal | 0:e6fcdb78a136 | 135 | * @a VL53L0X_RangingMeasurementData_t |
mjarvisal | 0:e6fcdb78a136 | 136 | * @param pRangeStatusString The returned RangeStatus string. |
mjarvisal | 0:e6fcdb78a136 | 137 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 138 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 139 | */ |
mjarvisal | 0:e6fcdb78a136 | 140 | VL53L0X_API VL53L0X_Error VL53L0X_GetRangeStatusString(uint8_t RangeStatus, |
mjarvisal | 0:e6fcdb78a136 | 141 | char *pRangeStatusString); |
mjarvisal | 0:e6fcdb78a136 | 142 | |
mjarvisal | 0:e6fcdb78a136 | 143 | /** |
mjarvisal | 0:e6fcdb78a136 | 144 | * @brief Human readable error string for a given Error Code |
mjarvisal | 0:e6fcdb78a136 | 145 | * |
mjarvisal | 0:e6fcdb78a136 | 146 | * @note This function doesn't access to the device |
mjarvisal | 0:e6fcdb78a136 | 147 | * |
mjarvisal | 0:e6fcdb78a136 | 148 | * @param ErrorCode The error code as stored on ::VL53L0X_DeviceError |
mjarvisal | 0:e6fcdb78a136 | 149 | * @param pDeviceErrorString The error string corresponding to the ErrorCode |
mjarvisal | 0:e6fcdb78a136 | 150 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 151 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 152 | */ |
mjarvisal | 0:e6fcdb78a136 | 153 | VL53L0X_API VL53L0X_Error VL53L0X_GetDeviceErrorString( |
mjarvisal | 0:e6fcdb78a136 | 154 | VL53L0X_DeviceError ErrorCode, char *pDeviceErrorString); |
mjarvisal | 0:e6fcdb78a136 | 155 | |
mjarvisal | 0:e6fcdb78a136 | 156 | /** |
mjarvisal | 0:e6fcdb78a136 | 157 | * @brief Human readable error string for current PAL error status |
mjarvisal | 0:e6fcdb78a136 | 158 | * |
mjarvisal | 0:e6fcdb78a136 | 159 | * @note This function doesn't access to the device |
mjarvisal | 0:e6fcdb78a136 | 160 | * |
mjarvisal | 0:e6fcdb78a136 | 161 | * @param PalErrorCode The error code as stored on @a VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 162 | * @param pPalErrorString The error string corresponding to the |
mjarvisal | 0:e6fcdb78a136 | 163 | * PalErrorCode |
mjarvisal | 0:e6fcdb78a136 | 164 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 165 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 166 | */ |
mjarvisal | 0:e6fcdb78a136 | 167 | VL53L0X_API VL53L0X_Error VL53L0X_GetPalErrorString(VL53L0X_Error PalErrorCode, |
mjarvisal | 0:e6fcdb78a136 | 168 | char *pPalErrorString); |
mjarvisal | 0:e6fcdb78a136 | 169 | |
mjarvisal | 0:e6fcdb78a136 | 170 | /** |
mjarvisal | 0:e6fcdb78a136 | 171 | * @brief Human readable PAL State string |
mjarvisal | 0:e6fcdb78a136 | 172 | * |
mjarvisal | 0:e6fcdb78a136 | 173 | * @note This function doesn't access to the device |
mjarvisal | 0:e6fcdb78a136 | 174 | * |
mjarvisal | 0:e6fcdb78a136 | 175 | * @param PalStateCode The State code as stored on @a VL53L0X_State |
mjarvisal | 0:e6fcdb78a136 | 176 | * @param pPalStateString The State string corresponding to the |
mjarvisal | 0:e6fcdb78a136 | 177 | * PalStateCode |
mjarvisal | 0:e6fcdb78a136 | 178 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 179 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 180 | */ |
mjarvisal | 0:e6fcdb78a136 | 181 | VL53L0X_API VL53L0X_Error VL53L0X_GetPalStateString(VL53L0X_State PalStateCode, |
mjarvisal | 0:e6fcdb78a136 | 182 | char *pPalStateString); |
mjarvisal | 0:e6fcdb78a136 | 183 | |
mjarvisal | 0:e6fcdb78a136 | 184 | /** |
mjarvisal | 0:e6fcdb78a136 | 185 | * @brief Reads the internal state of the PAL for a given Device |
mjarvisal | 0:e6fcdb78a136 | 186 | * |
mjarvisal | 0:e6fcdb78a136 | 187 | * @note This function doesn't access to the device |
mjarvisal | 0:e6fcdb78a136 | 188 | * |
mjarvisal | 0:e6fcdb78a136 | 189 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 190 | * @param pPalState Pointer to current state of the PAL for a |
mjarvisal | 0:e6fcdb78a136 | 191 | * given Device |
mjarvisal | 0:e6fcdb78a136 | 192 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 193 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 194 | */ |
mjarvisal | 0:e6fcdb78a136 | 195 | VL53L0X_API VL53L0X_Error VL53L0X_GetPalState(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 196 | VL53L0X_State *pPalState); |
mjarvisal | 0:e6fcdb78a136 | 197 | |
mjarvisal | 0:e6fcdb78a136 | 198 | /** |
mjarvisal | 0:e6fcdb78a136 | 199 | * @brief Set the power mode for a given Device |
mjarvisal | 0:e6fcdb78a136 | 200 | * The power mode can be Standby or Idle. Different level of both Standby and |
mjarvisal | 0:e6fcdb78a136 | 201 | * Idle can exists. |
mjarvisal | 0:e6fcdb78a136 | 202 | * This function should not be used when device is in Ranging state. |
mjarvisal | 0:e6fcdb78a136 | 203 | * |
mjarvisal | 0:e6fcdb78a136 | 204 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 205 | * |
mjarvisal | 0:e6fcdb78a136 | 206 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 207 | * @param PowerMode The value of the power mode to set. |
mjarvisal | 0:e6fcdb78a136 | 208 | * see ::VL53L0X_PowerModes |
mjarvisal | 0:e6fcdb78a136 | 209 | * Valid values are: |
mjarvisal | 0:e6fcdb78a136 | 210 | * VL53L0X_POWERMODE_STANDBY_LEVEL1, |
mjarvisal | 0:e6fcdb78a136 | 211 | * VL53L0X_POWERMODE_IDLE_LEVEL1 |
mjarvisal | 0:e6fcdb78a136 | 212 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 213 | * @return VL53L0X_ERROR_MODE_NOT_SUPPORTED This error occurs when PowerMode |
mjarvisal | 0:e6fcdb78a136 | 214 | * is not in the supported list |
mjarvisal | 0:e6fcdb78a136 | 215 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 216 | */ |
mjarvisal | 0:e6fcdb78a136 | 217 | VL53L0X_API VL53L0X_Error VL53L0X_SetPowerMode(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 218 | VL53L0X_PowerModes PowerMode); |
mjarvisal | 0:e6fcdb78a136 | 219 | |
mjarvisal | 0:e6fcdb78a136 | 220 | /** |
mjarvisal | 0:e6fcdb78a136 | 221 | * @brief Get the power mode for a given Device |
mjarvisal | 0:e6fcdb78a136 | 222 | * |
mjarvisal | 0:e6fcdb78a136 | 223 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 224 | * |
mjarvisal | 0:e6fcdb78a136 | 225 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 226 | * @param pPowerMode Pointer to the current value of the power |
mjarvisal | 0:e6fcdb78a136 | 227 | * mode. see ::VL53L0X_PowerModes |
mjarvisal | 0:e6fcdb78a136 | 228 | * Valid values are: |
mjarvisal | 0:e6fcdb78a136 | 229 | * VL53L0X_POWERMODE_STANDBY_LEVEL1, |
mjarvisal | 0:e6fcdb78a136 | 230 | * VL53L0X_POWERMODE_IDLE_LEVEL1 |
mjarvisal | 0:e6fcdb78a136 | 231 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 232 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 233 | */ |
mjarvisal | 0:e6fcdb78a136 | 234 | VL53L0X_API VL53L0X_Error VL53L0X_GetPowerMode(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 235 | VL53L0X_PowerModes *pPowerMode); |
mjarvisal | 0:e6fcdb78a136 | 236 | |
mjarvisal | 0:e6fcdb78a136 | 237 | /** |
mjarvisal | 0:e6fcdb78a136 | 238 | * Set or over-hide part to part calibration offset |
mjarvisal | 0:e6fcdb78a136 | 239 | * \sa VL53L0X_DataInit() VL53L0X_GetOffsetCalibrationDataMicroMeter() |
mjarvisal | 0:e6fcdb78a136 | 240 | * |
mjarvisal | 0:e6fcdb78a136 | 241 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 242 | * |
mjarvisal | 0:e6fcdb78a136 | 243 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 244 | * @param OffsetCalibrationDataMicroMeter Offset (microns) |
mjarvisal | 0:e6fcdb78a136 | 245 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 246 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 247 | */ |
mjarvisal | 0:e6fcdb78a136 | 248 | VL53L0X_API VL53L0X_Error VL53L0X_SetOffsetCalibrationDataMicroMeter( |
mjarvisal | 0:e6fcdb78a136 | 249 | VL53L0X_DEV Dev, int32_t OffsetCalibrationDataMicroMeter); |
mjarvisal | 0:e6fcdb78a136 | 250 | |
mjarvisal | 0:e6fcdb78a136 | 251 | /** |
mjarvisal | 0:e6fcdb78a136 | 252 | * @brief Get part to part calibration offset |
mjarvisal | 0:e6fcdb78a136 | 253 | * |
mjarvisal | 0:e6fcdb78a136 | 254 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 255 | * Should only be used after a successful call to @a VL53L0X_DataInit to backup |
mjarvisal | 0:e6fcdb78a136 | 256 | * device NVM value |
mjarvisal | 0:e6fcdb78a136 | 257 | * |
mjarvisal | 0:e6fcdb78a136 | 258 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 259 | * |
mjarvisal | 0:e6fcdb78a136 | 260 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 261 | * @param pOffsetCalibrationDataMicroMeter Return part to part |
mjarvisal | 0:e6fcdb78a136 | 262 | * calibration offset from device (microns) |
mjarvisal | 0:e6fcdb78a136 | 263 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 264 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 265 | */ |
mjarvisal | 0:e6fcdb78a136 | 266 | VL53L0X_API VL53L0X_Error VL53L0X_GetOffsetCalibrationDataMicroMeter( |
mjarvisal | 0:e6fcdb78a136 | 267 | VL53L0X_DEV Dev, int32_t *pOffsetCalibrationDataMicroMeter); |
mjarvisal | 0:e6fcdb78a136 | 268 | |
mjarvisal | 0:e6fcdb78a136 | 269 | /** |
mjarvisal | 0:e6fcdb78a136 | 270 | * Set the linearity corrective gain |
mjarvisal | 0:e6fcdb78a136 | 271 | * |
mjarvisal | 0:e6fcdb78a136 | 272 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 273 | * |
mjarvisal | 0:e6fcdb78a136 | 274 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 275 | * @param LinearityCorrectiveGain Linearity corrective |
mjarvisal | 0:e6fcdb78a136 | 276 | * gain in x1000 |
mjarvisal | 0:e6fcdb78a136 | 277 | * if value is 1000 then no modification is applied. |
mjarvisal | 0:e6fcdb78a136 | 278 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 279 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 280 | */ |
mjarvisal | 0:e6fcdb78a136 | 281 | VL53L0X_API VL53L0X_Error VL53L0X_SetLinearityCorrectiveGain(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 282 | int16_t LinearityCorrectiveGain); |
mjarvisal | 0:e6fcdb78a136 | 283 | |
mjarvisal | 0:e6fcdb78a136 | 284 | /** |
mjarvisal | 0:e6fcdb78a136 | 285 | * @brief Get the linearity corrective gain |
mjarvisal | 0:e6fcdb78a136 | 286 | * |
mjarvisal | 0:e6fcdb78a136 | 287 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 288 | * Should only be used after a successful call to @a VL53L0X_DataInit to backup |
mjarvisal | 0:e6fcdb78a136 | 289 | * device NVM value |
mjarvisal | 0:e6fcdb78a136 | 290 | * |
mjarvisal | 0:e6fcdb78a136 | 291 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 292 | * |
mjarvisal | 0:e6fcdb78a136 | 293 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 294 | * @param pLinearityCorrectiveGain Pointer to the linearity |
mjarvisal | 0:e6fcdb78a136 | 295 | * corrective gain in x1000 |
mjarvisal | 0:e6fcdb78a136 | 296 | * if value is 1000 then no modification is applied. |
mjarvisal | 0:e6fcdb78a136 | 297 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 298 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 299 | */ |
mjarvisal | 0:e6fcdb78a136 | 300 | VL53L0X_API VL53L0X_Error VL53L0X_GetLinearityCorrectiveGain(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 301 | uint16_t *pLinearityCorrectiveGain); |
mjarvisal | 0:e6fcdb78a136 | 302 | |
mjarvisal | 0:e6fcdb78a136 | 303 | /** |
mjarvisal | 0:e6fcdb78a136 | 304 | * Set Group parameter Hold state |
mjarvisal | 0:e6fcdb78a136 | 305 | * |
mjarvisal | 0:e6fcdb78a136 | 306 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 307 | * Set or remove device internal group parameter hold |
mjarvisal | 0:e6fcdb78a136 | 308 | * |
mjarvisal | 0:e6fcdb78a136 | 309 | * @note This function is not Implemented |
mjarvisal | 0:e6fcdb78a136 | 310 | * |
mjarvisal | 0:e6fcdb78a136 | 311 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 312 | * @param GroupParamHold Group parameter Hold state to be set (on/off) |
mjarvisal | 0:e6fcdb78a136 | 313 | * @return VL53L0X_ERROR_NOT_IMPLEMENTED Not implemented |
mjarvisal | 0:e6fcdb78a136 | 314 | */ |
mjarvisal | 0:e6fcdb78a136 | 315 | VL53L0X_API VL53L0X_Error VL53L0X_SetGroupParamHold(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 316 | uint8_t GroupParamHold); |
mjarvisal | 0:e6fcdb78a136 | 317 | |
mjarvisal | 0:e6fcdb78a136 | 318 | /** |
mjarvisal | 0:e6fcdb78a136 | 319 | * @brief Get the maximal distance for actual setup |
mjarvisal | 0:e6fcdb78a136 | 320 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 321 | * Device must be initialized through @a VL53L0X_SetParameters() prior calling |
mjarvisal | 0:e6fcdb78a136 | 322 | * this function. |
mjarvisal | 0:e6fcdb78a136 | 323 | * |
mjarvisal | 0:e6fcdb78a136 | 324 | * Any range value more than the value returned is to be considered as |
mjarvisal | 0:e6fcdb78a136 | 325 | * "no target detected" or |
mjarvisal | 0:e6fcdb78a136 | 326 | * "no target in detectable range"\n |
mjarvisal | 0:e6fcdb78a136 | 327 | * @warning The maximal distance depends on the setup |
mjarvisal | 0:e6fcdb78a136 | 328 | * |
mjarvisal | 0:e6fcdb78a136 | 329 | * @note This function is not Implemented |
mjarvisal | 0:e6fcdb78a136 | 330 | * |
mjarvisal | 0:e6fcdb78a136 | 331 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 332 | * @param pUpperLimitMilliMeter The maximal range limit for actual setup |
mjarvisal | 0:e6fcdb78a136 | 333 | * (in millimeter) |
mjarvisal | 0:e6fcdb78a136 | 334 | * @return VL53L0X_ERROR_NOT_IMPLEMENTED Not implemented |
mjarvisal | 0:e6fcdb78a136 | 335 | */ |
mjarvisal | 0:e6fcdb78a136 | 336 | VL53L0X_API VL53L0X_Error VL53L0X_GetUpperLimitMilliMeter(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 337 | uint16_t *pUpperLimitMilliMeter); |
mjarvisal | 0:e6fcdb78a136 | 338 | |
mjarvisal | 0:e6fcdb78a136 | 339 | |
mjarvisal | 0:e6fcdb78a136 | 340 | /** |
mjarvisal | 0:e6fcdb78a136 | 341 | * @brief Get the Total Signal Rate |
mjarvisal | 0:e6fcdb78a136 | 342 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 343 | * This function will return the Total Signal Rate after a good ranging is done. |
mjarvisal | 0:e6fcdb78a136 | 344 | * |
mjarvisal | 0:e6fcdb78a136 | 345 | * @note This function access to Device |
mjarvisal | 0:e6fcdb78a136 | 346 | * |
mjarvisal | 0:e6fcdb78a136 | 347 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 348 | * @param pTotalSignalRate Total Signal Rate value in Mega count per second |
mjarvisal | 0:e6fcdb78a136 | 349 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 350 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 351 | */ |
mjarvisal | 0:e6fcdb78a136 | 352 | VL53L0X_Error VL53L0X_GetTotalSignalRate(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 353 | FixPoint1616_t *pTotalSignalRate); |
mjarvisal | 0:e6fcdb78a136 | 354 | |
mjarvisal | 0:e6fcdb78a136 | 355 | /** @} VL53L0X_general_group */ |
mjarvisal | 0:e6fcdb78a136 | 356 | |
mjarvisal | 0:e6fcdb78a136 | 357 | /** @defgroup VL53L0X_init_group VL53L0X Init Functions |
mjarvisal | 0:e6fcdb78a136 | 358 | * @brief VL53L0X Init Functions |
mjarvisal | 0:e6fcdb78a136 | 359 | * @{ |
mjarvisal | 0:e6fcdb78a136 | 360 | */ |
mjarvisal | 0:e6fcdb78a136 | 361 | |
mjarvisal | 0:e6fcdb78a136 | 362 | /** |
mjarvisal | 0:e6fcdb78a136 | 363 | * @brief Set new device address |
mjarvisal | 0:e6fcdb78a136 | 364 | * |
mjarvisal | 0:e6fcdb78a136 | 365 | * After completion the device will answer to the new address programmed. |
mjarvisal | 0:e6fcdb78a136 | 366 | * This function should be called when several devices are used in parallel |
mjarvisal | 0:e6fcdb78a136 | 367 | * before start programming the sensor. |
mjarvisal | 0:e6fcdb78a136 | 368 | * When a single device us used, there is no need to call this function. |
mjarvisal | 0:e6fcdb78a136 | 369 | * |
mjarvisal | 0:e6fcdb78a136 | 370 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 371 | * |
mjarvisal | 0:e6fcdb78a136 | 372 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 373 | * @param DeviceAddress The new Device address |
mjarvisal | 0:e6fcdb78a136 | 374 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 375 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 376 | */ |
mjarvisal | 0:e6fcdb78a136 | 377 | VL53L0X_API VL53L0X_Error VL53L0X_SetDeviceAddress(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 378 | uint8_t DeviceAddress); |
mjarvisal | 0:e6fcdb78a136 | 379 | |
mjarvisal | 0:e6fcdb78a136 | 380 | /** |
mjarvisal | 0:e6fcdb78a136 | 381 | * |
mjarvisal | 0:e6fcdb78a136 | 382 | * @brief One time device initialization |
mjarvisal | 0:e6fcdb78a136 | 383 | * |
mjarvisal | 0:e6fcdb78a136 | 384 | * To be called once and only once after device is brought out of reset |
mjarvisal | 0:e6fcdb78a136 | 385 | * (Chip enable) and booted see @a VL53L0X_WaitDeviceBooted() |
mjarvisal | 0:e6fcdb78a136 | 386 | * |
mjarvisal | 0:e6fcdb78a136 | 387 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 388 | * When not used after a fresh device "power up" or reset, it may return |
mjarvisal | 0:e6fcdb78a136 | 389 | * @a #VL53L0X_ERROR_CALIBRATION_WARNING meaning wrong calibration data |
mjarvisal | 0:e6fcdb78a136 | 390 | * may have been fetched from device that can result in ranging offset error\n |
mjarvisal | 0:e6fcdb78a136 | 391 | * If application cannot execute device reset or need to run VL53L0X_DataInit |
mjarvisal | 0:e6fcdb78a136 | 392 | * multiple time then it must ensure proper offset calibration saving and |
mjarvisal | 0:e6fcdb78a136 | 393 | * restore on its own by using @a VL53L0X_GetOffsetCalibrationData() on first |
mjarvisal | 0:e6fcdb78a136 | 394 | * power up and then @a VL53L0X_SetOffsetCalibrationData() in all subsequent init |
mjarvisal | 0:e6fcdb78a136 | 395 | * This function will change the VL53L0X_State from VL53L0X_STATE_POWERDOWN to |
mjarvisal | 0:e6fcdb78a136 | 396 | * VL53L0X_STATE_WAIT_STATICINIT. |
mjarvisal | 0:e6fcdb78a136 | 397 | * |
mjarvisal | 0:e6fcdb78a136 | 398 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 399 | * |
mjarvisal | 0:e6fcdb78a136 | 400 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 401 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 402 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 403 | */ |
mjarvisal | 0:e6fcdb78a136 | 404 | VL53L0X_API VL53L0X_Error VL53L0X_DataInit(VL53L0X_DEV Dev); |
mjarvisal | 0:e6fcdb78a136 | 405 | |
mjarvisal | 0:e6fcdb78a136 | 406 | /** |
mjarvisal | 0:e6fcdb78a136 | 407 | * @brief Set the tuning settings pointer |
mjarvisal | 0:e6fcdb78a136 | 408 | * |
mjarvisal | 0:e6fcdb78a136 | 409 | * This function is used to specify the Tuning settings buffer to be used |
mjarvisal | 0:e6fcdb78a136 | 410 | * for a given device. The buffer contains all the necessary data to permit |
mjarvisal | 0:e6fcdb78a136 | 411 | * the API to write tuning settings. |
mjarvisal | 0:e6fcdb78a136 | 412 | * This function permit to force the usage of either external or internal |
mjarvisal | 0:e6fcdb78a136 | 413 | * tuning settings. |
mjarvisal | 0:e6fcdb78a136 | 414 | * |
mjarvisal | 0:e6fcdb78a136 | 415 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 416 | * |
mjarvisal | 0:e6fcdb78a136 | 417 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 418 | * @param pTuningSettingBuffer Pointer to tuning settings buffer. |
mjarvisal | 0:e6fcdb78a136 | 419 | * @param UseInternalTuningSettings Use internal tuning settings value. |
mjarvisal | 0:e6fcdb78a136 | 420 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 421 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 422 | */ |
mjarvisal | 0:e6fcdb78a136 | 423 | VL53L0X_API VL53L0X_Error VL53L0X_SetTuningSettingBuffer(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 424 | uint8_t *pTuningSettingBuffer, uint8_t UseInternalTuningSettings); |
mjarvisal | 0:e6fcdb78a136 | 425 | |
mjarvisal | 0:e6fcdb78a136 | 426 | /** |
mjarvisal | 0:e6fcdb78a136 | 427 | * @brief Get the tuning settings pointer and the internal external switch |
mjarvisal | 0:e6fcdb78a136 | 428 | * value. |
mjarvisal | 0:e6fcdb78a136 | 429 | * |
mjarvisal | 0:e6fcdb78a136 | 430 | * This function is used to get the Tuning settings buffer pointer and the |
mjarvisal | 0:e6fcdb78a136 | 431 | * value. |
mjarvisal | 0:e6fcdb78a136 | 432 | * of the switch to select either external or internal tuning settings. |
mjarvisal | 0:e6fcdb78a136 | 433 | * |
mjarvisal | 0:e6fcdb78a136 | 434 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 435 | * |
mjarvisal | 0:e6fcdb78a136 | 436 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 437 | * @param ppTuningSettingBuffer Pointer to tuning settings buffer. |
mjarvisal | 0:e6fcdb78a136 | 438 | * @param pUseInternalTuningSettings Pointer to store Use internal tuning |
mjarvisal | 0:e6fcdb78a136 | 439 | * settings value. |
mjarvisal | 0:e6fcdb78a136 | 440 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 441 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 442 | */ |
mjarvisal | 0:e6fcdb78a136 | 443 | VL53L0X_API VL53L0X_Error VL53L0X_GetTuningSettingBuffer(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 444 | uint8_t **ppTuningSettingBuffer, uint8_t *pUseInternalTuningSettings); |
mjarvisal | 0:e6fcdb78a136 | 445 | |
mjarvisal | 0:e6fcdb78a136 | 446 | /** |
mjarvisal | 0:e6fcdb78a136 | 447 | * @brief Do basic device init (and eventually patch loading) |
mjarvisal | 0:e6fcdb78a136 | 448 | * This function will change the VL53L0X_State from |
mjarvisal | 0:e6fcdb78a136 | 449 | * VL53L0X_STATE_WAIT_STATICINIT to VL53L0X_STATE_IDLE. |
mjarvisal | 0:e6fcdb78a136 | 450 | * In this stage all default setting will be applied. |
mjarvisal | 0:e6fcdb78a136 | 451 | * |
mjarvisal | 0:e6fcdb78a136 | 452 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 453 | * |
mjarvisal | 0:e6fcdb78a136 | 454 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 455 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 456 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 457 | */ |
mjarvisal | 0:e6fcdb78a136 | 458 | VL53L0X_API VL53L0X_Error VL53L0X_StaticInit(VL53L0X_DEV Dev); |
mjarvisal | 0:e6fcdb78a136 | 459 | |
mjarvisal | 0:e6fcdb78a136 | 460 | /** |
mjarvisal | 0:e6fcdb78a136 | 461 | * @brief Wait for device booted after chip enable (hardware standby) |
mjarvisal | 0:e6fcdb78a136 | 462 | * This function can be run only when VL53L0X_State is VL53L0X_STATE_POWERDOWN. |
mjarvisal | 0:e6fcdb78a136 | 463 | * |
mjarvisal | 0:e6fcdb78a136 | 464 | * @note This function is not Implemented |
mjarvisal | 0:e6fcdb78a136 | 465 | * |
mjarvisal | 0:e6fcdb78a136 | 466 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 467 | * @return VL53L0X_ERROR_NOT_IMPLEMENTED Not implemented |
mjarvisal | 0:e6fcdb78a136 | 468 | * |
mjarvisal | 0:e6fcdb78a136 | 469 | */ |
mjarvisal | 0:e6fcdb78a136 | 470 | VL53L0X_API VL53L0X_Error VL53L0X_WaitDeviceBooted(VL53L0X_DEV Dev); |
mjarvisal | 0:e6fcdb78a136 | 471 | |
mjarvisal | 0:e6fcdb78a136 | 472 | /** |
mjarvisal | 0:e6fcdb78a136 | 473 | * @brief Do an hard reset or soft reset (depending on implementation) of the |
mjarvisal | 0:e6fcdb78a136 | 474 | * device \nAfter call of this function, device must be in same state as right |
mjarvisal | 0:e6fcdb78a136 | 475 | * after a power-up sequence.This function will change the VL53L0X_State to |
mjarvisal | 0:e6fcdb78a136 | 476 | * VL53L0X_STATE_POWERDOWN. |
mjarvisal | 0:e6fcdb78a136 | 477 | * |
mjarvisal | 0:e6fcdb78a136 | 478 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 479 | * |
mjarvisal | 0:e6fcdb78a136 | 480 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 481 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 482 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 483 | */ |
mjarvisal | 0:e6fcdb78a136 | 484 | VL53L0X_API VL53L0X_Error VL53L0X_ResetDevice(VL53L0X_DEV Dev); |
mjarvisal | 0:e6fcdb78a136 | 485 | |
mjarvisal | 0:e6fcdb78a136 | 486 | /** @} VL53L0X_init_group */ |
mjarvisal | 0:e6fcdb78a136 | 487 | |
mjarvisal | 0:e6fcdb78a136 | 488 | /** @defgroup VL53L0X_parameters_group VL53L0X Parameters Functions |
mjarvisal | 0:e6fcdb78a136 | 489 | * @brief Functions used to prepare and setup the device |
mjarvisal | 0:e6fcdb78a136 | 490 | * @{ |
mjarvisal | 0:e6fcdb78a136 | 491 | */ |
mjarvisal | 0:e6fcdb78a136 | 492 | |
mjarvisal | 0:e6fcdb78a136 | 493 | /** |
mjarvisal | 0:e6fcdb78a136 | 494 | * @brief Prepare device for operation |
mjarvisal | 0:e6fcdb78a136 | 495 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 496 | * Update device with provided parameters |
mjarvisal | 0:e6fcdb78a136 | 497 | * @li Then start ranging operation. |
mjarvisal | 0:e6fcdb78a136 | 498 | * |
mjarvisal | 0:e6fcdb78a136 | 499 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 500 | * |
mjarvisal | 0:e6fcdb78a136 | 501 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 502 | * @param pDeviceParameters Pointer to store current device parameters. |
mjarvisal | 0:e6fcdb78a136 | 503 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 504 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 505 | */ |
mjarvisal | 0:e6fcdb78a136 | 506 | VL53L0X_API VL53L0X_Error VL53L0X_SetDeviceParameters(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 507 | const VL53L0X_DeviceParameters_t *pDeviceParameters); |
mjarvisal | 0:e6fcdb78a136 | 508 | |
mjarvisal | 0:e6fcdb78a136 | 509 | /** |
mjarvisal | 0:e6fcdb78a136 | 510 | * @brief Retrieve current device parameters |
mjarvisal | 0:e6fcdb78a136 | 511 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 512 | * Get actual parameters of the device |
mjarvisal | 0:e6fcdb78a136 | 513 | * @li Then start ranging operation. |
mjarvisal | 0:e6fcdb78a136 | 514 | * |
mjarvisal | 0:e6fcdb78a136 | 515 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 516 | * |
mjarvisal | 0:e6fcdb78a136 | 517 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 518 | * @param pDeviceParameters Pointer to store current device parameters. |
mjarvisal | 0:e6fcdb78a136 | 519 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 520 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 521 | */ |
mjarvisal | 0:e6fcdb78a136 | 522 | VL53L0X_API VL53L0X_Error VL53L0X_GetDeviceParameters(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 523 | VL53L0X_DeviceParameters_t *pDeviceParameters); |
mjarvisal | 0:e6fcdb78a136 | 524 | |
mjarvisal | 0:e6fcdb78a136 | 525 | /** |
mjarvisal | 0:e6fcdb78a136 | 526 | * @brief Set a new device mode |
mjarvisal | 0:e6fcdb78a136 | 527 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 528 | * Set device to a new mode (ranging, histogram ...) |
mjarvisal | 0:e6fcdb78a136 | 529 | * |
mjarvisal | 0:e6fcdb78a136 | 530 | * @note This function doesn't Access to the device |
mjarvisal | 0:e6fcdb78a136 | 531 | * |
mjarvisal | 0:e6fcdb78a136 | 532 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 533 | * @param DeviceMode New device mode to apply |
mjarvisal | 0:e6fcdb78a136 | 534 | * Valid values are: |
mjarvisal | 0:e6fcdb78a136 | 535 | * VL53L0X_DEVICEMODE_SINGLE_RANGING |
mjarvisal | 0:e6fcdb78a136 | 536 | * VL53L0X_DEVICEMODE_CONTINUOUS_RANGING |
mjarvisal | 0:e6fcdb78a136 | 537 | * VL53L0X_DEVICEMODE_CONTINUOUS_TIMED_RANGING |
mjarvisal | 0:e6fcdb78a136 | 538 | * VL53L0X_DEVICEMODE_SINGLE_HISTOGRAM |
mjarvisal | 0:e6fcdb78a136 | 539 | * VL53L0X_HISTOGRAMMODE_REFERENCE_ONLY |
mjarvisal | 0:e6fcdb78a136 | 540 | * VL53L0X_HISTOGRAMMODE_RETURN_ONLY |
mjarvisal | 0:e6fcdb78a136 | 541 | * VL53L0X_HISTOGRAMMODE_BOTH |
mjarvisal | 0:e6fcdb78a136 | 542 | * |
mjarvisal | 0:e6fcdb78a136 | 543 | * |
mjarvisal | 0:e6fcdb78a136 | 544 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 545 | * @return VL53L0X_ERROR_MODE_NOT_SUPPORTED This error occurs when DeviceMode is |
mjarvisal | 0:e6fcdb78a136 | 546 | * not in the supported list |
mjarvisal | 0:e6fcdb78a136 | 547 | */ |
mjarvisal | 0:e6fcdb78a136 | 548 | VL53L0X_API VL53L0X_Error VL53L0X_SetDeviceMode(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 549 | VL53L0X_DeviceModes DeviceMode); |
mjarvisal | 0:e6fcdb78a136 | 550 | |
mjarvisal | 0:e6fcdb78a136 | 551 | /** |
mjarvisal | 0:e6fcdb78a136 | 552 | * @brief Get current new device mode |
mjarvisal | 0:e6fcdb78a136 | 553 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 554 | * Get actual mode of the device(ranging, histogram ...) |
mjarvisal | 0:e6fcdb78a136 | 555 | * |
mjarvisal | 0:e6fcdb78a136 | 556 | * @note This function doesn't Access to the device |
mjarvisal | 0:e6fcdb78a136 | 557 | * |
mjarvisal | 0:e6fcdb78a136 | 558 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 559 | * @param pDeviceMode Pointer to current apply mode value |
mjarvisal | 0:e6fcdb78a136 | 560 | * Valid values are: |
mjarvisal | 0:e6fcdb78a136 | 561 | * VL53L0X_DEVICEMODE_SINGLE_RANGING |
mjarvisal | 0:e6fcdb78a136 | 562 | * VL53L0X_DEVICEMODE_CONTINUOUS_RANGING |
mjarvisal | 0:e6fcdb78a136 | 563 | * VL53L0X_DEVICEMODE_CONTINUOUS_TIMED_RANGING |
mjarvisal | 0:e6fcdb78a136 | 564 | * VL53L0X_DEVICEMODE_SINGLE_HISTOGRAM |
mjarvisal | 0:e6fcdb78a136 | 565 | * VL53L0X_HISTOGRAMMODE_REFERENCE_ONLY |
mjarvisal | 0:e6fcdb78a136 | 566 | * VL53L0X_HISTOGRAMMODE_RETURN_ONLY |
mjarvisal | 0:e6fcdb78a136 | 567 | * VL53L0X_HISTOGRAMMODE_BOTH |
mjarvisal | 0:e6fcdb78a136 | 568 | * |
mjarvisal | 0:e6fcdb78a136 | 569 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 570 | * @return VL53L0X_ERROR_MODE_NOT_SUPPORTED This error occurs when |
mjarvisal | 0:e6fcdb78a136 | 571 | * DeviceMode is not in the supported list |
mjarvisal | 0:e6fcdb78a136 | 572 | */ |
mjarvisal | 0:e6fcdb78a136 | 573 | VL53L0X_API VL53L0X_Error VL53L0X_GetDeviceMode(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 574 | VL53L0X_DeviceModes *pDeviceMode); |
mjarvisal | 0:e6fcdb78a136 | 575 | |
mjarvisal | 0:e6fcdb78a136 | 576 | /** |
mjarvisal | 0:e6fcdb78a136 | 577 | * @brief Sets the resolution of range measurements. |
mjarvisal | 0:e6fcdb78a136 | 578 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 579 | * Set resolution of range measurements to either 0.25mm if |
mjarvisal | 0:e6fcdb78a136 | 580 | * fraction enabled or 1mm if not enabled. |
mjarvisal | 0:e6fcdb78a136 | 581 | * |
mjarvisal | 0:e6fcdb78a136 | 582 | * @note This function Accesses the device |
mjarvisal | 0:e6fcdb78a136 | 583 | * |
mjarvisal | 0:e6fcdb78a136 | 584 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 585 | * @param Enable Enable high resolution |
mjarvisal | 0:e6fcdb78a136 | 586 | * |
mjarvisal | 0:e6fcdb78a136 | 587 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 588 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 589 | */ |
mjarvisal | 0:e6fcdb78a136 | 590 | VL53L0X_API VL53L0X_Error VL53L0X_SetRangeFractionEnable(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 591 | uint8_t Enable); |
mjarvisal | 0:e6fcdb78a136 | 592 | |
mjarvisal | 0:e6fcdb78a136 | 593 | /** |
mjarvisal | 0:e6fcdb78a136 | 594 | * @brief Gets the fraction enable parameter indicating the resolution of |
mjarvisal | 0:e6fcdb78a136 | 595 | * range measurements. |
mjarvisal | 0:e6fcdb78a136 | 596 | * |
mjarvisal | 0:e6fcdb78a136 | 597 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 598 | * Gets the fraction enable state, which translates to the resolution of |
mjarvisal | 0:e6fcdb78a136 | 599 | * range measurements as follows :Enabled:=0.25mm resolution, |
mjarvisal | 0:e6fcdb78a136 | 600 | * Not Enabled:=1mm resolution. |
mjarvisal | 0:e6fcdb78a136 | 601 | * |
mjarvisal | 0:e6fcdb78a136 | 602 | * @note This function Accesses the device |
mjarvisal | 0:e6fcdb78a136 | 603 | * |
mjarvisal | 0:e6fcdb78a136 | 604 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 605 | * @param pEnable Output Parameter reporting the fraction enable state. |
mjarvisal | 0:e6fcdb78a136 | 606 | * |
mjarvisal | 0:e6fcdb78a136 | 607 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 608 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 609 | */ |
mjarvisal | 0:e6fcdb78a136 | 610 | VL53L0X_API VL53L0X_Error VL53L0X_GetFractionEnable(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 611 | uint8_t *pEnable); |
mjarvisal | 0:e6fcdb78a136 | 612 | |
mjarvisal | 0:e6fcdb78a136 | 613 | /** |
mjarvisal | 0:e6fcdb78a136 | 614 | * @brief Set a new Histogram mode |
mjarvisal | 0:e6fcdb78a136 | 615 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 616 | * Set device to a new Histogram mode |
mjarvisal | 0:e6fcdb78a136 | 617 | * |
mjarvisal | 0:e6fcdb78a136 | 618 | * @note This function doesn't Access to the device |
mjarvisal | 0:e6fcdb78a136 | 619 | * |
mjarvisal | 0:e6fcdb78a136 | 620 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 621 | * @param HistogramMode New device mode to apply |
mjarvisal | 0:e6fcdb78a136 | 622 | * Valid values are: |
mjarvisal | 0:e6fcdb78a136 | 623 | * VL53L0X_HISTOGRAMMODE_DISABLED |
mjarvisal | 0:e6fcdb78a136 | 624 | * VL53L0X_DEVICEMODE_SINGLE_HISTOGRAM |
mjarvisal | 0:e6fcdb78a136 | 625 | * VL53L0X_HISTOGRAMMODE_REFERENCE_ONLY |
mjarvisal | 0:e6fcdb78a136 | 626 | * VL53L0X_HISTOGRAMMODE_RETURN_ONLY |
mjarvisal | 0:e6fcdb78a136 | 627 | * VL53L0X_HISTOGRAMMODE_BOTH |
mjarvisal | 0:e6fcdb78a136 | 628 | * |
mjarvisal | 0:e6fcdb78a136 | 629 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 630 | * @return VL53L0X_ERROR_MODE_NOT_SUPPORTED This error occurs when |
mjarvisal | 0:e6fcdb78a136 | 631 | * HistogramMode is not in the supported list |
mjarvisal | 0:e6fcdb78a136 | 632 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 633 | */ |
mjarvisal | 0:e6fcdb78a136 | 634 | VL53L0X_API VL53L0X_Error VL53L0X_SetHistogramMode(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 635 | VL53L0X_HistogramModes HistogramMode); |
mjarvisal | 0:e6fcdb78a136 | 636 | |
mjarvisal | 0:e6fcdb78a136 | 637 | /** |
mjarvisal | 0:e6fcdb78a136 | 638 | * @brief Get current new device mode |
mjarvisal | 0:e6fcdb78a136 | 639 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 640 | * Get current Histogram mode of a Device |
mjarvisal | 0:e6fcdb78a136 | 641 | * |
mjarvisal | 0:e6fcdb78a136 | 642 | * @note This function doesn't Access to the device |
mjarvisal | 0:e6fcdb78a136 | 643 | * |
mjarvisal | 0:e6fcdb78a136 | 644 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 645 | * @param pHistogramMode Pointer to current Histogram Mode value |
mjarvisal | 0:e6fcdb78a136 | 646 | * Valid values are: |
mjarvisal | 0:e6fcdb78a136 | 647 | * VL53L0X_HISTOGRAMMODE_DISABLED |
mjarvisal | 0:e6fcdb78a136 | 648 | * VL53L0X_DEVICEMODE_SINGLE_HISTOGRAM |
mjarvisal | 0:e6fcdb78a136 | 649 | * VL53L0X_HISTOGRAMMODE_REFERENCE_ONLY |
mjarvisal | 0:e6fcdb78a136 | 650 | * VL53L0X_HISTOGRAMMODE_RETURN_ONLY |
mjarvisal | 0:e6fcdb78a136 | 651 | * VL53L0X_HISTOGRAMMODE_BOTH |
mjarvisal | 0:e6fcdb78a136 | 652 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 653 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 654 | */ |
mjarvisal | 0:e6fcdb78a136 | 655 | VL53L0X_API VL53L0X_Error VL53L0X_GetHistogramMode(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 656 | VL53L0X_HistogramModes *pHistogramMode); |
mjarvisal | 0:e6fcdb78a136 | 657 | |
mjarvisal | 0:e6fcdb78a136 | 658 | /** |
mjarvisal | 0:e6fcdb78a136 | 659 | * @brief Set Ranging Timing Budget in microseconds |
mjarvisal | 0:e6fcdb78a136 | 660 | * |
mjarvisal | 0:e6fcdb78a136 | 661 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 662 | * Defines the maximum time allowed by the user to the device to run a |
mjarvisal | 0:e6fcdb78a136 | 663 | * full ranging sequence for the current mode (ranging, histogram, ASL ...) |
mjarvisal | 0:e6fcdb78a136 | 664 | * |
mjarvisal | 0:e6fcdb78a136 | 665 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 666 | * |
mjarvisal | 0:e6fcdb78a136 | 667 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 668 | * @param MeasurementTimingBudgetMicroSeconds Max measurement time in |
mjarvisal | 0:e6fcdb78a136 | 669 | * microseconds. |
mjarvisal | 0:e6fcdb78a136 | 670 | * Valid values are: |
mjarvisal | 0:e6fcdb78a136 | 671 | * >= 17000 microsecs when wraparound enabled |
mjarvisal | 0:e6fcdb78a136 | 672 | * >= 12000 microsecs when wraparound disabled |
mjarvisal | 0:e6fcdb78a136 | 673 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 674 | * @return VL53L0X_ERROR_INVALID_PARAMS This error is returned if |
mjarvisal | 0:e6fcdb78a136 | 675 | MeasurementTimingBudgetMicroSeconds out of range |
mjarvisal | 0:e6fcdb78a136 | 676 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 677 | */ |
mjarvisal | 0:e6fcdb78a136 | 678 | VL53L0X_API VL53L0X_Error VL53L0X_SetMeasurementTimingBudgetMicroSeconds( |
mjarvisal | 0:e6fcdb78a136 | 679 | VL53L0X_DEV Dev, uint32_t MeasurementTimingBudgetMicroSeconds); |
mjarvisal | 0:e6fcdb78a136 | 680 | |
mjarvisal | 0:e6fcdb78a136 | 681 | /** |
mjarvisal | 0:e6fcdb78a136 | 682 | * @brief Get Ranging Timing Budget in microseconds |
mjarvisal | 0:e6fcdb78a136 | 683 | * |
mjarvisal | 0:e6fcdb78a136 | 684 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 685 | * Returns the programmed the maximum time allowed by the user to the |
mjarvisal | 0:e6fcdb78a136 | 686 | * device to run a full ranging sequence for the current mode |
mjarvisal | 0:e6fcdb78a136 | 687 | * (ranging, histogram, ASL ...) |
mjarvisal | 0:e6fcdb78a136 | 688 | * |
mjarvisal | 0:e6fcdb78a136 | 689 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 690 | * |
mjarvisal | 0:e6fcdb78a136 | 691 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 692 | * @param pMeasurementTimingBudgetMicroSeconds Max measurement time in |
mjarvisal | 0:e6fcdb78a136 | 693 | * microseconds. |
mjarvisal | 0:e6fcdb78a136 | 694 | * Valid values are: |
mjarvisal | 0:e6fcdb78a136 | 695 | * >= 17000 microsecs when wraparound enabled |
mjarvisal | 0:e6fcdb78a136 | 696 | * >= 12000 microsecs when wraparound disabled |
mjarvisal | 0:e6fcdb78a136 | 697 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 698 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 699 | */ |
mjarvisal | 0:e6fcdb78a136 | 700 | VL53L0X_API VL53L0X_Error VL53L0X_GetMeasurementTimingBudgetMicroSeconds( |
mjarvisal | 0:e6fcdb78a136 | 701 | VL53L0X_DEV Dev, uint32_t *pMeasurementTimingBudgetMicroSeconds); |
mjarvisal | 0:e6fcdb78a136 | 702 | |
mjarvisal | 0:e6fcdb78a136 | 703 | /** |
mjarvisal | 0:e6fcdb78a136 | 704 | * @brief Gets the VCSEL pulse period. |
mjarvisal | 0:e6fcdb78a136 | 705 | * |
mjarvisal | 0:e6fcdb78a136 | 706 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 707 | * This function retrieves the VCSEL pulse period for the given period type. |
mjarvisal | 0:e6fcdb78a136 | 708 | * |
mjarvisal | 0:e6fcdb78a136 | 709 | * @note This function Accesses the device |
mjarvisal | 0:e6fcdb78a136 | 710 | * |
mjarvisal | 0:e6fcdb78a136 | 711 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 712 | * @param VcselPeriodType VCSEL period identifier (pre-range|final). |
mjarvisal | 0:e6fcdb78a136 | 713 | * @param pVCSELPulsePeriod Pointer to VCSEL period value. |
mjarvisal | 0:e6fcdb78a136 | 714 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 715 | * @return VL53L0X_ERROR_INVALID_PARAMS Error VcselPeriodType parameter not |
mjarvisal | 0:e6fcdb78a136 | 716 | * supported. |
mjarvisal | 0:e6fcdb78a136 | 717 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 718 | */ |
mjarvisal | 0:e6fcdb78a136 | 719 | VL53L0X_API VL53L0X_Error VL53L0X_GetVcselPulsePeriod(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 720 | VL53L0X_VcselPeriod VcselPeriodType, uint8_t *pVCSELPulsePeriod); |
mjarvisal | 0:e6fcdb78a136 | 721 | |
mjarvisal | 0:e6fcdb78a136 | 722 | /** |
mjarvisal | 0:e6fcdb78a136 | 723 | * @brief Sets the VCSEL pulse period. |
mjarvisal | 0:e6fcdb78a136 | 724 | * |
mjarvisal | 0:e6fcdb78a136 | 725 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 726 | * This function retrieves the VCSEL pulse period for the given period type. |
mjarvisal | 0:e6fcdb78a136 | 727 | * |
mjarvisal | 0:e6fcdb78a136 | 728 | * @note This function Accesses the device |
mjarvisal | 0:e6fcdb78a136 | 729 | * |
mjarvisal | 0:e6fcdb78a136 | 730 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 731 | * @param VcselPeriodType VCSEL period identifier (pre-range|final). |
mjarvisal | 0:e6fcdb78a136 | 732 | * @param VCSELPulsePeriod VCSEL period value |
mjarvisal | 0:e6fcdb78a136 | 733 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 734 | * @return VL53L0X_ERROR_INVALID_PARAMS Error VcselPeriodType parameter not |
mjarvisal | 0:e6fcdb78a136 | 735 | * supported. |
mjarvisal | 0:e6fcdb78a136 | 736 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 737 | */ |
mjarvisal | 0:e6fcdb78a136 | 738 | VL53L0X_API VL53L0X_Error VL53L0X_SetVcselPulsePeriod(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 739 | VL53L0X_VcselPeriod VcselPeriodType, uint8_t VCSELPulsePeriod); |
mjarvisal | 0:e6fcdb78a136 | 740 | |
mjarvisal | 0:e6fcdb78a136 | 741 | /** |
mjarvisal | 0:e6fcdb78a136 | 742 | * @brief Sets the (on/off) state of a requested sequence step. |
mjarvisal | 0:e6fcdb78a136 | 743 | * |
mjarvisal | 0:e6fcdb78a136 | 744 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 745 | * This function enables/disables a requested sequence step. |
mjarvisal | 0:e6fcdb78a136 | 746 | * |
mjarvisal | 0:e6fcdb78a136 | 747 | * @note This function Accesses the device |
mjarvisal | 0:e6fcdb78a136 | 748 | * |
mjarvisal | 0:e6fcdb78a136 | 749 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 750 | * @param SequenceStepId Sequence step identifier. |
mjarvisal | 0:e6fcdb78a136 | 751 | * @param SequenceStepEnabled Demanded state {0=Off,1=On} |
mjarvisal | 0:e6fcdb78a136 | 752 | * is enabled. |
mjarvisal | 0:e6fcdb78a136 | 753 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 754 | * @return VL53L0X_ERROR_INVALID_PARAMS Error SequenceStepId parameter not |
mjarvisal | 0:e6fcdb78a136 | 755 | * supported. |
mjarvisal | 0:e6fcdb78a136 | 756 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 757 | */ |
mjarvisal | 0:e6fcdb78a136 | 758 | VL53L0X_API VL53L0X_Error VL53L0X_SetSequenceStepEnable(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 759 | VL53L0X_SequenceStepId SequenceStepId, uint8_t SequenceStepEnabled); |
mjarvisal | 0:e6fcdb78a136 | 760 | |
mjarvisal | 0:e6fcdb78a136 | 761 | /** |
mjarvisal | 0:e6fcdb78a136 | 762 | * @brief Gets the (on/off) state of a requested sequence step. |
mjarvisal | 0:e6fcdb78a136 | 763 | * |
mjarvisal | 0:e6fcdb78a136 | 764 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 765 | * This function retrieves the state of a requested sequence step, i.e. on/off. |
mjarvisal | 0:e6fcdb78a136 | 766 | * |
mjarvisal | 0:e6fcdb78a136 | 767 | * @note This function Accesses the device |
mjarvisal | 0:e6fcdb78a136 | 768 | * |
mjarvisal | 0:e6fcdb78a136 | 769 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 770 | * @param SequenceStepId Sequence step identifier. |
mjarvisal | 0:e6fcdb78a136 | 771 | * @param pSequenceStepEnabled Out parameter reporting if the sequence step |
mjarvisal | 0:e6fcdb78a136 | 772 | * is enabled {0=Off,1=On}. |
mjarvisal | 0:e6fcdb78a136 | 773 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 774 | * @return VL53L0X_ERROR_INVALID_PARAMS Error SequenceStepId parameter not |
mjarvisal | 0:e6fcdb78a136 | 775 | * supported. |
mjarvisal | 0:e6fcdb78a136 | 776 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 777 | */ |
mjarvisal | 0:e6fcdb78a136 | 778 | VL53L0X_API VL53L0X_Error VL53L0X_GetSequenceStepEnable(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 779 | VL53L0X_SequenceStepId SequenceStepId, uint8_t *pSequenceStepEnabled); |
mjarvisal | 0:e6fcdb78a136 | 780 | |
mjarvisal | 0:e6fcdb78a136 | 781 | /** |
mjarvisal | 0:e6fcdb78a136 | 782 | * @brief Gets the (on/off) state of all sequence steps. |
mjarvisal | 0:e6fcdb78a136 | 783 | * |
mjarvisal | 0:e6fcdb78a136 | 784 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 785 | * This function retrieves the state of all sequence step in the scheduler. |
mjarvisal | 0:e6fcdb78a136 | 786 | * |
mjarvisal | 0:e6fcdb78a136 | 787 | * @note This function Accesses the device |
mjarvisal | 0:e6fcdb78a136 | 788 | * |
mjarvisal | 0:e6fcdb78a136 | 789 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 790 | * @param pSchedulerSequenceSteps Pointer to struct containing result. |
mjarvisal | 0:e6fcdb78a136 | 791 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 792 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 793 | */ |
mjarvisal | 0:e6fcdb78a136 | 794 | VL53L0X_API VL53L0X_Error VL53L0X_GetSequenceStepEnables(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 795 | VL53L0X_SchedulerSequenceSteps_t *pSchedulerSequenceSteps); |
mjarvisal | 0:e6fcdb78a136 | 796 | |
mjarvisal | 0:e6fcdb78a136 | 797 | /** |
mjarvisal | 0:e6fcdb78a136 | 798 | * @brief Sets the timeout of a requested sequence step. |
mjarvisal | 0:e6fcdb78a136 | 799 | * |
mjarvisal | 0:e6fcdb78a136 | 800 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 801 | * This function sets the timeout of a requested sequence step. |
mjarvisal | 0:e6fcdb78a136 | 802 | * |
mjarvisal | 0:e6fcdb78a136 | 803 | * @note This function Accesses the device |
mjarvisal | 0:e6fcdb78a136 | 804 | * |
mjarvisal | 0:e6fcdb78a136 | 805 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 806 | * @param SequenceStepId Sequence step identifier. |
mjarvisal | 0:e6fcdb78a136 | 807 | * @param TimeOutMilliSecs Demanded timeout |
mjarvisal | 0:e6fcdb78a136 | 808 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 809 | * @return VL53L0X_ERROR_INVALID_PARAMS Error SequenceStepId parameter not |
mjarvisal | 0:e6fcdb78a136 | 810 | * supported. |
mjarvisal | 0:e6fcdb78a136 | 811 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 812 | */ |
mjarvisal | 0:e6fcdb78a136 | 813 | VL53L0X_API VL53L0X_Error VL53L0X_SetSequenceStepTimeout(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 814 | VL53L0X_SequenceStepId SequenceStepId, FixPoint1616_t TimeOutMilliSecs); |
mjarvisal | 0:e6fcdb78a136 | 815 | |
mjarvisal | 0:e6fcdb78a136 | 816 | /** |
mjarvisal | 0:e6fcdb78a136 | 817 | * @brief Gets the timeout of a requested sequence step. |
mjarvisal | 0:e6fcdb78a136 | 818 | * |
mjarvisal | 0:e6fcdb78a136 | 819 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 820 | * This function retrieves the timeout of a requested sequence step. |
mjarvisal | 0:e6fcdb78a136 | 821 | * |
mjarvisal | 0:e6fcdb78a136 | 822 | * @note This function Accesses the device |
mjarvisal | 0:e6fcdb78a136 | 823 | * |
mjarvisal | 0:e6fcdb78a136 | 824 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 825 | * @param SequenceStepId Sequence step identifier. |
mjarvisal | 0:e6fcdb78a136 | 826 | * @param pTimeOutMilliSecs Timeout value. |
mjarvisal | 0:e6fcdb78a136 | 827 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 828 | * @return VL53L0X_ERROR_INVALID_PARAMS Error SequenceStepId parameter not |
mjarvisal | 0:e6fcdb78a136 | 829 | * supported. |
mjarvisal | 0:e6fcdb78a136 | 830 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 831 | */ |
mjarvisal | 0:e6fcdb78a136 | 832 | VL53L0X_API VL53L0X_Error VL53L0X_GetSequenceStepTimeout(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 833 | VL53L0X_SequenceStepId SequenceStepId, |
mjarvisal | 0:e6fcdb78a136 | 834 | FixPoint1616_t *pTimeOutMilliSecs); |
mjarvisal | 0:e6fcdb78a136 | 835 | |
mjarvisal | 0:e6fcdb78a136 | 836 | /** |
mjarvisal | 0:e6fcdb78a136 | 837 | * @brief Gets number of sequence steps managed by the API. |
mjarvisal | 0:e6fcdb78a136 | 838 | * |
mjarvisal | 0:e6fcdb78a136 | 839 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 840 | * This function retrieves the number of sequence steps currently managed |
mjarvisal | 0:e6fcdb78a136 | 841 | * by the API |
mjarvisal | 0:e6fcdb78a136 | 842 | * |
mjarvisal | 0:e6fcdb78a136 | 843 | * @note This function Accesses the device |
mjarvisal | 0:e6fcdb78a136 | 844 | * |
mjarvisal | 0:e6fcdb78a136 | 845 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 846 | * @param pNumberOfSequenceSteps Out parameter reporting the number of |
mjarvisal | 0:e6fcdb78a136 | 847 | * sequence steps. |
mjarvisal | 0:e6fcdb78a136 | 848 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 849 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 850 | */ |
mjarvisal | 0:e6fcdb78a136 | 851 | VL53L0X_API VL53L0X_Error VL53L0X_GetNumberOfSequenceSteps(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 852 | uint8_t *pNumberOfSequenceSteps); |
mjarvisal | 0:e6fcdb78a136 | 853 | |
mjarvisal | 0:e6fcdb78a136 | 854 | /** |
mjarvisal | 0:e6fcdb78a136 | 855 | * @brief Gets the name of a given sequence step. |
mjarvisal | 0:e6fcdb78a136 | 856 | * |
mjarvisal | 0:e6fcdb78a136 | 857 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 858 | * This function retrieves the name of sequence steps corresponding to |
mjarvisal | 0:e6fcdb78a136 | 859 | * SequenceStepId. |
mjarvisal | 0:e6fcdb78a136 | 860 | * |
mjarvisal | 0:e6fcdb78a136 | 861 | * @note This function doesn't Accesses the device |
mjarvisal | 0:e6fcdb78a136 | 862 | * |
mjarvisal | 0:e6fcdb78a136 | 863 | * @param SequenceStepId Sequence step identifier. |
mjarvisal | 0:e6fcdb78a136 | 864 | * @param pSequenceStepsString Pointer to Info string |
mjarvisal | 0:e6fcdb78a136 | 865 | * |
mjarvisal | 0:e6fcdb78a136 | 866 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 867 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 868 | */ |
mjarvisal | 0:e6fcdb78a136 | 869 | VL53L0X_API VL53L0X_Error VL53L0X_GetSequenceStepsInfo( |
mjarvisal | 0:e6fcdb78a136 | 870 | VL53L0X_SequenceStepId SequenceStepId, char *pSequenceStepsString); |
mjarvisal | 0:e6fcdb78a136 | 871 | |
mjarvisal | 0:e6fcdb78a136 | 872 | /** |
mjarvisal | 0:e6fcdb78a136 | 873 | * Program continuous mode Inter-Measurement period in milliseconds |
mjarvisal | 0:e6fcdb78a136 | 874 | * |
mjarvisal | 0:e6fcdb78a136 | 875 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 876 | * When trying to set too short time return INVALID_PARAMS minimal value |
mjarvisal | 0:e6fcdb78a136 | 877 | * |
mjarvisal | 0:e6fcdb78a136 | 878 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 879 | * |
mjarvisal | 0:e6fcdb78a136 | 880 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 881 | * @param InterMeasurementPeriodMilliSeconds Inter-Measurement Period in ms. |
mjarvisal | 0:e6fcdb78a136 | 882 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 883 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 884 | */ |
mjarvisal | 0:e6fcdb78a136 | 885 | VL53L0X_API VL53L0X_Error VL53L0X_SetInterMeasurementPeriodMilliSeconds( |
mjarvisal | 0:e6fcdb78a136 | 886 | VL53L0X_DEV Dev, uint32_t InterMeasurementPeriodMilliSeconds); |
mjarvisal | 0:e6fcdb78a136 | 887 | |
mjarvisal | 0:e6fcdb78a136 | 888 | /** |
mjarvisal | 0:e6fcdb78a136 | 889 | * Get continuous mode Inter-Measurement period in milliseconds |
mjarvisal | 0:e6fcdb78a136 | 890 | * |
mjarvisal | 0:e6fcdb78a136 | 891 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 892 | * When trying to set too short time return INVALID_PARAMS minimal value |
mjarvisal | 0:e6fcdb78a136 | 893 | * |
mjarvisal | 0:e6fcdb78a136 | 894 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 895 | * |
mjarvisal | 0:e6fcdb78a136 | 896 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 897 | * @param pInterMeasurementPeriodMilliSeconds Pointer to programmed |
mjarvisal | 0:e6fcdb78a136 | 898 | * Inter-Measurement Period in milliseconds. |
mjarvisal | 0:e6fcdb78a136 | 899 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 900 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 901 | */ |
mjarvisal | 0:e6fcdb78a136 | 902 | VL53L0X_API VL53L0X_Error VL53L0X_GetInterMeasurementPeriodMilliSeconds( |
mjarvisal | 0:e6fcdb78a136 | 903 | VL53L0X_DEV Dev, uint32_t *pInterMeasurementPeriodMilliSeconds); |
mjarvisal | 0:e6fcdb78a136 | 904 | |
mjarvisal | 0:e6fcdb78a136 | 905 | /** |
mjarvisal | 0:e6fcdb78a136 | 906 | * @brief Enable/Disable Cross talk compensation feature |
mjarvisal | 0:e6fcdb78a136 | 907 | * |
mjarvisal | 0:e6fcdb78a136 | 908 | * @note This function is not Implemented. |
mjarvisal | 0:e6fcdb78a136 | 909 | * Enable/Disable Cross Talk by set to zero the Cross Talk value |
mjarvisal | 0:e6fcdb78a136 | 910 | * by using @a VL53L0X_SetXTalkCompensationRateMegaCps(). |
mjarvisal | 0:e6fcdb78a136 | 911 | * |
mjarvisal | 0:e6fcdb78a136 | 912 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 913 | * @param XTalkCompensationEnable Cross talk compensation |
mjarvisal | 0:e6fcdb78a136 | 914 | * to be set 0=disabled else = enabled |
mjarvisal | 0:e6fcdb78a136 | 915 | * @return VL53L0X_ERROR_NOT_IMPLEMENTED Not implemented |
mjarvisal | 0:e6fcdb78a136 | 916 | */ |
mjarvisal | 0:e6fcdb78a136 | 917 | VL53L0X_API VL53L0X_Error VL53L0X_SetXTalkCompensationEnable(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 918 | uint8_t XTalkCompensationEnable); |
mjarvisal | 0:e6fcdb78a136 | 919 | |
mjarvisal | 0:e6fcdb78a136 | 920 | /** |
mjarvisal | 0:e6fcdb78a136 | 921 | * @brief Get Cross talk compensation rate |
mjarvisal | 0:e6fcdb78a136 | 922 | * |
mjarvisal | 0:e6fcdb78a136 | 923 | * @note This function is not Implemented. |
mjarvisal | 0:e6fcdb78a136 | 924 | * Enable/Disable Cross Talk by set to zero the Cross Talk value by |
mjarvisal | 0:e6fcdb78a136 | 925 | * using @a VL53L0X_SetXTalkCompensationRateMegaCps(). |
mjarvisal | 0:e6fcdb78a136 | 926 | * |
mjarvisal | 0:e6fcdb78a136 | 927 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 928 | * @param pXTalkCompensationEnable Pointer to the Cross talk compensation |
mjarvisal | 0:e6fcdb78a136 | 929 | * state 0=disabled or 1 = enabled |
mjarvisal | 0:e6fcdb78a136 | 930 | * @return VL53L0X_ERROR_NOT_IMPLEMENTED Not implemented |
mjarvisal | 0:e6fcdb78a136 | 931 | */ |
mjarvisal | 0:e6fcdb78a136 | 932 | VL53L0X_API VL53L0X_Error VL53L0X_GetXTalkCompensationEnable(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 933 | uint8_t *pXTalkCompensationEnable); |
mjarvisal | 0:e6fcdb78a136 | 934 | |
mjarvisal | 0:e6fcdb78a136 | 935 | /** |
mjarvisal | 0:e6fcdb78a136 | 936 | * @brief Set Cross talk compensation rate |
mjarvisal | 0:e6fcdb78a136 | 937 | * |
mjarvisal | 0:e6fcdb78a136 | 938 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 939 | * Set Cross talk compensation rate. |
mjarvisal | 0:e6fcdb78a136 | 940 | * |
mjarvisal | 0:e6fcdb78a136 | 941 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 942 | * |
mjarvisal | 0:e6fcdb78a136 | 943 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 944 | * @param XTalkCompensationRateMegaCps Compensation rate in |
mjarvisal | 0:e6fcdb78a136 | 945 | * Mega counts per second (16.16 fix point) see datasheet for details |
mjarvisal | 0:e6fcdb78a136 | 946 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 947 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 948 | */ |
mjarvisal | 0:e6fcdb78a136 | 949 | VL53L0X_API VL53L0X_Error VL53L0X_SetXTalkCompensationRateMegaCps(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 950 | FixPoint1616_t XTalkCompensationRateMegaCps); |
mjarvisal | 0:e6fcdb78a136 | 951 | |
mjarvisal | 0:e6fcdb78a136 | 952 | /** |
mjarvisal | 0:e6fcdb78a136 | 953 | * @brief Get Cross talk compensation rate |
mjarvisal | 0:e6fcdb78a136 | 954 | * |
mjarvisal | 0:e6fcdb78a136 | 955 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 956 | * Get Cross talk compensation rate. |
mjarvisal | 0:e6fcdb78a136 | 957 | * |
mjarvisal | 0:e6fcdb78a136 | 958 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 959 | * |
mjarvisal | 0:e6fcdb78a136 | 960 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 961 | * @param pXTalkCompensationRateMegaCps Pointer to Compensation rate |
mjarvisal | 0:e6fcdb78a136 | 962 | in Mega counts per second (16.16 fix point) see datasheet for details |
mjarvisal | 0:e6fcdb78a136 | 963 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 964 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 965 | */ |
mjarvisal | 0:e6fcdb78a136 | 966 | VL53L0X_API VL53L0X_Error VL53L0X_GetXTalkCompensationRateMegaCps(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 967 | FixPoint1616_t *pXTalkCompensationRateMegaCps); |
mjarvisal | 0:e6fcdb78a136 | 968 | |
mjarvisal | 0:e6fcdb78a136 | 969 | /** |
mjarvisal | 0:e6fcdb78a136 | 970 | * @brief Set Reference Calibration Parameters |
mjarvisal | 0:e6fcdb78a136 | 971 | * |
mjarvisal | 0:e6fcdb78a136 | 972 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 973 | * Set Reference Calibration Parameters. |
mjarvisal | 0:e6fcdb78a136 | 974 | * |
mjarvisal | 0:e6fcdb78a136 | 975 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 976 | * |
mjarvisal | 0:e6fcdb78a136 | 977 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 978 | * @param VhvSettings Parameter for VHV |
mjarvisal | 0:e6fcdb78a136 | 979 | * @param PhaseCal Parameter for PhaseCal |
mjarvisal | 0:e6fcdb78a136 | 980 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 981 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 982 | */ |
mjarvisal | 0:e6fcdb78a136 | 983 | VL53L0X_API VL53L0X_Error VL53L0X_SetRefCalibration(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 984 | uint8_t VhvSettings, uint8_t PhaseCal); |
mjarvisal | 0:e6fcdb78a136 | 985 | |
mjarvisal | 0:e6fcdb78a136 | 986 | /** |
mjarvisal | 0:e6fcdb78a136 | 987 | * @brief Get Reference Calibration Parameters |
mjarvisal | 0:e6fcdb78a136 | 988 | * |
mjarvisal | 0:e6fcdb78a136 | 989 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 990 | * Get Reference Calibration Parameters. |
mjarvisal | 0:e6fcdb78a136 | 991 | * |
mjarvisal | 0:e6fcdb78a136 | 992 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 993 | * |
mjarvisal | 0:e6fcdb78a136 | 994 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 995 | * @param pVhvSettings Pointer to VHV parameter |
mjarvisal | 0:e6fcdb78a136 | 996 | * @param pPhaseCal Pointer to PhaseCal Parameter |
mjarvisal | 0:e6fcdb78a136 | 997 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 998 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 999 | */ |
mjarvisal | 0:e6fcdb78a136 | 1000 | VL53L0X_API VL53L0X_Error VL53L0X_GetRefCalibration(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1001 | uint8_t *pVhvSettings, uint8_t *pPhaseCal); |
mjarvisal | 0:e6fcdb78a136 | 1002 | |
mjarvisal | 0:e6fcdb78a136 | 1003 | /** |
mjarvisal | 0:e6fcdb78a136 | 1004 | * @brief Get the number of the check limit managed by a given Device |
mjarvisal | 0:e6fcdb78a136 | 1005 | * |
mjarvisal | 0:e6fcdb78a136 | 1006 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1007 | * This function give the number of the check limit managed by the Device |
mjarvisal | 0:e6fcdb78a136 | 1008 | * |
mjarvisal | 0:e6fcdb78a136 | 1009 | * @note This function doesn't Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1010 | * |
mjarvisal | 0:e6fcdb78a136 | 1011 | * @param pNumberOfLimitCheck Pointer to the number of check limit. |
mjarvisal | 0:e6fcdb78a136 | 1012 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1013 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1014 | */ |
mjarvisal | 0:e6fcdb78a136 | 1015 | VL53L0X_API VL53L0X_Error VL53L0X_GetNumberOfLimitCheck( |
mjarvisal | 0:e6fcdb78a136 | 1016 | uint16_t *pNumberOfLimitCheck); |
mjarvisal | 0:e6fcdb78a136 | 1017 | |
mjarvisal | 0:e6fcdb78a136 | 1018 | /** |
mjarvisal | 0:e6fcdb78a136 | 1019 | * @brief Return a description string for a given limit check number |
mjarvisal | 0:e6fcdb78a136 | 1020 | * |
mjarvisal | 0:e6fcdb78a136 | 1021 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1022 | * This function returns a description string for a given limit check number. |
mjarvisal | 0:e6fcdb78a136 | 1023 | * The limit check is identified with the LimitCheckId. |
mjarvisal | 0:e6fcdb78a136 | 1024 | * |
mjarvisal | 0:e6fcdb78a136 | 1025 | * @note This function doesn't Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1026 | * |
mjarvisal | 0:e6fcdb78a136 | 1027 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1028 | * @param LimitCheckId Limit Check ID |
mjarvisal | 0:e6fcdb78a136 | 1029 | (0<= LimitCheckId < VL53L0X_GetNumberOfLimitCheck() ). |
mjarvisal | 0:e6fcdb78a136 | 1030 | * @param pLimitCheckString Pointer to the |
mjarvisal | 0:e6fcdb78a136 | 1031 | description string of the given check limit. |
mjarvisal | 0:e6fcdb78a136 | 1032 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1033 | * @return VL53L0X_ERROR_INVALID_PARAMS This error is |
mjarvisal | 0:e6fcdb78a136 | 1034 | returned when LimitCheckId value is out of range. |
mjarvisal | 0:e6fcdb78a136 | 1035 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1036 | */ |
mjarvisal | 0:e6fcdb78a136 | 1037 | VL53L0X_API VL53L0X_Error VL53L0X_GetLimitCheckInfo(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1038 | uint16_t LimitCheckId, char *pLimitCheckString); |
mjarvisal | 0:e6fcdb78a136 | 1039 | |
mjarvisal | 0:e6fcdb78a136 | 1040 | /** |
mjarvisal | 0:e6fcdb78a136 | 1041 | * @brief Return a the Status of the specified check limit |
mjarvisal | 0:e6fcdb78a136 | 1042 | * |
mjarvisal | 0:e6fcdb78a136 | 1043 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1044 | * This function returns the Status of the specified check limit. |
mjarvisal | 0:e6fcdb78a136 | 1045 | * The value indicate if the check is fail or not. |
mjarvisal | 0:e6fcdb78a136 | 1046 | * The limit check is identified with the LimitCheckId. |
mjarvisal | 0:e6fcdb78a136 | 1047 | * |
mjarvisal | 0:e6fcdb78a136 | 1048 | * @note This function doesn't Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1049 | * |
mjarvisal | 0:e6fcdb78a136 | 1050 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1051 | * @param LimitCheckId Limit Check ID |
mjarvisal | 0:e6fcdb78a136 | 1052 | (0<= LimitCheckId < VL53L0X_GetNumberOfLimitCheck() ). |
mjarvisal | 0:e6fcdb78a136 | 1053 | * @param pLimitCheckStatus Pointer to the |
mjarvisal | 0:e6fcdb78a136 | 1054 | Limit Check Status of the given check limit. |
mjarvisal | 0:e6fcdb78a136 | 1055 | * LimitCheckStatus : |
mjarvisal | 0:e6fcdb78a136 | 1056 | * 0 the check is not fail |
mjarvisal | 0:e6fcdb78a136 | 1057 | * 1 the check if fail or not enabled |
mjarvisal | 0:e6fcdb78a136 | 1058 | * |
mjarvisal | 0:e6fcdb78a136 | 1059 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1060 | * @return VL53L0X_ERROR_INVALID_PARAMS This error is |
mjarvisal | 0:e6fcdb78a136 | 1061 | returned when LimitCheckId value is out of range. |
mjarvisal | 0:e6fcdb78a136 | 1062 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1063 | */ |
mjarvisal | 0:e6fcdb78a136 | 1064 | VL53L0X_API VL53L0X_Error VL53L0X_GetLimitCheckStatus(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1065 | uint16_t LimitCheckId, uint8_t *pLimitCheckStatus); |
mjarvisal | 0:e6fcdb78a136 | 1066 | |
mjarvisal | 0:e6fcdb78a136 | 1067 | /** |
mjarvisal | 0:e6fcdb78a136 | 1068 | * @brief Enable/Disable a specific limit check |
mjarvisal | 0:e6fcdb78a136 | 1069 | * |
mjarvisal | 0:e6fcdb78a136 | 1070 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1071 | * This function Enable/Disable a specific limit check. |
mjarvisal | 0:e6fcdb78a136 | 1072 | * The limit check is identified with the LimitCheckId. |
mjarvisal | 0:e6fcdb78a136 | 1073 | * |
mjarvisal | 0:e6fcdb78a136 | 1074 | * @note This function doesn't Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1075 | * |
mjarvisal | 0:e6fcdb78a136 | 1076 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1077 | * @param LimitCheckId Limit Check ID |
mjarvisal | 0:e6fcdb78a136 | 1078 | * (0<= LimitCheckId < VL53L0X_GetNumberOfLimitCheck() ). |
mjarvisal | 0:e6fcdb78a136 | 1079 | * @param LimitCheckEnable if 1 the check limit |
mjarvisal | 0:e6fcdb78a136 | 1080 | * corresponding to LimitCheckId is Enabled |
mjarvisal | 0:e6fcdb78a136 | 1081 | * if 0 the check limit |
mjarvisal | 0:e6fcdb78a136 | 1082 | * corresponding to LimitCheckId is disabled |
mjarvisal | 0:e6fcdb78a136 | 1083 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1084 | * @return VL53L0X_ERROR_INVALID_PARAMS This error is returned |
mjarvisal | 0:e6fcdb78a136 | 1085 | * when LimitCheckId value is out of range. |
mjarvisal | 0:e6fcdb78a136 | 1086 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1087 | */ |
mjarvisal | 0:e6fcdb78a136 | 1088 | VL53L0X_API VL53L0X_Error VL53L0X_SetLimitCheckEnable(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1089 | uint16_t LimitCheckId, uint8_t LimitCheckEnable); |
mjarvisal | 0:e6fcdb78a136 | 1090 | |
mjarvisal | 0:e6fcdb78a136 | 1091 | /** |
mjarvisal | 0:e6fcdb78a136 | 1092 | * @brief Get specific limit check enable state |
mjarvisal | 0:e6fcdb78a136 | 1093 | * |
mjarvisal | 0:e6fcdb78a136 | 1094 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1095 | * This function get the enable state of a specific limit check. |
mjarvisal | 0:e6fcdb78a136 | 1096 | * The limit check is identified with the LimitCheckId. |
mjarvisal | 0:e6fcdb78a136 | 1097 | * |
mjarvisal | 0:e6fcdb78a136 | 1098 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1099 | * |
mjarvisal | 0:e6fcdb78a136 | 1100 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1101 | * @param LimitCheckId Limit Check ID |
mjarvisal | 0:e6fcdb78a136 | 1102 | * (0<= LimitCheckId < VL53L0X_GetNumberOfLimitCheck() ). |
mjarvisal | 0:e6fcdb78a136 | 1103 | * @param pLimitCheckEnable Pointer to the check limit enable |
mjarvisal | 0:e6fcdb78a136 | 1104 | * value. |
mjarvisal | 0:e6fcdb78a136 | 1105 | * if 1 the check limit |
mjarvisal | 0:e6fcdb78a136 | 1106 | * corresponding to LimitCheckId is Enabled |
mjarvisal | 0:e6fcdb78a136 | 1107 | * if 0 the check limit |
mjarvisal | 0:e6fcdb78a136 | 1108 | * corresponding to LimitCheckId is disabled |
mjarvisal | 0:e6fcdb78a136 | 1109 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1110 | * @return VL53L0X_ERROR_INVALID_PARAMS This error is returned |
mjarvisal | 0:e6fcdb78a136 | 1111 | * when LimitCheckId value is out of range. |
mjarvisal | 0:e6fcdb78a136 | 1112 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1113 | */ |
mjarvisal | 0:e6fcdb78a136 | 1114 | VL53L0X_API VL53L0X_Error VL53L0X_GetLimitCheckEnable(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1115 | uint16_t LimitCheckId, uint8_t *pLimitCheckEnable); |
mjarvisal | 0:e6fcdb78a136 | 1116 | |
mjarvisal | 0:e6fcdb78a136 | 1117 | /** |
mjarvisal | 0:e6fcdb78a136 | 1118 | * @brief Set a specific limit check value |
mjarvisal | 0:e6fcdb78a136 | 1119 | * |
mjarvisal | 0:e6fcdb78a136 | 1120 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1121 | * This function set a specific limit check value. |
mjarvisal | 0:e6fcdb78a136 | 1122 | * The limit check is identified with the LimitCheckId. |
mjarvisal | 0:e6fcdb78a136 | 1123 | * |
mjarvisal | 0:e6fcdb78a136 | 1124 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1125 | * |
mjarvisal | 0:e6fcdb78a136 | 1126 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1127 | * @param LimitCheckId Limit Check ID |
mjarvisal | 0:e6fcdb78a136 | 1128 | * (0<= LimitCheckId < VL53L0X_GetNumberOfLimitCheck() ). |
mjarvisal | 0:e6fcdb78a136 | 1129 | * @param LimitCheckValue Limit check Value for a given |
mjarvisal | 0:e6fcdb78a136 | 1130 | * LimitCheckId |
mjarvisal | 0:e6fcdb78a136 | 1131 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1132 | * @return VL53L0X_ERROR_INVALID_PARAMS This error is returned when either |
mjarvisal | 0:e6fcdb78a136 | 1133 | * LimitCheckId or LimitCheckValue value is out of range. |
mjarvisal | 0:e6fcdb78a136 | 1134 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1135 | */ |
mjarvisal | 0:e6fcdb78a136 | 1136 | VL53L0X_API VL53L0X_Error VL53L0X_SetLimitCheckValue(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1137 | uint16_t LimitCheckId, FixPoint1616_t LimitCheckValue); |
mjarvisal | 0:e6fcdb78a136 | 1138 | |
mjarvisal | 0:e6fcdb78a136 | 1139 | /** |
mjarvisal | 0:e6fcdb78a136 | 1140 | * @brief Get a specific limit check value |
mjarvisal | 0:e6fcdb78a136 | 1141 | * |
mjarvisal | 0:e6fcdb78a136 | 1142 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1143 | * This function get a specific limit check value from device then it updates |
mjarvisal | 0:e6fcdb78a136 | 1144 | * internal values and check enables. |
mjarvisal | 0:e6fcdb78a136 | 1145 | * The limit check is identified with the LimitCheckId. |
mjarvisal | 0:e6fcdb78a136 | 1146 | * |
mjarvisal | 0:e6fcdb78a136 | 1147 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1148 | * |
mjarvisal | 0:e6fcdb78a136 | 1149 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1150 | * @param LimitCheckId Limit Check ID |
mjarvisal | 0:e6fcdb78a136 | 1151 | * (0<= LimitCheckId < VL53L0X_GetNumberOfLimitCheck() ). |
mjarvisal | 0:e6fcdb78a136 | 1152 | * @param pLimitCheckValue Pointer to Limit |
mjarvisal | 0:e6fcdb78a136 | 1153 | * check Value for a given LimitCheckId. |
mjarvisal | 0:e6fcdb78a136 | 1154 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1155 | * @return VL53L0X_ERROR_INVALID_PARAMS This error is returned |
mjarvisal | 0:e6fcdb78a136 | 1156 | * when LimitCheckId value is out of range. |
mjarvisal | 0:e6fcdb78a136 | 1157 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1158 | */ |
mjarvisal | 0:e6fcdb78a136 | 1159 | VL53L0X_API VL53L0X_Error VL53L0X_GetLimitCheckValue(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1160 | uint16_t LimitCheckId, FixPoint1616_t *pLimitCheckValue); |
mjarvisal | 0:e6fcdb78a136 | 1161 | |
mjarvisal | 0:e6fcdb78a136 | 1162 | /** |
mjarvisal | 0:e6fcdb78a136 | 1163 | * @brief Get the current value of the signal used for the limit check |
mjarvisal | 0:e6fcdb78a136 | 1164 | * |
mjarvisal | 0:e6fcdb78a136 | 1165 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1166 | * This function get a the current value of the signal used for the limit check. |
mjarvisal | 0:e6fcdb78a136 | 1167 | * To obtain the latest value you should run a ranging before. |
mjarvisal | 0:e6fcdb78a136 | 1168 | * The value reported is linked to the limit check identified with the |
mjarvisal | 0:e6fcdb78a136 | 1169 | * LimitCheckId. |
mjarvisal | 0:e6fcdb78a136 | 1170 | * |
mjarvisal | 0:e6fcdb78a136 | 1171 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1172 | * |
mjarvisal | 0:e6fcdb78a136 | 1173 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1174 | * @param LimitCheckId Limit Check ID |
mjarvisal | 0:e6fcdb78a136 | 1175 | * (0<= LimitCheckId < VL53L0X_GetNumberOfLimitCheck() ). |
mjarvisal | 0:e6fcdb78a136 | 1176 | * @param pLimitCheckCurrent Pointer to current Value for a |
mjarvisal | 0:e6fcdb78a136 | 1177 | * given LimitCheckId. |
mjarvisal | 0:e6fcdb78a136 | 1178 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1179 | * @return VL53L0X_ERROR_INVALID_PARAMS This error is returned when |
mjarvisal | 0:e6fcdb78a136 | 1180 | * LimitCheckId value is out of range. |
mjarvisal | 0:e6fcdb78a136 | 1181 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1182 | */ |
mjarvisal | 0:e6fcdb78a136 | 1183 | VL53L0X_API VL53L0X_Error VL53L0X_GetLimitCheckCurrent(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1184 | uint16_t LimitCheckId, FixPoint1616_t *pLimitCheckCurrent); |
mjarvisal | 0:e6fcdb78a136 | 1185 | |
mjarvisal | 0:e6fcdb78a136 | 1186 | /** |
mjarvisal | 0:e6fcdb78a136 | 1187 | * @brief Enable (or disable) Wrap around Check |
mjarvisal | 0:e6fcdb78a136 | 1188 | * |
mjarvisal | 0:e6fcdb78a136 | 1189 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1190 | * |
mjarvisal | 0:e6fcdb78a136 | 1191 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1192 | * @param WrapAroundCheckEnable Wrap around Check to be set |
mjarvisal | 0:e6fcdb78a136 | 1193 | * 0=disabled, other = enabled |
mjarvisal | 0:e6fcdb78a136 | 1194 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1195 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1196 | */ |
mjarvisal | 0:e6fcdb78a136 | 1197 | VL53L0X_API VL53L0X_Error VL53L0X_SetWrapAroundCheckEnable(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1198 | uint8_t WrapAroundCheckEnable); |
mjarvisal | 0:e6fcdb78a136 | 1199 | |
mjarvisal | 0:e6fcdb78a136 | 1200 | /** |
mjarvisal | 0:e6fcdb78a136 | 1201 | * @brief Get setup of Wrap around Check |
mjarvisal | 0:e6fcdb78a136 | 1202 | * |
mjarvisal | 0:e6fcdb78a136 | 1203 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1204 | * This function get the wrapAround check enable parameters |
mjarvisal | 0:e6fcdb78a136 | 1205 | * |
mjarvisal | 0:e6fcdb78a136 | 1206 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1207 | * |
mjarvisal | 0:e6fcdb78a136 | 1208 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1209 | * @param pWrapAroundCheckEnable Pointer to the Wrap around Check state |
mjarvisal | 0:e6fcdb78a136 | 1210 | * 0=disabled or 1 = enabled |
mjarvisal | 0:e6fcdb78a136 | 1211 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1212 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1213 | */ |
mjarvisal | 0:e6fcdb78a136 | 1214 | VL53L0X_API VL53L0X_Error VL53L0X_GetWrapAroundCheckEnable(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1215 | uint8_t *pWrapAroundCheckEnable); |
mjarvisal | 0:e6fcdb78a136 | 1216 | |
mjarvisal | 0:e6fcdb78a136 | 1217 | /** |
mjarvisal | 0:e6fcdb78a136 | 1218 | * @brief Set Dmax Calibration Parameters for a given device |
mjarvisal | 0:e6fcdb78a136 | 1219 | * When one of the parameter is zero, this function will get parameter |
mjarvisal | 0:e6fcdb78a136 | 1220 | * from NVM. |
mjarvisal | 0:e6fcdb78a136 | 1221 | * @note This function doesn't Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1222 | * |
mjarvisal | 0:e6fcdb78a136 | 1223 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1224 | * @param RangeMilliMeter Calibration Distance |
mjarvisal | 0:e6fcdb78a136 | 1225 | * @param SignalRateRtnMegaCps Signal rate return read at CalDistance |
mjarvisal | 0:e6fcdb78a136 | 1226 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1227 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1228 | */ |
mjarvisal | 0:e6fcdb78a136 | 1229 | VL53L0X_API VL53L0X_Error VL53L0X_SetDmaxCalParameters(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1230 | uint16_t RangeMilliMeter, FixPoint1616_t SignalRateRtnMegaCps); |
mjarvisal | 0:e6fcdb78a136 | 1231 | |
mjarvisal | 0:e6fcdb78a136 | 1232 | /** |
mjarvisal | 0:e6fcdb78a136 | 1233 | * @brief Get Dmax Calibration Parameters for a given device |
mjarvisal | 0:e6fcdb78a136 | 1234 | * |
mjarvisal | 0:e6fcdb78a136 | 1235 | * |
mjarvisal | 0:e6fcdb78a136 | 1236 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1237 | * |
mjarvisal | 0:e6fcdb78a136 | 1238 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1239 | * @param pRangeMilliMeter Pointer to Calibration Distance |
mjarvisal | 0:e6fcdb78a136 | 1240 | * @param pSignalRateRtnMegaCps Pointer to Signal rate return |
mjarvisal | 0:e6fcdb78a136 | 1241 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1242 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1243 | */ |
mjarvisal | 0:e6fcdb78a136 | 1244 | VL53L0X_API VL53L0X_Error VL53L0X_GetDmaxCalParameters(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1245 | uint16_t *pRangeMilliMeter, FixPoint1616_t *pSignalRateRtnMegaCps); |
mjarvisal | 0:e6fcdb78a136 | 1246 | |
mjarvisal | 0:e6fcdb78a136 | 1247 | /** @} VL53L0X_parameters_group */ |
mjarvisal | 0:e6fcdb78a136 | 1248 | |
mjarvisal | 0:e6fcdb78a136 | 1249 | /** @defgroup VL53L0X_measurement_group VL53L0X Measurement Functions |
mjarvisal | 0:e6fcdb78a136 | 1250 | * @brief Functions used for the measurements |
mjarvisal | 0:e6fcdb78a136 | 1251 | * @{ |
mjarvisal | 0:e6fcdb78a136 | 1252 | */ |
mjarvisal | 0:e6fcdb78a136 | 1253 | |
mjarvisal | 0:e6fcdb78a136 | 1254 | /** |
mjarvisal | 0:e6fcdb78a136 | 1255 | * @brief Single shot measurement. |
mjarvisal | 0:e6fcdb78a136 | 1256 | * |
mjarvisal | 0:e6fcdb78a136 | 1257 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1258 | * Perform simple measurement sequence (Start measure, Wait measure to end, |
mjarvisal | 0:e6fcdb78a136 | 1259 | * and returns when measurement is done). |
mjarvisal | 0:e6fcdb78a136 | 1260 | * Once function returns, user can get valid data by calling |
mjarvisal | 0:e6fcdb78a136 | 1261 | * VL53L0X_GetRangingMeasurement or VL53L0X_GetHistogramMeasurement |
mjarvisal | 0:e6fcdb78a136 | 1262 | * depending on defined measurement mode |
mjarvisal | 0:e6fcdb78a136 | 1263 | * User should Clear the interrupt in case this are enabled by using the |
mjarvisal | 0:e6fcdb78a136 | 1264 | * function VL53L0X_ClearInterruptMask(). |
mjarvisal | 0:e6fcdb78a136 | 1265 | * |
mjarvisal | 0:e6fcdb78a136 | 1266 | * @warning This function is a blocking function |
mjarvisal | 0:e6fcdb78a136 | 1267 | * |
mjarvisal | 0:e6fcdb78a136 | 1268 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1269 | * |
mjarvisal | 0:e6fcdb78a136 | 1270 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1271 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1272 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1273 | */ |
mjarvisal | 0:e6fcdb78a136 | 1274 | VL53L0X_API VL53L0X_Error VL53L0X_PerformSingleMeasurement(VL53L0X_DEV Dev); |
mjarvisal | 0:e6fcdb78a136 | 1275 | |
mjarvisal | 0:e6fcdb78a136 | 1276 | /** |
mjarvisal | 0:e6fcdb78a136 | 1277 | * @brief Perform Reference Calibration |
mjarvisal | 0:e6fcdb78a136 | 1278 | * |
mjarvisal | 0:e6fcdb78a136 | 1279 | * @details Perform a reference calibration of the Device. |
mjarvisal | 0:e6fcdb78a136 | 1280 | * This function should be run from time to time before doing |
mjarvisal | 0:e6fcdb78a136 | 1281 | * a ranging measurement. |
mjarvisal | 0:e6fcdb78a136 | 1282 | * This function will launch a special ranging measurement, so |
mjarvisal | 0:e6fcdb78a136 | 1283 | * if interrupt are enable an interrupt will be done. |
mjarvisal | 0:e6fcdb78a136 | 1284 | * This function will clear the interrupt generated automatically. |
mjarvisal | 0:e6fcdb78a136 | 1285 | * |
mjarvisal | 0:e6fcdb78a136 | 1286 | * @warning This function is a blocking function |
mjarvisal | 0:e6fcdb78a136 | 1287 | * |
mjarvisal | 0:e6fcdb78a136 | 1288 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1289 | * |
mjarvisal | 0:e6fcdb78a136 | 1290 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1291 | * @param pVhvSettings Pointer to vhv settings parameter. |
mjarvisal | 0:e6fcdb78a136 | 1292 | * @param pPhaseCal Pointer to PhaseCal parameter. |
mjarvisal | 0:e6fcdb78a136 | 1293 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1294 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1295 | */ |
mjarvisal | 0:e6fcdb78a136 | 1296 | VL53L0X_API VL53L0X_Error VL53L0X_PerformRefCalibration(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1297 | uint8_t *pVhvSettings, uint8_t *pPhaseCal); |
mjarvisal | 0:e6fcdb78a136 | 1298 | |
mjarvisal | 0:e6fcdb78a136 | 1299 | /** |
mjarvisal | 0:e6fcdb78a136 | 1300 | * @brief Perform XTalk Measurement |
mjarvisal | 0:e6fcdb78a136 | 1301 | * |
mjarvisal | 0:e6fcdb78a136 | 1302 | * @details Measures the current cross talk from glass in front |
mjarvisal | 0:e6fcdb78a136 | 1303 | * of the sensor. |
mjarvisal | 0:e6fcdb78a136 | 1304 | * This functions performs a histogram measurement and uses the results |
mjarvisal | 0:e6fcdb78a136 | 1305 | * to measure the crosstalk. For the function to be successful, there |
mjarvisal | 0:e6fcdb78a136 | 1306 | * must be no target in front of the sensor. |
mjarvisal | 0:e6fcdb78a136 | 1307 | * |
mjarvisal | 0:e6fcdb78a136 | 1308 | * @warning This function is a blocking function |
mjarvisal | 0:e6fcdb78a136 | 1309 | * |
mjarvisal | 0:e6fcdb78a136 | 1310 | * @warning This function is not supported when the final range |
mjarvisal | 0:e6fcdb78a136 | 1311 | * vcsel clock period is set below 10 PCLKS. |
mjarvisal | 0:e6fcdb78a136 | 1312 | * |
mjarvisal | 0:e6fcdb78a136 | 1313 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1314 | * |
mjarvisal | 0:e6fcdb78a136 | 1315 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1316 | * @param TimeoutMs Histogram measurement duration. |
mjarvisal | 0:e6fcdb78a136 | 1317 | * @param pXtalkPerSpad Output parameter containing the crosstalk |
mjarvisal | 0:e6fcdb78a136 | 1318 | * measurement result, in MCPS/Spad. Format fixpoint 16:16. |
mjarvisal | 0:e6fcdb78a136 | 1319 | * @param pAmbientTooHigh Output parameter which indicate that |
mjarvisal | 0:e6fcdb78a136 | 1320 | * pXtalkPerSpad is not good if the Ambient is too high. |
mjarvisal | 0:e6fcdb78a136 | 1321 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1322 | * @return VL53L0X_ERROR_INVALID_PARAMS vcsel clock period not supported |
mjarvisal | 0:e6fcdb78a136 | 1323 | * for this operation. Must not be less than 10PCLKS. |
mjarvisal | 0:e6fcdb78a136 | 1324 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1325 | */ |
mjarvisal | 0:e6fcdb78a136 | 1326 | VL53L0X_API VL53L0X_Error VL53L0X_PerformXTalkMeasurement(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1327 | uint32_t TimeoutMs, FixPoint1616_t *pXtalkPerSpad, |
mjarvisal | 0:e6fcdb78a136 | 1328 | uint8_t *pAmbientTooHigh); |
mjarvisal | 0:e6fcdb78a136 | 1329 | |
mjarvisal | 0:e6fcdb78a136 | 1330 | /** |
mjarvisal | 0:e6fcdb78a136 | 1331 | * @brief Perform XTalk Calibration |
mjarvisal | 0:e6fcdb78a136 | 1332 | * |
mjarvisal | 0:e6fcdb78a136 | 1333 | * @details Perform a XTalk calibration of the Device. |
mjarvisal | 0:e6fcdb78a136 | 1334 | * This function will launch a ranging measurement, if interrupts |
mjarvisal | 0:e6fcdb78a136 | 1335 | * are enabled an interrupt will be done. |
mjarvisal | 0:e6fcdb78a136 | 1336 | * This function will clear the interrupt generated automatically. |
mjarvisal | 0:e6fcdb78a136 | 1337 | * This function will program a new value for the XTalk compensation |
mjarvisal | 0:e6fcdb78a136 | 1338 | * and it will enable the cross talk before exit. |
mjarvisal | 0:e6fcdb78a136 | 1339 | * This function will disable the VL53L0X_CHECKENABLE_RANGE_IGNORE_THRESHOLD. |
mjarvisal | 0:e6fcdb78a136 | 1340 | * |
mjarvisal | 0:e6fcdb78a136 | 1341 | * @warning This function is a blocking function |
mjarvisal | 0:e6fcdb78a136 | 1342 | * |
mjarvisal | 0:e6fcdb78a136 | 1343 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1344 | * |
mjarvisal | 0:e6fcdb78a136 | 1345 | * @note This function change the device mode to |
mjarvisal | 0:e6fcdb78a136 | 1346 | * VL53L0X_DEVICEMODE_SINGLE_RANGING |
mjarvisal | 0:e6fcdb78a136 | 1347 | * |
mjarvisal | 0:e6fcdb78a136 | 1348 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1349 | * @param XTalkCalDistance XTalkCalDistance value used for the XTalk |
mjarvisal | 0:e6fcdb78a136 | 1350 | * computation. |
mjarvisal | 0:e6fcdb78a136 | 1351 | * @param pXTalkCompensationRateMegaCps Pointer to new |
mjarvisal | 0:e6fcdb78a136 | 1352 | * XTalkCompensation value. |
mjarvisal | 0:e6fcdb78a136 | 1353 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1354 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1355 | */ |
mjarvisal | 0:e6fcdb78a136 | 1356 | VL53L0X_API VL53L0X_Error VL53L0X_PerformXTalkCalibration(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1357 | FixPoint1616_t XTalkCalDistance, |
mjarvisal | 0:e6fcdb78a136 | 1358 | FixPoint1616_t *pXTalkCompensationRateMegaCps); |
mjarvisal | 0:e6fcdb78a136 | 1359 | |
mjarvisal | 0:e6fcdb78a136 | 1360 | /** |
mjarvisal | 0:e6fcdb78a136 | 1361 | * @brief Perform Offset Calibration |
mjarvisal | 0:e6fcdb78a136 | 1362 | * |
mjarvisal | 0:e6fcdb78a136 | 1363 | * @details Perform a Offset calibration of the Device. |
mjarvisal | 0:e6fcdb78a136 | 1364 | * This function will launch a ranging measurement, if interrupts are |
mjarvisal | 0:e6fcdb78a136 | 1365 | * enabled an interrupt will be done. |
mjarvisal | 0:e6fcdb78a136 | 1366 | * This function will clear the interrupt generated automatically. |
mjarvisal | 0:e6fcdb78a136 | 1367 | * This function will program a new value for the Offset calibration value |
mjarvisal | 0:e6fcdb78a136 | 1368 | * This function will disable the VL53L0X_CHECKENABLE_RANGE_IGNORE_THRESHOLD. |
mjarvisal | 0:e6fcdb78a136 | 1369 | * |
mjarvisal | 0:e6fcdb78a136 | 1370 | * @warning This function is a blocking function |
mjarvisal | 0:e6fcdb78a136 | 1371 | * |
mjarvisal | 0:e6fcdb78a136 | 1372 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1373 | * |
mjarvisal | 0:e6fcdb78a136 | 1374 | * @note This function does not change the device mode. |
mjarvisal | 0:e6fcdb78a136 | 1375 | * |
mjarvisal | 0:e6fcdb78a136 | 1376 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1377 | * @param CalDistanceMilliMeter Calibration distance value used for the |
mjarvisal | 0:e6fcdb78a136 | 1378 | * offset compensation. |
mjarvisal | 0:e6fcdb78a136 | 1379 | * @param pOffsetMicroMeter Pointer to new Offset value computed by the |
mjarvisal | 0:e6fcdb78a136 | 1380 | * function. |
mjarvisal | 0:e6fcdb78a136 | 1381 | * |
mjarvisal | 0:e6fcdb78a136 | 1382 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1383 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1384 | */ |
mjarvisal | 0:e6fcdb78a136 | 1385 | VL53L0X_API VL53L0X_Error VL53L0X_PerformOffsetCalibration(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1386 | FixPoint1616_t CalDistanceMilliMeter, int32_t *pOffsetMicroMeter); |
mjarvisal | 0:e6fcdb78a136 | 1387 | |
mjarvisal | 0:e6fcdb78a136 | 1388 | /** |
mjarvisal | 0:e6fcdb78a136 | 1389 | * @brief Start device measurement |
mjarvisal | 0:e6fcdb78a136 | 1390 | * |
mjarvisal | 0:e6fcdb78a136 | 1391 | * @details Started measurement will depend on device parameters set through |
mjarvisal | 0:e6fcdb78a136 | 1392 | * @a VL53L0X_SetParameters() |
mjarvisal | 0:e6fcdb78a136 | 1393 | * This is a non-blocking function. |
mjarvisal | 0:e6fcdb78a136 | 1394 | * This function will change the VL53L0X_State from VL53L0X_STATE_IDLE to |
mjarvisal | 0:e6fcdb78a136 | 1395 | * VL53L0X_STATE_RUNNING. |
mjarvisal | 0:e6fcdb78a136 | 1396 | * |
mjarvisal | 0:e6fcdb78a136 | 1397 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1398 | * |
mjarvisal | 0:e6fcdb78a136 | 1399 | |
mjarvisal | 0:e6fcdb78a136 | 1400 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1401 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1402 | * @return VL53L0X_ERROR_MODE_NOT_SUPPORTED This error occurs when |
mjarvisal | 0:e6fcdb78a136 | 1403 | * DeviceMode programmed with @a VL53L0X_SetDeviceMode is not in the supported |
mjarvisal | 0:e6fcdb78a136 | 1404 | * list: |
mjarvisal | 0:e6fcdb78a136 | 1405 | * Supported mode are: |
mjarvisal | 0:e6fcdb78a136 | 1406 | * VL53L0X_DEVICEMODE_SINGLE_RANGING, |
mjarvisal | 0:e6fcdb78a136 | 1407 | * VL53L0X_DEVICEMODE_CONTINUOUS_RANGING, |
mjarvisal | 0:e6fcdb78a136 | 1408 | * VL53L0X_DEVICEMODE_CONTINUOUS_TIMED_RANGING |
mjarvisal | 0:e6fcdb78a136 | 1409 | * @return VL53L0X_ERROR_TIME_OUT Time out on start measurement |
mjarvisal | 0:e6fcdb78a136 | 1410 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1411 | */ |
mjarvisal | 0:e6fcdb78a136 | 1412 | VL53L0X_API VL53L0X_Error VL53L0X_StartMeasurement(VL53L0X_DEV Dev); |
mjarvisal | 0:e6fcdb78a136 | 1413 | |
mjarvisal | 0:e6fcdb78a136 | 1414 | /** |
mjarvisal | 0:e6fcdb78a136 | 1415 | * @brief Stop device measurement |
mjarvisal | 0:e6fcdb78a136 | 1416 | * |
mjarvisal | 0:e6fcdb78a136 | 1417 | * @details Will set the device in standby mode at end of current measurement\n |
mjarvisal | 0:e6fcdb78a136 | 1418 | * Not necessary in single mode as device shall return automatically |
mjarvisal | 0:e6fcdb78a136 | 1419 | * in standby mode at end of measurement. |
mjarvisal | 0:e6fcdb78a136 | 1420 | * This function will change the VL53L0X_State from VL53L0X_STATE_RUNNING |
mjarvisal | 0:e6fcdb78a136 | 1421 | * to VL53L0X_STATE_IDLE. |
mjarvisal | 0:e6fcdb78a136 | 1422 | * |
mjarvisal | 0:e6fcdb78a136 | 1423 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1424 | * |
mjarvisal | 0:e6fcdb78a136 | 1425 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1426 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1427 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1428 | */ |
mjarvisal | 0:e6fcdb78a136 | 1429 | VL53L0X_API VL53L0X_Error VL53L0X_StopMeasurement(VL53L0X_DEV Dev); |
mjarvisal | 0:e6fcdb78a136 | 1430 | |
mjarvisal | 0:e6fcdb78a136 | 1431 | /** |
mjarvisal | 0:e6fcdb78a136 | 1432 | * @brief Return Measurement Data Ready |
mjarvisal | 0:e6fcdb78a136 | 1433 | * |
mjarvisal | 0:e6fcdb78a136 | 1434 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1435 | * This function indicate that a measurement data is ready. |
mjarvisal | 0:e6fcdb78a136 | 1436 | * This function check if interrupt mode is used then check is done accordingly. |
mjarvisal | 0:e6fcdb78a136 | 1437 | * If perform function clear the interrupt, this function will not work, |
mjarvisal | 0:e6fcdb78a136 | 1438 | * like in case of @a VL53L0X_PerformSingleRangingMeasurement(). |
mjarvisal | 0:e6fcdb78a136 | 1439 | * The previous function is blocking function, VL53L0X_GetMeasurementDataReady |
mjarvisal | 0:e6fcdb78a136 | 1440 | * is used for non-blocking capture. |
mjarvisal | 0:e6fcdb78a136 | 1441 | * |
mjarvisal | 0:e6fcdb78a136 | 1442 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1443 | * |
mjarvisal | 0:e6fcdb78a136 | 1444 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1445 | * @param pMeasurementDataReady Pointer to Measurement Data Ready. |
mjarvisal | 0:e6fcdb78a136 | 1446 | * 0=data not ready, 1 = data ready |
mjarvisal | 0:e6fcdb78a136 | 1447 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1448 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1449 | */ |
mjarvisal | 0:e6fcdb78a136 | 1450 | VL53L0X_API VL53L0X_Error VL53L0X_GetMeasurementDataReady(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1451 | uint8_t *pMeasurementDataReady); |
mjarvisal | 0:e6fcdb78a136 | 1452 | |
mjarvisal | 0:e6fcdb78a136 | 1453 | /** |
mjarvisal | 0:e6fcdb78a136 | 1454 | * @brief Wait for device ready for a new measurement command. |
mjarvisal | 0:e6fcdb78a136 | 1455 | * Blocking function. |
mjarvisal | 0:e6fcdb78a136 | 1456 | * |
mjarvisal | 0:e6fcdb78a136 | 1457 | * @note This function is not Implemented |
mjarvisal | 0:e6fcdb78a136 | 1458 | * |
mjarvisal | 0:e6fcdb78a136 | 1459 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1460 | * @param MaxLoop Max Number of polling loop (timeout). |
mjarvisal | 0:e6fcdb78a136 | 1461 | * @return VL53L0X_ERROR_NOT_IMPLEMENTED Not implemented |
mjarvisal | 0:e6fcdb78a136 | 1462 | */ |
mjarvisal | 0:e6fcdb78a136 | 1463 | VL53L0X_API VL53L0X_Error VL53L0X_WaitDeviceReadyForNewMeasurement(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1464 | uint32_t MaxLoop); |
mjarvisal | 0:e6fcdb78a136 | 1465 | |
mjarvisal | 0:e6fcdb78a136 | 1466 | /** |
mjarvisal | 0:e6fcdb78a136 | 1467 | * @brief Retrieve the Reference Signal after a measurements |
mjarvisal | 0:e6fcdb78a136 | 1468 | * |
mjarvisal | 0:e6fcdb78a136 | 1469 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1470 | * Get Reference Signal from last successful Ranging measurement |
mjarvisal | 0:e6fcdb78a136 | 1471 | * This function return a valid value after that you call the |
mjarvisal | 0:e6fcdb78a136 | 1472 | * @a VL53L0X_GetRangingMeasurementData(). |
mjarvisal | 0:e6fcdb78a136 | 1473 | * |
mjarvisal | 0:e6fcdb78a136 | 1474 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1475 | * |
mjarvisal | 0:e6fcdb78a136 | 1476 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1477 | * @param pMeasurementRefSignal Pointer to the Ref Signal to fill up. |
mjarvisal | 0:e6fcdb78a136 | 1478 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1479 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1480 | */ |
mjarvisal | 0:e6fcdb78a136 | 1481 | VL53L0X_API VL53L0X_Error VL53L0X_GetMeasurementRefSignal(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1482 | FixPoint1616_t *pMeasurementRefSignal); |
mjarvisal | 0:e6fcdb78a136 | 1483 | |
mjarvisal | 0:e6fcdb78a136 | 1484 | /** |
mjarvisal | 0:e6fcdb78a136 | 1485 | * @brief Retrieve the measurements from device for a given setup |
mjarvisal | 0:e6fcdb78a136 | 1486 | * |
mjarvisal | 0:e6fcdb78a136 | 1487 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1488 | * Get data from last successful Ranging measurement |
mjarvisal | 0:e6fcdb78a136 | 1489 | * @warning USER should take care about @a VL53L0X_GetNumberOfROIZones() |
mjarvisal | 0:e6fcdb78a136 | 1490 | * before get data. |
mjarvisal | 0:e6fcdb78a136 | 1491 | * PAL will fill a NumberOfROIZones times the corresponding data |
mjarvisal | 0:e6fcdb78a136 | 1492 | * structure used in the measurement function. |
mjarvisal | 0:e6fcdb78a136 | 1493 | * |
mjarvisal | 0:e6fcdb78a136 | 1494 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1495 | * |
mjarvisal | 0:e6fcdb78a136 | 1496 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1497 | * @param pRangingMeasurementData Pointer to the data structure to fill up. |
mjarvisal | 0:e6fcdb78a136 | 1498 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1499 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1500 | */ |
mjarvisal | 0:e6fcdb78a136 | 1501 | VL53L0X_API VL53L0X_Error VL53L0X_GetRangingMeasurementData(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1502 | VL53L0X_RangingMeasurementData_t *pRangingMeasurementData); |
mjarvisal | 0:e6fcdb78a136 | 1503 | |
mjarvisal | 0:e6fcdb78a136 | 1504 | /** |
mjarvisal | 0:e6fcdb78a136 | 1505 | * @brief Retrieve the measurements from device for a given setup |
mjarvisal | 0:e6fcdb78a136 | 1506 | * |
mjarvisal | 0:e6fcdb78a136 | 1507 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1508 | * Get data from last successful Histogram measurement |
mjarvisal | 0:e6fcdb78a136 | 1509 | * @warning USER should take care about @a VL53L0X_GetNumberOfROIZones() |
mjarvisal | 0:e6fcdb78a136 | 1510 | * before get data. |
mjarvisal | 0:e6fcdb78a136 | 1511 | * PAL will fill a NumberOfROIZones times the corresponding data structure |
mjarvisal | 0:e6fcdb78a136 | 1512 | * used in the measurement function. |
mjarvisal | 0:e6fcdb78a136 | 1513 | * |
mjarvisal | 0:e6fcdb78a136 | 1514 | * @note This function is not Implemented |
mjarvisal | 0:e6fcdb78a136 | 1515 | * |
mjarvisal | 0:e6fcdb78a136 | 1516 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1517 | * @param pHistogramMeasurementData Pointer to the histogram data structure. |
mjarvisal | 0:e6fcdb78a136 | 1518 | * @return VL53L0X_ERROR_NOT_IMPLEMENTED Not implemented |
mjarvisal | 0:e6fcdb78a136 | 1519 | */ |
mjarvisal | 0:e6fcdb78a136 | 1520 | VL53L0X_API VL53L0X_Error VL53L0X_GetHistogramMeasurementData(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1521 | VL53L0X_HistogramMeasurementData_t *pHistogramMeasurementData); |
mjarvisal | 0:e6fcdb78a136 | 1522 | |
mjarvisal | 0:e6fcdb78a136 | 1523 | /** |
mjarvisal | 0:e6fcdb78a136 | 1524 | * @brief Performs a single ranging measurement and retrieve the ranging |
mjarvisal | 0:e6fcdb78a136 | 1525 | * measurement data |
mjarvisal | 0:e6fcdb78a136 | 1526 | * |
mjarvisal | 0:e6fcdb78a136 | 1527 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1528 | * This function will change the device mode to VL53L0X_DEVICEMODE_SINGLE_RANGING |
mjarvisal | 0:e6fcdb78a136 | 1529 | * with @a VL53L0X_SetDeviceMode(), |
mjarvisal | 0:e6fcdb78a136 | 1530 | * It performs measurement with @a VL53L0X_PerformSingleMeasurement() |
mjarvisal | 0:e6fcdb78a136 | 1531 | * It get data from last successful Ranging measurement with |
mjarvisal | 0:e6fcdb78a136 | 1532 | * @a VL53L0X_GetRangingMeasurementData. |
mjarvisal | 0:e6fcdb78a136 | 1533 | * Finally it clear the interrupt with @a VL53L0X_ClearInterruptMask(). |
mjarvisal | 0:e6fcdb78a136 | 1534 | * |
mjarvisal | 0:e6fcdb78a136 | 1535 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1536 | * |
mjarvisal | 0:e6fcdb78a136 | 1537 | * @note This function change the device mode to |
mjarvisal | 0:e6fcdb78a136 | 1538 | * VL53L0X_DEVICEMODE_SINGLE_RANGING |
mjarvisal | 0:e6fcdb78a136 | 1539 | * |
mjarvisal | 0:e6fcdb78a136 | 1540 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1541 | * @param pRangingMeasurementData Pointer to the data structure to fill up. |
mjarvisal | 0:e6fcdb78a136 | 1542 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1543 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1544 | */ |
mjarvisal | 0:e6fcdb78a136 | 1545 | VL53L0X_API VL53L0X_Error VL53L0X_PerformSingleRangingMeasurement(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1546 | VL53L0X_RangingMeasurementData_t *pRangingMeasurementData); |
mjarvisal | 0:e6fcdb78a136 | 1547 | |
mjarvisal | 0:e6fcdb78a136 | 1548 | /** |
mjarvisal | 0:e6fcdb78a136 | 1549 | * @brief Performs a single histogram measurement and retrieve the histogram |
mjarvisal | 0:e6fcdb78a136 | 1550 | * measurement data |
mjarvisal | 0:e6fcdb78a136 | 1551 | * Is equivalent to VL53L0X_PerformSingleMeasurement + |
mjarvisal | 0:e6fcdb78a136 | 1552 | * VL53L0X_GetHistogramMeasurementData |
mjarvisal | 0:e6fcdb78a136 | 1553 | * |
mjarvisal | 0:e6fcdb78a136 | 1554 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1555 | * Get data from last successful Ranging measurement. |
mjarvisal | 0:e6fcdb78a136 | 1556 | * This function will clear the interrupt in case of these are enabled. |
mjarvisal | 0:e6fcdb78a136 | 1557 | * |
mjarvisal | 0:e6fcdb78a136 | 1558 | * @note This function is not Implemented |
mjarvisal | 0:e6fcdb78a136 | 1559 | * |
mjarvisal | 0:e6fcdb78a136 | 1560 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1561 | * @param pHistogramMeasurementData Pointer to the data structure to fill up. |
mjarvisal | 0:e6fcdb78a136 | 1562 | * @return VL53L0X_ERROR_NOT_IMPLEMENTED Not implemented |
mjarvisal | 0:e6fcdb78a136 | 1563 | */ |
mjarvisal | 0:e6fcdb78a136 | 1564 | VL53L0X_API VL53L0X_Error VL53L0X_PerformSingleHistogramMeasurement(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1565 | VL53L0X_HistogramMeasurementData_t *pHistogramMeasurementData); |
mjarvisal | 0:e6fcdb78a136 | 1566 | |
mjarvisal | 0:e6fcdb78a136 | 1567 | /** |
mjarvisal | 0:e6fcdb78a136 | 1568 | * @brief Set the number of ROI Zones to be used for a specific Device |
mjarvisal | 0:e6fcdb78a136 | 1569 | * |
mjarvisal | 0:e6fcdb78a136 | 1570 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1571 | * Set the number of ROI Zones to be used for a specific Device. |
mjarvisal | 0:e6fcdb78a136 | 1572 | * The programmed value should be less than the max number of ROI Zones given |
mjarvisal | 0:e6fcdb78a136 | 1573 | * with @a VL53L0X_GetMaxNumberOfROIZones(). |
mjarvisal | 0:e6fcdb78a136 | 1574 | * This version of API manage only one zone. |
mjarvisal | 0:e6fcdb78a136 | 1575 | * |
mjarvisal | 0:e6fcdb78a136 | 1576 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1577 | * @param NumberOfROIZones Number of ROI Zones to be used for a |
mjarvisal | 0:e6fcdb78a136 | 1578 | * specific Device. |
mjarvisal | 0:e6fcdb78a136 | 1579 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1580 | * @return VL53L0X_ERROR_INVALID_PARAMS This error is returned if |
mjarvisal | 0:e6fcdb78a136 | 1581 | * NumberOfROIZones != 1 |
mjarvisal | 0:e6fcdb78a136 | 1582 | */ |
mjarvisal | 0:e6fcdb78a136 | 1583 | VL53L0X_API VL53L0X_Error VL53L0X_SetNumberOfROIZones(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1584 | uint8_t NumberOfROIZones); |
mjarvisal | 0:e6fcdb78a136 | 1585 | |
mjarvisal | 0:e6fcdb78a136 | 1586 | /** |
mjarvisal | 0:e6fcdb78a136 | 1587 | * @brief Get the number of ROI Zones managed by the Device |
mjarvisal | 0:e6fcdb78a136 | 1588 | * |
mjarvisal | 0:e6fcdb78a136 | 1589 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1590 | * Get number of ROI Zones managed by the Device |
mjarvisal | 0:e6fcdb78a136 | 1591 | * USER should take care about @a VL53L0X_GetNumberOfROIZones() |
mjarvisal | 0:e6fcdb78a136 | 1592 | * before get data after a perform measurement. |
mjarvisal | 0:e6fcdb78a136 | 1593 | * PAL will fill a NumberOfROIZones times the corresponding data |
mjarvisal | 0:e6fcdb78a136 | 1594 | * structure used in the measurement function. |
mjarvisal | 0:e6fcdb78a136 | 1595 | * |
mjarvisal | 0:e6fcdb78a136 | 1596 | * @note This function doesn't Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1597 | * |
mjarvisal | 0:e6fcdb78a136 | 1598 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1599 | * @param pNumberOfROIZones Pointer to the Number of ROI Zones value. |
mjarvisal | 0:e6fcdb78a136 | 1600 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1601 | */ |
mjarvisal | 0:e6fcdb78a136 | 1602 | VL53L0X_API VL53L0X_Error VL53L0X_GetNumberOfROIZones(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1603 | uint8_t *pNumberOfROIZones); |
mjarvisal | 0:e6fcdb78a136 | 1604 | |
mjarvisal | 0:e6fcdb78a136 | 1605 | /** |
mjarvisal | 0:e6fcdb78a136 | 1606 | * @brief Get the Maximum number of ROI Zones managed by the Device |
mjarvisal | 0:e6fcdb78a136 | 1607 | * |
mjarvisal | 0:e6fcdb78a136 | 1608 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1609 | * Get Maximum number of ROI Zones managed by the Device. |
mjarvisal | 0:e6fcdb78a136 | 1610 | * |
mjarvisal | 0:e6fcdb78a136 | 1611 | * @note This function doesn't Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1612 | * |
mjarvisal | 0:e6fcdb78a136 | 1613 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1614 | * @param pMaxNumberOfROIZones Pointer to the Maximum Number |
mjarvisal | 0:e6fcdb78a136 | 1615 | * of ROI Zones value. |
mjarvisal | 0:e6fcdb78a136 | 1616 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1617 | */ |
mjarvisal | 0:e6fcdb78a136 | 1618 | VL53L0X_API VL53L0X_Error VL53L0X_GetMaxNumberOfROIZones(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1619 | uint8_t *pMaxNumberOfROIZones); |
mjarvisal | 0:e6fcdb78a136 | 1620 | |
mjarvisal | 0:e6fcdb78a136 | 1621 | /** @} VL53L0X_measurement_group */ |
mjarvisal | 0:e6fcdb78a136 | 1622 | |
mjarvisal | 0:e6fcdb78a136 | 1623 | /** @defgroup VL53L0X_interrupt_group VL53L0X Interrupt Functions |
mjarvisal | 0:e6fcdb78a136 | 1624 | * @brief Functions used for interrupt managements |
mjarvisal | 0:e6fcdb78a136 | 1625 | * @{ |
mjarvisal | 0:e6fcdb78a136 | 1626 | */ |
mjarvisal | 0:e6fcdb78a136 | 1627 | |
mjarvisal | 0:e6fcdb78a136 | 1628 | /** |
mjarvisal | 0:e6fcdb78a136 | 1629 | * @brief Set the configuration of GPIO pin for a given device |
mjarvisal | 0:e6fcdb78a136 | 1630 | * |
mjarvisal | 0:e6fcdb78a136 | 1631 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1632 | * |
mjarvisal | 0:e6fcdb78a136 | 1633 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1634 | * @param Pin ID of the GPIO Pin |
mjarvisal | 0:e6fcdb78a136 | 1635 | * @param Functionality Select Pin functionality. |
mjarvisal | 0:e6fcdb78a136 | 1636 | * Refer to ::VL53L0X_GpioFunctionality |
mjarvisal | 0:e6fcdb78a136 | 1637 | * @param DeviceMode Device Mode associated to the Gpio. |
mjarvisal | 0:e6fcdb78a136 | 1638 | * @param Polarity Set interrupt polarity. Active high |
mjarvisal | 0:e6fcdb78a136 | 1639 | * or active low see ::VL53L0X_InterruptPolarity |
mjarvisal | 0:e6fcdb78a136 | 1640 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1641 | * @return VL53L0X_ERROR_GPIO_NOT_EXISTING Only Pin=0 is accepted. |
mjarvisal | 0:e6fcdb78a136 | 1642 | * @return VL53L0X_ERROR_GPIO_FUNCTIONALITY_NOT_SUPPORTED This error occurs |
mjarvisal | 0:e6fcdb78a136 | 1643 | * when Functionality programmed is not in the supported list: |
mjarvisal | 0:e6fcdb78a136 | 1644 | * Supported value are: |
mjarvisal | 0:e6fcdb78a136 | 1645 | * VL53L0X_GPIOFUNCTIONALITY_OFF, |
mjarvisal | 0:e6fcdb78a136 | 1646 | * VL53L0X_GPIOFUNCTIONALITY_THRESHOLD_CROSSED_LOW, |
mjarvisal | 0:e6fcdb78a136 | 1647 | * VL53L0X_GPIOFUNCTIONALITY_THRESHOLD_CROSSED_HIGH, |
mjarvisal | 0:e6fcdb78a136 | 1648 | VL53L0X_GPIOFUNCTIONALITY_THRESHOLD_CROSSED_OUT, |
mjarvisal | 0:e6fcdb78a136 | 1649 | * VL53L0X_GPIOFUNCTIONALITY_NEW_MEASURE_READY |
mjarvisal | 0:e6fcdb78a136 | 1650 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1651 | */ |
mjarvisal | 0:e6fcdb78a136 | 1652 | VL53L0X_API VL53L0X_Error VL53L0X_SetGpioConfig(VL53L0X_DEV Dev, uint8_t Pin, |
mjarvisal | 0:e6fcdb78a136 | 1653 | VL53L0X_DeviceModes DeviceMode, VL53L0X_GpioFunctionality Functionality, |
mjarvisal | 0:e6fcdb78a136 | 1654 | VL53L0X_InterruptPolarity Polarity); |
mjarvisal | 0:e6fcdb78a136 | 1655 | |
mjarvisal | 0:e6fcdb78a136 | 1656 | /** |
mjarvisal | 0:e6fcdb78a136 | 1657 | * @brief Get current configuration for GPIO pin for a given device |
mjarvisal | 0:e6fcdb78a136 | 1658 | * |
mjarvisal | 0:e6fcdb78a136 | 1659 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1660 | * |
mjarvisal | 0:e6fcdb78a136 | 1661 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1662 | * @param Pin ID of the GPIO Pin |
mjarvisal | 0:e6fcdb78a136 | 1663 | * @param pDeviceMode Pointer to Device Mode associated to the Gpio. |
mjarvisal | 0:e6fcdb78a136 | 1664 | * @param pFunctionality Pointer to Pin functionality. |
mjarvisal | 0:e6fcdb78a136 | 1665 | * Refer to ::VL53L0X_GpioFunctionality |
mjarvisal | 0:e6fcdb78a136 | 1666 | * @param pPolarity Pointer to interrupt polarity. |
mjarvisal | 0:e6fcdb78a136 | 1667 | * Active high or active low see ::VL53L0X_InterruptPolarity |
mjarvisal | 0:e6fcdb78a136 | 1668 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1669 | * @return VL53L0X_ERROR_GPIO_NOT_EXISTING Only Pin=0 is accepted. |
mjarvisal | 0:e6fcdb78a136 | 1670 | * @return VL53L0X_ERROR_GPIO_FUNCTIONALITY_NOT_SUPPORTED This error occurs |
mjarvisal | 0:e6fcdb78a136 | 1671 | * when Functionality programmed is not in the supported list: |
mjarvisal | 0:e6fcdb78a136 | 1672 | * Supported value are: |
mjarvisal | 0:e6fcdb78a136 | 1673 | * VL53L0X_GPIOFUNCTIONALITY_OFF, |
mjarvisal | 0:e6fcdb78a136 | 1674 | * VL53L0X_GPIOFUNCTIONALITY_THRESHOLD_CROSSED_LOW, |
mjarvisal | 0:e6fcdb78a136 | 1675 | * VL53L0X_GPIOFUNCTIONALITY_THRESHOLD_CROSSED_HIGH, |
mjarvisal | 0:e6fcdb78a136 | 1676 | * VL53L0X_GPIOFUNCTIONALITY_THRESHOLD_CROSSED_OUT, |
mjarvisal | 0:e6fcdb78a136 | 1677 | * VL53L0X_GPIOFUNCTIONALITY_NEW_MEASURE_READY |
mjarvisal | 0:e6fcdb78a136 | 1678 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1679 | */ |
mjarvisal | 0:e6fcdb78a136 | 1680 | VL53L0X_API VL53L0X_Error VL53L0X_GetGpioConfig(VL53L0X_DEV Dev, uint8_t Pin, |
mjarvisal | 0:e6fcdb78a136 | 1681 | VL53L0X_DeviceModes *pDeviceMode, |
mjarvisal | 0:e6fcdb78a136 | 1682 | VL53L0X_GpioFunctionality *pFunctionality, |
mjarvisal | 0:e6fcdb78a136 | 1683 | VL53L0X_InterruptPolarity *pPolarity); |
mjarvisal | 0:e6fcdb78a136 | 1684 | |
mjarvisal | 0:e6fcdb78a136 | 1685 | /** |
mjarvisal | 0:e6fcdb78a136 | 1686 | * @brief Set low and high Interrupt thresholds for a given mode |
mjarvisal | 0:e6fcdb78a136 | 1687 | * (ranging, ALS, ...) for a given device |
mjarvisal | 0:e6fcdb78a136 | 1688 | * |
mjarvisal | 0:e6fcdb78a136 | 1689 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1690 | * Set low and high Interrupt thresholds for a given mode (ranging, ALS, ...) |
mjarvisal | 0:e6fcdb78a136 | 1691 | * for a given device |
mjarvisal | 0:e6fcdb78a136 | 1692 | * |
mjarvisal | 0:e6fcdb78a136 | 1693 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1694 | * |
mjarvisal | 0:e6fcdb78a136 | 1695 | * @note DeviceMode is ignored for the current device |
mjarvisal | 0:e6fcdb78a136 | 1696 | * |
mjarvisal | 0:e6fcdb78a136 | 1697 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1698 | * @param DeviceMode Device Mode for which change thresholds |
mjarvisal | 0:e6fcdb78a136 | 1699 | * @param ThresholdLow Low threshold (mm, lux ..., depending on the mode) |
mjarvisal | 0:e6fcdb78a136 | 1700 | * @param ThresholdHigh High threshold (mm, lux ..., depending on the mode) |
mjarvisal | 0:e6fcdb78a136 | 1701 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1702 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1703 | */ |
mjarvisal | 0:e6fcdb78a136 | 1704 | VL53L0X_API VL53L0X_Error VL53L0X_SetInterruptThresholds(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1705 | VL53L0X_DeviceModes DeviceMode, FixPoint1616_t ThresholdLow, |
mjarvisal | 0:e6fcdb78a136 | 1706 | FixPoint1616_t ThresholdHigh); |
mjarvisal | 0:e6fcdb78a136 | 1707 | |
mjarvisal | 0:e6fcdb78a136 | 1708 | /** |
mjarvisal | 0:e6fcdb78a136 | 1709 | * @brief Get high and low Interrupt thresholds for a given mode |
mjarvisal | 0:e6fcdb78a136 | 1710 | * (ranging, ALS, ...) for a given device |
mjarvisal | 0:e6fcdb78a136 | 1711 | * |
mjarvisal | 0:e6fcdb78a136 | 1712 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1713 | * Get high and low Interrupt thresholds for a given mode (ranging, ALS, ...) |
mjarvisal | 0:e6fcdb78a136 | 1714 | * for a given device |
mjarvisal | 0:e6fcdb78a136 | 1715 | * |
mjarvisal | 0:e6fcdb78a136 | 1716 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1717 | * |
mjarvisal | 0:e6fcdb78a136 | 1718 | * @note DeviceMode is ignored for the current device |
mjarvisal | 0:e6fcdb78a136 | 1719 | * |
mjarvisal | 0:e6fcdb78a136 | 1720 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1721 | * @param DeviceMode Device Mode from which read thresholds |
mjarvisal | 0:e6fcdb78a136 | 1722 | * @param pThresholdLow Low threshold (mm, lux ..., depending on the mode) |
mjarvisal | 0:e6fcdb78a136 | 1723 | * @param pThresholdHigh High threshold (mm, lux ..., depending on the mode) |
mjarvisal | 0:e6fcdb78a136 | 1724 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1725 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1726 | */ |
mjarvisal | 0:e6fcdb78a136 | 1727 | VL53L0X_API VL53L0X_Error VL53L0X_GetInterruptThresholds(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1728 | VL53L0X_DeviceModes DeviceMode, FixPoint1616_t *pThresholdLow, |
mjarvisal | 0:e6fcdb78a136 | 1729 | FixPoint1616_t *pThresholdHigh); |
mjarvisal | 0:e6fcdb78a136 | 1730 | |
mjarvisal | 0:e6fcdb78a136 | 1731 | /** |
mjarvisal | 0:e6fcdb78a136 | 1732 | * @brief Return device stop completion status |
mjarvisal | 0:e6fcdb78a136 | 1733 | * |
mjarvisal | 0:e6fcdb78a136 | 1734 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1735 | * Returns stop completiob status. |
mjarvisal | 0:e6fcdb78a136 | 1736 | * User shall call this function after a stop command |
mjarvisal | 0:e6fcdb78a136 | 1737 | * |
mjarvisal | 0:e6fcdb78a136 | 1738 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1739 | * |
mjarvisal | 0:e6fcdb78a136 | 1740 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1741 | * @param pStopStatus Pointer to status variable to update |
mjarvisal | 0:e6fcdb78a136 | 1742 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1743 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1744 | */ |
mjarvisal | 0:e6fcdb78a136 | 1745 | VL53L0X_API VL53L0X_Error VL53L0X_GetStopCompletedStatus(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1746 | uint32_t *pStopStatus); |
mjarvisal | 0:e6fcdb78a136 | 1747 | |
mjarvisal | 0:e6fcdb78a136 | 1748 | |
mjarvisal | 0:e6fcdb78a136 | 1749 | /** |
mjarvisal | 0:e6fcdb78a136 | 1750 | * @brief Clear given system interrupt condition |
mjarvisal | 0:e6fcdb78a136 | 1751 | * |
mjarvisal | 0:e6fcdb78a136 | 1752 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1753 | * Clear given interrupt(s). |
mjarvisal | 0:e6fcdb78a136 | 1754 | * |
mjarvisal | 0:e6fcdb78a136 | 1755 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1756 | * |
mjarvisal | 0:e6fcdb78a136 | 1757 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1758 | * @param InterruptMask Mask of interrupts to clear |
mjarvisal | 0:e6fcdb78a136 | 1759 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1760 | * @return VL53L0X_ERROR_INTERRUPT_NOT_CLEARED Cannot clear interrupts |
mjarvisal | 0:e6fcdb78a136 | 1761 | * |
mjarvisal | 0:e6fcdb78a136 | 1762 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1763 | */ |
mjarvisal | 0:e6fcdb78a136 | 1764 | VL53L0X_API VL53L0X_Error VL53L0X_ClearInterruptMask(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1765 | uint32_t InterruptMask); |
mjarvisal | 0:e6fcdb78a136 | 1766 | |
mjarvisal | 0:e6fcdb78a136 | 1767 | /** |
mjarvisal | 0:e6fcdb78a136 | 1768 | * @brief Return device interrupt status |
mjarvisal | 0:e6fcdb78a136 | 1769 | * |
mjarvisal | 0:e6fcdb78a136 | 1770 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1771 | * Returns currently raised interrupts by the device. |
mjarvisal | 0:e6fcdb78a136 | 1772 | * User shall be able to activate/deactivate interrupts through |
mjarvisal | 0:e6fcdb78a136 | 1773 | * @a VL53L0X_SetGpioConfig() |
mjarvisal | 0:e6fcdb78a136 | 1774 | * |
mjarvisal | 0:e6fcdb78a136 | 1775 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1776 | * |
mjarvisal | 0:e6fcdb78a136 | 1777 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1778 | * @param pInterruptMaskStatus Pointer to status variable to update |
mjarvisal | 0:e6fcdb78a136 | 1779 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1780 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1781 | */ |
mjarvisal | 0:e6fcdb78a136 | 1782 | VL53L0X_API VL53L0X_Error VL53L0X_GetInterruptMaskStatus(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1783 | uint32_t *pInterruptMaskStatus); |
mjarvisal | 0:e6fcdb78a136 | 1784 | |
mjarvisal | 0:e6fcdb78a136 | 1785 | /** |
mjarvisal | 0:e6fcdb78a136 | 1786 | * @brief Configure ranging interrupt reported to system |
mjarvisal | 0:e6fcdb78a136 | 1787 | * |
mjarvisal | 0:e6fcdb78a136 | 1788 | * @note This function is not Implemented |
mjarvisal | 0:e6fcdb78a136 | 1789 | * |
mjarvisal | 0:e6fcdb78a136 | 1790 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1791 | * @param InterruptMask Mask of interrupt to Enable/disable |
mjarvisal | 0:e6fcdb78a136 | 1792 | * (0:interrupt disabled or 1: interrupt enabled) |
mjarvisal | 0:e6fcdb78a136 | 1793 | * @return VL53L0X_ERROR_NOT_IMPLEMENTED Not implemented |
mjarvisal | 0:e6fcdb78a136 | 1794 | */ |
mjarvisal | 0:e6fcdb78a136 | 1795 | VL53L0X_API VL53L0X_Error VL53L0X_EnableInterruptMask(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1796 | uint32_t InterruptMask); |
mjarvisal | 0:e6fcdb78a136 | 1797 | |
mjarvisal | 0:e6fcdb78a136 | 1798 | /** @} VL53L0X_interrupt_group */ |
mjarvisal | 0:e6fcdb78a136 | 1799 | |
mjarvisal | 0:e6fcdb78a136 | 1800 | /** @defgroup VL53L0X_SPADfunctions_group VL53L0X SPAD Functions |
mjarvisal | 0:e6fcdb78a136 | 1801 | * @brief Functions used for SPAD managements |
mjarvisal | 0:e6fcdb78a136 | 1802 | * @{ |
mjarvisal | 0:e6fcdb78a136 | 1803 | */ |
mjarvisal | 0:e6fcdb78a136 | 1804 | |
mjarvisal | 0:e6fcdb78a136 | 1805 | /** |
mjarvisal | 0:e6fcdb78a136 | 1806 | * @brief Set the SPAD Ambient Damper Threshold value |
mjarvisal | 0:e6fcdb78a136 | 1807 | * |
mjarvisal | 0:e6fcdb78a136 | 1808 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1809 | * This function set the SPAD Ambient Damper Threshold value |
mjarvisal | 0:e6fcdb78a136 | 1810 | * |
mjarvisal | 0:e6fcdb78a136 | 1811 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1812 | * |
mjarvisal | 0:e6fcdb78a136 | 1813 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1814 | * @param SpadAmbientDamperThreshold SPAD Ambient Damper Threshold value |
mjarvisal | 0:e6fcdb78a136 | 1815 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1816 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1817 | */ |
mjarvisal | 0:e6fcdb78a136 | 1818 | VL53L0X_API VL53L0X_Error VL53L0X_SetSpadAmbientDamperThreshold(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1819 | uint16_t SpadAmbientDamperThreshold); |
mjarvisal | 0:e6fcdb78a136 | 1820 | |
mjarvisal | 0:e6fcdb78a136 | 1821 | /** |
mjarvisal | 0:e6fcdb78a136 | 1822 | * @brief Get the current SPAD Ambient Damper Threshold value |
mjarvisal | 0:e6fcdb78a136 | 1823 | * |
mjarvisal | 0:e6fcdb78a136 | 1824 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1825 | * This function get the SPAD Ambient Damper Threshold value |
mjarvisal | 0:e6fcdb78a136 | 1826 | * |
mjarvisal | 0:e6fcdb78a136 | 1827 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1828 | * |
mjarvisal | 0:e6fcdb78a136 | 1829 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1830 | * @param pSpadAmbientDamperThreshold Pointer to programmed |
mjarvisal | 0:e6fcdb78a136 | 1831 | * SPAD Ambient Damper Threshold value |
mjarvisal | 0:e6fcdb78a136 | 1832 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1833 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1834 | */ |
mjarvisal | 0:e6fcdb78a136 | 1835 | VL53L0X_API VL53L0X_Error VL53L0X_GetSpadAmbientDamperThreshold(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1836 | uint16_t *pSpadAmbientDamperThreshold); |
mjarvisal | 0:e6fcdb78a136 | 1837 | |
mjarvisal | 0:e6fcdb78a136 | 1838 | /** |
mjarvisal | 0:e6fcdb78a136 | 1839 | * @brief Set the SPAD Ambient Damper Factor value |
mjarvisal | 0:e6fcdb78a136 | 1840 | * |
mjarvisal | 0:e6fcdb78a136 | 1841 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1842 | * This function set the SPAD Ambient Damper Factor value |
mjarvisal | 0:e6fcdb78a136 | 1843 | * |
mjarvisal | 0:e6fcdb78a136 | 1844 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1845 | * |
mjarvisal | 0:e6fcdb78a136 | 1846 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1847 | * @param SpadAmbientDamperFactor SPAD Ambient Damper Factor value |
mjarvisal | 0:e6fcdb78a136 | 1848 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1849 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1850 | */ |
mjarvisal | 0:e6fcdb78a136 | 1851 | VL53L0X_API VL53L0X_Error VL53L0X_SetSpadAmbientDamperFactor(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1852 | uint16_t SpadAmbientDamperFactor); |
mjarvisal | 0:e6fcdb78a136 | 1853 | |
mjarvisal | 0:e6fcdb78a136 | 1854 | /** |
mjarvisal | 0:e6fcdb78a136 | 1855 | * @brief Get the current SPAD Ambient Damper Factor value |
mjarvisal | 0:e6fcdb78a136 | 1856 | * |
mjarvisal | 0:e6fcdb78a136 | 1857 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1858 | * This function get the SPAD Ambient Damper Factor value |
mjarvisal | 0:e6fcdb78a136 | 1859 | * |
mjarvisal | 0:e6fcdb78a136 | 1860 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1861 | * |
mjarvisal | 0:e6fcdb78a136 | 1862 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1863 | * @param pSpadAmbientDamperFactor Pointer to programmed SPAD Ambient |
mjarvisal | 0:e6fcdb78a136 | 1864 | * Damper Factor value |
mjarvisal | 0:e6fcdb78a136 | 1865 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1866 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1867 | */ |
mjarvisal | 0:e6fcdb78a136 | 1868 | VL53L0X_API VL53L0X_Error VL53L0X_GetSpadAmbientDamperFactor(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1869 | uint16_t *pSpadAmbientDamperFactor); |
mjarvisal | 0:e6fcdb78a136 | 1870 | |
mjarvisal | 0:e6fcdb78a136 | 1871 | /** |
mjarvisal | 0:e6fcdb78a136 | 1872 | * @brief Performs Reference Spad Management |
mjarvisal | 0:e6fcdb78a136 | 1873 | * |
mjarvisal | 0:e6fcdb78a136 | 1874 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1875 | * The reference SPAD initialization procedure determines the minimum amount |
mjarvisal | 0:e6fcdb78a136 | 1876 | * of reference spads to be enables to achieve a target reference signal rate |
mjarvisal | 0:e6fcdb78a136 | 1877 | * and should be performed once during initialization. |
mjarvisal | 0:e6fcdb78a136 | 1878 | * |
mjarvisal | 0:e6fcdb78a136 | 1879 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1880 | * |
mjarvisal | 0:e6fcdb78a136 | 1881 | * @note This function change the device mode to |
mjarvisal | 0:e6fcdb78a136 | 1882 | * VL53L0X_DEVICEMODE_SINGLE_RANGING |
mjarvisal | 0:e6fcdb78a136 | 1883 | * |
mjarvisal | 0:e6fcdb78a136 | 1884 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1885 | * @param refSpadCount Reports ref Spad Count |
mjarvisal | 0:e6fcdb78a136 | 1886 | * @param isApertureSpads Reports if spads are of type |
mjarvisal | 0:e6fcdb78a136 | 1887 | * aperture or non-aperture. |
mjarvisal | 0:e6fcdb78a136 | 1888 | * 1:=aperture, 0:=Non-Aperture |
mjarvisal | 0:e6fcdb78a136 | 1889 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1890 | * @return VL53L0X_ERROR_REF_SPAD_INIT Error in the Ref Spad procedure. |
mjarvisal | 0:e6fcdb78a136 | 1891 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1892 | */ |
mjarvisal | 0:e6fcdb78a136 | 1893 | VL53L0X_API VL53L0X_Error VL53L0X_PerformRefSpadManagement(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1894 | uint32_t *refSpadCount, uint8_t *isApertureSpads); |
mjarvisal | 0:e6fcdb78a136 | 1895 | |
mjarvisal | 0:e6fcdb78a136 | 1896 | /** |
mjarvisal | 0:e6fcdb78a136 | 1897 | * @brief Applies Reference SPAD configuration |
mjarvisal | 0:e6fcdb78a136 | 1898 | * |
mjarvisal | 0:e6fcdb78a136 | 1899 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1900 | * This function applies a given number of reference spads, identified as |
mjarvisal | 0:e6fcdb78a136 | 1901 | * either Aperture or Non-Aperture. |
mjarvisal | 0:e6fcdb78a136 | 1902 | * The requested spad count and type are stored within the device specific |
mjarvisal | 0:e6fcdb78a136 | 1903 | * parameters data for access by the host. |
mjarvisal | 0:e6fcdb78a136 | 1904 | * |
mjarvisal | 0:e6fcdb78a136 | 1905 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1906 | * |
mjarvisal | 0:e6fcdb78a136 | 1907 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1908 | * @param refSpadCount Number of ref spads. |
mjarvisal | 0:e6fcdb78a136 | 1909 | * @param isApertureSpads Defines if spads are of type |
mjarvisal | 0:e6fcdb78a136 | 1910 | * aperture or non-aperture. |
mjarvisal | 0:e6fcdb78a136 | 1911 | * 1:=aperture, 0:=Non-Aperture |
mjarvisal | 0:e6fcdb78a136 | 1912 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1913 | * @return VL53L0X_ERROR_REF_SPAD_INIT Error in the in the reference |
mjarvisal | 0:e6fcdb78a136 | 1914 | * spad configuration. |
mjarvisal | 0:e6fcdb78a136 | 1915 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1916 | */ |
mjarvisal | 0:e6fcdb78a136 | 1917 | VL53L0X_API VL53L0X_Error VL53L0X_SetReferenceSpads(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1918 | uint32_t refSpadCount, uint8_t isApertureSpads); |
mjarvisal | 0:e6fcdb78a136 | 1919 | |
mjarvisal | 0:e6fcdb78a136 | 1920 | /** |
mjarvisal | 0:e6fcdb78a136 | 1921 | * @brief Retrieves SPAD configuration |
mjarvisal | 0:e6fcdb78a136 | 1922 | * |
mjarvisal | 0:e6fcdb78a136 | 1923 | * @par Function Description |
mjarvisal | 0:e6fcdb78a136 | 1924 | * This function retrieves the current number of applied reference spads |
mjarvisal | 0:e6fcdb78a136 | 1925 | * and also their type : Aperture or Non-Aperture. |
mjarvisal | 0:e6fcdb78a136 | 1926 | * |
mjarvisal | 0:e6fcdb78a136 | 1927 | * @note This function Access to the device |
mjarvisal | 0:e6fcdb78a136 | 1928 | * |
mjarvisal | 0:e6fcdb78a136 | 1929 | * @param Dev Device Handle |
mjarvisal | 0:e6fcdb78a136 | 1930 | * @param refSpadCount Number ref Spad Count |
mjarvisal | 0:e6fcdb78a136 | 1931 | * @param isApertureSpads Reports if spads are of type |
mjarvisal | 0:e6fcdb78a136 | 1932 | * aperture or non-aperture. |
mjarvisal | 0:e6fcdb78a136 | 1933 | * 1:=aperture, 0:=Non-Aperture |
mjarvisal | 0:e6fcdb78a136 | 1934 | * @return VL53L0X_ERROR_NONE Success |
mjarvisal | 0:e6fcdb78a136 | 1935 | * @return VL53L0X_ERROR_REF_SPAD_INIT Error in the in the reference |
mjarvisal | 0:e6fcdb78a136 | 1936 | * spad configuration. |
mjarvisal | 0:e6fcdb78a136 | 1937 | * @return "Other error code" See ::VL53L0X_Error |
mjarvisal | 0:e6fcdb78a136 | 1938 | */ |
mjarvisal | 0:e6fcdb78a136 | 1939 | VL53L0X_API VL53L0X_Error VL53L0X_GetReferenceSpads(VL53L0X_DEV Dev, |
mjarvisal | 0:e6fcdb78a136 | 1940 | uint32_t *refSpadCount, uint8_t *isApertureSpads); |
mjarvisal | 0:e6fcdb78a136 | 1941 | |
mjarvisal | 0:e6fcdb78a136 | 1942 | /** @} VL53L0X_SPADfunctions_group */ |
mjarvisal | 0:e6fcdb78a136 | 1943 | |
mjarvisal | 0:e6fcdb78a136 | 1944 | /** @} VL53L0X_cut11_group */ |
mjarvisal | 0:e6fcdb78a136 | 1945 | |
mjarvisal | 0:e6fcdb78a136 | 1946 | #ifdef __cplusplus |
mjarvisal | 0:e6fcdb78a136 | 1947 | } |
mjarvisal | 0:e6fcdb78a136 | 1948 | #endif |
mjarvisal | 0:e6fcdb78a136 | 1949 | |
mjarvisal | 0:e6fcdb78a136 | 1950 | #endif /* _VL53L0X_API_H_ */ |