upd
This commit is contained in:
@@ -103,7 +103,6 @@ void vl6180_init (void)
|
||||
/* Enable Dmax calculation only if value is displayed (to save computation power) */
|
||||
//VL6180_DMaxSetState(theVL6180Dev, DMaxDispTime>0);
|
||||
VL6180_ClearAllInterrupt(theVL6180Dev);
|
||||
VL6180_RangeStartContinuousMode(theVL6180Dev);
|
||||
allowIT = 1;
|
||||
}
|
||||
|
||||
@@ -275,4 +274,14 @@ void HAL_GPIO_EXTI_Falling_Callback(uint16_t GPIO_Pin)
|
||||
}
|
||||
}
|
||||
}
|
||||
/* USER CODE END 4 */
|
||||
/* USER CODE END 4 */
|
||||
|
||||
uint8_t vl6180_single_shot ()
|
||||
{
|
||||
VL6180_RangeStartSingleShot(theVL6180Dev);
|
||||
}
|
||||
|
||||
int32_t vl6180_is_ready ()
|
||||
{
|
||||
return VL6180_RangeWaitDeviceReady(theVL6180Dev, 3);
|
||||
}
|
||||
@@ -10,4 +10,6 @@
|
||||
#endif //MYPROJECT_VL6180_APP_H
|
||||
void vl6180_init (void);
|
||||
__weak void proximityMessureCompleted (void);
|
||||
uint8_t getRange (VL6180_RangeData_t* range);
|
||||
uint8_t getRange (VL6180_RangeData_t* range);
|
||||
uint8_t vl6180_single_shot ();
|
||||
int32_t vl6180_is_ready ();
|
||||
|
||||
Reference in New Issue
Block a user