Skip to content

Commit 20b9cee

Browse files
committed
library: use register definition instead of serie name
Signed-off-by: Frederic Pillon <[email protected]>
1 parent 1a6cb41 commit 20b9cee

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

libraries/IWatchdog/src/IWatchdog.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ void IWatchdogClass::begin(uint32_t timeout, uint32_t window)
3838
}
3939

4040
// Enable the peripheral clock IWDG
41-
#ifdef STM32WBxx
41+
#ifdef RCC_CSR_LSI1ON
4242
LL_RCC_LSI1_Enable();
4343
while (LL_RCC_LSI1_IsReady() != 1) {
4444
}

libraries/SrcWrapper/src/stm32/clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ void enableClock(sourceClock_t source)
9191

9292
switch (source) {
9393
case LSI_CLOCK:
94-
#ifdef STM32WBxx
94+
#ifdef RCC_FLAG_LSI1RDY
9595
if (__HAL_RCC_GET_FLAG(RCC_FLAG_LSI1RDY) == RESET) {
9696
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_LSI1;
9797
#else

0 commit comments

Comments
 (0)