From 1b23ca28f0fff8c70631859a9f1fc42b9ad75a54 Mon Sep 17 00:00:00 2001 From: YunHorn Technology Date: Sat, 13 Apr 2024 22:21:04 +0800 Subject: [PATCH] minor --- Core/Src/main.c | 5 ++++- Core/Src/sts_lamp_bar.c | 4 ++-- LoRaWAN/App/lora_app.c | 6 +++--- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/Core/Src/main.c b/Core/Src/main.c index 85a96d4..9c671ef 100644 --- a/Core/Src/main.c +++ b/Core/Src/main.c @@ -101,10 +101,13 @@ int main(void) /* Initialize all configured peripherals */ MX_LoRaWAN_Init(); - /* USER CODE BEGIN 2 */ STS_Lamp_Bar_Self_Test_Simple(); + /* USER CODE BEGIN 2 */ + + + /* USER CODE END 2 */ /* Infinite loop */ diff --git a/Core/Src/sts_lamp_bar.c b/Core/Src/sts_lamp_bar.c index 8978106..a73e64d 100644 --- a/Core/Src/sts_lamp_bar.c +++ b/Core/Src/sts_lamp_bar.c @@ -102,7 +102,7 @@ void STS_YunhornSTSEventP1_Process(void) void STS_YunhornSTSEventP2_Process(void) { - //STS_Lamp_Bar_Refresh(); //TODO XXX eliminate refresh every second.... try + STS_Lamp_Bar_Refresh(); //TODO XXX eliminate refresh every second.... try if ((sts_work_mode >= STS_RSS_MODE) && (sts_work_mode <= STS_TOF_RSS_MODE)) { STS_RSS_Smart_Presence_Detection(); @@ -563,7 +563,7 @@ void STS_Lamp_Bar_Self_Test_Simple(void) do { STS_Lamp_Bar_Set_STS_RGB_Color(color, luminance_level); HAL_Delay(50); - luminance_level += 20; + luminance_level += 10; } while (luminance_level < 99); //STS_Lamp_Bar_Set_Dark(); } diff --git a/LoRaWAN/App/lora_app.c b/LoRaWAN/App/lora_app.c index 1d2a569..ea5de6c 100644 --- a/LoRaWAN/App/lora_app.c +++ b/LoRaWAN/App/lora_app.c @@ -600,8 +600,8 @@ void HAL_GPIO_EXTI_Callback(uint16_t GPIO_Pin) switch (GPIO_Pin) { case BUT1_Pin: -#if defined(USE_STM32WL55) - //sts_reed_hall_ext_int = 1; + + sts_reed_hall_ext_int = 1; UTIL_SEQ_SetTask((1 << CFG_SEQ_Task_YunhornSTSEventP1), CFG_SEQ_Prio_0); //sts_reed_hall_ext_int = 0; /* Note: when "EventType == TX_ON_TIMER" this GPIO is not initialized */ @@ -609,7 +609,7 @@ void HAL_GPIO_EXTI_Callback(uint16_t GPIO_Pin) { UTIL_SEQ_SetTask((1 << CFG_SEQ_Task_LoRaSendOnTxTimerOrButtonEvent), CFG_SEQ_Prio_0); } -#endif + break; case BUT2_Pin: