2025-12-29 7:14 AM
Hello,
Can you please share an example code where active tampering is enabled in Standby mode and tamper event (disconnect loop) is used to wake up the MCU.
I would like to know how we can configure the TAMP as a wakeup source during Standby.
If you can show configuration in terms of STM HAL driver that would be great. Let me know if you need more context.
Kind Regards,
2025-12-29 8:27 AM
Hello leonahi,
You can refer to the example in STM32Cube_FW_WBA for tamper initialization at:
STM32Cube_FW_WBA_V1.7.0\Projects\STM32WBA55G-DK1\Examples_LL\RTC\RTC_Tamper_Init
You also need to add the tamper wakeup source configuration and the standby mode entry function as follows:
/* USER CODE BEGIN 2 */
/* @brief Enable the wake up line functionality. PWR_WAKEUP_PIN8_HIGH_3 < TAMP : Wakeup pin 8 (high polarity) */
HAL_PWR_EnableWakeUpPin(PWR_WAKEUP_PIN8_HIGH_3)
/* @brief Enter the whole system to Standby mode.*/
HAL_PWR_EnterSTANDBYMode();
/* USER CODE END 2 */
BRs
2026-01-05 1:59 AM
Thanks for the answer.
One follow-up question:
I enabled two active tampering loops (TAMP_IN1 - TAMP_OUT5 and TAMP_IN6 - TAMP_OUT4) in standby and the measured current is around ~0.35uA, which is something similar to what is mentioned in datasheet for "standby with RTC".
I would like to know whether this behavior is expected when active tamper is enabled? Since TAMP is part of the RTC, I understand that the full RTC module is enabled.
Does this also depend on how many active tamper loops are enabled because I can see similar current irrespective of one or two loops are enabled?
Thanks in advance.