From 4addfae3f843f97b99ae2a7bf71eb7b7bc722276 Mon Sep 17 00:00:00 2001 From: YunHorn Technology Date: Wed, 23 Jul 2025 11:03:04 +0800 Subject: [PATCH] refine defines of VL53L0 --- Core/Inc/main.h | 6 +++--- STS/TOF/App/app_tof_vl53l0x_range.c | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Core/Inc/main.h b/Core/Inc/main.h index 2061557..17c7802 100644 --- a/Core/Inc/main.h +++ b/Core/Inc/main.h @@ -117,10 +117,10 @@ void Error_Handler(void); #define PME_OFF HAL_GPIO_WritePin(MEMS_POWER_GPIO_Port, MEMS_POWER_Pin, GPIO_PIN_RESET ) #define PME_TOGGLE HAL_GPIO_TogglePin(MEMS_POWER_GPIO_Port, MEMS_POWER_Pin) -#if (defined(TOF_1)||defined(TOF_2)||defined(STS_R1)||defined(STS_R5)||defined(STS_R1D)) -#define VL53L0 1U +#if (defined(TOF_1)||defined(TOF_2)||defined(STS_R1)||defined(STS_R2)||defined(STS_R5)||defined(STS_R1D)||defined(STS_R1x)||defined(STS_R2x)||defined(STS_R5x)) +#define VL53L0 1U #elif (defined(STS_P2)||defined(STS_T6)) -#define VL53LX 1U +#define VL53LX 1U #endif /* DUAL TOF VL53L0 */ diff --git a/STS/TOF/App/app_tof_vl53l0x_range.c b/STS/TOF/App/app_tof_vl53l0x_range.c index e2f3570..c682fed 100644 --- a/STS/TOF/App/app_tof_vl53l0x_range.c +++ b/STS/TOF/App/app_tof_vl53l0x_range.c @@ -29,7 +29,7 @@ #include "sys_app.h" #include "yunhorn_sts_sensors.h" -#if defined(VL53L0)||(VL53L0 == 1) +#if defined(VL53L0) /** * @defgroup Configuration Static configuration * @{