boards/nucleo: factorize code of the different board types (32 pins, 144 pins)#6705
boards/nucleo: factorize code of the different board types (32 pins, 144 pins)#6705vincent-d merged 8 commits intoRIOT-OS:masterfrom
Conversation
| /* | ||
| * Copyright (C) 2017 Inria | ||
| * 2017 OTA keys | ||
| * Copyright (C) Inria 2017 |
| @@ -1,13 +1,13 @@ | |||
| /* | |||
| * Copyright (C) 2017 Inria | |||
| * Copyright (C) Inria 2017 | |||
|
I like this refactoring 👍 and codewise looks good. Are you planning to include the 64 pin boards (there are many more of these more than of 32/144)? |
| # load the common Makefile.include for Nucleo boards | ||
| include $(RIOTBOARD)/nucleo-common/Makefile.include | ||
| # include nucleo common serial configuration | ||
| include $(RIOTBOARD)/nucleo-common/Makefile.include.serial |
There was a problem hiding this comment.
looking at my changes again, this line is not required as it's already include by indirectly by the line above. I'll update this for others.
| # include nucleo common serial configuration | ||
| include $(RIOTBOARD)/nucleo-common/Makefile.include.serial | ||
|
|
||
| # load the common Makefile.include for Nucleo-32 boards |
There was a problem hiding this comment.
nucleo-144 (auto-review ;) )
|
@lebrush thanks for having a look.
In fact, the 64 pins are taken as reference as they are many more. So I think I'll keep it as it is in this PR. |
|
@lebrush I directly rebased and force push. |
| { | ||
| .name = "B1(User button)", | ||
| .pin = BTN_B1_PIN, | ||
| .mode = GPIO_IN_PU |
There was a problem hiding this comment.
On nucleo144, the pin is pulled-down externally, so it should be either GPIO_IN or GPIO_IN_PD
There was a problem hiding this comment.
Thanks ! I changed it to GPIO_IN_PD
|
Looks like I broke a few things with gpio params, will fix. |
8c1054d to
7b95c71
Compare
|
Rebased on master with #6714 inside. Related boards need to be tested (using saul in examples/default):
|
7b95c71 to
35962bd
Compare
|
Tested nucleo32-f042 and nucleo-f303 : works |
|
I'll test the nucleo144-f207 and nucleo144-f413 by the end of the week if you don't have them. |
|
I have the 207 but not the 413, thanks |
|
nucleo144-f207 works |
35962bd to
62ccabc
Compare
|
examples/default works on nucleo144-f413 (tested saul and rtc) |
|
Works also with nucleo32-f031 and nucleo32-l031. If someone (@vincent-d, @lebrush) could ACK that would be great. |
|
And go! |
|
@vincent-d thanks ! but you forgot to wait for Murdock :) |
|
@aabadie I saw only green on my screen...either a github lag, or my eyes. Sorry! |
|
np @vincent-d, it's just that Murdock is our "official" CI. Check that "Ready for CI build" label is set before pressing the green button ;) |
This PR also adds/fixes Arduino support for nucleo-32 boards.
The serial configuration is shared between the different nucleo board types: 32, 64 and 144 pins.
We can even more factorize : move cpp feature to nucleo-common and share it with nucleo32 and nucleo144. The inheritance tree could also be improved with a common folder for all nucleo types, then a common for each board type (32, 64, 144), this is not what is done here but it can be changed if it makes more sense to the reviewers.