Skip to content

Commit

Permalink
STM32L0 : I2C2 was missing
Browse files Browse the repository at this point in the history
  • Loading branch information
jeromecoutant committed Apr 20, 2022
1 parent decc6d0 commit 271ed68
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions targets/TARGET_STM/TARGET_STM32L0/i2c_device.c
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,11 @@ uint32_t i2c_get_pclk(I2CName i2c)
break;
}
}
#if defined I2C2_BASE
else if (i2c == I2C_2) {
pclk = HAL_RCC_GetPCLK1Freq();
}
#endif
#if defined I2C3_BASE
else if (i2c == I2C_3) {
clocksource = __HAL_RCC_GET_I2C3_SOURCE();
Expand Down

0 comments on commit 271ed68

Please sign in to comment.