-
Notifications
You must be signed in to change notification settings - Fork 7.5k
boards: nucleo_f103rb: enables I2C_1 and I2C_2 #12246
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now that you enable I2C on the board, could you configure boards arduino connector (uart, spi and i2c)? Check nucleo_f746zg for reference.
@ydamigos, first I'd like to see I2C working on the nucleo board before I look at other board's configurations. Right now, a simple i2c_read lets the system hangs in
(Just learning how to debug with Eclipse...) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Besides activating devices in dts file, you'll need to configure activation in Kconfig.defconfig (cf nucleo_f401re for instance) and configure pinmux as well.
@erwango , thanks for the help - I got I2C working finally. Right now the default assignment is SCL/PB6, SDA/PB7. |
This would make sense.
Theoretically should go in |
Hm. That would add a board dependency to I succeeded remapping the pin to PB8/PB9 by adding If PB8/PB9 are used in I'm struggling to see I know, it's only I2C but zephyr is quite new to me. :-) |
Indeed, we should avoid to make it as a board dependency. I first though it could be done in board pinmux.c func: pinmux_stm32_init.
There are dedicated helper function from STM32Cube SDK that might be handy here, you could check LL_GPIO_AF_EnableRemap_I2C1 for instance. You'll find it in |
Thanks for pointing me to the helper functions, exactly what I was looking for. |
Anything else I can do to for this PR? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Last comments.
Additionally, please rebase on master
Resolves #12243 Signed-off-by: Matthias Wientapper <[email protected]>
Resolves #12243 Signed-off-by: Matthias Wientapper <[email protected]>
Resolves #12243 Signed-off-by: Matthias Wientapper <[email protected]>
Resolves #12243 Signed-off-by: Matthias Wientapper <[email protected]>
Resolves #12243 Signed-off-by: Matthias Wientapper <[email protected]>
@mattzzw , sorry this PR has been left unreviewed for a (long) while. |
Any plans to update? |
Resolves #12243
Signed-off-by: Matthias Wientapper [email protected]