-
Notifications
You must be signed in to change notification settings - Fork 2k
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
boards/stm32-based: use shared configuration snippets #8549
boards/stm32-based: use shared configuration snippets #8549
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.
I like the idea! And it looks quite good except the missing include. I unfortunately don't have any of theses board to test it.
@@ -22,42 +22,12 @@ | |||
#define PERIPH_CONF_H | |||
|
|||
#include "periph_cpu.h" | |||
#include "f4/cfg_clock_168_8_1.h" |
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.
missing #include "cfg_spi_divtable.h"
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.
ups, will fix
fixed missing include |
also fixed header guards |
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.
Untested ACK (I don't have any of these boards). Please squash
c54c43e
to
b7fbecf
Compare
rebased |
and squashed... |
* @author Hauke Petersen <[email protected]> | ||
*/ | ||
|
||
#ifndef PERIPH_CFG_SPI_DIVTABLE_H |
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.
This header guard is still wrong according to Murdock
b7fbecf
to
079f3c0
Compare
fixed the header guard issue (squashed right in) and rebased. |
@vincent-d would you mind to give this one last look and press the big green button?! Thanks! |
It may introduces some conflicts with the I2C refactoring. @aabadie will be able to confirm it better than me. |
I don't know, it needs to be confirmed locally first I would say. |
Let's go then :) |
Contribution description
This is another change cut from #8044 to reduce the vast code duplication in the (STM32) board configurations.
Presented in this PR in my idea for using shared configuration snippets in the board's
periph_conf.h
files. This is demonstrated so far only for some selectedstm32f4
-based boards, and focused on their clock configuration only. Once we agree for this approach, we can optimize the configuration for more STM32-based boards, in small, easily revieweable steps...Issues/PRs references
continuation of merging #8044 in small steps...