Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -70,12 +70,20 @@ void LINKLAYER_PLAT_ClockInit(void)
AHB5_SwitchedOff = 0;
radio_sleep_timer_val = 0;

#ifdef __ZEPHYR__
LINKLAYER_PLAT_EnableBackupDomainAccess();
#else
LL_PWR_EnableBkUpAccess();
#endif

/* Select LSE as Sleep CLK */
__HAL_RCC_RADIOSLPTIM_CONFIG(RCC_RADIOSTCLKSOURCE_LSE);

#ifdef __ZEPHYR__
LINKLAYER_PLAT_DisableBackupDomainAccess();
#else
LL_PWR_DisableBkUpAccess();
#endif

/* Enable AHB5ENR peripheral clock (bus CLK) */
__HAL_RCC_RADIO_CLK_ENABLE();
Expand Down
16 changes: 16 additions & 0 deletions lib/stm32wba/STM32_WPAN/link_layer/ll_sys/inc/linklayer_plat.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,22 @@
*/
extern void LINKLAYER_PLAT_ClockInit(void);

#ifdef __ZEPHYR__
/**
* @brief Enable access to backup domain resources
* @param None
* @retval None
*/
extern void LINKLAYER_PLAT_EnableBackupDomainAccess(void);

/**
* @brief Disable access to backup domain resources
* @param None
* @retval None
*/
extern void LINKLAYER_PLAT_DisableBackupDomainAccess(void);
#endif /* __ZEPHYR__ */

/**
* @brief Link Layer active waiting loop.
* @param delay: delay in us
Expand Down